Qargo Use case / E-invoicing API

Required api role: not applicable Purpose: This interface allows an external party to send e-invoices in a structured format. A [webhook](/docs/use-case-e-invoicing/e-invoicing-webhook) can be used to send e-invoices to Qargo. The e-invoice can either be a **purchase invoice** or a **purchase credit note**. ### Supported formats | Format | Content-Type | Notes | |--------|-------------|-------| | JSON | `application/json` | Qargo's own purchase invoice/credit note schema | | XML (UBL) | `application/xml` | Peppol-compliant UBL documents | | Multipart | `multipart/form-data` | JSON invoice data + supporting document files (PDF, XML, etc.) | ### Attachments Attachments (e.g. invoice PDF, CMR, proof of delivery) can be included in two ways: - **In JSON payloads**: Use the `attachments` array, where each item contains a `document` object with `base64`, `content_type`, `document_type`, and `filename` fields. - **In multipart uploads**: Send the JSON invoice data as the first part, followed by file attachments as additional parts. See the [e-invoicing webhook endpoint](/docs/use-case-e-invoicing/e-invoicing-webhook) for detailed examples of all formats and attachment handling.

Operations 1

POST /v1/webhook/e-invoicing Send E-Invoices #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/qargo-use-case-e-invoicing-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

qargo-use-case-e-invoicing-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Qargo TMS Use case / E-invoicing API
  description: For support, please contact integrations@qargo.com.
  version: 1.2.0
servers:
- url: https://api.qargo.com
tags:
- name: Use case / E-invoicing
  description: 'Required api role: not applicable


    Purpose: This interface allows an external party to send e-invoices in a structured format.'
