---
title: "Send an invoice (draft → open, mints the payment token; idempotent)"
method: POST
path: "/companies/{companyId}/ar/{id}/send"
tags: ["AR/AP"]
---

# Send an invoice (draft → open, mints the payment token; idempotent)

`POST /companies/{companyId}/ar/{id}/send`

## Request

- Base URL: `https://api.medianfi.com/api/v1`
- URL: `https://api.medianfi.com/api/v1/companies/{companyId}/ar/{id}/send`
- Auth: HTTP bearer

DARK — 404s unless ar_ap_items_enabled. First send transitions a draft to open through the FSM and mints a unique non-guessable payment_token; re-sends are idempotent (token and sentAt stable). Requires a positive total and a counterparty. Email dispatch is a separate sub-issue.

## Response `200`

Invoice sent (item with lines and availableTransitions)

## Other responses

- `404`: Not found or AR/AP not enabled
- `409`: Stripe-source item is status-locked
- `422`: Non-positive total, missing counterparty, or illegal transition

---

[API](https://skmtc.dev/medianfi/apis/median-api.md) · [All operations](https://skmtc.dev/medianfi/apis/median-api/llms.txt) · [OpenAPI document](https://skmtc.dev/medianfi/apis/median-api/revisions/20090ea32b0d?raw)
