Email Marketing
Sender identities
A sender identity is a display name plus From address on a domain you have already verified in the app. Campaigns and some transactional sends require a matching row.
Prerequisites
Add the domain under Email → Domains and complete DNS verification first. The API cannot verify DNS for you. fromEmail must be on that domain (for example [email protected] when example.com is verified).
Create a sender identity
/api/v1/email/sender-identitiescampaigns:write| fromName | Required. Display name recipients see (e.g. your brand). |
|---|---|
| fromEmail | Required. Must be on a verified sending domain for this organization. |
| replyTo | Optional reply-to address. |
| isDefault | Optional. When true, becomes the default From; first identity is default if omitted. |
curl -sS https://api.thealtermeai.com/api/v1/email/sender-identities \
-H "Authorization: Bearer emk_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{
"fromName": "TheAlterMeAI",
"fromEmail": "[email protected]",
"replyTo": "[email protected]",
"isDefault": true
}'Returns 201 and senderIdentity with sendable: true when the domain is verified. 409 with DOMAIN_NOT_REGISTERED or DOMAIN_NOT_VERIFIED if DNS is not ready. 409 DUPLICATE if that From address already exists.
List identities
/api/v1/email/sender-identitiescampaigns:readsendableOnly=true filters to identities on verified domains — use this before creating a campaign to pick fromEmail.
curl -sS "https://api.thealtermeai.com/api/v1/email/sender-identities?sendableOnly=true" \
-H "Authorization: Bearer emk_YOUR_KEY"Use in campaigns
POST /api/v1/email/campaigns requires fromName and fromEmail that match a sendable identity. Transactional POST /api/v1/email/messages can use from or a verified sender on the same domain — see Transactional email.