---
title: "Send invoice email to contractor"
method: POST
path: "/sales/invoice/send"
tags: ["Sales"]
---

# Send invoice email to contractor

`POST /sales/invoice/send`

## Request

- Base URL: `https://api.altera.co`
- URL: `https://api.altera.co/sales/invoice/send`
- Auth: API key in header `Authorization`

Send an invoice to its contractor by email. Configure the company global reply-to address in Settings > Sales > E-mail messages before calling this endpoint. HTTP 200 with result OK confirms that the email was queued; it does not confirm mailbox delivery. In QA, external recipient addresses are filtered out by sandbox routing. To verify actual receipt in QA, coordinate a recipient address in the @altera.co domain with Altera support. See the endpoint guide for template requirements and testing.

## Request body

- union
  - object
    - `invoiceId` integer, required: ID of an invoice belonging to the company identified by the API token.
    - `topic` string: Optional email subject. If omitted, empty or whitespace-only, generates Faktura numer {invoiceNumber}, independently of the company body template and invoice document language. A nonblank topic overrides the standard subject. Requires the subject fallback fix in the target environment; see the endpoint guide for the older-version workaround.
    - `content` string: Optional email body as plain text or HTML. If omitted, empty or whitespace-only, uses the company invoice-send email template with invoice placeholders expanded. Configure that template in Settings > Sales > E-mail messages first; a missing template returns HTTP 400. A nonblank value overrides the company template.
    - `recipient` string[], required: Explicit email recipients. Required unless recipientFromSystem is true. Ignored when recipientFromSystem is true.
    - `recipientFromSystem` boolean: When true, load recipient addresses from the contractor saved on the invoice. Takes precedence over recipient. At least one contractor email address must exist.
  - object
    - `invoiceId` integer, required: ID of an invoice belonging to the company identified by the API token.
    - `topic` string: Optional email subject. If omitted, empty or whitespace-only, generates Faktura numer {invoiceNumber}, independently of the company body template and invoice document language. A nonblank topic overrides the standard subject. Requires the subject fallback fix in the target environment; see the endpoint guide for the older-version workaround.
    - `content` string: Optional email body as plain text or HTML. If omitted, empty or whitespace-only, uses the company invoice-send email template with invoice placeholders expanded. Configure that template in Settings > Sales > E-mail messages first; a missing template returns HTTP 400. A nonblank value overrides the company template.
    - `recipient` string[]: Explicit email recipients. Required unless recipientFromSystem is true. Ignored when recipientFromSystem is true.
    - `recipientFromSystem` true, required: When true, load recipient addresses from the contractor saved on the invoice. Takes precedence over recipient. At least one contractor email address must exist.

## Response `200`

Email accepted into the sending queue. This confirms enqueueing, not delivery to the recipient mailbox.

- object
  - `result` 'OK', required
  - `data` 'Ok', required

## Other responses

- `400`: Invalid request, missing company reply-to, missing invoice or recipient, or omitted content without a configured invoice email template.
- `401`: KEY_EXPIRED: a verified API key has expired. This requires that the company still has OpenAPI access. Unknown/invalid keys can receive the gateway 403.

## Changes

- **2026-10-12** `45544bcb4e8a`: 1 breaking, 1 warning, 6 info
  - request body became required
  - the `invoiceId` request property's min was set to `1.00`
  - added `subschema #1, subschema #2` to the request body `anyOf` list
  - the `recipientFromSystem` request property default value `false` was added
  - …4 more
- **2024-08-26** `64c683372c45`: 1 info
  - endpoint added
- **2024-08-26** `a2d864f3a8db`: 1 breaking
  - api path removed without deprecation

[Operation history](https://skmtc.dev/altera-co/apis/altera-api/changes/sales/invoice/send/post.md)

---

[API](https://skmtc.dev/altera-co/apis/altera-api.md) - [All operations](https://skmtc.dev/altera-co/apis/altera-api/llms.txt) - [OpenAPI document](https://skmtc.dev/altera-co/apis/altera-api/revisions/45544bcb4e8a?raw)
