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

# Invoicing a policy

> The three ways to put invoices on a policy, who each is for, and five requests with the invoices each one produces

Every request that invoices a policy says where its invoices come from. You
either drive a saved quote through the same steps as the app, or you state the
invoices yourself. Either way, a policy's invoices always add up to its
billing.

## Three doors

| Door | Who it's for | Where its invoices come from | Endpoints |
| - | - | - | - |
| **Quote door** | Integrators who drive a saved quote through the same steps as the app | The quote. Its bind says which of the quote's invoices it applies: `invoices: "generate"` builds them from the quote's invoice settings, `invoices: "saved"` binds the plan saved on the quote, and no `invoices` binds none. | [Bind Quote](/api-reference/policies/bind-quote), the by-reference form of [Bind Quote by Reference or by Value](/api-reference/policies/bind-quote-by-reference-or-by-value), [Check Bind Conditions](/api-reference/policies/check-bind-conditions), and the five [quote invoicing](/api-reference/invoicing/quote-invoicing) endpoints that prepare them |
| **Value door** | Integrators who own billing themselves rather than relying on the quote's calculations | The request. You send the whole change, so you send its invoices too: an `invoicePlan`, or none. | The five policy transactions ([New Business](/api-reference/policies/new-business-transaction), [Endorse](/api-reference/policies/endorse-policy-transaction), [Cancel](/api-reference/policies/cancel-policy-transaction), [Reinstate](/api-reference/policies/reinstate-policy-transaction), [Renew](/api-reference/policies/renew-policy-transaction)) and the by-value form of [Bind Quote by Reference or by Value](/api-reference/policies/bind-quote-by-reference-or-by-value) |
| **After the bind** | Anyone re-planning a bound policy's invoices without changing the policy | The request: a plan that voids any set of the policy's invoices and creates any set, in one atomic step. | [Update Policy Invoices](/api-reference/invoicing/update-policy-invoices) |

## Nothing applies silently

Invoice behavior lives in the request, so the request you send predicts the
invoices you get. No invoices apply that the request does not name:

* A quote's saved plan applies only when its bind names it with
  `invoices: "saved"`. A bind that names no invoices while the quote holds a
  plan is refused (`409 finv2-quote-has-invoice-plan`) rather than applying it.
  A saved quote's bind binds the quote's state, so it never takes an
  `invoicePlan`: a plan you wrote goes on the quote first, where Check Bind
  Conditions can check it before anything commits.
* A value door creates exactly the invoices its `invoicePlan` creates and
  voids exactly the invoices it names. Without a plan it creates none.
