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

# creates an invoice



## OpenAPI

````yaml https://integration.teceo.co/aos post /v1/invoices
openapi: 3.0.0
info:
  title: teceo brand integrator API
  description: integrate your brand with teceo
  version: '1.0'
  contact: {}
servers:
  - url: /
security: []
tags: []
paths:
  /v1/invoices:
    post:
      tags:
        - 'Invoices:'
      summary: creates an invoice
      operationId: InvoiceController_create_v1
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateInvoiceDto'
      responses:
        '200':
          description: creates an invoice
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateInvoiceResponseDTO'
        '400':
          description: >-
            response status code indicates that the server cannot or will not
            process the request due to something that is perceived to be a
            client error
        '403':
          description: >-
            client error status response code indicates that the server
            understood the request but refuses to authorize it
        '404':
          description: customer or sku not found
        '409':
          description: >-
            an invoice with the informed code and series, or with the informed
            accessKey, already exists. the body carries code
            api.exception.invoiceAlreadyExists
      security:
        - ApiKey: []
components:
  schemas:
    CreateInvoiceDto:
      type: object
      properties:
        code:
          type: string
          description: invoice number
        series:
          type: string
          description: invoice series
        accessKey:
          type: string
          description: invoice access key (44 digits)
          example: '44444444444444444444444444444444444444444444'
        issuedAt:
          type: string
          description: issue date
          example: '2026-07-10'
          format: date
        customerCode:
          type: string
          description: customer code
        orderCodes:
          description: external codes of the linked orders
          type: array
          items:
            type: string
        grossValue:
          type: number
          description: gross value
        subtotal:
          type: number
          description: subtotal
        discount:
          type: number
          description: discount
        totalAmount:
          type: number
          description: total number of units in the invoice, not a monetary value
        taxesValue:
          type: number
          description: taxes value
        items:
          description: >-
            invoice items, at least one. every orderCode used by an item must
            also be listed in orderCodes, otherwise the request is rejected with
            400 invoiceOrderNotSynced
          type: array
          items:
            $ref: '#/components/schemas/CreateInvoiceItemDto'
      required:
        - code
        - series
        - accessKey
        - issuedAt
        - customerCode
        - grossValue
        - subtotal
        - discount
        - totalAmount
        - taxesValue
        - items
    CreateInvoiceResponseDTO:
      type: object
      properties:
        id:
          type: string
          description: created invoice id
        code:
          type: string
          description: invoice number
        series:
          type: string
          description: invoice series
        accessKey:
          type: string
          description: invoice access key
      required:
        - id
        - code
        - series
        - accessKey
    CreateInvoiceItemDto:
      type: object
      properties:
        skuCode:
          type: string
          description: sku code of the item
        quantity:
          type: number
          description: item quantity
        unitPrice:
          type: number
          description: item unit price
        orderCode:
          type: string
          description: external code of the order this item belongs to
      required:
        - skuCode
        - quantity
        - unitPrice
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: unique identifier access key. each brand has it own unique key.

````

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