> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://infonite.dev/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://infonite.dev/_mcp/server.

# Attachments

**Where it lives:** on every result that carries documents — e.g.
`data.employment.labor_check.attachments` — and listed session-wide by the attachments
endpoint.

Many results carry the **original documents** they were extracted from — official PDF reports,
receipts — as attachments. The result itself only carries the attachment's description; the
bytes are downloaded separately through the session's attachments endpoint using the
attachment's `id`, so payloads stay light and you fetch only the files you need.

Attachments follow the session's lifetime: download what you want to keep while the session is
available.

### Schema (`FileAttachmentSchema`)

A document attached to a result — an official report, a receipt, an invoice... The entry
describes the file; its bytes are downloaded through the execution's attachments endpoint
using `id`.

```yaml
components:
  schemas:
    ProductAttachmentType:
      type: string
      enum:
        - attachment:attachment
        - attachment:supplier_invoice
        - attachment:client_invoice
        - attachment:es-tgss-life-report
        - attachment:es-tgss-contribution-base-report
        - attachment:es-aeat-model-100
        - attachment:es-cirbe-report
        - attachment:sepa-direct-debit-bill
      description: Product Attachment Type
      title: ProductAttachmentType
    FileAttachmentSchema:
      type: object
      properties:
        product:
          type: string
          enum:
            - attachment
          default: attachment
          description: The product type identifier. Always `attachment`.
        sub_family:
          $ref: '#/components/schemas/ProductAttachmentType'
          description: >-
            What kind of document this is (e.g.
            `attachment:es-tgss-life-report`).
        id:
          type: string
          format: ObjectId
          description: >-
            Attachment identifier — use it to download the file through the
            execution's attachments

            endpoint.
        content_name:
          type: string
          description: File name of the document.
        content_hash:
          type: string
          description: Fingerprint of the content, to verify its integrity.
        content_type:
          type: string
          format: mime-type
          description: MIME type of the content.
        metadata:
          type: object
          additionalProperties:
            description: Any type
          description: >-
            Extra facts about the document, as simple key-value pairs (e.g. its
            official verification

            code, its issue date).
      required:
        - sub_family
        - id
        - content_name
        - content_type
        - metadata
      title: FileAttachmentSchema
```

## Document kinds

`sub_family` tells you what each document is:

### Schema (`ProductAttachmentType`)

Product Attachment Type

```yaml
components:
  schemas:
    ProductAttachmentType:
      type: string
      enum:
        - attachment:attachment
        - attachment:supplier_invoice
        - attachment:client_invoice
        - attachment:es-tgss-life-report
        - attachment:es-tgss-contribution-base-report
        - attachment:es-aeat-model-100
        - attachment:es-cirbe-report
        - attachment:sepa-direct-debit-bill
      title: ProductAttachmentType
```