* A refusal commits nothing and names its fix, with the ids of your request
  in any path it names. [Invoice plans](/api-reference/invoicing/invoice-plans#refusals)
  lists them.

Invoices need policy invoicing enabled for your company. With it disabled, a
request that names invoices (an `invoicePlan`, a bind's `invoices`, the
invoice batch or the quote invoicing endpoints) returns
`403 finv2-policy-invoicing-disabled` and saves nothing.

## The rule

A policy's active invoices add up to its billing, per line item, to the cent.
A plan names the invoices it voids; every invoice it does not name is kept and
counts toward the total. [Invoice plans](/api-reference/invoicing/invoice-plans)
explains the plan's shape, why the rule holds, credits, and how a stale plan
is refused.

## Five flows

All five use one policy: a year from 2026-01-01 whose billing states one line,
`Premium` on the `Policy Invoice` type, of 1,200.00. Billing states dollars
(`"amount": 1200`); a plan states cents (`"amountCents": 120000`). Every invoice
is issued to the same payee, an organization of the company.

The names (the `Policy Invoice` type, the `Premium` line item and its
`premium` classification) are this example company's. Use your company's own,
which [Export Financials Configuration](/api-reference/financials/export-financials-configuration)
lists. The request bodies show what invoicing needs; your company's policy
configuration may require more in `data`, such as a policy number, a time zone
or the insured.

### 1. Review, then bind

**Quote door.** You prepare the quote's invoices, review them, then bind
exactly what you reviewed.

1. Save the quote (for example with
   [Update Entity](/api-reference/entities/update-entity) after rating it). Its
   billing calculation states `fullTermBillingInfo`.

2. Choose the schedule, payees and endorsement handling.

   ```json PUT /api/v1/companies/{companyId}/quotes/{quoteId}/invoicing/settings theme={null}
   {
     "schedule": {
       "paymentPeriod": "quarterly",
       "installmentCount": 4,
       "firstDueDate": "2026-01-01",
       "owedLeadTimeDays": 0,
       "avoidWeekendSends": false,
       "downPayment": null
     },
     "payees": [
       { "group": "Policy Invoice", "payeeId": "550e8400-e29b-41d4-a716-446655440010" }
     ],
     "endorsementHandling": { "mode": "void", "status": "scheduled" }
   }
   ```

3. Generate the invoices onto the quote:
   `POST /api/v1/companies/{companyId}/quotes/{quoteId}/invoicing/generate`,
   with no body. The quote's `plan` now creates four `Premium` invoices of
   `30000` cents, due 2026-01-01, 2026-04-01, 2026-07-01 and 2026-10-01.

4. Review them with
   `GET /api/v1/companies/{companyId}/quotes/{quoteId}/invoicing`. Optionally,
   check the bind you are about to send:
   `GET /api/v1/companies/{companyId}/quotes/{quoteId}/bind-conditions?invoices=saved`
   answers `"readyToBind": true`.

5. Bind the plan you reviewed.

   ```json POST /api/v1/companies/{companyId}/quotes/{quoteId}/bind theme={null}
   { "invoices": "saved" }
   ```

**Outcome:** the new policy has the four invoices of the plan, `30000` cents
each, `120000` in all, which is its billing.

### 2. Generate at bind

**Quote door.** You let the bind build the invoices from the quote's settings.

1. Save the quote, as in flow 1. Choose its settings first if the company's
   payment defaults are not what you want.
2. Bind, generating as you go.

   ```json POST /api/v1/companies/{companyId}/quotes/{quoteId}/bind theme={null}
   { "invoices": "generate" }
   ```

**Outcome:** the policy's invoices are the ones
[Generate Quote Invoices](/api-reference/invoicing/generate-quote-invoices)
would build from the quote's saved settings at that moment: four quarterly
invoices of `30000` cents with the settings of flow 1. The quote keeps no plan
of them, and a plan already saved on the quote is not applied.

### 3. New business with a plan

**Value door.** You create the policy and state its twelve monthly invoices in
the same request.

```json POST /api/v1/companies/{companyId}/policies/transaction/new-business theme={null}
{
  "data": {
    "policyStatus": "active",
    "policyStartDate": { "date": "2026-01-01", "timezone": "America/New_York" },
    "policyEndDate": { "date": "2027-01-01", "timezone": "America/New_York" },
    "fullTermPricingInfo": {
      "pricingComponents": [
        { "label": "Premium", "classification": "premium", "value": 1200 }
      ]
    },
    "fullTermBillingInfo": {
      "lines": [
        { "invoiceType": "Policy Invoice", "lineItem": "Premium", "direction": "receivable", "amount": 1200 }
      ]
    }
  },
  "invoicePlan": {
    "incurredDate": "2026-01-01",
    "voidInvoices": [],
    "creates": [
      { "group": "Policy Invoice", "dueDate": "2026-01-01", "scheduledDate": "2026-01-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-02-01", "scheduledDate": "2026-02-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-03-01", "scheduledDate": "2026-03-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-04-01", "scheduledDate": "2026-04-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-05-01", "scheduledDate": "2026-05-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-06-01", "scheduledDate": "2026-06-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-07-01", "scheduledDate": "2026-07-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-08-01", "scheduledDate": "2026-08-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-09-01", "scheduledDate": "2026-09-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-10-01", "scheduledDate": "2026-10-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-11-01", "scheduledDate": "2026-11-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
      { "group": "Policy Invoice", "dueDate": "2026-12-01", "scheduledDate": "2026-12-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] }
    ]
  }
}
```

**Outcome:** the policy and its twelve invoices commit together, `10000`
cents each, `120000` in all. Each invoice is sent on its `scheduledDate`.

### 4. Mid-term endorsement

**Value door.** On 2026-10-15 the premium rises to 1,320.00. The ten invoices
due through October stay; the last two are replaced.

1. Read the policy's invoices and note the `id` and `headJournalId` of the two
   you will replace:
   `GET /api/v1/companies/{companyId}/financials/invoices?linkedPolicy={policyId}`.
2. Endorse, stating the new price and billing and the invoices that change.

   ```json POST /api/v1/companies/{companyId}/policies/{policyId}/transaction/endorse theme={null}
   {
     "effectiveDate": "2026-10-15",
     "fullTermPricingInfo": {
       "pricingComponents": [
         { "label": "Premium", "classification": "premium", "value": 1320 }
       ]
     },
     "fullTermBillingInfo": {
       "lines": [
         { "invoiceType": "Policy Invoice", "lineItem": "Premium", "direction": "receivable", "amount": 1320 }
       ]
     },
     "invoicePlan": {
       "incurredDate": "2026-10-15",
       "voidInvoices": [
         { "invoiceId": "550e8400-e29b-41d4-a716-446655440711", "headJournalId": "550e8400-e29b-41d4-a716-446655440911" },
         { "invoiceId": "550e8400-e29b-41d4-a716-446655440712", "headJournalId": "550e8400-e29b-41d4-a716-446655440912" }
       ],
       "creates": [
         { "group": "Policy Invoice", "dueDate": "2026-11-01", "scheduledDate": "2026-11-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 16000 }] },
         { "group": "Policy Invoice", "dueDate": "2026-12-01", "scheduledDate": "2026-12-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 16000 }] }
       ]
     }
   }
   ```

**Outcome:** kept plus new add up to the new billing: ten kept invoices of
`10000` and two new ones of `16000` make `132000` cents, which is 1,320.00. The
version and its invoices commit together. Had an invoice changed since you read
it, the endorsement would have been refused with
`409 finv2-invoice-head-conflict` and nothing saved; read the invoices again
and rebuild the plan.

### 5. Switch to monthly

**After the bind.** The policy of flow 1 has four quarterly invoices, and the
first is paid. On 2026-03-15 the insured asks to pay the rest monthly.

1. Read the policy's invoices, as in flow 4.
2. Void the three unpaid quarterly invoices and create nine monthly ones.

   ```json POST /api/v1/companies/{companyId}/financials/policies/{policyId}/invoices/batch theme={null}
   {
     "incurredDate": "2026-03-15",
     "voidInvoices": [
       { "invoiceId": "550e8400-e29b-41d4-a716-446655440702", "headJournalId": "550e8400-e29b-41d4-a716-446655440902" },
       { "invoiceId": "550e8400-e29b-41d4-a716-446655440703", "headJournalId": "550e8400-e29b-41d4-a716-446655440903" },
       { "invoiceId": "550e8400-e29b-41d4-a716-446655440704", "headJournalId": "550e8400-e29b-41d4-a716-446655440904" }
     ],
     "creates": [
       { "group": "Policy Invoice", "dueDate": "2026-04-01", "scheduledDate": "2026-04-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
       { "group": "Policy Invoice", "dueDate": "2026-05-01", "scheduledDate": "2026-05-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
       { "group": "Policy Invoice", "dueDate": "2026-06-01", "scheduledDate": "2026-06-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
       { "group": "Policy Invoice", "dueDate": "2026-07-01", "scheduledDate": "2026-07-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
       { "group": "Policy Invoice", "dueDate": "2026-08-01", "scheduledDate": "2026-08-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
       { "group": "Policy Invoice", "dueDate": "2026-09-01", "scheduledDate": "2026-09-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
       { "group": "Policy Invoice", "dueDate": "2026-10-01", "scheduledDate": "2026-10-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
       { "group": "Policy Invoice", "dueDate": "2026-11-01", "scheduledDate": "2026-11-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] },
       { "group": "Policy Invoice", "dueDate": "2026-12-01", "scheduledDate": "2026-12-01", "payeeId": "550e8400-e29b-41d4-a716-446655440010", "lineItems": [{ "label": "Premium", "amountCents": 10000 }] }
     ]
   }
   ```

**Outcome:** the same total on a new schedule: the paid quarterly invoice of
`30000` is kept, and nine monthly invoices of `10000` replace the three voided
ones, `120000` cents in all. The policy itself does not change.

## Where to go next

* [Invoice plans](/api-reference/invoicing/invoice-plans): the plan's fields,
  the add-up rule, credits, version checks and every refusal with its fix.
* [Quote invoicing](/api-reference/invoicing/quote-invoicing): a quote's
  settings, where payees and defaults come from, generating versus attaching,
  and endorsement handling.
* [Policy Transactions](/api-reference/policies/overview): the five
  transactions and the policy's billing.


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