Skip to main content
GET
Get an attachment
Any member of the organization can read it. A deleted attachment is still returned, with status: DELETED, so you can tell it apart from an ID that never existed. The automatic analysis fills four fields after the upload, each on its own: summary and contents (in Portuguese), the preview image in thumbnail, the file’s dimensions in image and — when the file is a nota fiscal or an invoice — the structured extractedReceipt. Check the matching status block (ai, thumbnail, fiscal) before reading one: PENDING and PROCESSING mean the file hasn’t been read yet.

Path Parameters

realmId
string<uuid>
required

ID of your realm.

Format: UUID

organizationId
string<uuid>
required

ID of the organization the attachment belongs to.

Format: UUID

attachmentId
string<uuid>
required

ID of the attachment, as returned when it was created.

Format: UUID

Response

Successful response

A stored file and what was read from it.

id
string<uuid>
required

ID of the attachment. Store it wherever the file is used.

Example:

"3f6c2a1e-8b4d-4f7a-9c2e-5d1b7a9e4c60"

realmId
string<uuid>
required

ID of the realm the attachment belongs to.

Example:

"f495ff0c-ab54-4f99-8e92-ca8682e4de9b"

organizationId
string<uuid>
required

ID of the organization the attachment belongs to.

Example:

"c4bd3f21-dfbd-44e8-8055-68ba15bed410"

status
enum<string>
required

Lifecycle of a stored file: PENDING_UPLOAD once created and an upload URL has been issued, AVAILABLE once the upload is confirmed, DELETED after removal. Deletion is permanent — an attachment cannot be restored.

Available options:
PENDING_UPLOAD,
AVAILABLE,
DELETED
Example:

"AVAILABLE"

name
string
required

Name of the file, as sent when it was created.

Example:

"cupom-fiscal-posto.jpg"

contentType
string
required

Media type of the file, as declared when it was created.

Example:

"image/jpeg"

ai
object
required

Progress of the automatic content analysis. Always present.

thumbnail
object
required

The attachment's preview image. Always present; check status before reading data.

fiscal
object
required

Progress of the fiscal-data extraction that fills extractedReceipt. Always present; a PENDING/PROCESSING status means the file has not been read yet, which is why an extractedReceipt can be absent from a document that does have one.

createdBy
string
required

ID of the user (or API client) who created the attachment.

Example:

"e3553bc1-5e20-4e17-b22a-a796fda0aa99"

sizeBytes
number

Size of the file in bytes.

Example:

2457600

image
object

Dimensions and format of the original file. Absent when the file's header could not be read.

⚠️ width and height are in PIXELS for an image and in POINTS (1/72 inch) for a PDF — check format to tell which. An A4 page reports 595 x 842 points, not pixels.

summary
string

A short description of the file, in Portuguese, written by the automatic analysis. Present once ai.status is DONE.

Example:

"Cupom fiscal eletrônico (NFC-e) do Posto Exemplo Ltda., de 15/10/2026: 40 litros de gasolina comum, total de R$ 250,00, pago com cartão de crédito."

contents
string[]

Short facts read from the file (values, dates, names, document numbers), in Portuguese. Empty until ai.status is DONE.


Example: ["Emitente: Posto Exemplo Ltda., CNPJ 11.222.333/0001-81","Gasolina comum: 40 L a R$ 6,25","Total: R$ 250,00","Pagamento: cartão de crédito"]

extractedReceipt
object

The fiscal document this file represents — a nota fiscal or an invoice. Absent unless the file is one and its details are known. Every field inside is optional: null-check your way in, and read status before rendering any amount.

Example:
createdAt
string<date-time>

When the attachment was created.

Example:

"2026-10-15T14:31:05.000Z"

updatedAt
string<date-time>

When the attachment last changed — its upload being confirmed or an analysis finishing.

Example:

"2026-10-15T14:32:58.000Z"

deletedAt
string<date-time>

When the attachment was deleted. Present only on a DELETED attachment.

deletedBy
string

ID of the user who deleted the attachment. Present only on a DELETED attachment.