Creates personalized, clickable UI actions to automate email tasks.

Install

mkdir -p .claude/skills/action-creator && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/2050" && unzip -o skill.zip -d .claude/skills/action-creator && rm skill.zip

Installs to .claude/skills/action-creator

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

Creates user-specific one-click action templates that execute email operations when clicked in the chat interface. Use when user wants reusable actions for their specific workflows (send payment reminder to ACME Corp, forward bugs to engineering, archive old newsletters from specific sources).
294 chars✓ has a “when” triggerlonger than Claude Code's old 250-char listing cap (fine on current versions)
Intermediate

Key capabilities

  • Generate TypeScript action handler files
  • Define configuration and metadata for UI buttons
  • Bind email operation parameters to user context
  • Configure event-based or manual triggers

How it works

Scaffolds standardized TypeScript classes that interface with a chat UI button registry.

Inputs & outputs

You give it
Workflow description and target email operation
You get back
Custom TypeScript action template

When to use action-creator

  • Automate payment reminders
  • Create custom email forwarding buttons
  • Workflow triggers for repetitive emailing

About this skill

Action Creator

Creates TypeScript action template files that define reusable, user-specific operations users can execute with one click in the chat interface.

When to Use This Skill

Use this skill when the user wants to:

  • Create reusable actions for their specific workflows ("I often need to send payment reminders to ACME Corp")
  • Set up one-click operations for their vendors/customers ("Forward bugs to engineering team")
  • Automate repetitive email tasks with their specific context ("Archive newsletters from TechCrunch/Morning Brew")
  • Build personalized email management tools for their business processes

Key difference from listeners: Actions are user-triggered (clicked in chat), while listeners are event-triggered (automatic).

How Actions Work

Actions are TypeScript files in agent/custom_scripts/actions/ that:

  1. Export a config object defining the template metadata and parameter schema
  2. Export a handler function that executes the operation with given parameters
  3. Use ActionContext methods to perform operations (email API, send emails, call AI, etc.)

The agent creates action instances during conversation by providing specific parameters to these templates, which appear as clickable buttons in the chat.

Creating an Action Template

1. Understand User-Specific Workflow

Parse the user's request to identify:

  • User context: Who are their specific vendors/customers/teams?
  • Operation: What specific action do they need? (send to ACME Corp, forward to engineering team, etc.)
  • Parameters: What varies per execution? (invoice number, priority level, days old)
  • Frequency: How often will they use this?

2. Write the Action Template File

Create a file in agent/custom_scripts/actions/ with this structure:

import type { ActionTemplate, ActionContext, ActionResult } from "../types";

export const config: ActionTemplate = {
  id: "unique_action_id",                    // kebab-case, user-specific
  name: "Human Readable Name",                // For UI display
  description: "What this action does",       // Explain the operation
  icon: "📨",                                 // Optional emoji icon
  parameterSchema: {
    type: "object",
    properties: {
      paramName: {
        type: "string",                      // or "number", "boolean"
        description: "Parameter description",
        enum: ["option1", "option2"],        // Optional: restrict values
        default: "defaultValue"              // Optional: default value
      }
    },
    required: ["paramName"]                  // List required parameters
  }
};

export async function handler(
  params: Record<string, any>,
  context: ActionContext
): Promise<ActionResult> {
  const { paramName } = params;

  context.log(`Starting action: ${config.name}`);

  try {
    // 1. Perform operations using context methods
    // 2. Use AI for intelligent processing if needed
    // 3. Update emails, send emails, etc.

    context.notify("Action completed successfully", {
      type: "success",
      priority: "normal"
    });

    return {
      success: true,
      message: "Action completed successfully",
      data: { /* optional structured data */ },
      refreshInbox: true  // Optional: refresh inbox after action
    };
  } catch (error: any) {
    context.log(`Action failed: ${error}`, "error");
    return {
      success: false,
      message: `Failed: ${error.message}`
    };
  }
}

3. File Naming Convention

