E

extension-email

by @caffeinelabsv
4.6(120)

This skill enables sending service and transactional emails directly from the backend canister. It provides a streamlined interface for developers to easily integrate email sending capabilities, ensuring critical information like order confirmations, password resets, and notifications reaches users promptly. This enhances user experience and system reliability by automating essential communication workflows and reducing the complexity of external email service interactions.

email-sendingtransactional-emailbackend-servicenotificationsautomationGitHub
Installation
npx skills add https://github.com/caffeinelabs/skills --skill extension-email
compare_arrows

Before / After Comparison

1 组
Before

Before this skill, developers had to manually integrate third-party email services, writing extensive code for API calls, error handling, and recipient management. This was time-consuming and prone to errors, delaying feature deployment.

After

This Skill provides a concise interface, allowing developers to send service emails with a single function call. This significantly simplifies the integration process, reduces development effort and potential errors, and accelerates feature deployment.

SKILL.md

Email — Service/Transactional

Service/transactional email extension for Caffeine AI.

Overview

This skill adds support for sending service and transactional emails from the backend canister. Use sendServiceEmail for order confirmations, notifications, and similar one-off emails.

Backend

This component is for sending service/transactional emails.

There is the prefabricated module mo:caffeineai-email/emailClient.mo which cannot be modified.

  • Use the sendServiceEmail function.
  • Each recipient is sent an individual email
  • It returns a SendResult which is #ok if the email is sent successfully otherwise #err(error) with the error text.
module {
  public type SendResult = {
    #ok;
    #err : Text;
  };

  public func sendServiceEmail(
    fromUsername : Text,
    recipients : [Text],
    subject : Text,
    htmlBody : Text,
  ) : async SendResult;
};

Usage for sendServiceEmail:

import Runtime "mo:core/Runtime";
import EmailClient "mo:caffeineai-email/emailClient";

actor {
  public func sendOrderConfirmationEmail(recipientEmailAddress : Text, username : Text, orderReference : Text) : async () {
    let result = await EmailClient.sendServiceEmail(
      "no-reply",
      [recipientEmailAddress],
      "Order " # orderReference # " confirmed",
      "Hello " # username # ",\nYour order " # orderReference # " has been confirmed. Your items will ship tomorrow.",
    );
    switch (result) {
      case (#ok) {};
      case (#err(error)) {
        Runtime.trap("Failed to send order confirmation email: " # error);
      };
    };
  };
};

User Reviews (0)

Write a Review

Effect
Usability
Docs
Compatibility

No reviews yet

Statistics

Installs27.7K
Rating4.6 / 5.0
Version
Updated2026年10月24日
Comparisons1

User Rating

4.6(120)
5
37%
4
43%
3
13%
2
5%
1
2%

Rate this Skill

0.0

Compatible Platforms

🤖claude-code

Timeline

Created2026年6月25日
Last Updated2026年10月24日
🎁 Agent Knowledge Cards
Survey