paths:
  /v1/webhook/e-invoicing:
    post:
      tags:
      - Use case / E-invoicing
      summary: Send E-Invoices
      description: Webhook to receive e-invoices in structured format or as file uploads.
      operationId: e-invoicing-webhook
      security:
      - BasicAuthWebhookCredentials: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              anyOf:
              - $ref: '#/components/schemas/PurchaseEInvoiceInput'
              - $ref: '#/components/schemas/PurchaseECreditNoteInput'
              - type: string
                format: binary
              title: Body
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '400':
          description: Bad Request — invalid input or malformed request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationErrorResponse'
        '401':
          description: Unauthorized — missing or invalid authentication credentials
        '403':
          description: Forbidden — insufficient permissions for this operation
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '429':
          description: Too Many Requests — rate limit exceeded. See the `Retry-After` header
        '500':
          description: Internal Server Error
        '503':
          description: Service Unavailable — temporarily unable to handle the request
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    api__accounting__models__invoice__TaxRate:
      properties:
        id:
          anyOf:
          - type: string
            format: uuid
          - type: 'null'
          title: Id
          description: Unique identifier of the tax rate in Qargo.
        name:
          anyOf:
          - type: string
          - type: 'null'
          title: Name
          description: Name of the Tax rate in Qargo.
          examples:
          - 21%
        percentage:
          anyOf:
          - type: number
          - type: 'null'
          title: Percentage
          examples:
          - 21
        code:
          anyOf:
          - type: string
          - type: 'null'
          title: Code
          description: Code of the tax rate item in the accounting software.
          examples:
          - 21% VAT
        tax_type:
          anyOf:
          - $ref: '#/components/schemas/TaxRateType'
          - type: 'null'
          default: VAT
          examples:
          - VAT
      type: object
      title: TaxRate
    ExchangeRate:
      properties:
        rate_date:
          anyOf:
          - type: string
            format: date
          - type: 'null'
          title: Rate Date
          examples:
          - '2022-01-01'
        rate:
          type: number
          title: Rate
          examples:
          - 1
        inverse_rate:
          type: number
          title: Inverse Rate
          examples:
          - 1
      type: object
      required:
      - rate
      - inverse_rate
      title: ExchangeRate
    TaxRateType:
      type: string
      enum:
      - VAT
      - NO_VAT
      - REVERSE_CHARGE
      - TRANSIT
      - CO_CONTRACTING
      - OTHER
      title: TaxRateType
    Location:
      properties:
        code:
          anyOf:
          - type: string
          - type: 'null'
          title: Code
          description: Technical code for integrations/mapping logic; should be treated as stable once set.
          examples:
          - LOC123
        display_name:
          anyOf:
          - type: string
          - type: 'null'
          title: Display Name
          description: Human-readable label for a location in operational views.
          examples:
          - Main Office
        external_id:
          anyOf:
          - type: string
          - type: 'null'
          title: External Id
          description: Identifier from an external (master data) system.
        address:
          anyOf:
          - type: string
          - type: 'null'
          title: Address
          description: First address line of the location
          examples:
          - Gaston Crommenlaan 4
        address_second_line:
          anyOf:
          - type: string
          - type: 'null'
          title: Address Second Line
          description: Second address line of the location
          examples:
          - ''
        city:
          anyOf:
          - type: string
          - type: 'null'
          title: City
          description: City of the location
          examples:
          - Ghent
        state:
          anyOf:
          - type: string
          - type: 'null'
          title: State
          description: State of the location
          examples:
          - ''
        country:
          anyOf:
          - type: string
          - type: 'null'
          title: Country
          description: Country code (ISO 3166-1 alpha-2) of the location
          examples:
          - BE
        postal_code:
          anyOf:
          - type: string
          - type: 'null'
          title: Postal Code
          description: Postal code of the location
          examples:
          - '9050'
        name:
          anyOf:
          - type: string
          - type: 'null'
          title: Name
          description: Name of the location
          examples:
          - Qargo HQ
        id:
          anyOf:
          - type: string
            format: uuid
          - type: 'null'
          title: Id
          description: Identifier of the location
        latitude:
          anyOf:
          - type: number
          - type: 'null'
          title: Latitude
        longitude:
          anyOf:
          - type: number
          - type: 'null'
          title: Longitude
        description:
          anyOf:
          - type: string
          - type: 'null'
          title: Description
          description: Location description
        location_identifier:
          anyOf:
          - type: string
          - type: 'null'
          title: Location Identifier
          description: External location identifier
      type: object
      title: Location
    ValidationErrorDetail:
      properties:
        message:
          description: Human-readable summary of this validation failure
          title: Message
          type: string
        field:
          anyOf:
          - type: string
          - type: 'null'
          default: null
          description: Name of the field that failed validation, if known
          title: Field
        path:
          anyOf:
          - type: string
          - type: 'null'
          default: null
          description: JSON path to the field within the request payload (e.g. '$.consignor.address.country')
          title: Path
        detail:
          anyOf:
          - type: string
          - type: object
          - type: 'null'
          default: null
          description: Additional structured context about the failure, if provided by the backend
          title: Detail
      required:
      - message
      title: ValidationErrorDetail
      type: object
    EInvoiceCompanyInput:
      properties:
        id:
          anyOf:
          - type: string
            format: uuid
          - type: 'null'
          title: Id
          description: The unique identifier of the company.
        name:
          type: string
          title: Name
          description: Name of the company.
          examples:
          - John Doe
        vat_number:
          anyOf:
          - type: string
          - type: 'null'
          title: Vat Number
          description: VAT number of the company.
          examples:
          - BE1234.123.123
        billing_location:
          anyOf:
          - $ref: '#/components/schemas/Location'
          - type: 'null'
          description: Billing address of the company.
      type: object
      required:
      - name
      title: EInvoiceCompanyInput
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
            - type: string
            - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
      - loc
      - msg
      - type
      title: ValidationError
    EInvoiceDocumentAttachment:
      properties:
        base64:
          type: string
          title: Base64
          description: Base64 encoded content of the document attachment.
        content_type:
          type: string
          title: Content Type
          description: MIME type of the document attachment, e.g., 'application/pdf', 'application/xml'.
        document_type:
          $ref: '#/components/schemas/EInvoiceDocumentType'
          description: Type of the document attachment.
        filename:
          type: string
          title: Filename
          description: Filename of the document attachment.
      type: object
      required:
      - base64
      - content_type
      - document_type
      - filename
      title: EInvoiceDocumentAttachment
    PurchaseECreditNoteInput:
      properties:
        name:
          type: string
          title: Name
          description: Reference from invoicing party.
          examples:
          - Invoice-0001
        date:
          type: string
          format: date
          title: Date
          description: Invoice transaction date.
          examples:
          - '2022-01-01'
        currency:
          type: string
          title: Currency
          description: Currency code of the e-invoice.
          examples:
          - EUR
        exchange_rate:
          anyOf:
          - $ref: '#/components/schemas/ExchangeRate'
          - type: 'null'
          description: Exchange rate information if applicable.
        total_excl_tax:
          anyOf:
          - type: number
          - type: string
          title: Total Excl Tax
          description: Total amount excluding tax for the e-invoice.
          examples:
          - '100'
        total_incl_tax:
          anyOf:
          - type: number
          - type: string
          title: Total Incl Tax
          description: Total amount including tax for the e-invoice.
          examples:
          - '121'
        total_tax:
          anyOf:
          - type: number
          - type: string
          title: Total Tax
          description: Total tax amount for the e-invoice.
          examples:
          - '21'
        custom_fields:
          type: object
          title: Custom Fields
          description: Custom fields associated with this e-invoice.
        supplier:
          $ref: '#/components/schemas/EInvoiceCompanyInput'
          description: Supplier company information.
        customer_reference_numbers:
          items:
            type: string
          type: array
          title: Customer Reference Numbers
          description: Reference numbers used to match the invoice.
          examples:
          - - '12345'
        line_items:
          items:
            $ref: '#/components/schemas/EInvoiceLineItem'
          type: array
          title: Line Items
          description: List of invoice lines associated with this e-invoice.
        attachments:
          anyOf:
          - items:
              $ref: '#/components/schemas/EInvoiceAttachment'
            type: array
          - type: 'null'
          title: Attachments
          description: List of document attachments associated with this e-invoice.
        invoice_type:
          type: string
          const: PURCHASE_CREDIT_NOTE
          title: Invoice Type
          description: Indicates that this is a purchase credit note.
      type: object
      required:
      - name
      - date
      - currency
      - total_excl_tax
      - total_incl_tax
      - total_tax
      - supplier
      - line_items
      - invoice_type
      title: PurchaseECreditNoteInput
    EInvoiceAttachment:
      properties:
        document:
          $ref: '#/components/schemas/EInvoiceDocumentAttachment'
      type: object
      required:
      - document
      title: EInvoiceAttachment
    EInvoiceLineItem:
      properties:
        description:
          anyOf:
          - type: string
          - type: 'null'
          title: Description
          description: Freeform description field.
          default: ''
          examples:
          - Charge description
        amount:
          anyOf:
          - type: number
          - type: string
          title: Amount
          description: Amount of the charge line.
          examples:
          - '100'
        account:
          anyOf:
          - $ref: '#/components/schemas/api__order__models__charge__AccountInput'
          - type: 'null'
          description: Accounting account associated with this line item.
        tax_rate:
          anyOf:
          - $ref: '#/components/schemas/api__accounting__models__invoice__TaxRate'
          - type: 'null'
          description: Tax rate applied to this line item.
        currency:
          type: string
          title: Currency
          description: Currency of the line item.
          examples:
          - USD
        references:
          anyOf:
          - additionalProperties:
              type: string
            type: object
          - type: 'null'
          title: References
          description: References associated with this line item.
          examples:
          - order_name: OR-1234
      type: object
      required:
      - amount
      - currency
      title: EInvoiceLineItem
    PurchaseEInvoiceInput:
      properties:
        name:
          type: string
          title: Name
          description: Reference from invoicing party.
          examples:
          - Invoice-0001
        date:
          type: string
          format: date
          title: Date
          description: Invoice transaction date.
          examples:
          - '2022-01-01'
        currency:
          type: string
          title: Currency
          description: Currency code of the e-invoice.
          examples:
          - EUR
        exchange_rate:
          anyOf:
          - $ref: '#/components/schemas/ExchangeRate'
          - type: 'null'
          description: Exchange rate information if applicable.
        total_excl_tax:
          anyOf:
          - type: number
          - type: string
          title: Total Excl Tax
          description: Total amount excluding tax for the e-invoice.
          examples:
          - '100'
        total_incl_tax:
          anyOf:
          - type: number
          - type: string
          title: Total Incl Tax
          description: Total amount including tax for the e-invoice.
          examples:
          - '121'
        total_tax:
          anyOf:
          - type: number
          - type: string
          title: Total Tax
          description: Total tax amount for the e-invoice.
          examples:
          - '21'
        custom_fields:
          type: object
          title: Custom Fields
          description: Custom fields associated with this e-invoice.
        supplier:
          $ref: '#/components/schemas/EInvoiceCompanyInput'
          description: Supplier company information.
        customer_reference_numbers:
          items:
            type: string
          type: array
          title: Customer Reference Numbers
          description: Reference numbers used to match the invoice.
          examples:
          - - '12345'
        line_items:
          items:
            $ref: '#/components/schemas/EInvoiceLineItem'
          type: array
          title: Line Items
          description: List of invoice lines associated with this e-invoice.
        attachments:
          anyOf:
          - items:
              $ref: '#/components/schemas/EInvoiceAttachment'
            type: array
          - type: 'null'
          title: Attachments
          description: List of document attachments associated with this e-invoice.
        due_date:
          type: string
          format: date
          title: Due Date
          description: Payment due date.
          examples:
          - '2022-01-01'
        invoice_type:
          type: string
          const: PURCHASE
          title: Invoice Type
          description: Indicates that this is a purchase invoice.
      type: object
      required:
      - name
      - date
      - currency
      - total_excl_tax
      - total_incl_tax
      - total_tax
      - supplier
      - line_items
      - due_date
      - invoice_type
      title: PurchaseEInvoiceInput
    api__order__models__charge__AccountInput:
      properties:
        code:
          type: string
          title: Code
          description: Code of the general ledger in the accounting software linked to this charge line.
          examples:
          - '200'
      type: object
      required:
      - code
      title: AccountInput
    EInvoiceDocumentType:
      type: string
      enum:
      - INVOICE
      - CREDIT_NOTE
      - OTHER
      title: EInvoiceDocumentType
    ValidationErrorResponse:
      properties:
        message:
          description: Human-readable summary of the validation failure
          title: Message
          type: string
        errors:
          description: One entry per validation failure. Always present and non-empty — a single failure yields a one-item array, so integrators can handle one and many the same way.
          items:
            $ref: '#/components/schemas/ValidationErrorDetail'
          minItems: 1
          title: Errors
          type: array
      required:
      - message
      - errors
      title: ValidationErrorResponse
      type: object
  securitySchemes:
    oAuth2ClientCredentials:
      type: oauth2
      flows:
        clientCredentials:
          scopes: {}
          tokenUrl: /v1/auth/token
    BasicAuthWebhookCredentials:
      type: http
      scheme: basic
x-tagGroups:
- name: Use cases
  tags:
  - Use case / Accounting
  - Use case / Customer portal
  - Use case / Document import
  - Use case / E-invoicing
  - Use case / Fleet dispatch
  - Use case / Intermodal [partner]
  - Use case / Location booking
  - Use case / Master data sync
  - Use case / Order
  - Use case / Subcontractor dispatch
  - Use case / Tracking
  - Use case / Trip import
  - Use case / Visibility
- name: API
  tags:
  - API / Accounting
  - API / Authentication
  - API / Company
  - API / Document
  - API / Order
  - API / Resource
  - API / Task
  - API / Trip
- name: System
  tags:
  - System
- name: Webhooks
  tags:
  - Webhooks / Inbound
  - Webhooks / Outbound
- name: ''
  tags: []