Use kebab-case that reflects the user-specific operation:

  • send-payment-reminder-to-acme.ts (not send-email.ts)
  • forward-bugs-to-engineering.ts (not forward-email.ts)
  • archive-newsletters-from-techcrunch.ts (not archive-emails.ts)
  • summarize-weekly-updates-from-ceo.ts (not summarize-emails.ts)

Important: Templates should be specific to the user's actual workflows, vendors, teams, and processes.

4. Available Context Methods

The ActionContext provides these capabilities:

// Email API operations
const emails = await context.emailAPI.getInbox({ limit: 30, includeRead: false });
const results = await context.emailAPI.searchEmails({ from: "[email protected]" });
const results = await context.emailAPI.searchWithGmailQuery("from:sender after:2024/01/01");
const emails = await context.emailAPI.getEmailsByIds(["id1", "id2"]);
const email = await context.emailAPI.getEmailById("email-id");

// Direct email operations
await context.archiveEmail(emailId);
await context.starEmail(emailId);
await context.unstarEmail(emailId);
await context.markAsRead(emailId);
await context.markAsUnread(emailId);
await context.addLabel(emailId, "label-name");
await context.removeLabel(emailId, "label-name");

// Send emails
const result = await context.sendEmail({
  to: "[email protected]",
  subject: "Email subject",
  body: "Email body content",
  cc: "[email protected]",           // Optional
  bcc: "[email protected]",          // Optional
  replyTo: "[email protected]"     // Optional
});

// AI-powered processing
const analysis = await context.callAgent<ResultType>({
  prompt: "Analyze this email and extract key info...",
  systemPrompt: "You are an expert at...",  // Optional
  tools: ["Read", "WebSearch"],              // Optional
  maxTokens: 2000                            // Optional
});

// Session messaging (inject into chat)
context.addUserMessage("User said this");
context.addAssistantMessage("Assistant responds");
context.addSystemMessage("System notification");

// Notifications
context.notify("Operation completed", {
  priority: "high" | "normal" | "low",
  type: "info" | "success" | "warning" | "error"
});

// External API access
const response = await context.fetch("https://api.example.com/data");
const data = await response.json();

// Logging (visible in server logs)
context.log("Info message", "info");
context.log("Warning message", "warn");
context.log("Error message", "error");

Action Result

Always return an ActionResult object:

return {
  success: true,                          // Required: boolean
  message: "Human-readable result",       // Required: string
  data: { key: "value" },                // Optional: structured data
  suggestedActions: [],                   // Optional: follow-up actions
  refreshInbox: true                      // Optional: refresh inbox
};

Examples and Templates

Reference the template files for common patterns:

Best Practices

  1. User-Specific Templates: Create templates tailored to user's actual vendors, customers, teams, and processes
  2. Descriptive Naming: Use specific names that reflect the operation (not generic like "send-email")
  3. Rich Parameter Schemas: Define clear parameter types with descriptions
  4. AI-Powered: Use context.callAgent() for intelligent processing
  5. Error Handling: Always wrap operations in try-catch and return meaningful errors
  6. Clear Messages: Return human-readable success/failure messages
  7. Idempotency: Design handlers to be safely re-runnable when possible
  8. Logging: Use context.log() for debugging and audit trail

Parameter Schema Guidelines

Define parameters using JSON Schema:

parameterSchema: {
  type: "object",
  properties: {
    // String parameter
    emailId: {
      type: "string",
      description: "Email ID to process"
    },

    // Number parameter with default
    daysOld: {
      type: "number",
      description: "Number of days old",
      default: 30
    },

    // Enum parameter (dropdown)
    priority: {
      type: "string",
      description: "Priority level",
      enum: ["P0 - Critical", "P1 - High", "P2 - Medium", "P3 - Low"]
    },

    // Boolean parameter
    sendNotification: {
      type: "boolean",
      description: "Send notification when complete"
    }
  },
  required: ["emailId", "priority"]  // List required params
}

Creating the File

