createMailActions (imap-smtp/actions.ts)

open-connector · src/mail/imap-smtp/actions.ts · typescript · Apache-2.0
email

Factory function that creates IMAP/SMTP mail actions with comprehensive JSON schemas.

// Source: https://github.com/oomol-lab/open-connector | License: Apache-2.0 | Copyright You must retain, in the Source form of any Derivative Works
// Provided via justclaw.it.com; keep this notice with the code.
import type { ProviderActionDefinition } from "../../core/provider-definition.ts";
import type { JsonSchema } from "../../core/types.ts";

import { s } from "../../core/json-schema.ts";
import { defineProviderAction } from "../../core/provider-definition.ts";

export type MailActionName =
  | "send_email"
  | "list_folders"
  | "search_emails"
  | "get_email"
  | "download_attachment"
  | "mark_email_read"
  | "mark_email_unread"
  | "move_email"
  | "delete_email"
  | "get_folder_status"
  | "reply_email"
  | "forward_email";

export function createMailActions<const TService ext

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key