Skip to content
Esc
↑↓navigate↵open⌘Jpreview

Get an attachment

One attachment’s metadata and a signed download link valid for one hour. Needs a full access key.

GET/emails/receiving/{email_id}/attachments/{id}
Authorization
AuthorizationBearer token · headerrequired

A BillionSend API key (bs_…).

Path parameters
email_idstring<uuid>required
idstring<uuid>required
Responses
200

Attachment

idstring<uuid>required
filenamestring
sizeintegerrequired
content_typestringrequired
content_dispositionstringrequired
Allowed:inlineattachment
content_idstring
download_urlstringrequired

Signed link to the file's bytes, valid for one hour; it needs no API key

expires_atstringrequired
objectstringrequired
Allowed:attachment
401

Missing, malformed, unknown or revoked API key

statusCodenumberrequired
namestringrequired
messagestringrequired
403

Restricted API key

statusCodenumberrequired
namestringrequired
messagestringrequired
404

Not found

statusCodenumberrequired
namestringrequired
messagestringrequired
429

Over the rate limit (rate_limit_exceeded, with Retry-After)

statusCodenumberrequired
namestringrequired
messagestringrequired
Try it
Server
Authorization
Parameters
Request
curl -X GET 'https://api.billionsend.com/emails/receiving/497f6eca-6276-4993-bfeb-53cbbbba6f08/attachments/497f6eca-6276-4993-bfeb-53cbbbba6f08' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Accept: application/json'
Response
{
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "filename": "string",
  "size": 0,
  "content_type": "string",
  "content_disposition": "inline",
  "content_id": "string",
  "download_url": "string",
  "expires_at": "string",
  "object": "attachment"
}

Was this page helpful?