When the user requests an action template:

  1. Clarify user-specific context:

    • Who are their vendors/customers/teams?
    • What are their specific workflows?
    • What parameters vary per execution?
  2. Write the TypeScript file in agent/custom_scripts/actions/

  3. Use Write tool to create the file with:

    • Proper imports from "../types"
    • User-specific config (not generic)
    • Parameter schema with all required fields
    • Handler with error handling
    • Clear success/failure messages
  4. Test parameters: Ensure all required parameters are defined

  5. Confirm with user that the action matches their workflow

Common Patterns

1. Send Email to Specific Recipient

User-specific → Compose email with template → Send → Return result

const body = `Hi ${recipientName},
Your invoice ${invoiceNumber} for ${amount} is ${daysPastDue} days past due...`;

await context.sendEmail({
  to: "[email protected]",
  subject: `Payment Reminder: Invoice ${invoiceNumber}`,
  body
});

2. Bulk Email Operation

Search emails → Filter → Apply operation to each → Return count

const emails = await context.emailAPI.searchWithGmailQuery(query);
for (const email of emails) {
  await context.archiveEmail(email.messageId);
}
return { success: true, message: `Archived ${emails.length} emails` };

3. AI-Powered Email Processing

Get email → Call AI to analyze → Use AI result → Take action → Return summary

const email = await context.emailAPI.getEmailById(emailId);
const analysis = await context.callAgent({
  prompt: `Analyze this bug report: ${email.body}...`,
  maxTokens: 

---

*Content truncated.*

When not to use it

  • Building backend server API endpoints
  • Creating non-email related automation tasks

Prerequisites

Access to ActionContext

Limitations

  • Requires predefined email API access
  • Actions must follow the existing registry structure

How it compares

Produces persistent, clickable interface components rather than transient script runs.

Compared to similar skills

action-creator side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
action-creator (this skill)29moNo flagsIntermediate
listener-creator29moNo flagsIntermediate
klaviyo14moReviewIntermediate
zapier-workflows118moReviewBeginner

Try saying

Example prompts that trigger this skill in your AI assistant.

More by anthropics

View all by anthropics

frontend-design

anthropics

Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.

481544

pptx

anthropics

Presentation creation, editing, and analysis. When Claude needs to work with presentations (.pptx files) for: (1) Creating new presentations, (2) Modifying or editing content, (3) Working with layouts, (4) Adding comments or speaker notes, or any other presentation tasks

393763

webapp-testing

anthropics

Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.

353585

mcp-builder

anthropics

Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK).

136215

skill-creator

anthropics

Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Claude's capabilities with specialized knowledge, workflows, or tool integrations.

128200

docx

anthropics

Comprehensive document creation, editing, and analysis with support for tracked changes, comments, formatting preservation, and text extraction. When Claude needs to work with professional documents (.docx files) for: (1) Creating new documents, (2) Modifying or editing content, (3) Working with tracked changes, (4) Adding comments, or any other document tasks

93225

You might also like

listener-creator

anthropics

Creates event-driven email listeners that monitor for specific conditions (like urgent emails from boss, newsletters to archive, package tracking) and execute custom actions. Use when user wants to be notified about emails, automatically handle certain emails, or set up email automation workflows.

212

klaviyo

alinaqi

Klaviyo email/SMS marketing - profiles, events, flows, segmentation

10

zapier-workflows

davila7

Manage and trigger pre-built Zapier workflows and MCP tool orchestration. Use when user mentions workflows, Zaps, automations, daily digest, research, search, lead tracking, expenses, or asks to "run" any process. Also handles Perplexity-based research and Google Sheets data tracking.

11101

automation-brainstorm

MacroMan5

Interactive workflow design advisor for Power Automate, n8n, Make, Zapier and other platforms. Guides users through planning automation workflows with smart questions about triggers, actions, data flow, and error handling. Uses research sub-agent to find best practices and generates detailed implementation plan. Triggers when user mentions "create workflow", "build flow", "design automation", "need ideas for", or describes workflow requirements without having a complete design.

778

connect-apps

ComposioHQ

Connect Claude to external apps like Gmail, Slack, GitHub. Use this skill when the user wants to send emails, create issues, post messages, or take actions in external services.

647

agent-workflow

ruvnet

Agent skill for workflow - invoke with $agent-workflow

436

Search skills

Search the agent skills registry