MCPサーバー

email

dev.primitive/email
コミュニケーション 公開・接続可能 MCP 2026-07-28

このMCPでできること

Provides managed email infrastructure for sending, receiving, searching, replying to, scheduling, and processing email and webhook deliveries.

addDomain
Add domain
Claim a new domain and receive the DNS records to publish. Returns dns_records with the exact records to add. If the domain has an mx_conflict (existing mail provider), re-call with confirmed: true to proceed. After publishing DNS records, call verifyDomain to complete setup.
入力スキーマ
{'type': 'object', 'required': ['requestBody'], 'properties': {'requestBody': {'type': 'object', 'required': ['domain'], 'properties': {'domain': {'type': 'string', 'maxLength': 253, 'minLength': 1, 'description': 'The domain name to claim (e.g. "example.com").'}, 'confirmed': {'type': 'boolean', 'description': 'Set to true to confirm replacing an existing mailbox provider after an mx_conflict response.'}}, 'additionalProperties': False}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
awaitReply
Await reply
Wait for the threaded reply to a sent email. Call this immediately after sendEmail or replyToEmail when you expect an answer. With only the sent email's id it long-polls for up to 30 seconds by default. Do not report that nobody replied or ask the user to check later until this call returns with no reply. Set wait=false only for a deliberate immediate poll. Matching uses reply threading, not a sender or subject guess.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'The sent email id to fetch the reply for (from a sendEmail/replyToEmail response).'}, 'wait': {'type': 'boolean', 'default': True, 'description': 'When true, long-poll until a reply arrives or wait_timeout_ms elapses. Defaults to true. Set false only for a single immediate poll.'}, 'api_key': {'type': 'string', 'maxLength': 200, 'minLength': 8, 'description': 'Primitive API key (prim_...). Only needed when this connection has no signed-in account: pass the api_key returned by createEmailAddress, unchanged, on every call for the rest of the conversation. Omit it when the user is signed in.'}, 'wait_timeout_ms': {'type': 'number', 'default': 30000, 'maximum': 30000, 'minimum': 1000, 'description': 'How long to wait when wait=true (1000 to 30000 ms). Defaults to 30000.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
cancelScheduledSend
Cancel scheduled send
Cancel a still-scheduled send before it dispatches (terminal status "canceled"; the same idempotency key becomes reusable). Pass the sent email id from a sendEmail response that used scheduled_at, or from listSentEmails. Returns a conflict error once the send has already started dispatching.
破壊的操作あり
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Sent email ID of the scheduled send, from a sendEmail response or listSentEmails.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
createEmailAddress
Get a managed email domain (no signup)
Get this user's Primitive managed inbox domain, creating the account on first use: no signup form, no password, no email verification, no browser. CALL THIS FIRST whenever you do not already have a Primitive API key and the user wants to send or receive email, instead of telling them to sign up or visit a website. On first use the REST response's address field is a domain such as pink-ram.primitive.email, not a complete mailbox. When it is non-null, this MCP result also includes sender_address such as agent@pink-ram.primitive.email for use as sendEmail.requestBody.from. It also returns an api_key. IMPORTANT: pass that api_key as the `api_key` argument on every later Primitive tool call in this conversation, exactly as returned; those calls fail without it. If this user already has a domain, the result repeats it with existing_account: true. Report it as their existing managed inbox rather than announcing a new one, and calling again will not produce a different one. The result also carries an upgrade link the user can open whenever they want to attach this domain to a full account.
入力スキーマ
{'type': 'object', 'required': ['requestBody'], 'properties': {'requestBody': {'type': 'object', 'required': ['terms_accepted'], 'properties': {'device_name': {'type': 'string', 'description': 'Optional label for where the account was created, e.g. "ChatGPT". Up to 80 characters once surrounding whitespace is removed. Shown to the user later so they can recognise this account.'}, 'terms_accepted': {'const': True, 'description': "Must be true. Creating the account accepts Primitive's terms of service (https://www.primitive.dev/terms); say so to the user rather than accepting silently on their behalf."}}, 'additionalProperties': False}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
createEndpoint
Create webhook endpoint
Create a webhook endpoint to receive email.received events. If an endpoint with the same URL already exists but is deactivated, it is reactivated. After creating, call testEndpoint to confirm your signature verifier accepts the payload.
入力スキーマ
{'type': 'object', 'required': ['requestBody'], 'properties': {'requestBody': {'type': 'object', 'required': ['url'], 'properties': {'url': {'type': 'string', 'minLength': 1, 'description': 'The webhook URL to deliver events to.'}, 'rules': {'type': 'object', 'description': 'Endpoint-specific filtering rules.', 'additionalProperties': True}, 'enabled': {'type': 'boolean', 'default': True, 'description': 'Whether the endpoint should receive deliveries immediately after creation (default true).'}, 'domain_id': {'type': 'string', 'format': 'uuid', 'description': 'Restrict deliveries to emails from a specific domain. Omit to receive events for all domains.'}}, 'additionalProperties': False}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
createFilter
Create filter
Create a whitelist or blocklist filter rule. Patterns are stored lowercase. Per-domain filters require a Pro plan.
入力スキーマ
{'type': 'object', 'required': ['requestBody'], 'properties': {'requestBody': {'type': 'object', 'required': ['type', 'pattern'], 'properties': {'type': {'enum': ['whitelist', 'blocklist'], 'type': 'string', 'description': 'Whether to allow (whitelist) or block (blocklist) matching senders.'}, 'pattern': {'type': 'string', 'maxLength': 500, 'minLength': 1, 'description': 'Email address or pattern to filter.'}, 'domain_id': {'type': 'string', 'format': 'uuid', 'description': 'Restrict to a specific domain (Pro plan required). Omit for org-wide filter.'}}, 'additionalProperties': False}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
deleteEndpoint
Delete webhook endpoint
Soft-delete a webhook endpoint. The endpoint will no longer receive deliveries.
破壊的操作あり
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Endpoint ID from listEndpoints or createEndpoint.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
deleteFilter
Delete filter
Delete a filter rule.
破壊的操作あり
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Filter rule ID from listFilters or createFilter.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
downloadDomainZoneFile
Download DNS zone file
Download a BIND-format DNS zone file for a domain. Useful when users want to import all required DNS records at once rather than copying them individually. Returns plain text in BIND zone file format.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Domain ID from listDomains or addDomain.'}, 'outbound_only': {'type': 'boolean', 'description': 'When true, include only outbound DNS records (SPF, DKIM, DMARC). Defaults to all records for unverified domains, outbound-only for verified.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
downloadEmailAttachments
Download email attachments
Download all attachments for an inbound email as a gzip-compressed tar archive. Returns the archive as a base64-encoded string along with the attachment count and SHA-256 digest. Prefer getEmail first to check the attachment manifest before downloading.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Inbound email ID.'}, 'token': {'type': 'string', 'description': 'Signed download token from a webhook payload. Optional — the bearer token is used when this is omitted.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
getAccount
Get account
Use this when you need the authenticated Primitive account summary, including plan, onboarding state, and managed inbox domain. managed_inbox_address is a domain, not a complete mailbox. When it is non-null, this MCP result also includes sender_address, such as agent@pink-ram.primitive.email, for use as sendEmail.requestBody.from.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': [], 'properties': {'api_key': {'type': 'string', 'maxLength': 200, 'minLength': 8, 'description': 'Primitive API key (prim_...). Only needed when this connection has no signed-in account: pass the api_key returned by createEmailAddress, unchanged, on every call for the rest of the conversation. Omit it when the user is signed in.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
getConversation
Get conversation
Get the full conversation an inbound email belongs to as ordered, chat-model-ready turns with bodies. Each message is oldest-first with a direction (inbound/outbound) and a derived role (inbound→user, outbound→assistant). For a brand-new message, returns just that one turn. The response includes a truncated boolean (true when the message cap was reached) and a message_count field.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'ID of any inbound email in the conversation.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
getEmail
Get email
Use this when you need full details for one inbound email ID, including parsed bodies, threading metadata, SMTP envelope, webhook state, and replies.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Inbound email ID from listEmails or searchEmails.'}, 'api_key': {'type': 'string', 'maxLength': 200, 'minLength': 8, 'description': 'Primitive API key (prim_...). Only needed when this connection has no signed-in account: pass the api_key returned by createEmailAddress, unchanged, on every call for the rest of the conversation. Omit it when the user is signed in.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
getInboxStatus
Get inbox status
Use this when the user asks whether inbound email is ready or needs setup. Returns domains, routes, deployed Functions, and recent inbound activity.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': [], 'properties': {'api_key': {'type': 'string', 'maxLength': 200, 'minLength': 8, 'description': 'Primitive API key (prim_...). Only needed when this connection has no signed-in account: pass the api_key returned by createEmailAddress, unchanged, on every call for the rest of the conversation. Omit it when the user is signed in.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
getOutboundStatus
Get outbound status
What can I send FROM? Lists this account's verified outbound (sendable) domains plus any domains still pending DNS verification, with next actions. Call this BEFORE sendEmail to pick a valid `from` domain — the account email is not necessarily sendable. The same sendable list is echoed in a cannot_send_from_domain error.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': [], 'properties': {}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
getSentEmail
Get sent email
Get the full record for a single sent email by id, including body_text and body_html. Use to inspect delivery details for a specific send — e.g. the SMTP response on a bounced row, or the gate denial reason on a gate_denied row.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Sent email ID from listSentEmails or a /send-mail response.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
getThread
Get thread
Get a conversation thread by id: metadata plus all inbound and outbound messages interleaved oldest-first. Each message has a direction (inbound/outbound) and id; fetch inbound message bodies via getEmail, or outbound bodies via getSentEmail. Discover thread_id from any email or sent-email record. Compare message_count against messages.length to detect truncation.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Thread ID from the thread_id field on any email or sent-email.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
listDomains
List domains
List all inbound domains for the organization, both verified and unverified. Each domain includes its verification status and DNS records. Use before addDomain to check whether a domain is already claimed.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'properties': {}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
listEmails
List inbound emails
Use this when you need to browse inbound emails received at verified domains with cursor pagination, status filters, date filters, or sender/recipient search.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'properties': {'wait': {'type': 'number', 'default': 0, 'maximum': 30, 'minimum': 0, 'description': 'Long-poll up to this many seconds (0–30, default 0) holding the request for new mail instead of returning an empty page immediately. Requires `since`. Returns as soon as matching mail arrives, or an empty page when the wait elapses.'}, 'limit': {'type': 'number', 'default': 50, 'maximum': 100, 'minimum': 1, 'description': 'Maximum number of emails to return (1–100, default 50).'}, 'since': {'type': 'string', 'description': 'Forward-tail cursor (a `meta.cursor` value, format `{ISO datetime}|{UUID}`): returns emails strictly NEWER than this position, oldest-first, for lossless polling of just-arrived mail. Mutually exclusive with `cursor`.'}, 'cursor': {'type': 'string', 'description': "Backward (history) pagination cursor from a previous response's `meta.cursor` field: returns emails OLDER than this position, newest-first. Mutually exclusive with `since`."}, 'search': {'type': 'string', 'maxLength': 500, 'description': 'Free-text search across sender, recipient, and subject.'}, 'status': {'enum': ['pending', 'accepted', 'completed', 'rejected'], 'type': 'string', 'description': 'Filter to emails in this processing status.'}, 'api_key': {'type': 'string', 'maxLength': 200, 'minLength': 8, 'description': 'Primitive API key (prim_...). Only needed when this connection has no signed-in account: pass the api_key returned by createEmailAddress, unchanged, on every call for the rest of the conversation. Omit it when the user is signed in.'}, 'date_to': {'type': 'string', 'format': 'date-time', 'description': 'Inclusive upper bound on created_at (ISO 8601).'}, 'date_from': {'type': 'string', 'format': 'date-time', 'description': 'Inclusive lower bound on created_at (ISO 8601).'}, 'domain_id': {'type': 'string', 'format': 'uuid', 'description': 'Filter to emails received on a specific verified domain.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
listEndpoints
List webhook endpoints
List all active webhook endpoints for the organization. Each endpoint shows its URL, enabled state, and optional domain restriction.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'properties': {}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
listFilters
List filters
List all whitelist and blocklist filter rules for the organization.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'properties': {}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
listSentEmails
List sent emails
List outbound emails sent by this org, with cursor pagination and filters. Bodies are omitted from list rows to keep responses small — use getSentEmail to fetch a specific row with full body. Useful for auditing delivery status, finding bounced sends, or checking gate-denied attempts.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'properties': {'limit': {'type': 'number', 'default': 50, 'maximum': 100, 'minimum': 1, 'description': 'Maximum number of sent emails to return (1–100, default 50).'}, 'cursor': {'type': 'string', 'description': "Pagination cursor from a previous response's `meta.cursor` field."}, 'status': {'enum': ['queued', 'submitted_to_agent', 'agent_failed', 'gate_denied', 'unknown', 'delivered', 'bounced', 'deferred', 'wait_timeout', 'scheduled', 'canceled'], 'type': 'string', 'description': 'Filter to rows in this status. Use "scheduled" to find pending scheduled sends (cancelable via cancelScheduledSend) and "canceled" for ones already canceled.'}, 'date_to': {'type': 'string', 'format': 'date-time', 'description': 'Inclusive upper bound on created_at (ISO 8601).'}, 'date_from': {'type': 'string', 'format': 'date-time', 'description': 'Inclusive lower bound on created_at (ISO 8601).'}, 'request_id': {'type': 'string', 'format': 'uuid', 'description': 'Filter to the row matching a specific server-issued request_id from a /send-mail response.'}, 'idempotency_key': {'type': 'string', 'maxLength': 255, 'minLength': 1, 'description': 'Filter to rows with the given client idempotency key.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
listWebhookDeliveries
List webhook deliveries
List webhook delivery attempts with pagination and filters. Each delivery includes the target endpoint and a nested email object with sender/recipient/subject. Useful for diagnosing delivery failures or confirming a specific email was delivered.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'properties': {'limit': {'type': 'number', 'default': 50, 'maximum': 100, 'minimum': 1, 'description': 'Maximum number of delivery records to return (1–100, default 50).'}, 'cursor': {'type': 'string', 'description': "Pagination cursor from a previous response's `meta.cursor` field."}, 'status': {'enum': ['pending', 'delivered', 'header_confirmed', 'failed'], 'type': 'string', 'description': 'Filter to deliveries in this status.'}, 'date_to': {'type': 'string', 'format': 'date-time', 'description': 'Inclusive upper bound on attempted_at (ISO 8601).'}, 'email_id': {'type': 'string', 'format': 'uuid', 'description': 'Filter by inbound email ID.'}, 'date_from': {'type': 'string', 'format': 'date-time', 'description': 'Inclusive lower bound on attempted_at (ISO 8601).'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
replayWebhookDelivery
Replay webhook delivery
Re-send a stored webhook payload from a previous delivery attempt to its original endpoint. Rate limited per org (burst + sustained windows, shared budget with email webhook replays).
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'description': 'Delivery ID (numeric string from listWebhookDeliveries).'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
replyToEmail
Reply to email
Use this when the user has selected a specific inbound email and confirmed a reply. Sends real outbound email with threading handled server-side.
破壊的操作あり 外部アクセスあり
入力スキーマ
{'type': 'object', 'required': ['id', 'requestBody'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Inbound email ID to reply to. Threading headers are set server-side.'}, 'api_key': {'type': 'string', 'maxLength': 200, 'minLength': 8, 'description': 'Primitive API key (prim_...). Only needed when this connection has no signed-in account: pass the api_key returned by createEmailAddress, unchanged, on every call for the rest of the conversation. Omit it when the user is signed in.'}, 'requestBody': {'type': 'object', 'properties': {'from': {'type': 'string', 'maxLength': 998, 'minLength': 3, 'description': 'RFC 5322 From header. Defaults to the original recipient address if omitted.'}, 'wait': {'type': 'boolean', 'description': 'When true, wait for the first SMTP delivery outcome before returning.'}, 'body_html': {'type': 'string', 'description': 'HTML reply body. Provide at least one of body_text or body_html.'}, 'body_text': {'type': 'string', 'description': 'Plain-text reply body. Provide at least one of body_text or body_html.'}, 'attachments': {'type': 'array', 'items': {'type': 'object', 'required': ['filename', 'content_base64'], 'properties': {'filename': {'type': 'string', 'maxLength': 255, 'minLength': 1, 'description': 'Attachment filename including extension.'}, 'content_id': {'type': 'string', 'pattern': '^[\\x21-\\x3B\\x3D\\x3F-\\x7E]+$', 'maxLength': 128, 'minLength': 1, 'description': 'Content-ID for an inline (cid) attachment: 1-128 printable ASCII characters, no whitespace or angle brackets. When set, the part renders inline and body_html can reference it (e.g. src="cid:logo-1"). Omit for a regular downloadable attachment.'}, 'content_type': {'type': 'string', 'maxLength': 255, 'minLength': 1, 'description': 'MIME type of the attachment (e.g. "application/pdf"). Inferred from the filename when omitted.'}, 'content_base64': {'type': 'string', 'maxLength': 44040192, 'minLength': 1, 'description': 'Base64-encoded attachment content.'}}, 'additionalProperties': False}, 'maxItems': 100, 'description': 'Optional file attachments to include in the reply.'}}, 'additionalProperties': False}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
searchEmails
Search inbound emails
Use this when you need to find inbound emails with structured filters or full-text matching. Use sort=received_at_asc plus date_from for new-mail polling.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'properties': {'q': {'type': 'string', 'maxLength': 500, 'description': 'Full-text query matched across subject, body, sender, and recipient.'}, 'to': {'type': 'string', 'maxLength': 255, 'description': 'Filter to emails addressed to this recipient.'}, 'body': {'type': 'string', 'maxLength': 2000, 'description': 'Filter to emails whose body contains this string.'}, 'from': {'type': 'string', 'maxLength': 255, 'description': 'Filter to emails from this sender address or domain.'}, 'sort': {'enum': ['relevance', 'received_at_desc', 'received_at_asc'], 'type': 'string', 'description': 'Sort order. Use received_at_asc with date_from for polling new mail.'}, 'limit': {'type': 'number', 'default': 50, 'maximum': 100, 'minimum': 1, 'description': 'Maximum number of emails to return (1–100, default 50).'}, 'cursor': {'type': 'string', 'maxLength': 200, 'description': "Pagination cursor from a previous response's `meta.cursor` field."}, 'status': {'enum': ['pending', 'accepted', 'completed', 'rejected'], 'type': 'string', 'description': 'Filter to emails in this processing status.'}, 'date_to': {'type': 'string', 'format': 'date-time', 'description': 'Inclusive upper bound on received_at (ISO 8601).'}, 'snippet': {'enum': ['true', 'false'], 'type': 'string', 'default': 'true', 'description': 'Include a short body snippet in each result (default true).'}, 'subject': {'type': 'string', 'maxLength': 500, 'description': 'Filter to emails whose subject contains this string.'}, 'date_from': {'type': 'string', 'format': 'date-time', 'description': 'Inclusive lower bound on received_at (ISO 8601).'}, 'domain_id': {'type': 'string', 'format': 'uuid', 'description': 'Filter to emails received on a specific verified domain.'}, 'spam_score_lt': {'type': 'number', 'description': 'Filter to emails with a spam score strictly below this value.'}, 'has_attachment': {'enum': ['true', 'false'], 'type': 'string', 'description': 'Filter to emails that have ("true") or lack ("false") attachments.'}, 'include_facets': {'enum': ['true', 'false'], 'type': 'string', 'default': 'true', 'description': 'Include aggregated facet counts (sender, domain, status) in the response (default true).'}, 'spam_score_gte': {'type': 'number', 'description': 'Filter to emails with a spam score at or above this value.'}, 'reply_to_sent_email_id': {'type': 'string', 'format': 'uuid', 'description': 'Filter to inbound emails that are replies to a specific sent email ID.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
sendEmail
Send email
Use this when the user has confirmed a new outbound email. Sends real email through Primitive's relay and can wait for the first SMTP delivery outcome, or schedule the send for a future time with scheduled_at. IMPORTANT: `from` is YOUR OWN complete mailbox address, never the recipient's. Use sender_address from createEmailAddress or getAccount for a managed inbox. AFTER sending, if you expect an answer, immediately call awaitReply with the returned id and wait for it, rather than telling the user the message was sent and stopping. Most agent mailboxes answer within seconds, and the answer is usually the thing the user actually asked you for.
破壊的操作あり 外部アクセスあり
入力スキーマ
{'type': 'object', 'required': ['requestBody'], 'properties': {'api_key': {'type': 'string', 'maxLength': 200, 'minLength': 8, 'description': 'Primitive API key (prim_...). Only needed when this connection has no signed-in account: pass the api_key returned by createEmailAddress, unchanged, on every call for the rest of the conversation. Omit it when the user is signed in.'}, 'requestBody': {'type': 'object', 'required': ['from', 'to', 'subject'], 'properties': {'cc': {'oneOf': [{'type': 'string', 'maxLength': 998, 'minLength': 3}, {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 3}, 'maxItems': 100, 'minItems': 1}], 'description': 'Optional CC recipients: a single address or an array of single-address strings (each entry exactly one address). Counts toward the combined to+cc+bcc max of 100.'}, 'to': {'oneOf': [{'type': 'string', 'maxLength': 998, 'minLength': 3}, {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 3}, 'maxItems': 100, 'minItems': 1}], 'description': 'Recipient email address (RFC 5321 mailbox, display-name form allowed), or an array of single-address strings to address multiple recipients with one message. Each array entry must be exactly one address. Combined to+cc+bcc count max 100.'}, 'bcc': {'oneOf': [{'type': 'string', 'maxLength': 998, 'minLength': 3}, {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 3}, 'maxItems': 100, 'minItems': 1}], 'description': 'Optional BCC recipients: a single address or an array of single-address strings (each entry exactly one address). Counts toward the combined to+cc+bcc max of 100.'}, 'from': {'type': 'string', 'maxLength': 998, 'minLength': 3, 'description': "RFC 5322 From header: YOUR OWN complete mailbox address, never the recipient's. createEmailAddress.address and getAccount.managed_inbox_address are domains, not mailbox addresses. When present, use the sender_address added to those MCP results, such as agent@pink-ram.primitive.email. Putting the recipient's address here mails them as themselves, which they will ignore. The sender domain must be a verified outbound domain for your organization."}, 'tags': {'type': 'array', 'items': {'type': 'object', 'required': ['name', 'value'], 'properties': {'name': {'type': 'string', 'pattern': '^[A-Za-z0-9_-]+$', 'maxLength': 64, 'minLength': 1, 'description': 'Tag name: ASCII letters, digits, underscores, dashes only.'}, 'value': {'type': 'string', 'pattern': '^[A-Za-z0-9_-]+$', 'maxLength': 256, 'minLength': 1, 'description': 'Tag value: same charset as the name. Use "true" for a bare marker tag.'}}, 'additionalProperties': False}, 'maxItems': 10, 'description': 'Optional metadata tags (max 10, unique names) stored on the send record for correlation and filtering via listSentEmails. Never rendered into headers and never delivered.'}, 'wait': {'type': 'boolean', 'description': 'When true, wait for the first SMTP delivery outcome before returning. Respects wait_timeout_ms. Cannot be combined with scheduled_at.'}, 'subject': {'type': 'string', 'maxLength': 998, 'minLength': 1, 'description': 'Email subject line.'}, 'reply_to': {'oneOf': [{'type': 'string', 'maxLength': 998, 'minLength': 3}, {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 3}, 'maxItems': 10, 'minItems': 1}], 'description': 'Optional Reply-To header: a single address or an array of up to 10 single-address entries. A pure header: adds no recipients and does not count toward the recipient cap.'}, 'body_html': {'type': 'string', 'description': 'HTML message body. Provide at least one of body_text or body_html. Reference inline attachments via cid: URLs matching their content_id.'}, 'body_text': {'type': 'string', 'description': 'Plain-text message body. Provide at least one of body_text or body_html.'}, 'references': {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 1}, 'maxItems': 100, 'description': 'List of Message-IDs for the References header, oldest-first.'}, 'attachments': {'type': 'array', 'items': {'type': 'object', 'required': ['filename', 'content_base64'], 'properties': {'filename': {'type': 'string', 'maxLength': 255, 'minLength': 1, 'description': 'Attachment filename including extension.'}, 'content_id': {'type': 'string', 'pattern': '^[\\x21-\\x3B\\x3D\\x3F-\\x7E]+$', 'maxLength': 128, 'minLength': 1, 'description': 'Content-ID for an inline (cid) attachment: 1-128 printable ASCII characters, no whitespace or angle brackets. When set, the part renders inline and body_html can reference it (e.g. src="cid:logo-1"). Omit for a regular downloadable attachment.'}, 'content_type': {'type': 'string', 'maxLength': 255, 'minLength': 1, 'description': 'MIME type of the attachment (e.g. "application/pdf"). Inferred from the filename when omitted.'}, 'content_base64': {'type': 'string', 'maxLength': 44040192, 'minLength': 1, 'description': 'Base64-encoded attachment content.'}}, 'additionalProperties': False}, 'maxItems': 100, 'description': 'Optional file attachments. Not allowed on scheduled sends (scheduled_at).'}, 'in_reply_to': {'type': 'string', 'maxLength': 998, 'minLength': 1, 'description': 'Message-ID of the email being replied to, for threading (e.g. "<abc@example.com>").'}, 'scheduled_at': {'type': 'string', 'format': 'date-time', 'description': 'Schedule the send for a future time (ISO 8601 UTC, e.g. "2026-08-01T09:00:00Z"). Must be strictly in the future and at most 30 days out. Cannot be combined with wait or with attachments. Cancel before dispatch with cancelScheduledSend.'}, 'wait_timeout_ms': {'type': 'number', 'maximum': 30000, 'minimum': 1000, 'description': 'How long to wait for delivery confirmation when wait is true (1000-30000 ms, default 10000).'}}, 'additionalProperties': False}, 'Idempotency-Key': {'type': 'string', 'maxLength': 255, 'minLength': 1, 'description': 'Client-supplied idempotency key. Retrying with the same key returns the original result without re-sending.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
sendEmailDemo
Preview a send (simulated, nothing is delivered)
SIMULATION ONLY: nothing is delivered. NEVER call this when the user actually wants an email to arrive, and never describe its result as a sent email: no message is sent, queued, or stored, and the recipient receives nothing. To really send with no account, call createEmailAddress (instant, no signup form and no verification) and then sendEmail with the api_key it returns; that is the correct path for any genuine send request. This tool exists only to preview the response shape: it validates the body against the exact same schema as sendEmail (including cc/bcc, reply_to, tags, attachments, and scheduled_at) and returns a synthetic success envelope marked demo: true. Demo requests are capped at 16KB total body, so large attachments are rejected even though the schema allows them.
読み取り専用 冪等
入力スキーマ
{'type': 'object', 'required': ['requestBody'], 'properties': {'requestBody': {'type': 'object', 'required': ['from', 'to', 'subject'], 'properties': {'cc': {'oneOf': [{'type': 'string', 'maxLength': 998, 'minLength': 3}, {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 3}, 'maxItems': 100, 'minItems': 1}], 'description': 'Optional CC recipients: a single address or an array of single-address strings (each entry exactly one address). Counts toward the combined to+cc+bcc max of 100.'}, 'to': {'oneOf': [{'type': 'string', 'maxLength': 998, 'minLength': 3}, {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 3}, 'maxItems': 100, 'minItems': 1}], 'description': 'Recipient email address (RFC 5321 mailbox, display-name form allowed), or an array of single-address strings to address multiple recipients with one message. Each array entry must be exactly one address. Combined to+cc+bcc count max 100.'}, 'bcc': {'oneOf': [{'type': 'string', 'maxLength': 998, 'minLength': 3}, {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 3}, 'maxItems': 100, 'minItems': 1}], 'description': 'Optional BCC recipients: a single address or an array of single-address strings (each entry exactly one address). Counts toward the combined to+cc+bcc max of 100.'}, 'from': {'type': 'string', 'maxLength': 998, 'minLength': 3, 'description': "RFC 5322 From header: YOUR OWN complete mailbox address, never the recipient's. createEmailAddress.address and getAccount.managed_inbox_address are domains, not mailbox addresses. When present, use the sender_address added to those MCP results, such as agent@pink-ram.primitive.email. Putting the recipient's address here mails them as themselves, which they will ignore. The sender domain must be a verified outbound domain for your organization."}, 'tags': {'type': 'array', 'items': {'type': 'object', 'required': ['name', 'value'], 'properties': {'name': {'type': 'string', 'pattern': '^[A-Za-z0-9_-]+$', 'maxLength': 64, 'minLength': 1, 'description': 'Tag name: ASCII letters, digits, underscores, dashes only.'}, 'value': {'type': 'string', 'pattern': '^[A-Za-z0-9_-]+$', 'maxLength': 256, 'minLength': 1, 'description': 'Tag value: same charset as the name. Use "true" for a bare marker tag.'}}, 'additionalProperties': False}, 'maxItems': 10, 'description': 'Optional metadata tags (max 10, unique names) stored on the send record for correlation and filtering via listSentEmails. Never rendered into headers and never delivered.'}, 'wait': {'type': 'boolean', 'description': 'When true, wait for the first SMTP delivery outcome before returning. Respects wait_timeout_ms. Cannot be combined with scheduled_at.'}, 'subject': {'type': 'string', 'maxLength': 998, 'minLength': 1, 'description': 'Email subject line.'}, 'reply_to': {'oneOf': [{'type': 'string', 'maxLength': 998, 'minLength': 3}, {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 3}, 'maxItems': 10, 'minItems': 1}], 'description': 'Optional Reply-To header: a single address or an array of up to 10 single-address entries. A pure header: adds no recipients and does not count toward the recipient cap.'}, 'body_html': {'type': 'string', 'description': 'HTML message body. Provide at least one of body_text or body_html. Reference inline attachments via cid: URLs matching their content_id.'}, 'body_text': {'type': 'string', 'description': 'Plain-text message body. Provide at least one of body_text or body_html.'}, 'references': {'type': 'array', 'items': {'type': 'string', 'maxLength': 998, 'minLength': 1}, 'maxItems': 100, 'description': 'List of Message-IDs for the References header, oldest-first.'}, 'attachments': {'type': 'array', 'items': {'type': 'object', 'required': ['filename', 'content_base64'], 'properties': {'filename': {'type': 'string', 'maxLength': 255, 'minLength': 1, 'description': 'Attachment filename including extension.'}, 'content_id': {'type': 'string', 'pattern': '^[\\x21-\\x3B\\x3D\\x3F-\\x7E]+$', 'maxLength': 128, 'minLength': 1, 'description': 'Content-ID for an inline (cid) attachment: 1-128 printable ASCII characters, no whitespace or angle brackets. When set, the part renders inline and body_html can reference it (e.g. src="cid:logo-1"). Omit for a regular downloadable attachment.'}, 'content_type': {'type': 'string', 'maxLength': 255, 'minLength': 1, 'description': 'MIME type of the attachment (e.g. "application/pdf"). Inferred from the filename when omitted.'}, 'content_base64': {'type': 'string', 'maxLength': 44040192, 'minLength': 1, 'description': 'Base64-encoded attachment content.'}}, 'additionalProperties': False}, 'maxItems': 100, 'description': 'Optional file attachments. Not allowed on scheduled sends (scheduled_at).'}, 'in_reply_to': {'type': 'string', 'maxLength': 998, 'minLength': 1, 'description': 'Message-ID of the email being replied to, for threading (e.g. "<abc@example.com>").'}, 'scheduled_at': {'type': 'string', 'format': 'date-time', 'description': 'Schedule the send for a future time (ISO 8601 UTC, e.g. "2026-08-01T09:00:00Z"). Must be strictly in the future and at most 30 days out. Cannot be combined with wait or with attachments. Cancel before dispatch with cancelScheduledSend.'}, 'wait_timeout_ms': {'type': 'number', 'maximum': 30000, 'minimum': 1000, 'description': 'How long to wait for delivery confirmation when wait is true (1000-30000 ms, default 10000).'}}, 'additionalProperties': False}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
testEndpoint
Test webhook endpoint
Send a sample email.received event to a webhook endpoint to verify your signature verifier. Rate limited to 4/min and 30/hr. Successful deliveries and verified-domain endpoints are exempt.
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Endpoint ID from listEndpoints or createEndpoint.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
verifyDomain
Verify domain
Check DNS records for a domain claim (MX, TXT, SPF, DKIM, DMARC). On success the domain becomes verified and starts receiving mail. On failure, returns which checks passed and which still need attention. If DNS propagation is incomplete, wait a few minutes and retry.
冪等
入力スキーマ
{'type': 'object', 'required': ['id'], 'properties': {'id': {'type': 'string', 'format': 'uuid', 'description': 'Domain ID returned by addDomain or listDomains.'}}, 'additionalProperties': False}
出力スキーマ
{'type': 'object', 'required': ['tool', 'status', 'data'], 'properties': {'data': {}, 'tool': {'type': 'string'}, 'status': {'type': 'number'}, 'statusText': {'type': 'string'}}, 'additionalProperties': False}
追加
createEmailAddress
2026年9月17日12:39
追加
replayWebhookDelivery
2026年9月17日12:39
追加
listWebhookDeliveries
2026年9月17日12:39
追加
deleteFilter
2026年9月17日12:39
追加
createFilter
2026年9月17日12:39
追加
listFilters
2026年9月17日12:39
追加
testEndpoint
2026年9月17日12:39
追加
deleteEndpoint
2026年9月17日12:39
追加
createEndpoint
2026年9月17日12:39
追加
listEndpoints
2026年9月17日12:39
追加
downloadEmailAttachments
2026年9月17日12:39
追加
getThread
2026年9月17日12:39
追加
getConversation
2026年9月17日12:39
追加
awaitReply
2026年9月17日12:39
追加
cancelScheduledSend
2026年9月17日12:39
追加
getSentEmail
2026年9月17日12:39
追加
listSentEmails
2026年9月17日12:39
追加
sendEmailDemo
2026年9月17日12:39
追加
sendEmail
2026年9月17日12:39
追加
replyToEmail
2026年9月17日12:39
追加
getEmail
2026年9月17日12:39
追加
searchEmails
2026年9月17日12:39
追加
listEmails
2026年9月17日12:39
追加
getOutboundStatus
2026年9月17日12:39
追加
getInboxStatus
2026年9月17日12:39
追加
getAccount
2026年9月17日12:39
追加
downloadDomainZoneFile
2026年9月17日12:39
追加
verifyDomain
2026年9月17日12:39
追加
addDomain
2026年9月17日12:39
追加
listDomains
2026年9月17日12:39