Hoppa till innehållet

Download an attachment

GET/v1/inbound/{id}/attachments/{attachmentId}

TypeScript sendora.inbound.attachment(inboundMessageId, attachmentId)

Python sendora.inbound.attachment(inbound_message_id, attachment_id)

Key sk_… a server key

The attachment’s bytes as application/octet-stream whatever the sender declared, under Content-Disposition: attachment with its sanitised name. 410 once the content window has passed.

Parameters

  • idin pathstring (uuid)required

    The inbound message id.

  • attachmentIdin pathstring (uuid)required

    The attachment id, from the message.

Responses

Errors

Every error answers error, the code, and message, a sentence for a person. A code that adds fields is shown in full below the table.

CodeStatusMeaning
unauthorized401The key is missing, malformed or revoked.
wrong_token_kind403The key is of the other kind: a server key (sk_) where an account key (ak_) is needed, or the reverse. The message names the kind the operation takes.
not_found404No such inbound message of this server.
content_unreadable409The stored content of this received message cannot be opened. Sendora has been told.
content_expired410The content of this received message is gone; the stream’s content window has passed. The message itself stays 13 months.