> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getspecs.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Get supplier invoices report field schema

> Merge fields for supplier invoices pdf templates. Fixed per report kind, not per workspace.



## OpenAPI

````yaml /openapi.yaml get /reports/supplier_invoices_list/schema
openapi: 3.0.1
info:
  title: GetSpecs REST API
  description: REST API documentation for GetSpecs.
  version: 1.0.0
servers:
  - url: /v1
  - url: https://demo-api.getspecs.io/v1
security: []
paths:
  /reports/supplier_invoices_list/schema:
    get:
      tags:
        - Report
      summary: Get supplier invoices report field schema
      description: >-
        Merge fields for supplier invoices pdf templates. Fixed per report kind,
        not per workspace.
      operationId: reports/supplier_invoices_list#schema
      parameters:
        - name: X-Workspace-ID
          in: header
          required: true
          schema:
            type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/report_supplier_invoices_list_schema'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error'
      security:
        - apiKey: []
          workspaceId: []
components:
  schemas:
    report_supplier_invoices_list_schema:
      type: object
      description: >-
        Available merge fields for supplier invoices report templates. Fixed per
        report kind: the `workspace` and `project` records (`project` resolves
        to nulls unless the report is generated with a `project_id`) plus the
        `supplier_invoices` collection: one row per invoice, in list order.
        `status` / `payment_status` are labels; `overdue` the string
        "true"/"false"; `purchase_orders` the billed orders' numbers joined with
        ", "; amounts (`format: currency`) are "USD 1,234.50" strings in the
        invoice's currency, plain numbers without one. Plus
        `supplier_invoice_items`: each row's lines, nested in the rows.
      properties:
        workspace:
          $ref: '#/components/schemas/report_schema_record'
        project:
          $ref: '#/components/schemas/report_schema_record'
        supplier_invoices:
          type: object
          properties:
            name:
              type: string
            type:
              type: string
              enum:
                - collection
            fields:
              type: object
              additionalProperties:
                type: object
                properties:
                  type:
                    type: string
                    enum:
                      - string
                      - strings
                      - number
                      - date
                      - boolean
                  name:
                    type: string
                  whitelist_values:
                    type: array
                    items:
                      type: string
                  format:
                    type: string
                    enum:
                      - currency
                required:
                  - type
                  - name
          required:
            - name
            - type
            - fields
        supplier_invoice_items:
          description: >-
            Each row's lines, the same collection as in the single supplier
            invoice pdf. Never a list of its own: each row of
            `supplier_invoices` nests its lines under `supplier_invoice_items`
            (`{{#each supplier_invoice_items}}` inside `{{#each
            supplier_invoices}}`) when `used_fields.collections` names
            `supplier_invoice_items`.
          type: object
          properties:
            name:
              type: string
            type:
              type: string
              enum:
                - collection
            fields:
              type: object
              additionalProperties:
                type: object
                properties:
                  type:
                    type: string
                    enum:
                      - string
                      - strings
                      - number
                      - date
                      - boolean
                  name:
                    type: string
                  whitelist_values:
                    type: array
                    items:
                      type: string
                  format:
                    type: string
                    enum:
                      - currency
                required:
                  - type
                  - name
          required:
            - name
            - type
            - fields
      required:
        - workspace
        - project
        - supplier_invoices
        - supplier_invoice_items
    error:
      type: object
      properties:
        error:
          type: string
        errors:
          type: array
          items:
            type: object
            properties:
              field:
                type: string
                nullable: true
              code:
                type: string
                nullable: true
              message:
                type: string
            required:
              - message
    report_schema_record:
      type: object
      properties:
        name:
          type: string
        type:
          type: string
          enum:
            - record
        fields:
          type: object
          additionalProperties:
            type: object
            properties:
              type:
                type: string
                enum:
                  - string
                  - image
                  - date
              name:
                type: string
            required:
              - type
              - name
      required:
        - name
        - type
        - fields
  securitySchemes:
    apiKey:
      type: apiKey
      name: authorization
      in: header
    workspaceId:
      type: apiKey
      name: X-Workspace-ID
      in: header

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.