Capability catalogue
emailwrite
email.send
Send an email
Bare-email send via SMTP/SendGrid/SES. Use tickets.reply when the source is a ticketing system; use email.send only when no ticket context exists.
Effect
write Fanout
no
Cache TTL
none
Traits
human_authored
Request arguments
Passed as the args parameter to ctx.capability.call("email.send", …).
| Field | Type | Required | Description |
|---|---|---|---|
| to | string | yes | |
| body | string | yes | |
| headers | object | no | |
| subject | string | yes | |
| linkStyle | string | no | How links show in the sent email: text = the label (or the host for a bare URL), button = a button, plain = the URL itself. default: "text" · enum: ["text","button","plain"] |
| buttonColor | string | no | Button colour when linkStyle is button (#rgb or #rrggbb). |
Response
Returned by ctx.capability.call("email.send", …).
| Field | Type | Required | Description |
|---|---|---|---|
| ok | boolean | yes | |
| sentAt | string | no | format: date-time |
| messageId | string | no |
Example call
From inside your agent's handle(). The kernel resolves email.send to the tenant's connector binding at invocation time.
response = await ctx.capability.call(
"email.send",
args={
"to": "...",
"body": "...",
"headers": {},
"subject": "...",
"linkStyle": "text",
"buttonColor": "...",
},
)See SDK quickstart for the full agent handler template; code examples covers invocation patterns including fanout and error handling.