Get an attachment download URL
GET/api/v1/email/received/{id}/attachments/{attachmentId}
GET /email/received/{id}/attachments/{attachmentId}
curl -X GET 'https://www.unitpost.com/api/v1/email/received/email_123/attachments/att_789' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'User-Agent: my-app/1.0'Response · 200
{
"object": "received_attachment_url",
"url": "https://example.com",
"expires_at": "2026-01-01T00:00:00.000Z"
}Get a short-lived, signed URL for downloading one inbound attachment's bytes. Fetch the URL and download promptly — it expires quickly (the expiry is included in the response). Find attachment ids on the message via Retrieve a received email. Requires the emails:read capability.
Parameters2 fields
| Field | Type | Description |
|---|---|---|
idrequired | string · path | — |
attachmentIdrequired | string · path | — |
Response · 200 fields3 fields
| Field | Type | Description |
|---|---|---|
objectrequired | enumreceived_attachment_url | — |
urlrequired | string | A signed, expiring URL to download the attachment bytes. |
expires_atrequired | string | ISO 8601 expiry of the signed URL (~5 minutes out). |
200401403404503