cURL
curl --request PUT \ --url https://api.morphic.io/api/email-drafts/{draft_id} \ --header 'Content-Type: application/json' \ --header 'X-API-Key: <api-key>' \ --data ' { "subject": "<string>", "body_html": "<string>", "to_emails": [ "<string>" ], "cc_emails": [ "<string>" ], "bcc_emails": [ "<string>" ], "attachments": [ {} ] } '
{ "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a", "created_at": "2023-11-07T05:31:56Z", "updated_at": "2023-11-07T05:31:56Z", "account_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a", "user_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a", "subject": "<string>", "body_html": "<string>", "to_emails": [ "<string>" ], "cc_emails": [ "<string>" ], "bcc_emails": [ "<string>" ], "attachments": [ {} ] }
Update an existing email draft.
API key (sk_xxx) from Developer Settings. No X-Account-ID needed.
Successful Response