Withdraws an invoice’s approval, for example when a bill was approved by
mistake, so a payment needs approval again before it posts. It is the
reverse of Approve Invoice (approveFinancialsInvoice) and works only
while the invoice has no payments; remove them first with Remove Payment
(removeFinancialsInvoicePayment).
Revokes the invoice’s approval — the invoice.unapproved action: it clears
approved / approvedAt and posts NOTHING to the books. The inverse of
approve.
Authority. Granting and revoking an approval are the SAME authority:
the calling key must hold invoice.approve. The company’s in-app
approval rules are never applied to API callers. A key without the
permission gets 403.
Preconditions (422). The invoice must not be paid or partially paid
(UNAPPROVE_PAID) — once live payments exist, the endpoint will not alter
approval state, so
remove the payments first. It
must also be neither voided (INVOICE_VOIDED) nor deleted
(INVOICE_DELETED). Unapproving a never-approved invoice is a DEFINED
no-op: still journaled, zero ledger rows, refreshed state returned.
Concurrency + idempotency. Requires If-Match (the invoice’s current
headJournalId); the body carries the client-minted actionId — an
identical retry replays the original outcome.
API key authentication. Send your raw API key as the Authorization header value with NO scheme prefix — Authorization: YOUR-API-KEY. Do NOT prefix it with Bearer or ApiKey, and do not use an X-API-Key header; those are not accepted.
Headers
If-Match
string<uuid>
required
The invoice's current headJournalId — the optimistic-concurrency watermark every single-invoice write after creation must send. Read it off any invoice read or write response and echo it verbatim (a bare uuid; an entity-tag dressing of it — "uuid" or W/"uuid" — is also accepted). Missing or malformed is a 400 (IF_MATCH_REQUIRED / IF_MATCH_INVALID); a stale value is a 409 IF_MATCH_CONFLICT whose body carries the current invoice. An idempotent actionId replay short-circuits BEFORE the watermark is evaluated.
Path Parameters
companyId
string<uuid>
required
Company identifier
invoiceId
string<uuid>
required
Invoice identifier
Body
application/json
actionId
string<uuid>
required
Client-minted idempotency key — becomes the action's journal id. An identical retry replays the original outcome; reuse with a different payload is 409 ACTION_ID_REUSED
author
string
Optional display label for the source system's author. Stamped as the journal record's display attribution; the acting principal stays the External API service user. Ignored on idempotent replays
Required string length: 1 - 255
Response
The invoice with its approval revoked — refreshed read state (approved: false)
The response of every single-invoice write — refreshed read state, not an ack: the emitted journal id(s), THE invoice row (identical shape to the reads — one invoice representation everywhere; its headJournalId is the next If-Match), and the invoice's live payments. An idempotent actionId replay returns this same shape rebuilt from the original outcome, server-minted values included.
journalIds
string<uuid>[]
required
Every journal id the write emitted — the anchor action's id (the actionId you supplied) first, then any engine-minted siblings (a multi-mark payment's additional marks) and any companion the horizon rule composed (e.g. the reserve unwind of a pre-horizon eroding payment's removal, or a delete's payment sweep)
Minimum array length: 1
invoice
object
required
THE invoice representation — the same shape everywhere an endpoint returns an invoice (listing rows, the detail read, and every write's refreshed-row response; the policy invoice batch's rows also carry approvedBy). headJournalId is the invoice's current journal head — the optimistic-concurrency token subsequent writes echo back as If-Match.
Show child attributes
payments
object[]
required
The invoice's live payment marks after the write, newest first
Show child attributes
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"AI Insurance","colors":{"primary":"#714CC5","light":"#D3BFFF","dark":"#A887F3"},"logo":{"light":"https://mintcdn.com/ai-insurance-fmv1/HtPQvD-FDA5nbM7L/logo/dark.jpg?fit=max\u0026auto=format\u0026n=HtPQvD-FDA5nbM7L\u0026q=85\u0026s=14ace86d6e87c6eab47960c514760266","dark":"https://mintcdn.com/ai-insurance-fmv1/HtPQvD-FDA5nbM7L/logo/dark.jpg?fit=max\u0026auto=format\u0026n=HtPQvD-FDA5nbM7L\u0026q=85\u0026s=14ace86d6e87c6eab47960c514760266","href":"https://go.aiinsurance.io"},"favicon":"https://mintcdn.com/ai-insurance-fmv1/HtPQvD-FDA5nbM7L/logo/dark.jpg?fit=max\u0026auto=format\u0026n=HtPQvD-FDA5nbM7L\u0026q=85\u0026s=14ace86d6e87c6eab47960c514760266","navbar":{"links":[{"href":"mailto:support@aiinsurance.io","label":"Support"}],"primary":{"type":"button","label":"Dashboard","href":"https://go.aiinsurance.io"}},"footer":{"socials":{"linkedin":"https://www.linkedin.com/company/a-i-insurance-inc"}},"seo":{"metatags":{"canonical":"https://docs.go.aiinsurance.io"}},"contextual":{"options":["copy","view","chatgpt","claude","perplexity"],"display":"header"},"styling":{"latex":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"ai-insurance-fmv1","hasAudioNarration":false,"actualSubdomain":"ai-insurance-fmv1","customDomains":["docs.go.aiinsurance.io"],"gitSource":{"type":"github","owner":"ai-insurance","repo":"docs-mirror","deployBranch":"main","contentDirectory":"docs","isPrivate":true,"mountPath":"","label":"","_id":"6af4b096ee8edba08e00c669"},"entitlements":{"AI_CHAT":{"status":"DISABLED"}},"buildId":"6af7498e75f3e5c02082a680","clientVersion":"0.0.4131","searchFilterCounts":[{"language":"default","tag":"API","count":244},{"language":"default","tag":"Financials","count":94},{"language":"default","tag":"App","count":35},{"language":"default","tag":"Policy Transactions","count":34},{"language":"default","tag":"Company Files","count":28},{"language":"default","tag":"Entities","count":25},{"language":"default","tag":"Record Emails","count":23},{"language":"default","tag":"Configuration","count":23},{"language":"default","tag":"Forms","count":18},{"language":"default","tag":"Guides","count":18}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/financials/unapprove-invoice","slug":"/api-reference/financials/unapprove-invoice","pageMetadata":{"title":"Unapprove Invoice","description":"Withdraws an invoice's approval, for example when a bill was approved by\nmistake, so a payment needs approval again before it posts. It is the\nreverse of Approve Invoice (`approveFinancialsInvoice`) and works only\nwhile the invoice has no payments; remove them first with Remove Payment\n(`removeFinancialsInvoicePayment`).\n\nRevokes the invoice's approval — the `invoice.unapproved` action: it clears\n`approved` / `approvedAt` and posts NOTHING to the books. The inverse of\n[approve](/api-reference/financials/approve-invoice).\n\n**Authority.** Granting and revoking an approval are the SAME authority:\nthe calling key must hold `invoice.approve`. The company's in-app\napproval rules are never applied to API callers. A key without the\npermission gets `403`.\n\n**Preconditions (`422`).** The invoice must not be paid or partially paid\n(`UNAPPROVE_PAID`) — once live payments exist, the endpoint will not alter\napproval state, so\n[remove the payments](/api-reference/financials/remove-payment) first. It\nmust also be neither voided (`INVOICE_VOIDED`) nor deleted\n(`INVOICE_DELETED`). Unapproving a never-approved invoice is a DEFINED\nno-op: still journaled, zero ledger rows, refreshed state returned.\n\n**Concurrency + idempotency.** Requires `If-Match` (the invoice's current\n`headJournalId`); the body carries the client-minted `actionId` — an\nidentical retry replays the original outcome.\n\n**Required permission:** `invoice.approve`\n","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/unapprove","href":"/api-reference/financials/unapprove-invoice","autogeneratedByOpenApi":true},"description":{"compiledSource":"\"use strict\";\nconst {Fragment: _Fragment, jsx: _jsx, jsxs: _jsxs} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n a: \"a\",\n code: \"code\",\n p: \"p\",\n strong: \"strong\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsxs(_Fragment, {\n children: [_jsxs(_components.p, {\n children: [\"Withdraws an invoice’s approval, for example when a bill was approved by\\nmistake, so a payment needs approval again before it posts. It is the\\nreverse of Approve Invoice (\", _jsx(_components.code, {\n children: \"approveFinancialsInvoice\"\n }), \") and works only\\nwhile the invoice has no payments; remove them first with Remove Payment\\n(\", _jsx(_components.code, {\n children: \"removeFinancialsInvoicePayment\"\n }), \").\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [\"Revokes the invoice’s approval — the \", _jsx(_components.code, {\n children: \"invoice.unapproved\"\n }), \" action: it clears\\n\", _jsx(_components.code, {\n children: \"approved\"\n }), \" / \", _jsx(_components.code, {\n children: \"approvedAt\"\n }), \" and posts NOTHING to the books. The inverse of\\n\", _jsx(_components.a, {\n href: \"/api-reference/financials/approve-invoice\",\n children: \"approve\"\n }), \".\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [_jsx(_components.strong, {\n children: \"Authority.\"\n }), \" Granting and revoking an approval are the SAME authority:\\nthe calling key must hold \", _jsx(_components.code, {\n children: \"invoice.approve\"\n }), \". The company’s in-app\\napproval rules are never applied to API callers. A key without the\\npermission gets \", _jsx(_components.code, {\n children: \"403\"\n }), \".\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [_jsxs(_components.strong, {\n children: [\"Preconditions (\", _jsx(_components.code, {\n children: \"422\"\n }), \").\"]\n }), \" The invoice must not be paid or partially paid\\n(\", _jsx(_components.code, {\n children: \"UNAPPROVE_PAID\"\n }), \") — once live payments exist, the endpoint will not alter\\napproval state, so\\n\", _jsx(_components.a, {\n href: \"/api-reference/financials/remove-payment\",\n children: \"remove the payments\"\n }), \" first. It\\nmust also be neither voided (\", _jsx(_components.code, {\n children: \"INVOICE_VOIDED\"\n }), \") nor deleted\\n(\", _jsx(_components.code, {\n children: \"INVOICE_DELETED\"\n }), \"). Unapproving a never-approved invoice is a DEFINED\\nno-op: still journaled, zero ledger rows, refreshed state returned.\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [_jsx(_components.strong, {\n children: \"Concurrency + idempotency.\"\n }), \" Requires \", _jsx(_components.code, {\n children: \"If-Match\"\n }), \" (the invoice’s current\\n\", _jsx(_components.code, {\n children: \"headJournalId\"\n }), \"); the body carries the client-minted \", _jsx(_components.code, {\n children: \"actionId\"\n }), \" — an\\nidentical retry replays the original outcome.\"]\n }), \"\\n\", _jsxs(_components.p, {\n children: [_jsx(_components.strong, {\n children: \"Required permission:\"\n }), \" \", _jsx(_components.code, {\n children: \"invoice.approve\"\n })]\n })]\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Unapprove Invoice","description":"Withdraws an invoice's approval, for example when a bill was approved by\nmistake, so a payment needs approval again before it posts. It is the\nreverse of Approve Invoice (`approveFinancialsInvoice`) and works only\nwhile the invoice has no payments; remove them first with Remove Payment\n(`removeFinancialsInvoicePayment`).\n\nRevokes the invoice's approval — the `invoice.unapproved` action: it clears\n`approved` / `approvedAt` and posts NOTHING to the books. The inverse of\n[approve](/api-reference/financials/approve-invoice).\n\n**Authority.** Granting and revoking an approval are the SAME authority:\nthe calling key must hold `invoice.approve`. The company's in-app\napproval rules are never applied to API callers. A key without the\npermission gets `403`.\n\n**Preconditions (`422`).** The invoice must not be paid or partially paid\n(`UNAPPROVE_PAID`) — once live payments exist, the endpoint will not alter\napproval state, so\n[remove the payments](/api-reference/financials/remove-payment) first. It\nmust also be neither voided (`INVOICE_VOIDED`) nor deleted\n(`INVOICE_DELETED`). Unapproving a never-approved invoice is a DEFINED\nno-op: still journaled, zero ledger rows, refreshed state returned.\n\n**Concurrency + idempotency.** Requires `If-Match` (the invoice's current\n`headJournalId`); the body carries the client-minted `actionId` — an\nidentical retry replays the original outcome.\n\n**Required permission:** `invoice.approve`\n","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/unapprove","href":"/api-reference/financials/unapprove-invoice","autogeneratedByOpenApi":true}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"operationId":"unapproveFinancialsInvoice","summary":"Unapprove Invoice","description":"Withdraws an invoice's approval, for example when a bill was approved by\nmistake, so a payment needs approval again before it posts. It is the\nreverse of Approve Invoice (`approveFinancialsInvoice`) and works only\nwhile the invoice has no payments; remove them first with Remove Payment\n(`removeFinancialsInvoicePayment`).\n\nRevokes the invoice's approval — the `invoice.unapproved` action: it clears\n`approved` / `approvedAt` and posts NOTHING to the books. The inverse of\n[approve](/api-reference/financials/approve-invoice).\n\n**Authority.** Granting and revoking an approval are the SAME authority:\nthe calling key must hold `invoice.approve`. The company's in-app\napproval rules are never applied to API callers. A key without the\npermission gets `403`.\n\n**Preconditions (`422`).** The invoice must not be paid or partially paid\n(`UNAPPROVE_PAID`) — once live payments exist, the endpoint will not alter\napproval state, so\n[remove the payments](/api-reference/financials/remove-payment) first. It\nmust also be neither voided (`INVOICE_VOIDED`) nor deleted\n(`INVOICE_DELETED`). Unapproving a never-approved invoice is a DEFINED\nno-op: still journaled, zero ledger rows, refreshed state returned.\n\n**Concurrency + idempotency.** Requires `If-Match` (the invoice's current\n`headJournalId`); the body carries the client-minted `actionId` — an\nidentical retry replays the original outcome.\n\n**Required permission:** `invoice.approve`\n","tags":["Financials"],"parameters":["3f140413-99c8-4829-8031-d14a40af25fe","3ed43062-a16b-4789-bb5a-2ce2127c65cc","925d2a69-db74-4860-9a69-9a6c67139eca"],"requestBody":"e0a29dd3-9ef1-4097-9b91-8d24729d1261","responses":{"200":"83dc8c80-85f9-4144-a81e-d58e8bdf8a41","400":"54a6dcb5-b886-42f6-be38-715778d41b55","401":"dbb44d7f-7c3c-41c2-afa3-ef7c14612fee","403":"ee26ce09-afe8-4c3c-b309-80bbb647826e","404":"a3a95f2c-e9bb-450f-9ee0-5289f54c68ce","409":"6e09fe30-11c9-4f31-8e94-545c06234685","422":"ec128c50-de05-4879-908a-86423cf58077","500":"f42129a0-931e-4cd2-b111-040644bcb637"},"method":"post","type":"path","servers":["b4993f5b-e21e-4dbd-8ace-9c59b5197d8e"],"security":["35370c79-340a-4ed7-a68a-8c786f4a2235"],"path":"/api/v1/companies/{companyId}/financials/invoices/{invoiceId}/unapprove","baseUrlOptions":["https://go.aiinsurance.io"],"title":"Unapprove Invoice","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{"3f140413-99c8-4829-8031-d14a40af25fe":{"name":"companyId","in":"path","required":true,"schema":{"type":"string","format":"uuid","isRequired":true,"description":"Company identifier","uniqueKey":"","typeLabel":"string\u003cuuid>"},"description":"Company identifier"},"3ed43062-a16b-4789-bb5a-2ce2127c65cc":{"name":"invoiceId","in":"path","required":true,"schema":{"type":"string","format":"uuid","isRequired":true,"description":"Invoice identifier","uniqueKey":"","typeLabel":"string\u003cuuid>"},"description":"Invoice identifier"},"925d2a69-db74-4860-9a69-9a6c67139eca":{"name":"If-Match","in":"header","required":true,"schema":{"type":"string","format":"uuid","isRequired":true,"description":"The invoice's current `headJournalId` — the optimistic-concurrency watermark every single-invoice write after creation must send. Read it off any invoice read or write response and echo it verbatim (a bare uuid; an entity-tag dressing of it — `\"uuid\"` or `W/\"uuid\"` — is also accepted). Missing or malformed is a `400` (`IF_MATCH_REQUIRED` / `IF_MATCH_INVALID`); a stale value is a `409 IF_MATCH_CONFLICT` whose body carries the current invoice. An idempotent `actionId` replay short-circuits BEFORE the watermark is evaluated.","uniqueKey":"","typeLabel":"string\u003cuuid>"},"description":"The invoice's current `headJournalId` — the optimistic-concurrency watermark every single-invoice write after creation must send. Read it off any invoice read or write response and echo it verbatim (a bare uuid; an entity-tag dressing of it — `\"uuid\"` or `W/\"uuid\"` — is also accepted). Missing or malformed is a `400` (`IF_MATCH_REQUIRED` / `IF_MATCH_INVALID`); a stale value is a `409 IF_MATCH_CONFLICT` whose body carries the current invoice. An idempotent `actionId` replay short-circuits BEFORE the watermark is evaluated."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["actionId"],"properties":{"actionId":{"type":"string","format":"uuid","description":"Client-minted idempotency key — becomes the action's journal id. An identical retry replays the original outcome; reuse with a different payload is `409 ACTION_ID_REUSED`","isRequired":true,"uniqueKey":"actionId","typeLabel":"string\u003cuuid>"},"author":{"type":"string","minLength":1,"maxLength":255,"description":"Optional display label for the source system's author. Stamped as the journal record's display attribution; the acting principal stays the External API service user. Ignored on idempotent replays","uniqueKey":"author","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"unapprove":{"title":"unapprove","value":{"actionId":"2c3d4e5f-6071-4823-9934-a5b6c7d8e9fa"}}},"exampleType":"examples"}},"exampleType":"examples"},"responses":{"83dc8c80-85f9-4144-a81e-d58e8bdf8a41":{"description":"The invoice with its approval revoked — refreshed read state (`approved: false`)","content":{"application/json":{"schema":{"type":"object","description":"The response of every single-invoice write — refreshed read state, not an ack: the emitted journal id(s), THE invoice row (identical shape to the reads — one invoice representation everywhere; its `headJournalId` is the next `If-Match`), and the invoice's live payments. An idempotent `actionId` replay returns this same shape rebuilt from the original outcome, server-minted values included.","required":["journalIds","invoice","payments"],"properties":{"journalIds":{"type":"array","minItems":1,"items":{"type":"string","format":"uuid","uniqueKey":"journalIds.items.[INDEX]","typeLabel":"string\u003cuuid>"},"description":"Every journal id the write emitted — the anchor action's id (the `actionId` you supplied) first, then any engine-minted siblings (a multi-mark payment's additional marks) and any companion the horizon rule composed (e.g. the reserve unwind of a pre-horizon eroding payment's removal, or a delete's payment sweep)","isRequired":true,"uniqueKey":"journalIds","typeLabel":"string\u003cuuid>[]"},"invoice":{"type":"object","description":"THE invoice representation — the same shape everywhere an endpoint returns an invoice (listing rows, the detail read, and every write's refreshed-row response; the policy invoice batch's rows also carry `approvedBy`). `headJournalId` is the invoice's current journal head — the optimistic-concurrency token subsequent writes echo back as `If-Match`.","required":["id","transactionId","invoiceNumber","categoryId","status","linkedEvent","linkedPolicy","linkedPayee","incurredDate","dueDate","memo","fieldData","lineItems","totalAmountCents","amountPaidCents","balanceDueCents","draftAmountPaidCents","paidDate","lastPaymentDate","voidedAt","deletedAt","approved","approvedAt","approvalRequired","createdAt","updatedAt","headJournalId"],"properties":{"id":{"type":"string","format":"uuid","description":"The invoice's id","isRequired":true,"uniqueKey":"invoice.id","typeLabel":"string\u003cuuid>"},"transactionId":{"type":"string","description":"The invoice's Transaction ID, `INV-XXXXXX-XXX`, generated by the server when the invoice is created. Unique per company, never reused, and never changed; it is the value that names an invoice to a person","isRequired":true,"uniqueKey":"invoice.transactionId","typeLabel":"string"},"invoiceNumber":{"oneOf":[{"type":"string","description":"The sender's invoice number: the number printed on the invoice by whoever issued it, or `null` when none was given. Free text with no uniqueness, so several invoices may share one. Set on create, event import or a policy invoice batch, and changeable through Update Invoice before and after posting. A policy invoice the batch creates defaults to its own `transactionId` here unless the batch names another","isRequired":true,"uniqueKey":"invoice.invoiceNumber.oneOf.0","typeLabel":"string"},{"type":"null","description":"The sender's invoice number: the number printed on the invoice by whoever issued it, or `null` when none was given. Free text with no uniqueness, so several invoices may share one. Set on create, event import or a policy invoice batch, and changeable through Update Invoice before and after posting. A policy invoice the batch creates defaults to its own `transactionId` here unless the batch names another","isRequired":true,"uniqueKey":"invoice.invoiceNumber.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.invoiceNumber","typeLabel":"string | null"},"categoryId":{"type":"string","format":"uuid","description":"The transaction category the invoice belongs to","isRequired":true,"uniqueKey":"invoice.categoryId","typeLabel":"string\u003cuuid>"},"status":{"type":"string","enum":["draft","no_charges","owed","partially_paid","paid","voided","deleted"],"description":"Derived status, first match wins: `deleted` → `draft` → `voided` → `no_charges` (every line item's amount is zero) → `paid` (every line item is settled — its amount minus its live marks is exactly zero) → `owed` (no live payment marks) → `partially_paid`. Settlement is per line: no scalar makes a document paid, and a zero-due document with unsettled lines still reads `owed`","isRequired":true,"uniqueKey":"invoice.status","typeLabel":"enum\u003cstring>"},"linkedEvent":{"oneOf":[{"type":"object","description":"The linked event, display-ready (the server resolves the display name), or `null` when not linked to an event","required":["id","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The linked event's id","isRequired":true,"uniqueKey":"invoice.linkedEvent.oneOf.0.id","typeLabel":"string\u003cuuid>"},"displayName":{"type":"string","description":"The linked event's display name","isRequired":true,"uniqueKey":"invoice.linkedEvent.oneOf.0.displayName","typeLabel":"string"}},"isRequired":true,"uniqueKey":"invoice.linkedEvent.oneOf.0","typeLabel":"object"},{"type":"null","description":"The linked event, display-ready (the server resolves the display name), or `null` when not linked to an event","required":["id","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The linked event's id"},"displayName":{"type":"string","description":"The linked event's display name"}},"isRequired":true,"uniqueKey":"invoice.linkedEvent.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.linkedEvent","typeLabel":"object | null"},"linkedPolicy":{"oneOf":[{"type":"object","description":"The linked policy, display-ready, or `null`. An invoice links to an event or a policy, never both","required":["id","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The linked policy's id","isRequired":true,"uniqueKey":"invoice.linkedPolicy.oneOf.0.id","typeLabel":"string\u003cuuid>"},"displayName":{"type":"string","description":"The linked policy's display name","isRequired":true,"uniqueKey":"invoice.linkedPolicy.oneOf.0.displayName","typeLabel":"string"}},"isRequired":true,"uniqueKey":"invoice.linkedPolicy.oneOf.0","typeLabel":"object"},{"type":"null","description":"The linked policy, display-ready, or `null`. An invoice links to an event or a policy, never both","required":["id","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The linked policy's id"},"displayName":{"type":"string","description":"The linked policy's display name"}},"isRequired":true,"uniqueKey":"invoice.linkedPolicy.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.linkedPolicy","typeLabel":"object | null"},"linkedPayee":{"oneOf":[{"type":"object","description":"The invoice's payee, display-ready, or `null` when none is set. `entityType` is an open string (e.g. `Person`, `Organization`) — the payee vocabulary is the entity module's, not part of this contract","required":["id","entityType","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The payee entity's id","isRequired":true,"uniqueKey":"invoice.linkedPayee.oneOf.0.id","typeLabel":"string\u003cuuid>"},"entityType":{"type":"string","description":"The payee's entity type (e.g. Person, Organization)","isRequired":true,"uniqueKey":"invoice.linkedPayee.oneOf.0.entityType","typeLabel":"string"},"displayName":{"type":"string","description":"The payee's display name","isRequired":true,"uniqueKey":"invoice.linkedPayee.oneOf.0.displayName","typeLabel":"string"}},"isRequired":true,"uniqueKey":"invoice.linkedPayee.oneOf.0","typeLabel":"object"},{"type":"null","description":"The invoice's payee, display-ready, or `null` when none is set. `entityType` is an open string (e.g. `Person`, `Organization`) — the payee vocabulary is the entity module's, not part of this contract","required":["id","entityType","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The payee entity's id"},"entityType":{"type":"string","description":"The payee's entity type (e.g. Person, Organization)"},"displayName":{"type":"string","description":"The payee's display name"}},"isRequired":true,"uniqueKey":"invoice.linkedPayee.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.linkedPayee","typeLabel":"object | null"},"incurredDate":{"oneOf":[{"type":"string","format":"date","description":"The date the charges were incurred (ISO `YYYY-MM-DD`), or `null`","isRequired":true,"uniqueKey":"invoice.incurredDate.oneOf.0","typeLabel":"string\u003cdate>"},{"type":"null","format":"date","description":"The date the charges were incurred (ISO `YYYY-MM-DD`), or `null`","isRequired":true,"uniqueKey":"invoice.incurredDate.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.incurredDate","typeLabel":"string\u003cdate> | null"},"dueDate":{"oneOf":[{"type":"string","format":"date","description":"When payment is owed (display metadata only), or `null`","isRequired":true,"uniqueKey":"invoice.dueDate.oneOf.0","typeLabel":"string\u003cdate>"},{"type":"null","format":"date","description":"When payment is owed (display metadata only), or `null`","isRequired":true,"uniqueKey":"invoice.dueDate.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.dueDate","typeLabel":"string\u003cdate> | null"},"memo":{"oneOf":[{"type":"string","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"invoice.memo.oneOf.0","typeLabel":"string"},{"type":"null","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"invoice.memo.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.memo","typeLabel":"string | null"},"fieldData":{"oneOf":[{"type":"object","additionalProperties":true,"description":"Values for the tenant-defined custom invoice fields, keyed by field referenceId — an opaque JSON object, or `null`","isRequired":true,"uniqueKey":"invoice.fieldData.oneOf.0","typeLabel":"object"},{"type":"null","additionalProperties":true,"description":"Values for the tenant-defined custom invoice fields, keyed by field referenceId — an opaque JSON object, or `null`","isRequired":true,"uniqueKey":"invoice.fieldData.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.fieldData","typeLabel":"object | null"},"lineItems":{"type":"array","description":"The invoice's line items","items":{"type":"object","description":"A stored invoice line item as rendered on invoice reads.","required":["lineItemId","lineItemTypeId","memo","amountCents"],"properties":{"lineItemId":{"type":"string","format":"uuid","description":"The line item's id","isRequired":true,"uniqueKey":"invoice.lineItems.items.[INDEX].lineItemId","typeLabel":"string\u003cuuid>"},"lineItemTypeId":{"type":"string","format":"uuid","description":"The configured line item type this item cites — discover ids with `GET /api/v1/companies/{companyId}/financials/config/categories`","isRequired":true,"uniqueKey":"invoice.lineItems.items.[INDEX].lineItemTypeId","typeLabel":"string\u003cuuid>"},"memo":{"oneOf":[{"type":"string","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"invoice.lineItems.items.[INDEX].memo.oneOf.0","typeLabel":"string"},{"type":"null","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"invoice.lineItems.items.[INDEX].memo.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.lineItems.items.[INDEX].memo","typeLabel":"string | null"},"amountCents":{"type":"integer","description":"The line item's signed amount in integer cents; a negative amount is a credit within the item's own frame — it posts opposite the line item type's expected direction (e.g. a reversal or refund); the posting rule always comes from the type, never the sign","isRequired":true,"uniqueKey":"invoice.lineItems.items.[INDEX].amountCents","typeLabel":"integer"}},"uniqueKey":"invoice.lineItems.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"invoice.lineItems","typeLabel":"object[]"},"totalAmountCents":{"type":"integer","description":"Sum of the ORIENTED line-item amounts (a payable-direction line counts +, a receivable-direction line counts −), in integer cents — the net cash the document commits to move","isRequired":true,"uniqueKey":"invoice.totalAmountCents","typeLabel":"integer"},"amountPaidCents":{"type":"integer","description":"Sum of the ORIENTED live payment marks, in integer cents — the net cash moved so far","isRequired":true,"uniqueKey":"invoice.amountPaidCents","typeLabel":"integer"},"balanceDueCents":{"type":"integer","description":"`totalAmountCents - amountPaidCents`, in integer cents — the net cash remaining to move: positive = out, negative = in. May move non-monotonically as opposite-direction lines settle. A voided invoice keeps its amounts here and in `totalAmountCents`, although it no longer owes anything, so leave voided invoices out when adding up what is owed","isRequired":true,"uniqueKey":"invoice.balanceDueCents","typeLabel":"integer"},"draftAmountPaidCents":{"oneOf":[{"type":"integer","description":"A DRAFT's annex-derived paid total: the oriented net-cash sum of the payment marks the draft was born carrying (the same frame as `amountPaidCents`, which counts LIVE posted marks only and reads 0 while drafting) — what a draft's underlying payment picture will read once finalized. `null` on non-draft invoices (the annex is spent at finalize). Display-only — never a posted ledger amount","isRequired":true,"uniqueKey":"invoice.draftAmountPaidCents.oneOf.0","typeLabel":"integer"},{"type":"null","description":"A DRAFT's annex-derived paid total: the oriented net-cash sum of the payment marks the draft was born carrying (the same frame as `amountPaidCents`, which counts LIVE posted marks only and reads 0 while drafting) — what a draft's underlying payment picture will read once finalized. `null` on non-draft invoices (the annex is spent at finalize). Display-only — never a posted ledger amount","isRequired":true,"uniqueKey":"invoice.draftAmountPaidCents.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.draftAmountPaidCents","typeLabel":"integer | null"},"paidDate":{"oneOf":[{"type":"string","format":"date","description":"Payment date of the mark that first made every line item settled; clears (`null`) whenever any line reopens","isRequired":true,"uniqueKey":"invoice.paidDate.oneOf.0","typeLabel":"string\u003cdate>"},{"type":"null","format":"date","description":"Payment date of the mark that first made every line item settled; clears (`null`) whenever any line reopens","isRequired":true,"uniqueKey":"invoice.paidDate.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.paidDate","typeLabel":"string\u003cdate> | null"},"lastPaymentDate":{"oneOf":[{"type":"string","format":"date","description":"Date of the most recent live payment, or `null`","isRequired":true,"uniqueKey":"invoice.lastPaymentDate.oneOf.0","typeLabel":"string\u003cdate>"},{"type":"null","format":"date","description":"Date of the most recent live payment, or `null`","isRequired":true,"uniqueKey":"invoice.lastPaymentDate.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.lastPaymentDate","typeLabel":"string\u003cdate> | null"},"voidedAt":{"oneOf":[{"type":"string","format":"date-time","description":"When the invoice was voided, or `null`","isRequired":true,"uniqueKey":"invoice.voidedAt.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","format":"date-time","description":"When the invoice was voided, or `null`","isRequired":true,"uniqueKey":"invoice.voidedAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.voidedAt","typeLabel":"string\u003cdate-time> | null"},"deletedAt":{"oneOf":[{"type":"string","format":"date-time","description":"When the invoice was deleted, or `null`","isRequired":true,"uniqueKey":"invoice.deletedAt.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","format":"date-time","description":"When the invoice was deleted, or `null`","isRequired":true,"uniqueKey":"invoice.deletedAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.deletedAt","typeLabel":"string\u003cdate-time> | null"},"approved":{"type":"boolean","description":"The approval projection: `true` after `invoice.approved`, cleared only by `invoice.unapproved` — an edit never resets approval (the approval-relevant facts, line items and category, are immutable once posted)","isRequired":true,"uniqueKey":"invoice.approved","typeLabel":"boolean"},"approvedAt":{"oneOf":[{"type":"string","format":"date-time","description":"When the approval landed (`invoice.approved`), or `null` while unapproved — `approved` is exactly `approvedAt != null`","isRequired":true,"uniqueKey":"invoice.approvedAt.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","format":"date-time","description":"When the approval landed (`invoice.approved`), or `null` while unapproved — `approved` is exactly `approvedAt != null`","isRequired":true,"uniqueKey":"invoice.approvedAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"invoice.approvedAt","typeLabel":"string\u003cdate-time> | null"},"approvalRequired":{"type":"boolean","description":"Whether approval applies to this invoice. A money-out invoice (a positive `totalAmountCents`) requires approval when its type's \"Money-out invoices require approval\" setting is on; a money-in invoice (negative total) never does, and a zero total follows its type's expected direction. The value is recorded on the invoice when it is created, so a later change to the type's setting does not alter it. When `false`, Record Payment goes through without an approval, and any approval the invoice carries (`approved`) is kept but no longer matters.","isRequired":true,"uniqueKey":"invoice.approvalRequired","typeLabel":"boolean"},"createdAt":{"type":"string","format":"date-time","description":"When the invoice was created","isRequired":true,"uniqueKey":"invoice.createdAt","typeLabel":"string\u003cdate-time>"},"updatedAt":{"type":"string","format":"date-time","description":"When the invoice last changed","isRequired":true,"uniqueKey":"invoice.updatedAt","typeLabel":"string\u003cdate-time>"},"headJournalId":{"type":"string","format":"uuid","description":"The invoice's current journal head — send it as `If-Match` on the next write to this invoice; a mismatch is a `409` carrying the current row","isRequired":true,"uniqueKey":"invoice.headJournalId","typeLabel":"string\u003cuuid>"}},"isRequired":true,"uniqueKey":"invoice","typeLabel":"object"},"payments":{"type":"array","description":"The invoice's live payment marks after the write, newest first","items":{"type":"object","description":"A recorded payment MARK on an invoice: one row = one per-line settlement mark against `lineItemId`. `amountCents` is signed in the LINE's frame — its sign matches the line's open remaining, and the mark settles that line toward zero. One journal action per mark (`journalId` is the record that created it), each independently removable by `id`; one gesture (e.g. paying a document's whole balance due) may create several marks. `erodeReserves` is the caller's choice at record time (`null` where the invoice's category has no reserves to erode).","required":["id","journalId","lineItemId","amountCents","paymentDate","erodeReserves","memo","createdAt"],"properties":{"id":{"type":"string","format":"uuid","description":"The payment mark's id — the handle for removing it","isRequired":true,"uniqueKey":"payments.items.[INDEX].id","typeLabel":"string\u003cuuid>"},"journalId":{"type":"string","format":"uuid","description":"The journal record that recorded the mark","isRequired":true,"uniqueKey":"payments.items.[INDEX].journalId","typeLabel":"string\u003cuuid>"},"lineItemId":{"type":"string","format":"uuid","description":"The invoice line item the mark settles","isRequired":true,"uniqueKey":"payments.items.[INDEX].lineItemId","typeLabel":"string\u003cuuid>"},"amountCents":{"type":"integer","description":"The mark's amount in signed integer cents, in its line item's frame — the sign matches the line's remaining and the mark settles it toward zero","isRequired":true,"uniqueKey":"payments.items.[INDEX].amountCents","typeLabel":"integer"},"paymentDate":{"type":"string","format":"date","description":"The payment date (ISO `YYYY-MM-DD`)","isRequired":true,"uniqueKey":"payments.items.[INDEX].paymentDate","typeLabel":"string\u003cdate>"},"erodeReserves":{"oneOf":[{"type":"boolean","description":"Whether the mark erodes the linked event's reserves; `null` where the invoice's category carries no reserves","isRequired":true,"uniqueKey":"payments.items.[INDEX].erodeReserves.oneOf.0","typeLabel":"boolean"},{"type":"null","description":"Whether the mark erodes the linked event's reserves; `null` where the invoice's category carries no reserves","isRequired":true,"uniqueKey":"payments.items.[INDEX].erodeReserves.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"payments.items.[INDEX].erodeReserves","typeLabel":"boolean | null"},"memo":{"oneOf":[{"type":"string","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"payments.items.[INDEX].memo.oneOf.0","typeLabel":"string"},{"type":"null","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"payments.items.[INDEX].memo.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"payments.items.[INDEX].memo","typeLabel":"string | null"},"createdAt":{"type":"string","format":"date-time","description":"When the mark was recorded","isRequired":true,"uniqueKey":"payments.items.[INDEX].createdAt","typeLabel":"string\u003cdate-time>"}},"uniqueKey":"payments.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"payments","typeLabel":"object[]"}},"uniqueKey":"","typeLabel":"object"},"examples":{"unapproved":{"title":"unapproved","value":{"journalIds":["2c3d4e5f-6071-4823-9934-a5b6c7d8e9fa"],"invoice":{"id":"550e8400-e29b-41d4-a716-446655440700","transactionId":"INV-389538-455","invoiceNumber":"SL-2026-0412","categoryId":"550e8400-e29b-41d4-a716-446655440100","status":"owed","linkedEvent":{"id":"550e8400-e29b-41d4-a716-446655440200","displayName":"Claim #1042"},"linkedPolicy":null,"linkedPayee":null,"incurredDate":"2026-06-01","dueDate":null,"memo":"Legal defense","fieldData":null,"lineItems":[{"lineItemId":"550e8400-e29b-41d4-a716-446655440300","lineItemTypeId":"550e8400-e29b-41d4-a716-446655440110","memo":null,"amountCents":10000}],"totalAmountCents":10000,"amountPaidCents":0,"balanceDueCents":10000,"draftAmountPaidCents":null,"paidDate":null,"lastPaymentDate":null,"approved":false,"approvedAt":null,"approvalRequired":true,"voidedAt":null,"deletedAt":null,"createdAt":"2026-06-01T10:30:00.000Z","updatedAt":"2026-06-14T12:05:00.000Z","headJournalId":"2c3d4e5f-6071-4823-9934-a5b6c7d8e9fa"},"payments":[]}}},"exampleType":"examples"}},"exampleType":"examples"},"54a6dcb5-b886-42f6-be38-715778d41b55":{"description":"Bad Request — a malformed payload or a missing/malformed `If-Match` header (`IF_MATCH_REQUIRED` / `IF_MATCH_INVALID`)","content":{"application/json":{"schema":{"type":"object","description":"Standard error response for all external API endpoints","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Machine-readable error code","example":"VALIDATION_ERROR","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"submissionId: Required field is missing","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"userMessages":{"type":"array","description":"Clean, verbatim-displayable messages — one entry per failure, free of error-code tags, field paths, and internal noise. Suitable for showing to end users as-is.","items":{"type":"string","uniqueKey":"error.userMessages.items.[INDEX]","typeLabel":"string"},"example":["Exposures of type 'company' require an address"],"uniqueKey":"error.userMessages","typeLabel":"string[]"},"details":{"type":"array","description":"Additional details for validation errors (field-level errors)","items":{"type":"object","properties":{"field":{"type":"string","description":"The field that caused the error","example":"submissionId","uniqueKey":"error.details.items.[INDEX].field","typeLabel":"string"},"code":{"type":"string","description":"Stable problem code for this individual validation failure","example":"BLANK_LIST_ELEMENT","uniqueKey":"error.details.items.[INDEX].code","typeLabel":"string"},"reason":{"type":"string","description":"Stable reason the value violates its canonical contract","example":"blank-list-element","uniqueKey":"error.details.items.[INDEX].reason","typeLabel":"string"},"expected":{"type":"string","description":"The expected canonical value contract","example":"nonblank trimmed string","uniqueKey":"error.details.items.[INDEX].expected","typeLabel":"string"},"message":{"type":"string","description":"Description of the field error","example":"Required field is missing","uniqueKey":"error.details.items.[INDEX].message","typeLabel":"string"}},"uniqueKey":"error.details.items.[INDEX]","typeLabel":"object"},"uniqueKey":"error.details","typeLabel":"object[]"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"ifMatchInvalid":{"title":"ifMatchInvalid","value":{"error":{"code":"IF_MATCH_INVALID","message":"The If-Match header must be the invoice's headJournalId (a uuid).","userMessages":["The If-Match header must be the invoice's headJournalId (a uuid)."]}}}},"exampleType":"examples"}},"exampleType":"examples"},"dbb44d7f-7c3c-41c2-afa3-ef7c14612fee":{"description":"Unauthorized - Invalid or missing API key","content":{"application/json":{"schema":{"type":"object","description":"Standard error response for all external API endpoints","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Machine-readable error code","example":"VALIDATION_ERROR","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"submissionId: Required field is missing","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"userMessages":{"type":"array","description":"Clean, verbatim-displayable messages — one entry per failure, free of error-code tags, field paths, and internal noise. Suitable for showing to end users as-is.","items":{"type":"string","uniqueKey":"error.userMessages.items.[INDEX]","typeLabel":"string"},"example":["Exposures of type 'company' require an address"],"uniqueKey":"error.userMessages","typeLabel":"string[]"},"details":{"type":"array","description":"Additional details for validation errors (field-level errors)","items":{"type":"object","properties":{"field":{"type":"string","description":"The field that caused the error","example":"submissionId","uniqueKey":"error.details.items.[INDEX].field","typeLabel":"string"},"code":{"type":"string","description":"Stable problem code for this individual validation failure","example":"BLANK_LIST_ELEMENT","uniqueKey":"error.details.items.[INDEX].code","typeLabel":"string"},"reason":{"type":"string","description":"Stable reason the value violates its canonical contract","example":"blank-list-element","uniqueKey":"error.details.items.[INDEX].reason","typeLabel":"string"},"expected":{"type":"string","description":"The expected canonical value contract","example":"nonblank trimmed string","uniqueKey":"error.details.items.[INDEX].expected","typeLabel":"string"},"message":{"type":"string","description":"Description of the field error","example":"Required field is missing","uniqueKey":"error.details.items.[INDEX].message","typeLabel":"string"}},"uniqueKey":"error.details.items.[INDEX]","typeLabel":"object"},"uniqueKey":"error.details","typeLabel":"object[]"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"missingApiKey":{"title":"missingApiKey","value":{"error":{"code":"AuthenticationError","message":"API key authentication required","userMessages":["API key authentication required"]}}},"invalidApiKey":{"title":"invalidApiKey","value":{"error":{"code":"AuthenticationError","message":"Invalid API key","userMessages":["Invalid API key"]}}}},"exampleType":"examples"}},"exampleType":"examples"},"ee26ce09-afe8-4c3c-b309-80bbb647826e":{"description":"Forbidden - Insufficient permissions","content":{"application/json":{"schema":{"type":"object","description":"Standard error response for all external API endpoints","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Machine-readable error code","example":"VALIDATION_ERROR","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"submissionId: Required field is missing","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"userMessages":{"type":"array","description":"Clean, verbatim-displayable messages — one entry per failure, free of error-code tags, field paths, and internal noise. Suitable for showing to end users as-is.","items":{"type":"string","uniqueKey":"error.userMessages.items.[INDEX]","typeLabel":"string"},"example":["Exposures of type 'company' require an address"],"uniqueKey":"error.userMessages","typeLabel":"string[]"},"details":{"type":"array","description":"Additional details for validation errors (field-level errors)","items":{"type":"object","properties":{"field":{"type":"string","description":"The field that caused the error","example":"submissionId","uniqueKey":"error.details.items.[INDEX].field","typeLabel":"string"},"code":{"type":"string","description":"Stable problem code for this individual validation failure","example":"BLANK_LIST_ELEMENT","uniqueKey":"error.details.items.[INDEX].code","typeLabel":"string"},"reason":{"type":"string","description":"Stable reason the value violates its canonical contract","example":"blank-list-element","uniqueKey":"error.details.items.[INDEX].reason","typeLabel":"string"},"expected":{"type":"string","description":"The expected canonical value contract","example":"nonblank trimmed string","uniqueKey":"error.details.items.[INDEX].expected","typeLabel":"string"},"message":{"type":"string","description":"Description of the field error","example":"Required field is missing","uniqueKey":"error.details.items.[INDEX].message","typeLabel":"string"}},"uniqueKey":"error.details.items.[INDEX]","typeLabel":"object"},"uniqueKey":"error.details","typeLabel":"object[]"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"insufficientPermissions":{"title":"insufficientPermissions","value":{"error":{"code":"AuthorizationError","message":"User is not authorized to perform the requested action","userMessages":["User is not authorized to perform the requested action"]}}},"companyMismatch":{"title":"companyMismatch","value":{"error":{"code":"AuthorizationError","message":"API key is not scoped to the requested company","userMessages":["API key is not scoped to the requested company"]}}}},"exampleType":"examples"}},"exampleType":"examples"},"a3a95f2c-e9bb-450f-9ee0-5289f54c68ce":{"description":"Not Found — no invoice with this id","content":{"application/json":{"schema":{"type":"object","description":"Standard error response for all external API endpoints","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Machine-readable error code","example":"VALIDATION_ERROR","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"submissionId: Required field is missing","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"userMessages":{"type":"array","description":"Clean, verbatim-displayable messages — one entry per failure, free of error-code tags, field paths, and internal noise. Suitable for showing to end users as-is.","items":{"type":"string","uniqueKey":"error.userMessages.items.[INDEX]","typeLabel":"string"},"example":["Exposures of type 'company' require an address"],"uniqueKey":"error.userMessages","typeLabel":"string[]"},"details":{"type":"array","description":"Additional details for validation errors (field-level errors)","items":{"type":"object","properties":{"field":{"type":"string","description":"The field that caused the error","example":"submissionId","uniqueKey":"error.details.items.[INDEX].field","typeLabel":"string"},"code":{"type":"string","description":"Stable problem code for this individual validation failure","example":"BLANK_LIST_ELEMENT","uniqueKey":"error.details.items.[INDEX].code","typeLabel":"string"},"reason":{"type":"string","description":"Stable reason the value violates its canonical contract","example":"blank-list-element","uniqueKey":"error.details.items.[INDEX].reason","typeLabel":"string"},"expected":{"type":"string","description":"The expected canonical value contract","example":"nonblank trimmed string","uniqueKey":"error.details.items.[INDEX].expected","typeLabel":"string"},"message":{"type":"string","description":"Description of the field error","example":"Required field is missing","uniqueKey":"error.details.items.[INDEX].message","typeLabel":"string"}},"uniqueKey":"error.details.items.[INDEX]","typeLabel":"object"},"uniqueKey":"error.details","typeLabel":"object[]"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"invoiceNotFound":{"title":"invoiceNotFound","value":{"error":{"code":"NotFoundError","message":"Invoice not found","userMessages":["Invoice not found"]}}}},"exampleType":"examples"}},"exampleType":"examples"},"6e09fe30-11c9-4f31-8e94-545c06234685":{"description":"Conflict — a stale `If-Match` watermark (`IF_MATCH_CONFLICT`: the body carries the invoice's CURRENT row; re-read, reconcile, retry with its `headJournalId`), or an `actionId` reused by a different action (`ACTION_ID_REUSED`: supply a fresh uuid — an identical retry replays instead).","content":{"application/json":{"schema":{"type":"object","description":"The conflict envelope of an `If-Match` invoice write. `IF_MATCH_CONFLICT`: the supplied watermark is stale — `error.currentInvoice` is the invoice's CURRENT row; re-read, reconcile, and retry with its `headJournalId`. `ACTION_ID_REUSED`: the `actionId` names a different recorded action (no `currentInvoice`).","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["IF_MATCH_CONFLICT","ACTION_ID_REUSED"],"description":"Which conflict occurred","isRequired":true,"uniqueKey":"error.code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable error message","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"userMessages":{"type":"array","description":"Clean, verbatim-displayable messages","items":{"type":"string","uniqueKey":"error.userMessages.items.[INDEX]","typeLabel":"string"},"uniqueKey":"error.userMessages","typeLabel":"string[]"},"currentInvoice":{"type":"object","description":"Present exactly when `code` is `IF_MATCH_CONFLICT` — the invoice's current row; its `headJournalId` is the fresh `If-Match` value for the retry","required":["id","transactionId","invoiceNumber","categoryId","status","linkedEvent","linkedPolicy","linkedPayee","incurredDate","dueDate","memo","fieldData","lineItems","totalAmountCents","amountPaidCents","balanceDueCents","draftAmountPaidCents","paidDate","lastPaymentDate","voidedAt","deletedAt","approved","approvedAt","approvalRequired","createdAt","updatedAt","headJournalId"],"properties":{"id":{"type":"string","format":"uuid","description":"The invoice's id","isRequired":true,"uniqueKey":"error.currentInvoice.id","typeLabel":"string\u003cuuid>"},"transactionId":{"type":"string","description":"The invoice's Transaction ID, `INV-XXXXXX-XXX`, generated by the server when the invoice is created. Unique per company, never reused, and never changed; it is the value that names an invoice to a person","isRequired":true,"uniqueKey":"error.currentInvoice.transactionId","typeLabel":"string"},"invoiceNumber":{"oneOf":[{"type":"string","description":"The sender's invoice number: the number printed on the invoice by whoever issued it, or `null` when none was given. Free text with no uniqueness, so several invoices may share one. Set on create, event import or a policy invoice batch, and changeable through Update Invoice before and after posting. A policy invoice the batch creates defaults to its own `transactionId` here unless the batch names another","isRequired":true,"uniqueKey":"error.currentInvoice.invoiceNumber.oneOf.0","typeLabel":"string"},{"type":"null","description":"The sender's invoice number: the number printed on the invoice by whoever issued it, or `null` when none was given. Free text with no uniqueness, so several invoices may share one. Set on create, event import or a policy invoice batch, and changeable through Update Invoice before and after posting. A policy invoice the batch creates defaults to its own `transactionId` here unless the batch names another","isRequired":true,"uniqueKey":"error.currentInvoice.invoiceNumber.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.invoiceNumber","typeLabel":"string | null"},"categoryId":{"type":"string","format":"uuid","description":"The transaction category the invoice belongs to","isRequired":true,"uniqueKey":"error.currentInvoice.categoryId","typeLabel":"string\u003cuuid>"},"status":{"type":"string","enum":["draft","no_charges","owed","partially_paid","paid","voided","deleted"],"description":"Derived status, first match wins: `deleted` → `draft` → `voided` → `no_charges` (every line item's amount is zero) → `paid` (every line item is settled — its amount minus its live marks is exactly zero) → `owed` (no live payment marks) → `partially_paid`. Settlement is per line: no scalar makes a document paid, and a zero-due document with unsettled lines still reads `owed`","isRequired":true,"uniqueKey":"error.currentInvoice.status","typeLabel":"enum\u003cstring>"},"linkedEvent":{"oneOf":[{"type":"object","description":"The linked event, display-ready (the server resolves the display name), or `null` when not linked to an event","required":["id","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The linked event's id","isRequired":true,"uniqueKey":"error.currentInvoice.linkedEvent.oneOf.0.id","typeLabel":"string\u003cuuid>"},"displayName":{"type":"string","description":"The linked event's display name","isRequired":true,"uniqueKey":"error.currentInvoice.linkedEvent.oneOf.0.displayName","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error.currentInvoice.linkedEvent.oneOf.0","typeLabel":"object"},{"type":"null","description":"The linked event, display-ready (the server resolves the display name), or `null` when not linked to an event","required":["id","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The linked event's id"},"displayName":{"type":"string","description":"The linked event's display name"}},"isRequired":true,"uniqueKey":"error.currentInvoice.linkedEvent.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.linkedEvent","typeLabel":"object | null"},"linkedPolicy":{"oneOf":[{"type":"object","description":"The linked policy, display-ready, or `null`. An invoice links to an event or a policy, never both","required":["id","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The linked policy's id","isRequired":true,"uniqueKey":"error.currentInvoice.linkedPolicy.oneOf.0.id","typeLabel":"string\u003cuuid>"},"displayName":{"type":"string","description":"The linked policy's display name","isRequired":true,"uniqueKey":"error.currentInvoice.linkedPolicy.oneOf.0.displayName","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error.currentInvoice.linkedPolicy.oneOf.0","typeLabel":"object"},{"type":"null","description":"The linked policy, display-ready, or `null`. An invoice links to an event or a policy, never both","required":["id","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The linked policy's id"},"displayName":{"type":"string","description":"The linked policy's display name"}},"isRequired":true,"uniqueKey":"error.currentInvoice.linkedPolicy.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.linkedPolicy","typeLabel":"object | null"},"linkedPayee":{"oneOf":[{"type":"object","description":"The invoice's payee, display-ready, or `null` when none is set. `entityType` is an open string (e.g. `Person`, `Organization`) — the payee vocabulary is the entity module's, not part of this contract","required":["id","entityType","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The payee entity's id","isRequired":true,"uniqueKey":"error.currentInvoice.linkedPayee.oneOf.0.id","typeLabel":"string\u003cuuid>"},"entityType":{"type":"string","description":"The payee's entity type (e.g. Person, Organization)","isRequired":true,"uniqueKey":"error.currentInvoice.linkedPayee.oneOf.0.entityType","typeLabel":"string"},"displayName":{"type":"string","description":"The payee's display name","isRequired":true,"uniqueKey":"error.currentInvoice.linkedPayee.oneOf.0.displayName","typeLabel":"string"}},"isRequired":true,"uniqueKey":"error.currentInvoice.linkedPayee.oneOf.0","typeLabel":"object"},{"type":"null","description":"The invoice's payee, display-ready, or `null` when none is set. `entityType` is an open string (e.g. `Person`, `Organization`) — the payee vocabulary is the entity module's, not part of this contract","required":["id","entityType","displayName"],"properties":{"id":{"type":"string","format":"uuid","description":"The payee entity's id"},"entityType":{"type":"string","description":"The payee's entity type (e.g. Person, Organization)"},"displayName":{"type":"string","description":"The payee's display name"}},"isRequired":true,"uniqueKey":"error.currentInvoice.linkedPayee.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.linkedPayee","typeLabel":"object | null"},"incurredDate":{"oneOf":[{"type":"string","format":"date","description":"The date the charges were incurred (ISO `YYYY-MM-DD`), or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.incurredDate.oneOf.0","typeLabel":"string\u003cdate>"},{"type":"null","format":"date","description":"The date the charges were incurred (ISO `YYYY-MM-DD`), or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.incurredDate.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.incurredDate","typeLabel":"string\u003cdate> | null"},"dueDate":{"oneOf":[{"type":"string","format":"date","description":"When payment is owed (display metadata only), or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.dueDate.oneOf.0","typeLabel":"string\u003cdate>"},{"type":"null","format":"date","description":"When payment is owed (display metadata only), or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.dueDate.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.dueDate","typeLabel":"string\u003cdate> | null"},"memo":{"oneOf":[{"type":"string","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.memo.oneOf.0","typeLabel":"string"},{"type":"null","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.memo.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.memo","typeLabel":"string | null"},"fieldData":{"oneOf":[{"type":"object","additionalProperties":true,"description":"Values for the tenant-defined custom invoice fields, keyed by field referenceId — an opaque JSON object, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.fieldData.oneOf.0","typeLabel":"object"},{"type":"null","additionalProperties":true,"description":"Values for the tenant-defined custom invoice fields, keyed by field referenceId — an opaque JSON object, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.fieldData.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.fieldData","typeLabel":"object | null"},"lineItems":{"type":"array","description":"The invoice's line items","items":{"type":"object","description":"A stored invoice line item as rendered on invoice reads.","required":["lineItemId","lineItemTypeId","memo","amountCents"],"properties":{"lineItemId":{"type":"string","format":"uuid","description":"The line item's id","isRequired":true,"uniqueKey":"error.currentInvoice.lineItems.items.[INDEX].lineItemId","typeLabel":"string\u003cuuid>"},"lineItemTypeId":{"type":"string","format":"uuid","description":"The configured line item type this item cites — discover ids with `GET /api/v1/companies/{companyId}/financials/config/categories`","isRequired":true,"uniqueKey":"error.currentInvoice.lineItems.items.[INDEX].lineItemTypeId","typeLabel":"string\u003cuuid>"},"memo":{"oneOf":[{"type":"string","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.lineItems.items.[INDEX].memo.oneOf.0","typeLabel":"string"},{"type":"null","description":"Free-text memo, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.lineItems.items.[INDEX].memo.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.lineItems.items.[INDEX].memo","typeLabel":"string | null"},"amountCents":{"type":"integer","description":"The line item's signed amount in integer cents; a negative amount is a credit within the item's own frame — it posts opposite the line item type's expected direction (e.g. a reversal or refund); the posting rule always comes from the type, never the sign","isRequired":true,"uniqueKey":"error.currentInvoice.lineItems.items.[INDEX].amountCents","typeLabel":"integer"}},"uniqueKey":"error.currentInvoice.lineItems.items.[INDEX]","typeLabel":"object"},"isRequired":true,"uniqueKey":"error.currentInvoice.lineItems","typeLabel":"object[]"},"totalAmountCents":{"type":"integer","description":"Sum of the ORIENTED line-item amounts (a payable-direction line counts +, a receivable-direction line counts −), in integer cents — the net cash the document commits to move","isRequired":true,"uniqueKey":"error.currentInvoice.totalAmountCents","typeLabel":"integer"},"amountPaidCents":{"type":"integer","description":"Sum of the ORIENTED live payment marks, in integer cents — the net cash moved so far","isRequired":true,"uniqueKey":"error.currentInvoice.amountPaidCents","typeLabel":"integer"},"balanceDueCents":{"type":"integer","description":"`totalAmountCents - amountPaidCents`, in integer cents — the net cash remaining to move: positive = out, negative = in. May move non-monotonically as opposite-direction lines settle. A voided invoice keeps its amounts here and in `totalAmountCents`, although it no longer owes anything, so leave voided invoices out when adding up what is owed","isRequired":true,"uniqueKey":"error.currentInvoice.balanceDueCents","typeLabel":"integer"},"draftAmountPaidCents":{"oneOf":[{"type":"integer","description":"A DRAFT's annex-derived paid total: the oriented net-cash sum of the payment marks the draft was born carrying (the same frame as `amountPaidCents`, which counts LIVE posted marks only and reads 0 while drafting) — what a draft's underlying payment picture will read once finalized. `null` on non-draft invoices (the annex is spent at finalize). Display-only — never a posted ledger amount","isRequired":true,"uniqueKey":"error.currentInvoice.draftAmountPaidCents.oneOf.0","typeLabel":"integer"},{"type":"null","description":"A DRAFT's annex-derived paid total: the oriented net-cash sum of the payment marks the draft was born carrying (the same frame as `amountPaidCents`, which counts LIVE posted marks only and reads 0 while drafting) — what a draft's underlying payment picture will read once finalized. `null` on non-draft invoices (the annex is spent at finalize). Display-only — never a posted ledger amount","isRequired":true,"uniqueKey":"error.currentInvoice.draftAmountPaidCents.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.draftAmountPaidCents","typeLabel":"integer | null"},"paidDate":{"oneOf":[{"type":"string","format":"date","description":"Payment date of the mark that first made every line item settled; clears (`null`) whenever any line reopens","isRequired":true,"uniqueKey":"error.currentInvoice.paidDate.oneOf.0","typeLabel":"string\u003cdate>"},{"type":"null","format":"date","description":"Payment date of the mark that first made every line item settled; clears (`null`) whenever any line reopens","isRequired":true,"uniqueKey":"error.currentInvoice.paidDate.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.paidDate","typeLabel":"string\u003cdate> | null"},"lastPaymentDate":{"oneOf":[{"type":"string","format":"date","description":"Date of the most recent live payment, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.lastPaymentDate.oneOf.0","typeLabel":"string\u003cdate>"},{"type":"null","format":"date","description":"Date of the most recent live payment, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.lastPaymentDate.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.lastPaymentDate","typeLabel":"string\u003cdate> | null"},"voidedAt":{"oneOf":[{"type":"string","format":"date-time","description":"When the invoice was voided, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.voidedAt.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","format":"date-time","description":"When the invoice was voided, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.voidedAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.voidedAt","typeLabel":"string\u003cdate-time> | null"},"deletedAt":{"oneOf":[{"type":"string","format":"date-time","description":"When the invoice was deleted, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.deletedAt.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","format":"date-time","description":"When the invoice was deleted, or `null`","isRequired":true,"uniqueKey":"error.currentInvoice.deletedAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.deletedAt","typeLabel":"string\u003cdate-time> | null"},"approved":{"type":"boolean","description":"The approval projection: `true` after `invoice.approved`, cleared only by `invoice.unapproved` — an edit never resets approval (the approval-relevant facts, line items and category, are immutable once posted)","isRequired":true,"uniqueKey":"error.currentInvoice.approved","typeLabel":"boolean"},"approvedAt":{"oneOf":[{"type":"string","format":"date-time","description":"When the approval landed (`invoice.approved`), or `null` while unapproved — `approved` is exactly `approvedAt != null`","isRequired":true,"uniqueKey":"error.currentInvoice.approvedAt.oneOf.0","typeLabel":"string\u003cdate-time>"},{"type":"null","format":"date-time","description":"When the approval landed (`invoice.approved`), or `null` while unapproved — `approved` is exactly `approvedAt != null`","isRequired":true,"uniqueKey":"error.currentInvoice.approvedAt.oneOf.1","typeLabel":"null"}],"isRequired":true,"uniqueKey":"error.currentInvoice.approvedAt","typeLabel":"string\u003cdate-time> | null"},"approvalRequired":{"type":"boolean","description":"Whether approval applies to this invoice. A money-out invoice (a positive `totalAmountCents`) requires approval when its type's \"Money-out invoices require approval\" setting is on; a money-in invoice (negative total) never does, and a zero total follows its type's expected direction. The value is recorded on the invoice when it is created, so a later change to the type's setting does not alter it. When `false`, Record Payment goes through without an approval, and any approval the invoice carries (`approved`) is kept but no longer matters.","isRequired":true,"uniqueKey":"error.currentInvoice.approvalRequired","typeLabel":"boolean"},"createdAt":{"type":"string","format":"date-time","description":"When the invoice was created","isRequired":true,"uniqueKey":"error.currentInvoice.createdAt","typeLabel":"string\u003cdate-time>"},"updatedAt":{"type":"string","format":"date-time","description":"When the invoice last changed","isRequired":true,"uniqueKey":"error.currentInvoice.updatedAt","typeLabel":"string\u003cdate-time>"},"headJournalId":{"type":"string","format":"uuid","description":"The invoice's current journal head — send it as `If-Match` on the next write to this invoice; a mismatch is a `409` carrying the current row","isRequired":true,"uniqueKey":"error.currentInvoice.headJournalId","typeLabel":"string\u003cuuid>"}},"uniqueKey":"error.currentInvoice","typeLabel":"object"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"ifMatchConflict":{"title":"ifMatchConflict","value":{"error":{"code":"IF_MATCH_CONFLICT","message":"If-Match 550e8400-e29b-41d4-a716-446655440901 does not match the invoice's current head journal id","userMessages":["If-Match 550e8400-e29b-41d4-a716-446655440901 does not match the invoice's current head journal id"],"currentInvoice":{"id":"550e8400-e29b-41d4-a716-446655440700","transactionId":"INV-389538-455","invoiceNumber":"SL-2026-0412","categoryId":"550e8400-e29b-41d4-a716-446655440100","status":"partially_paid","linkedEvent":{"id":"550e8400-e29b-41d4-a716-446655440200","displayName":"Claim #1042"},"linkedPolicy":null,"linkedPayee":null,"incurredDate":"2026-06-01","dueDate":null,"memo":"Legal defense","fieldData":null,"lineItems":[{"lineItemId":"550e8400-e29b-41d4-a716-446655440300","lineItemTypeId":"550e8400-e29b-41d4-a716-446655440110","memo":null,"amountCents":10000}],"totalAmountCents":10000,"amountPaidCents":4000,"balanceDueCents":6000,"draftAmountPaidCents":null,"paidDate":null,"lastPaymentDate":"2026-06-10","approved":true,"approvedAt":"2026-06-10T09:00:00.000Z","approvalRequired":true,"voidedAt":null,"deletedAt":null,"createdAt":"2026-06-01T10:30:00.000Z","updatedAt":"2026-06-10T09:00:00.000Z","headJournalId":"550e8400-e29b-41d4-a716-446655440900"}}}},"actionIdReused":{"title":"actionIdReused","value":{"error":{"code":"ACTION_ID_REUSED","message":"actionId 550e8400-e29b-41d4-a716-446655440000 was already used by a different action; supply a fresh uuid (or retry with the identical action to replay it)","userMessages":["actionId 550e8400-e29b-41d4-a716-446655440000 was already used by a different action; supply a fresh uuid (or retry with the identical action to replay it)"]}}}},"exampleType":"examples"}},"exampleType":"examples"},"ec128c50-de05-4879-908a-86423cf58077":{"description":"Unprocessable — a write precondition failed. Fails closed: no journal record, no ledger change, no read-state change.","content":{"application/json":{"schema":{"type":"object","description":"A failed write precondition (`422`): the request was well-formed but the books reject it. Preconditions fail closed — a rejected write leaves no journal record, no ledger change, and no read-state change. `error.code` is one of the STABLE financials error codes (single source: `FINANCIALS_V2_PRECONDITION_CODES` in the engine's error module, re-exported to this surface as `FINANCIALS_V2_API_ERROR_CODES`) — messages may be reworded, the codes will not.","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","enum":["LIVE_PAYMENTS","AMOUNT_EXCEEDS_BALANCE_DUE","INVALID_AMOUNT","LINE_ITEMS_IMMUTABLE","INVOICE_DELETED","INVOICE_VOIDED","INVOICE_DRAFT","INVOICE_NOT_DRAFT","PAYMENT_NOT_FOUND","ERODE_RESERVES_MISMATCH","ERODE_REQUIRES_EVENT","DEPRECATED_CONFIG","NOT_RESERVED_CATEGORY","FUTURE_DATE","UNKNOWN_ID","LINK_TARGET_MISSING","UNAPPROVE_PAID","NOT_APPROVED","POLICY_INVOICE_BATCH_ONLY"],"description":"The stable precondition code — one per guard. `LIVE_PAYMENTS` (the action — re-link, payee change, or void — needs the invoice's live payments removed first); `AMOUNT_EXCEEDS_BALANCE_DUE` (a payment mark's magnitude overshoots its line item's remaining — per line, never a document scalar); `INVALID_AMOUNT` (a zero mark, or a mark whose sign opposes its line item's open remaining — a `payBalanceDue` against a document with nothing open included); `LINE_ITEMS_IMMUTABLE` (a posted invoice's line items — ids, types, amounts — and its category are fixed from the posting moment: any post-posting change is rejected, at any payment count; corrections are void-and-recreate, payments removed first; drafts edit freely until finalize); `INVOICE_DELETED` / `INVOICE_VOIDED` (lifecycle closures); `INVOICE_DRAFT` (drafts are unposted — money may not touch one: recording a payment on or voiding a draft is rejected; finalize it first); `INVOICE_NOT_DRAFT` (finalize targets exactly a draft); `PAYMENT_NOT_FOUND` (no live payment mark with that id on that invoice); `ERODE_RESERVES_MISMATCH` / `ERODE_REQUIRES_EVENT` (the erode flag missing on a reserved category or present on operating; eroding needs a linked event — there is no headroom bound: the remaining reserve is a signed balance and may cross zero); `DEPRECATED_CONFIG` / `NOT_RESERVED_CATEGORY` / `UNKNOWN_ID` (cited configuration guards); `FUTURE_DATE`; `LINK_TARGET_MISSING` (the named link target does not exist); `UNAPPROVE_PAID` (an approval cannot be revoked once payments have been recorded — remove them first); `NOT_APPROVED` (money cannot post against an unapproved invoice that requires approval (`approvalRequired: true`) AND the calling key does not hold `invoice.approve`, so it cannot approve it either — a key that holds the permission auto-approves instead of failing here); `POLICY_INVOICE_BATCH_ONLY` (the write touches a POLICY-LINKED invoice's document — creating one with `links.policy`; updating fields other than its Invoice Number, finalizing, voiding, restoring, deleting, or re-linking one that is already policy-linked; or re-linking any invoice onto a policy. A policy's invoices are checked as one set so that every price component of the policy's pricing contract stays netted to its own line item, so they change only through the policy invoice batch, `POST /api/v1/companies/{companyId}/financials/policies/{policyId}/invoices/batch`, or a policy transaction or bind that carries an invoice plan. The message names the batch path with the request's company and the policy's ids. A batch voids and creates only the invoices it names; the policy's other invoices stay as they are. Recording and removing payments, approving and unapproving, and changing the payee while the invoice has no payments still work on a policy invoice). `DRAFT_ANNEX_CONFLICT` (also returned, not yet in this enum): an edit or re-link of a draft that would leave one of its parsed payment marks unable to post at finalize","isRequired":true,"uniqueKey":"error.code","typeLabel":"enum\u003cstring>"},"message":{"type":"string","description":"Human-readable description of the failed precondition","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"userMessages":{"type":"array","description":"Clean, verbatim-displayable messages","items":{"type":"string","uniqueKey":"error.userMessages.items.[INDEX]","typeLabel":"string"},"uniqueKey":"error.userMessages","typeLabel":"string[]"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"unapprovePaid":{"title":"unapprovePaid","value":{"error":{"code":"UNAPPROVE_PAID","message":"Invoice 550e8400-e29b-41d4-a716-446655440700 is paid; an approval cannot be revoked once payments have been recorded — remove them first","userMessages":["Invoice 550e8400-e29b-41d4-a716-446655440700 is paid; an approval cannot be revoked once payments have been recorded — remove them first"]}}},"invoiceVoided":{"title":"invoiceVoided","value":{"error":{"code":"INVOICE_VOIDED","message":"Invoice 550e8400-e29b-41d4-a716-446655440700 is voided; 'invoice.unapproved' cannot be applied to it","userMessages":["Invoice 550e8400-e29b-41d4-a716-446655440700 is voided; 'invoice.unapproved' cannot be applied to it"]}}}},"exampleType":"examples"}},"exampleType":"examples"},"f42129a0-931e-4cd2-b111-040644bcb637":{"description":"Internal Server Error - Unexpected error occurred","content":{"application/json":{"schema":{"type":"object","description":"Standard error response for all external API endpoints","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Machine-readable error code","example":"VALIDATION_ERROR","isRequired":true,"uniqueKey":"error.code","typeLabel":"string"},"message":{"type":"string","description":"Human-readable error message","example":"submissionId: Required field is missing","isRequired":true,"uniqueKey":"error.message","typeLabel":"string"},"userMessages":{"type":"array","description":"Clean, verbatim-displayable messages — one entry per failure, free of error-code tags, field paths, and internal noise. Suitable for showing to end users as-is.","items":{"type":"string","uniqueKey":"error.userMessages.items.[INDEX]","typeLabel":"string"},"example":["Exposures of type 'company' require an address"],"uniqueKey":"error.userMessages","typeLabel":"string[]"},"details":{"type":"array","description":"Additional details for validation errors (field-level errors)","items":{"type":"object","properties":{"field":{"type":"string","description":"The field that caused the error","example":"submissionId","uniqueKey":"error.details.items.[INDEX].field","typeLabel":"string"},"code":{"type":"string","description":"Stable problem code for this individual validation failure","example":"BLANK_LIST_ELEMENT","uniqueKey":"error.details.items.[INDEX].code","typeLabel":"string"},"reason":{"type":"string","description":"Stable reason the value violates its canonical contract","example":"blank-list-element","uniqueKey":"error.details.items.[INDEX].reason","typeLabel":"string"},"expected":{"type":"string","description":"The expected canonical value contract","example":"nonblank trimmed string","uniqueKey":"error.details.items.[INDEX].expected","typeLabel":"string"},"message":{"type":"string","description":"Description of the field error","example":"Required field is missing","uniqueKey":"error.details.items.[INDEX].message","typeLabel":"string"}},"uniqueKey":"error.details.items.[INDEX]","typeLabel":"object"},"uniqueKey":"error.details","typeLabel":"object[]"}},"isRequired":true,"uniqueKey":"error","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"examples":{"internalError":{"title":"internalError","value":{"error":{"code":"UncaughtActionError","message":"Uncaught error occurred in \u003cactionName>","userMessages":["An unexpected error occurred. Please try again later."]}}}},"exampleType":"examples"}},"exampleType":"examples"}},"security":{"35370c79-340a-4ed7-a68a-8c786f4a2235":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"API key authentication. Send your raw API key as the `Authorization` header value with NO scheme prefix — `Authorization: YOUR-API-KEY`. Do NOT prefix it with `Bearer ` or `ApiKey `, and do not use an `X-API-Key` header; those are not accepted.","scopes":[],"schemeName":"ApiKeyAuth"}}},"servers":{"b4993f5b-e21e-4dbd-8ace-9c59b5197d8e":{"url":"https://go.aiinsurance.io","description":"Production"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"header","name":"Authorization","description":"API key authentication. Send your raw API key as the `Authorization` header value with NO scheme prefix — `Authorization: YOUR-API-KEY`. Do NOT prefix it with `Bearer ` or `ApiKey `, and do not use an `X-API-Key` header; those are not accepted.","scopes":[],"schemeName":"ApiKeyAuth"},"schema":{"title":"Authorization","type":"string","description":"API key authentication. Send your raw API key as the `Authorization` header value with NO scheme prefix — `Authorization: YOUR-API-KEY`. Do NOT prefix it with `Bearer ` or `ApiKey `, and do not use an `X-API-Key` header; those are not accepted.","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"ApiKeyAuth","name":"Authorization"}],"title":"ApiKeyAuth"}]},"originalFileLocation":"openapi/generated-external-api.yaml"},"subdomain":"ai-insurance-fmv1","siteName":"AI Insurance","title":"Unapprove Invoice - AI Insurance","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-13T17:32:14.116Z","originalFileLocation":"api-reference/financials/unapprove-invoice.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Withdraws an invoice\u0026#x27;s approval, for example when a bill was approved by mistake, so a payment needs approval again before it posts. It is the reverse of Approve Invoice (approveFinancialsInvoice) and works only while the invoice has no payments; remove them first with Remove Payment (removeFinancialsInvoicePayment). Revokes the invoice\u0026#x27;s approval — the invoice.unapproved action: it clears approved / approvedAt and posts NOTHING to the books. The inverse of approve. Authority. Granting and revoking an approval are the SAME authority: the calling key must hold invoice.approve. The company\u0026#x27;s in-app approval rules are never applied to API callers. A key without the permission gets 403. Preconditions (422). The invoice must not be paid or partially paid (UNAPPROVE_PAID) — once live payments exist, the endpoint will not alter approval state, so remove the payments first. It must also be neither voided (INVOICE_VOIDED) nor deleted (INVOICE_DELETED). Unapproving a never-approved invoice is a DEFINED no-op: still journaled, zero ledger rows, refreshed state returned. Concurrency + idempotency. Requires If-Match (the invoice\u0026#x27;s current headJournalId); the body carries the client-minted actionId — an identical retry replays the original outcome. Required permission: invoice.approve\">\u003cmeta data-mint-head name=\"application-name\" content=\"AI Insurance\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Unapprove Invoice - AI Insurance\">\u003cmeta data-mint-head property=\"og:description\" content=\"Withdraws an invoice\u0026#x27;s approval, for example when a bill was approved by mistake, so a payment needs approval again before it posts. It is the reverse of Approve Invoice (approveFinancialsInvoice) and works only while the invoice has no payments; remove them first with Remove Payment (removeFinancialsInvoicePayment). Revokes the invoice\u0026#x27;s approval — the invoice.unapproved action: it clears approved / approvedAt and posts NOTHING to the books. The inverse of approve. Authority. Granting and revoking an approval are the SAME authority: the calling key must hold invoice.approve. The company\u0026#x27;s in-app approval rules are never applied to API callers. A key without the permission gets 403. Preconditions (422). The invoice must not be paid or partially paid (UNAPPROVE_PAID) — once live payments exist, the endpoint will not alter approval state, so remove the payments first. It must also be neither voided (INVOICE_VOIDED) nor deleted (INVOICE_DELETED). Unapproving a never-approved invoice is a DEFINED no-op: still journaled, zero ledger rows, refreshed state returned. Concurrency + idempotency. Requires If-Match (the invoice\u0026#x27;s current headJournalId); the body carries the client-minted actionId — an identical retry replays the original outcome. Required permission: invoice.approve\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"AI Insurance\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://ai-insurance-fmv1.mintlify.site/_mintlify/api/og/v2?division=Invoice+Lifecycle\u0026amp;title=Unapprove+Invoice\u0026amp;description=Withdraws+an+invoice%27s+approval%2C+for+example+when+a+bill+was+approved+by%0Amistake%2C+so+a+payment+needs+approval+again+before+it+posts.+It+is+the%0Areverse+of+Approv\u0026amp;theme=0995c531691aeb9df7f9b066\u0026amp;signature=1f1b9756b5eb3d3c59db73c491a08ee38771ff4b0fa7713acb61f50f85d28fe2\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Unapprove Invoice - AI Insurance\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Withdraws an invoice\u0026#x27;s approval, for example when a bill was approved by mistake, so a payment needs approval again before it posts. It is the reverse of Approve Invoice (approveFinancialsInvoice) and works only while the invoice has no payments; remove them first with Remove Payment (removeFinancialsInvoicePayment). Revokes the invoice\u0026#x27;s approval — the invoice.unapproved action: it clears approved / approvedAt and posts NOTHING to the books. The inverse of approve. Authority. Granting and revoking an approval are the SAME authority: the calling key must hold invoice.approve. The company\u0026#x27;s in-app approval rules are never applied to API callers. A key without the permission gets 403. Preconditions (422). The invoice must not be paid or partially paid (UNAPPROVE_PAID) — once live payments exist, the endpoint will not alter approval state, so remove the payments first. It must also be neither voided (INVOICE_VOIDED) nor deleted (INVOICE_DELETED). Unapproving a never-approved invoice is a DEFINED no-op: still journaled, zero ledger rows, refreshed state returned. Concurrency + idempotency. Requires If-Match (the invoice\u0026#x27;s current headJournalId); the body carries the client-minted actionId — an identical retry replays the original outcome. Required permission: invoice.approve\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://ai-insurance-fmv1.mintlify.site/_mintlify/api/og/v2?division=Invoice+Lifecycle\u0026amp;title=Unapprove+Invoice\u0026amp;description=Withdraws+an+invoice%27s+approval%2C+for+example+when+a+bill+was+approved+by%0Amistake%2C+so+a+payment+needs+approval+again+before+it+posts.+It+is+the%0Areverse+of+Approv\u0026amp;theme=0995c531691aeb9df7f9b066\u0026amp;signature=1f1b9756b5eb3d3c59db73c491a08ee38771ff4b0fa7713acb61f50f85d28fe2\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/ai-insurance-fmv1/OV-zcpS7BkiQB75q/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"AI Insurance\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#714CC5\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/financials/unapprove-invoice.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.go.aiinsurance.io/#organization\",\"name\":\"AI Insurance\",\"url\":\"https://docs.go.aiinsurance.io\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/ai-insurance-fmv1/HtPQvD-FDA5nbM7L/logo/dark.jpg?fit=max\u0026auto=format\u0026n=HtPQvD-FDA5nbM7L\u0026q=85\u0026s=14ace86d6e87c6eab47960c514760266\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.go.aiinsurance.io#website\",\"name\":\"AI Insurance\",\"url\":\"https://docs.go.aiinsurance.io\",\"publisher\":{\"@id\":\"https://docs.go.aiinsurance.io/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice#webpage\",\"url\":\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice\",\"name\":\"Unapprove Invoice\",\"description\":\"Withdraws an invoice's approval, for example when a bill was approved by mistake, so a payment needs approval again before it posts. It is the reverse of Approve Invoice (approveFinancialsInvoice) and works only while the invoice has no payments; remove them first with Remove Payment (removeFinancialsInvoicePayment). Revokes the invoice's approval — the invoice.unapproved action: it clears approved / approvedAt and posts NOTHING to the books. The inverse of approve. Authority. Granting and revoking an approval are the SAME authority: the calling key must hold invoice.approve. The company's in-app approval rules are never applied to API callers. A key without the permission gets 403. Preconditions (422). The invoice must not be paid or partially paid (UNAPPROVE_PAID) — once live payments exist, the endpoint will not alter approval state, so remove the payments first. It must also be neither voided (INVOICE_VOIDED) nor deleted (INVOICE_DELETED). Unapproving a never-approved invoice is a DEFINED no-op: still journaled, zero ledger rows, refreshed state returned. Concurrency + idempotency. Requires If-Match (the invoice's current headJournalId); the body carries the client-minted actionId — an identical retry replays the original outcome. Required permission: invoice.approve\",\"dateModified\":\"2026-11-13T17:32:14.116Z\",\"isPartOf\":{\"@id\":\"https://docs.go.aiinsurance.io#website\"},\"breadcrumb\":{\"@id\":\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Financials\",\"item\":\"https://docs.go.aiinsurance.io/api-reference/financials/overview\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Invoice Lifecycle\",\"item\":\"https://docs.go.aiinsurance.io/api-reference/financials/approve-invoice\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Unapprove Invoice\",\"item\":\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice#apireference\",\"headline\":\"Unapprove Invoice\",\"name\":\"Unapprove Invoice\",\"description\":\"Withdraws an invoice's approval, for example when a bill was approved by mistake, so a payment needs approval again before it posts. It is the reverse of Approve Invoice (approveFinancialsInvoice) and works only while the invoice has no payments; remove them first with Remove Payment (removeFinancialsInvoicePayment). Revokes the invoice's approval — the invoice.unapproved action: it clears approved / approvedAt and posts NOTHING to the books. The inverse of approve. Authority. Granting and revoking an approval are the SAME authority: the calling key must hold invoice.approve. The company's in-app approval rules are never applied to API callers. A key without the permission gets 403. Preconditions (422). The invoice must not be paid or partially paid (UNAPPROVE_PAID) — once live payments exist, the endpoint will not alter approval state, so remove the payments first. It must also be neither voided (INVOICE_VOIDED) nor deleted (INVOICE_DELETED). Unapproving a never-approved invoice is a DEFINED no-op: still journaled, zero ledger rows, refreshed state returned. Concurrency + idempotency. Requires If-Match (the invoice's current headJournalId); the body carries the client-minted actionId — an identical retry replays the original outcome. Required permission: invoice.approve\",\"url\":\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice\",\"mainEntityOfPage\":{\"@id\":\"https://docs.go.aiinsurance.io/api-reference/financials/unapprove-invoice#webpage\"},\"dateModified\":\"2026-11-13T17:32:14.116Z\",\"publisher\":{\"@id\":\"https://docs.go.aiinsurance.io/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.go.aiinsurance.io#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"AI Insurance\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"AI Insurance\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/api-reference/financials/unapprove-invoice.md","siteName":"AI Insurance","nav":{"global":null,"tabs":[{"tab":"Home","pages":[{"title":"Home","href":"/homepage"}]},{"tab":"App","pages":[{"title":"App","href":"/app/getting-started/overview"}]},{"tab":"Entities","pages":[{"title":"Entities","href":"/entities/overview"}]},{"tab":"Markets","pages":[{"title":"Markets","href":"/markets/overview"}]},{"tab":"Financials","pages":[{"title":"Financials","href":"/financials/overview"}]},{"tab":"API","groups":[{"group":"Getting Started","pages":[{"title":"Overview","href":"/api-reference/overview"},{"title":"Roadmap","href":"/api-reference/roadmap"},{"title":"Generating API Keys","href":"/api-reference/authentication"},{"title":"MCP Connector (Beta)","href":"/api-reference/mcp-connector"}]},{"group":"User","pages":[{"title":"Get my profile","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/me","href":"/api-reference/user/get-my-profile"},{"title":"List my accessible companies","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/me/companies","href":"/api-reference/user/list-my-accessible-companies"}]},{"group":"Companies","pages":[{"title":"Companies","href":"/api-reference/companies/overview"},{"title":"Get Company Metadata","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}","href":"/api-reference/companies/get-company-metadata"},{"title":"List Company Members","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/members","href":"/api-reference/companies/list-company-members"},{"title":"Get Company Lifecycle","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/lifecycle","href":"/api-reference/companies/get-company-lifecycle"},{"title":"Reset Sandbox","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/reset","href":"/api-reference/companies/reset-sandbox"},{"title":"Get Company Email Branding","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/email-branding","href":"/api-reference/companies/get-company-email-branding"},{"title":"Set Company Email Branding","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/email-branding","href":"/api-reference/companies/set-company-email-branding"}]},{"group":"Entities","pages":[{"title":"Overview","href":"/api-reference/entities/overview"},{"title":"List Entity Types","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entity-types","href":"/api-reference/entities/list-entity-types"},{"title":"Get Page Layout","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/pages/{pageKey}/layout","href":"/api-reference/entities/get-page-layout"},{"title":"Get Entity Configuration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/configuration","href":"/api-reference/entities/get-entity-configuration"},{"title":"Create Entity","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/{entityType}","href":"/api-reference/entities/create-entity"},{"title":"Create Entity Batch","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/batch","href":"/api-reference/entities/create-entity-batch"},{"title":"List Entities","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}","href":"/api-reference/entities/list-entities"},{"title":"Start Entity Export Run","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/{entityType}/export-runs","href":"/api-reference/entities/start-entity-export-run"},{"title":"Get Entity Export Run","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/export-runs/{runId}","href":"/api-reference/entities/get-entity-export-run"},{"title":"Download Entity Export Run","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/export-runs/{runId}/download","href":"/api-reference/entities/download-entity-export-run"},{"title":"List Export Presets For Member","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/export-presets","href":"/api-reference/entities/list-export-presets-for-member"},{"title":"Create Export Preset For Member","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/export-presets","href":"/api-reference/entities/create-export-preset-for-member"},{"title":"Replace Export Preset For Member","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/export-presets/{presetId}","href":"/api-reference/entities/replace-export-preset-for-member"},{"title":"Delete Export Preset For Member","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/export-presets/{presetId}","href":"/api-reference/entities/delete-export-preset-for-member"},{"title":"Get Entity","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/{entityId}","href":"/api-reference/entities/get-entity"},{"title":"Update Entity","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/entities/{entityType}/{entityId}","href":"/api-reference/entities/update-entity"},{"title":"Delete Entity","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/entities/{entityType}/{entityId}","href":"/api-reference/entities/delete-entity"}]},{"group":"Submission and Quote Lifecycle","pages":[{"title":"Rate, Quote, Bind","href":"/api-reference/rate-quote-bind"},{"title":"Close Submission","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/submissions/{submissionId}/close","href":"/api-reference/submission-and-quote-lifecycle/close-submission"},{"title":"Reopen Submission","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/submissions/{submissionId}/reopen","href":"/api-reference/submission-and-quote-lifecycle/reopen-submission"},{"title":"Cancel Quote","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/quotes/{quoteId}/cancel","href":"/api-reference/submission-and-quote-lifecycle/cancel-quote"}]},{"group":"Event Lifecycle","pages":[{"title":"Overview","href":"/api-reference/event-lifecycle/overview"},{"title":"Close Event","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/events/{eventId}/close","href":"/api-reference/event-lifecycle/close-event"},{"title":"Re-open Event","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/events/{eventId}/reopen","href":"/api-reference/event-lifecycle/re-open-event"},{"title":"Replace Event Open/Close History","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/events/{eventId}/open-close-history","href":"/api-reference/event-lifecycle/replace-event-openclose-history"}]},{"group":"Record Emails","pages":[{"title":"Overview","href":"/api-reference/record-emails/overview"},{"title":"List Record Email Conversations","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/email-conversations","href":"/api-reference/record-emails/list-record-email-conversations"},{"title":"Get Record Email Conversation","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/email-conversations/{threadId}","href":"/api-reference/record-emails/get-record-email-conversation"},{"title":"Remove Record Email Conversation","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/email-conversations/{threadId}/remove","href":"/api-reference/record-emails/remove-record-email-conversation"},{"title":"Link Earlier Record Emails","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/email-people/{personId}/link-earlier","href":"/api-reference/record-emails/link-earlier-record-emails"},{"title":"Unlink Record Person Emails","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/email-people/{personId}/unlink","href":"/api-reference/record-emails/unlink-record-person-emails"},{"title":"List Record Email Link Events","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/email-link-events","href":"/api-reference/record-emails/list-record-email-link-events"},{"title":"List Record Sendable Email Templates","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/sendable-email-templates","href":"/api-reference/record-emails/list-record-sendable-email-templates"},{"title":"Preview Record Email","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/emails/preview","href":"/api-reference/record-emails/preview-record-email"},{"title":"Send Record Email","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/emails","href":"/api-reference/record-emails/send-record-email"},{"title":"Retry Record Email Delivery","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/email-deliveries/{deliveryId}/retry","href":"/api-reference/record-emails/retry-record-email-delivery"},{"title":"List Record Packet Emails","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/packet-emails","href":"/api-reference/record-emails/list-record-packet-emails"},{"title":"List Policy Email Conversations","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/email-conversations","href":"/api-reference/record-emails/list-policy-email-conversations"},{"title":"Get Policy Email Conversation","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/email-conversations/{threadId}","href":"/api-reference/record-emails/get-policy-email-conversation"},{"title":"Remove Policy Email Conversation","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/email-conversations/{threadId}/remove","href":"/api-reference/record-emails/remove-policy-email-conversation"},{"title":"Link Earlier Policy Emails","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/email-people/{personId}/link-earlier","href":"/api-reference/record-emails/link-earlier-policy-emails"},{"title":"Unlink Policy Person Emails","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/email-people/{personId}/unlink","href":"/api-reference/record-emails/unlink-policy-person-emails"},{"title":"List Policy Email Link Events","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/email-link-events","href":"/api-reference/record-emails/list-policy-email-link-events"},{"title":"List Policy Sendable Email Templates","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/sendable-email-templates","href":"/api-reference/record-emails/list-policy-sendable-email-templates"},{"title":"Preview Policy Email","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/emails/preview","href":"/api-reference/record-emails/preview-policy-email"},{"title":"Send Policy Email","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/emails","href":"/api-reference/record-emails/send-policy-email"},{"title":"Retry Policy Email Delivery","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/email-deliveries/{deliveryId}/retry","href":"/api-reference/record-emails/retry-policy-email-delivery"},{"title":"List Policy Packet Emails","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/packet-emails","href":"/api-reference/record-emails/list-policy-packet-emails"}]},{"group":"OFAC Screening","pages":[{"title":"Overview","href":"/api-reference/ofac-screening/overview"},{"title":"Screen Exposure For OFAC","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/ofac/screen","href":"/api-reference/ofac-screening/screen-exposure-for-ofac"}]},{"group":"Policy Transactions","pages":[{"title":"Overview","href":"/api-reference/policies/overview"},{"title":"Concepts","href":"/api-reference/policies/concepts"},{"title":"Effective Dates \u0026 the Policy Timeline","href":"/api-reference/policies/effective-dates"},{"title":"Lifecycle Walkthrough","href":"/api-reference/policies/lifecycle-walkthrough"},{"group":"Configuration","pages":[{"title":"Get Policy Configuration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/configuration","href":"/api-reference/field-model-policy-configuration/get-policy-configuration"}]},{"group":"Reset","pages":[{"title":"Delete All Policies","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/deleteAll","href":"/api-reference/policies/delete-all-policies"}]},{"group":"Transactions","pages":[{"title":"New Business Transaction","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/transaction/new-business","href":"/api-reference/field-model-policy-transactions/new-business-transaction"},{"title":"Endorse Policy Transaction","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/transaction/endorse","href":"/api-reference/field-model-policy-transactions/endorse-policy-transaction"},{"title":"Cancel Policy Transaction","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/transaction/cancel","href":"/api-reference/field-model-policy-transactions/cancel-policy-transaction"},{"title":"Reinstate Policy Transaction","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/transaction/reinstate","href":"/api-reference/field-model-policy-transactions/reinstate-policy-transaction"},{"title":"Renew Policy Transaction","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/transaction/renew","href":"/api-reference/field-model-policy-transactions/renew-policy-transaction"},{"title":"Generate Quote from Policy (Stateless)","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/quotes/generate","href":"/api-reference/field-model-policies/generate-quote-from-policy-stateless"},{"title":"Bind Quote","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/quotes/{quoteId}/bind","href":"/api-reference/field-model-policy-transactions/bind-quote"},{"title":"Bind Quote by Reference or by Value","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/quotes/bind","href":"/api-reference/field-model-policy-transactions/bind-quote-by-reference-or-by-value"},{"title":"Delete Policy Transaction","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/policies/{policyId}/transactions/{transactionId}","href":"/api-reference/field-model-policy-transactions/delete-policy-transaction"},{"title":"Get Policy Version","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/versions/{version}","href":"/api-reference/field-model-policy-transactions/get-policy-version"},{"title":"List Single Policy Versions","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/versions","href":"/api-reference/field-model-policy-transactions/list-single-policy-versions"},{"title":"List Policy Transactions","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/transactions","href":"/api-reference/field-model-policy-transactions/list-policy-transactions"},{"title":"Get Policy Transaction","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/transactions/{transactionId}","href":"/api-reference/field-model-policy-transactions/get-policy-transaction"},{"title":"Update Transaction Display Author","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/policies/{policyId}/transactions/{transactionId}","href":"/api-reference/field-model-policy-transactions/update-transaction-display-author"}]},{"group":"Contacts","pages":[{"title":"List Policy Contacts","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/contacts","href":"/api-reference/field-model-policy-transactions/list-policy-contacts"},{"title":"Add Policy Contact","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/{policyId}/contacts","href":"/api-reference/field-model-policy-transactions/add-policy-contact"},{"title":"Remove Policy Contact","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/policies/{policyId}/contacts/{personId}","href":"/api-reference/field-model-policy-transactions/remove-policy-contact"}]},{"group":"Bordereau","pages":[{"title":"List Bordereau Rows","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/bordereau","href":"/api-reference/field-model-bordereau/list-bordereau-rows"},{"title":"Start Bordereau Export Run","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/bordereau/export-runs","href":"/api-reference/field-model-bordereau/start-bordereau-export-run"},{"title":"Get Bordereau Export Run","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/bordereau/export-runs/{runId}","href":"/api-reference/field-model-bordereau/get-bordereau-export-run"},{"title":"Download Bordereau Export Run","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/bordereau/export-runs/{runId}/download","href":"/api-reference/field-model-bordereau/download-bordereau-export-run"},{"title":"Send Bordereau Export Run to Google Drive","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/bordereau/export-runs/{runId}/drive","href":"/api-reference/field-model-bordereau/send-bordereau-export-run-to-google-drive"}]},{"group":"Listing Policies","pages":[{"title":"List Policies","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/list","href":"/api-reference/field-model-policy-transactions/list-policies"},{"title":"List Policy Versions","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/versions","href":"/api-reference/field-model-policy-transactions/list-policy-versions"}]},{"group":"Validation","pages":[{"title":"Check Bind Conditions","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/quotes/{quoteId}/bind-conditions","href":"/api-reference/field-model-policy-validation/check-bind-conditions"},{"title":"Validate Policy","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/{policyId}/validate","href":"/api-reference/field-model-policy-validation/validate-policy"},{"title":"Validate Policies (Batch)","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/policies/validate","href":"/api-reference/field-model-policy-validation/validate-policies-batch"},{"title":"Repair Policies","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/policies/repair","href":"/api-reference/field-model-policy-transactions/repair-policies"}]}]},{"group":"Policy Invoicing","pages":[{"title":"Invoicing a policy","href":"/api-reference/invoicing/overview"},{"title":"Invoice plans","href":"/api-reference/invoicing/invoice-plans"},{"title":"Quote Invoicing Overview","sidebarTitle":"Quote Invoicing Overview","href":"/api-reference/invoicing/quote-invoicing"},{"group":"Quote Invoicing","pages":[{"title":"Get Quote Invoicing","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/quotes/{quoteId}/invoicing","href":"/api-reference/policy-invoicing/get-quote-invoicing"},{"title":"Replace Quote Invoice Settings","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/quotes/{quoteId}/invoicing/settings","href":"/api-reference/policy-invoicing/replace-quote-invoice-settings"},{"title":"Generate Quote Invoices","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/quotes/{quoteId}/invoicing/generate","href":"/api-reference/policy-invoicing/generate-quote-invoices"},{"title":"Attach Quote Invoice Plan","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/quotes/{quoteId}/invoicing/plan","href":"/api-reference/policy-invoicing/attach-quote-invoice-plan"},{"title":"Clear Quote Invoice Plan","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/quotes/{quoteId}/invoicing/plan","href":"/api-reference/policy-invoicing/clear-quote-invoice-plan"}]},{"group":"Pricing Stack","pages":[{"title":"The pricing stack","href":"/api-reference/invoicing/pricing-stack"},{"title":"Get Quote Pricing Stack Intended Layer","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/quotes/{quoteId}/pricing-stack-intended-layer","href":"/api-reference/policy-invoicing/get-quote-pricing-stack-intended-layer"},{"title":"Set Quote Pricing Stack Intended Layer","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/quotes/{quoteId}/pricing-stack-intended-layer","href":"/api-reference/policy-invoicing/set-quote-pricing-stack-intended-layer"},{"title":"Clear Quote Rating","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/quotes/{quoteId}/rating","href":"/api-reference/policy-invoicing/clear-quote-rating"}]},{"title":"Update Policy Invoices","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/policies/{policyId}/invoices/batch","href":"/api-reference/financials/update-policy-invoices"}]},{"group":"Financials","pages":[{"title":"Overview","href":"/api-reference/financials/overview"},{"group":"Invoices","pages":[{"title":"List Invoices","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/invoices","href":"/api-reference/financials/list-invoices"},{"title":"Create Invoice","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices","href":"/api-reference/financials/create-invoice"},{"title":"Get Invoice","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/invoices/{invoiceId}","href":"/api-reference/financials/get-invoice"},{"title":"Update Invoice","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/financials/invoices/{invoiceId}","href":"/api-reference/financials/update-invoice"},{"title":"Delete Invoice","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/financials/invoices/{invoiceId}","href":"/api-reference/financials/delete-invoice"},{"title":"Re-link Invoice","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/relink","href":"/api-reference/financials/re-link-invoice"}]},{"group":"Invoice Lifecycle","pages":[{"title":"Approve Invoice","description":"Approves an invoice or bill for payment. It changes no amounts, and Record\nPayment (`recordFinancialsInvoicePayment`) requires it on an invoice that\nrequires approval (`approvalRequired: true`), although Record Payment\napproves the invoice itself when your key holds `invoice.approve`.\nUnapprove Invoice (`unapproveFinancialsInvoice`) revokes it, and the\ncompany's in-app approval limits do not apply to API keys.\n\nApproves the invoice — the `invoice.approved` action: it stamps the\ndocument's approval state (`approved: true` plus `approvedAt`) and posts\nNOTHING to the books. Approval is an authorization state, not money.\n\nPayments recorded on a live invoice that requires approval need it, so\nthis is the endpoint to call before\n[recording a payment](/api-reference/financials/record-payment). An\ninvoice that does not require approval (`approvalRequired: false`) can\nstill be approved here; the approval is kept but changes nothing.\nParsed payment marks carried by a draft are the exception: finalize\nmaterializes those marks without changing the draft's approval state.\n[Unapprove](/api-reference/financials/unapprove-invoice) revokes it.\n\n**Authority.** Approving over the API requires exactly one thing: the\ncalling key holds `invoice.approve`. The company's own approval\nrules (per-approver amount and category limits, configured in the app)\nscope the IN-APP approve action only — they are never applied to API\ncallers, who have no approver identity to match. A key without the\npermission gets `403`.\n\n**Attribution.** The recorded approver is the acting identity behind the\ncredential — for an API key, the user who created it. The journal record's\nown author stays the External API service user, as with every write on this\nsurface.\n\n**Precondition (`422`).** The invoice must be neither voided\n(`INVOICE_VOIDED`) nor deleted (`INVOICE_DELETED`). Re-approving an\nalready-approved invoice is a DEFINED no-op: still journaled (a fresh\n`actionId` gets a fresh journal id), zero ledger rows, and the ORIGINAL\napproval is kept — `approvedAt` does not move.\n\n**Concurrency + idempotency.** Requires `If-Match` (the invoice's current\n`headJournalId`); the body carries the client-minted `actionId` — an\nidentical retry replays the original outcome.\n\n**Required permission:** `invoice.approve`\n","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/approve","href":"/api-reference/financials/approve-invoice"},{"title":"Unapprove Invoice","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/unapprove","href":"/api-reference/financials/unapprove-invoice"},{"title":"Finalize Invoice","description":"Posts a draft invoice, so its charges reach the books and balances, and\napplies any payments carried on the draft. Use it after creating a draft\nwith Create Invoice (`createFinancialsInvoice`) and `stage: \"draft\"`, for\nexample for a bill parsed from an uploaded document. It does not approve\nthe invoice, so call Approve Invoice (`approveFinancialsInvoice`)\nseparately when it requires approval (`approvalRequired: true`).\n\nFinalizes a DRAFT invoice — the `invoice.finalized` action: the draft's\ncharges post to the ledger, its derived status flips off `draft`, and any\n`draftPayments` annex carried since\n[create](/api-reference/financials/create-invoice) is applied as real\npayments in the same transaction. The invoice keeps its id and number — a\ndraft becomes a live invoice in place. Returns the refreshed document (the\nposted invoice row and its now-materialized payments).\n\n**Approval.** Finalize does not approve the invoice. If the draft carries\n`draftPayments`, their real payment marks are materialized while the\ninvoice keeps its existing approval state; an unapproved draft therefore\nreturns `approved: false` even when its status becomes `partially_paid` or\n`paid`.\n\n**Precondition (`422 INVOICE_NOT_DRAFT`).** The target must be a draft;\nfinalizing a live invoice is rejected. Finalize refuses any policy-linked\ninvoice with `422 POLICY_INVOICE_BATCH_ONLY`: a policy's invoices are\nwritten only by the\n[policy invoice batch](/api-reference/financials/update-policy-invoices).\n\n**Concurrency + idempotency.** Requires `If-Match` (the draft's current\n`headJournalId`); the body carries the client-minted `actionId`. An\nidentical retry replays the original outcome — the finalized invoice — and\nnever re-posts or double-applies the annex.\n\n**Required permission:** `invoice.finalize`. When the draft carries\n`draftPayments` that post on finalize, the invoice lands paid, which\nrequires `invoice.finalize-paid`, or `invoice.finalize` together with\n`payment.record`. A key without them receives `403`.\n","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/finalize","href":"/api-reference/financials/finalize-invoice"},{"title":"Void Invoice","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/void","href":"/api-reference/financials/void-invoice"},{"title":"Restore Invoice","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/restore","href":"/api-reference/financials/restore-invoice"}]},{"group":"Bill Review","pages":[{"title":"Start Invoice Bill Review","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/bill-review","href":"/api-reference/financials/start-invoice-bill-review"},{"title":"Get Invoice Bill Review","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/bill-review","href":"/api-reference/financials/get-invoice-bill-review"}]},{"group":"Payments","pages":[{"title":"Record Payment","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/payments","href":"/api-reference/financials/record-payment"},{"title":"Remove Payment","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/payments/{paymentId}","href":"/api-reference/financials/remove-payment"}]},{"group":"Payees","pages":[{"title":"Change Invoice Payee","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/invoices/{invoiceId}/payee","href":"/api-reference/financials/change-invoice-payee"},{"title":"Merge Payee","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/payees/{payeeId}/merge","href":"/api-reference/financials/merge-payee"}]},{"group":"Reserves","pages":[{"title":"Set Reserves","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/financials/events/{eventId}/reserves/{categoryId}","href":"/api-reference/financials/set-reserves"},{"title":"Reset Reserve History","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/events/{eventId}/reserves/{categoryId}/history-reset","href":"/api-reference/financials/reset-reserve-history"},{"title":"List Reserve Updates","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/events/{eventId}/reserve-updates","href":"/api-reference/financials/list-reserve-updates"},{"title":"List Company Reserve Updates","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/reserve-updates","href":"/api-reference/financials/list-company-reserve-updates"}]},{"group":"Balances","pages":[{"title":"Get Balances","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/balances","href":"/api-reference/financials/get-balances"},{"title":"Get Entity Balances","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/entities/{entityType}/{entityId}/balances","href":"/api-reference/financials/get-entity-balances"}]},{"group":"Configuration","pages":[{"title":"Export Financials Configuration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/export","href":"/api-reference/financials/export-financials-configuration"},{"title":"Import Financials Configuration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/import","href":"/api-reference/financials/import-financials-configuration"},{"title":"List Transaction Categories","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/config/categories","href":"/api-reference/financials/list-transaction-categories"},{"title":"Set Transaction Category Money-Out Approval","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/financials/config/categories/{categoryId}/money-out-approval","href":"/api-reference/financials/set-transaction-category-money-out-approval"},{"title":"List Policy Invoice Types","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/config/policy-invoice-types","href":"/api-reference/financials/list-policy-invoice-types"},{"title":"Create Policy Invoice Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/policy-invoice-types","href":"/api-reference/financials/create-policy-invoice-type"},{"title":"List Policy Line Item Types","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/config/policy-line-item-types","href":"/api-reference/financials/list-policy-line-item-types"},{"title":"Create Policy Line Item Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/policy-line-item-types","href":"/api-reference/financials/create-policy-line-item-type"},{"title":"Rename Policy Invoice Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/financials/config/policy-invoice-types/{categoryId}","href":"/api-reference/financials/rename-policy-invoice-type"},{"title":"Delete Policy Invoice Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/financials/config/policy-invoice-types/{categoryId}","href":"/api-reference/financials/delete-policy-invoice-type"},{"title":"Deprecate Policy Invoice Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/policy-invoice-types/{categoryId}/deprecate","href":"/api-reference/financials/deprecate-policy-invoice-type"},{"title":"Reactivate Policy Invoice Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/policy-invoice-types/{categoryId}/reactivate","href":"/api-reference/financials/reactivate-policy-invoice-type"},{"title":"Rename Policy Line Item Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/financials/config/policy-line-item-types/{lineItemTypeId}","href":"/api-reference/financials/rename-policy-line-item-type"},{"title":"Delete Policy Line Item Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/financials/config/policy-line-item-types/{lineItemTypeId}","href":"/api-reference/financials/delete-policy-line-item-type"},{"title":"Deprecate Policy Line Item Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/policy-line-item-types/{lineItemTypeId}/deprecate","href":"/api-reference/financials/deprecate-policy-line-item-type"},{"title":"Reactivate Policy Line Item Type","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/policy-line-item-types/{lineItemTypeId}/reactivate","href":"/api-reference/financials/reactivate-policy-line-item-type"},{"title":"Set Policy Invoice Type Direction","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/financials/config/policy-invoice-types/{categoryId}/expected-direction","href":"/api-reference/financials/set-policy-invoice-type-direction"},{"title":"Set Policy Invoice Type Payee Defaults","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/financials/config/policy-invoice-types/{categoryId}/payee-defaults","href":"/api-reference/financials/set-policy-invoice-type-payee-defaults"},{"title":"Set Policy Invoice Type Presets","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/financials/config/policy-invoice-types/{categoryId}/presets","href":"/api-reference/financials/set-policy-invoice-type-presets"},{"title":"Set Policy Invoice Type Money-Out Approval","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/financials/config/policy-invoice-types/{categoryId}/money-out-approval","href":"/api-reference/financials/set-policy-invoice-type-money-out-approval"},{"title":"Set Policy Line Item Associations","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/config/policy-line-item-types/associations","href":"/api-reference/financials/set-policy-line-item-associations"},{"title":"Reset Approval Config","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/financials/config/approvals","href":"/api-reference/financials/reset-approval-config"}]},{"group":"Maintenance","pages":[{"title":"Import Event Financials","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/events/{eventId}/import","href":"/api-reference/financials/import-event-financials"},{"title":"Check Financials Read-State Consistency","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/financials/validation/check","href":"/api-reference/financials/check-financials-read-state-consistency"},{"title":"Rebuild Financials Read-State","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/validation/sync","href":"/api-reference/financials/rebuild-financials-read-state"},{"title":"Delete All Financial Data","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/financials/deleteAll","href":"/api-reference/financials/delete-all-financial-data"}]}]},{"group":"Rating","pages":[{"title":"Overview","href":"/api-reference/rating/overview"},{"title":"Rate Quote (Read-Only)","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/quotes/rate","href":"/api-reference/field-model-rating/rate-quote-read-only"},{"title":"Rate Saved Quote by Id","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/quotes/{quoteId}/rate","href":"/api-reference/field-model-rating/rate-saved-quote-by-id"}]},{"group":"Notes","pages":[{"title":"Overview","href":"/api-reference/notes/overview"},{"title":"List Notes","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/notes","href":"/api-reference/field-model-notes/list-notes"},{"title":"Create Note","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/notes","href":"/api-reference/field-model-notes/create-note"},{"title":"Get Note","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/notes/{noteId}","href":"/api-reference/field-model-notes/get-note"},{"title":"Update Note","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/notes/{noteId}","href":"/api-reference/field-model-notes/update-note"},{"title":"Delete Note","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/notes/{noteId}","href":"/api-reference/field-model-notes/delete-note"}]},{"group":"Tasks","pages":[{"title":"Overview","href":"/api-reference/tasks/overview"},{"title":"List Tasks","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/tasks","href":"/api-reference/tasks/list-tasks"},{"title":"Get Task","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/tasks/{taskId}","href":"/api-reference/tasks/get-task"},{"title":"Create Task","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/tasks","href":"/api-reference/tasks/create-task"},{"title":"Update Task","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/tasks/{taskId}","href":"/api-reference/tasks/update-task"},{"title":"Delete Task","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/tasks/{taskId}","href":"/api-reference/tasks/delete-task"}]},{"group":"Imports","hidden":true,"pages":[{"title":"Overview","href":"/api-reference/imports/overview"},{"title":"Import Rows","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/imports/rows","href":"/api-reference/imports/import-rows"},{"title":"Queue Import Job","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/imports/jobs","href":"/api-reference/imports/queue-import-job"},{"title":"Get Import Job","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/imports/jobs/{jobId}","href":"/api-reference/imports/get-import-job"},{"title":"Import Entity","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/imports","href":"/api-reference/imports/import-entity"},{"title":"Retry Import","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/imports/retry","href":"/api-reference/imports/retry-import"},{"title":"List Import Rows","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/imports/rows","href":"/api-reference/imports/list-import-rows"},{"title":"Get Import Row","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/imports/rows/{importRowId}","href":"/api-reference/imports/get-import-row"},{"title":"List Import Attempts","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/imports/attempts","href":"/api-reference/imports/list-import-attempts"},{"title":"Get Import Attempt","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/imports/attempts/{importAttemptId}","href":"/api-reference/imports/get-import-attempt"},{"title":"Replace Record Legacy Activity","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/entities/{entityType}/{entityId}/legacy-activity","href":"/api-reference/imports/replace-record-legacy-activity"}]},{"group":"Configuration Management","pages":[{"title":"Overview","href":"/api-reference/configuration/overview"},{"title":"Conversion Rules","href":"/api-reference/configuration/conversion-rules"},{"title":"Author JEXL expressions","href":"/api-reference/configuration/jexl-authoring"},{"title":"JEXL reference","href":"/api-reference/configuration/jexl-reference"},{"group":"Inspect","pages":[{"title":"Export Configuration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/export","href":"/api-reference/fmv1-configuration/export-configuration"},{"title":"Describe Configuration (run-down)","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/describe","href":"/api-reference/fmv1-configuration/describe-configuration-run-down"},{"title":"Describe Configuration Entity (fields of one entity or custom object)","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/describe/{entityOrObjectKey}","href":"/api-reference/fmv1-configuration/describe-configuration-entity-fields-of-one-entity-or-custom-object"},{"title":"Get Configuration Metadata","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/metadata","href":"/api-reference/fmv1-configuration/get-configuration-metadata"},{"title":"Get Configuration JSON Schema","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/schema","href":"/api-reference/fmv1-configuration/get-configuration-json-schema"}]},{"group":"Validate \u0026 Compare","pages":[{"title":"Validate Configuration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/validate","href":"/api-reference/fmv1-configuration/validate-configuration"},{"title":"Compare Configuration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/compare","href":"/api-reference/fmv1-configuration/compare-configuration"},{"title":"Start Data Validation Run","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/data-validation-runs","href":"/api-reference/fmv1-configuration/start-data-validation-run"},{"title":"Get Data Validation Run","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/configuration/data-validation-runs/{runId}","href":"/api-reference/fmv1-configuration/get-data-validation-run"},{"title":"List Data Validation Run Findings","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/configuration/data-validation-runs/{runId}/findings","href":"/api-reference/fmv1-configuration/list-data-validation-run-findings"}]},{"group":"Apply Changes","pages":[{"title":"Import Configuration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/import","href":"/api-reference/fmv1-configuration/import-configuration"},{"title":"Patch Configuration (typed changes)","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/configuration/patch","href":"/api-reference/fmv1-configuration/patch-configuration-typed-changes"}]}]},{"group":"Company Files","pages":[{"title":"Overview","href":"/api-reference/company-files/overview"},{"title":"List File Categories","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/files/categories","href":"/api-reference/company-files/list-file-categories"},{"group":"Uploads","pages":[{"title":"Create Upload Intent","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files","href":"/api-reference/company-files/create-upload-intent"},{"title":"Finalize Upload","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/{fileId}/finalize","href":"/api-reference/company-files/finalize-upload"}]},{"group":"Migrations","pages":[{"title":"Prepare File Migration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/migrations/prepare","href":"/api-reference/company-files/prepare-file-migration"},{"title":"Get File Migration State","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/migrations/state","href":"/api-reference/company-files/get-file-migration-state"},{"title":"Refresh File Migration Upload","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/migrations/refresh","href":"/api-reference/company-files/refresh-file-migration-upload"},{"title":"Finalize File Migration","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/migrations/finalize","href":"/api-reference/company-files/finalize-file-migration"},{"title":"Reconcile File Migration Metadata","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/migrations/reconcile","href":"/api-reference/company-files/reconcile-file-migration-metadata"}]},{"group":"Files","pages":[{"title":"List Files","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/files","href":"/api-reference/company-files/list-files"},{"title":"Get File Metadata","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/files/{fileId}","href":"/api-reference/company-files/get-file-metadata"},{"title":"Rename, Move, or Categorize File","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/files/{fileId}","href":"/api-reference/company-files/rename-move-or-categorize-file"},{"title":"Bulk Move Files","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/bulk-move","href":"/api-reference/company-files/bulk-move-files"},{"title":"Delete File","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/files/{fileId}","href":"/api-reference/company-files/delete-file"}]},{"group":"Downloads","pages":[{"title":"Get Download URL","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/files/{fileId}/download-url","href":"/api-reference/company-files/get-download-url"},{"title":"Batch Download URLs","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/download-urls","href":"/api-reference/company-files/batch-download-urls"}]},{"group":"Versions","pages":[{"title":"List File Versions","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/files/{fileId}/versions","href":"/api-reference/company-files/list-file-versions"},{"title":"Create Re-upload Intent","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/{fileId}/versions","href":"/api-reference/company-files/create-re-upload-intent"},{"title":"Restore File Version","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/{fileId}/versions/{versionId}/restore","href":"/api-reference/company-files/restore-file-version"}]},{"group":"Placements","pages":[{"title":"List File Placements","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/files/{fileId}/placements","href":"/api-reference/company-files/list-file-placements"},{"title":"Add File Placement (Share to Another Entity)","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/{fileId}/placements","href":"/api-reference/company-files/add-file-placement-share-to-another-entity"},{"title":"Update File Placement (Move / Categorize per Entity)","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/files/{fileId}/placements/{placementId}","href":"/api-reference/company-files/update-file-placement-move-categorize-per-entity"},{"title":"Remove File Placement","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/files/{fileId}/placements/{placementId}","href":"/api-reference/company-files/remove-file-placement"}]},{"group":"Folders","pages":[{"title":"Create Folder","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/folders","href":"/api-reference/company-files/create-folder"},{"title":"Get Folder Tree","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/folders","href":"/api-reference/company-files/get-folder-tree"},{"title":"List Folder Contents","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/folders/{folderId}","href":"/api-reference/company-files/list-folder-contents"},{"title":"Rename, Move or Categorize Folder","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/folders/{folderId}","href":"/api-reference/company-files/rename-move-or-categorize-folder"},{"title":"Delete Folder","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/folders/{folderId}","href":"/api-reference/company-files/delete-folder"}]}]},{"group":"Forms","pages":[{"title":"Overview","href":"/api-reference/forms/overview"},{"title":"List Forms","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/forms","href":"/api-reference/forms/list-forms"},{"title":"Download Form","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/forms/{number}","href":"/api-reference/forms/download-form"},{"title":"Rename Form","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml patch /api/v1/companies/{companyId}/forms/{number}","href":"/api-reference/forms/rename-form"},{"title":"Delete Form","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml delete /api/v1/companies/{companyId}/forms/{number}","href":"/api-reference/forms/delete-form"},{"group":"Templates","pages":[{"title":"Upload Form Template","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/forms/template","href":"/api-reference/forms/upload-form-template"},{"title":"Replace Form Template","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/forms/template/{number}","href":"/api-reference/forms/replace-form-template"},{"title":"Touch Form Template","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/forms/template/{number}/touch","href":"/api-reference/forms/touch-form-template"},{"title":"Audit Form Template Smart Tags","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/forms/template/{number}/smart-tag-audit","href":"/api-reference/forms/audit-form-template-smart-tags"}]},{"group":"Static Forms","pages":[{"title":"Upload Static Form","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/forms/static","href":"/api-reference/forms/upload-static-form"},{"title":"Replace Static Form","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml put /api/v1/companies/{companyId}/forms/static/{number}","href":"/api-reference/forms/replace-static-form"}]},{"group":"Generated Forms","pages":[{"title":"List Generated Forms","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/forms/generated","href":"/api-reference/forms/list-generated-forms"},{"title":"Upload Event Form","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/forms/generated","href":"/api-reference/forms/upload-event-form"},{"title":"Touch Generated Form","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/forms/generated/{id}/touch","href":"/api-reference/forms/touch-generated-form"},{"title":"Audit Generated Form Smart Tags","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/forms/generated/{id}/smart-tag-audit","href":"/api-reference/forms/audit-generated-form-smart-tags"}]},{"group":"Packets","pages":[{"title":"List Form Packets","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/forms/packets","href":"/api-reference/forms/list-form-packets"},{"title":"Import Historical Form Packet","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/forms/packets/import","href":"/api-reference/forms/import-historical-form-packet"},{"title":"Get Form Packet Download URL","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/forms/packets/{packetId}/download-url","href":"/api-reference/forms/get-form-packet-download-url"}]}]},{"group":"Document Generation","pages":[{"title":"Overview","href":"/api-reference/documents/overview"}]},{"group":"Submission Parsing","pages":[{"title":"Overview","href":"/api-reference/parsing/overview"},{"title":"Trigger Parse","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml post /api/v1/companies/{companyId}/files/trigger-parse","href":"/api-reference/submission-parsing/trigger-parse"},{"title":"List Parse Runs","deprecated":null,"version":null,"openapi":"/openapi/generated-external-api.yaml get /api/v1/companies/{companyId}/files/parse-runs","href":"/api-reference/submission-parsing/list-parse-runs"}]},{"group":"Reference","pages":[{"title":"Structured Field Values","href":"/api-reference/field-values/overview"},{"title":"Data Models","href":"/api-reference/data-models"},{"title":"API Changelog","href":"/api-reference/changelog"}]}]}]},"basePath":"","title":"Unapprove Invoice - AI Insurance","buildId":"dpl_5joLUXmnJgwqjrHAS4dxZrQTdxgh","deploymentId":"dpl_5joLUXmnJgwqjrHAS4dxZrQTdxgh","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-DPDWPCdE.js","utils-DyjUHyLo.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-BWYE1cdS.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-COAzxpEw.js","snippetPresets-DNiD_S52.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","ApiExamples-CjwVt80x.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-ByHQMk7z.js","shallow-CaZuw1AO.js","getApiPlaygroundDisplay-DPVPOknm.js","CodeSnippet-B31CH-Mp.js","CodeSnippets-BxTYZWz6.js","Page-DDHbuAIY.js","getPastedJson-DhoAwiNO.js","icon-Dhq8z75J.js","MethodPill-DLXmKOwr.js","DuplicateIcon-jzdVwyRU.js","createIcon-eD0b3klN.js","DynamicMarkdown-BfddVCX7.js","SectionHeading-2pSCIo17.js","axios-vUo_bRtp.js","Markdown-DsWjhwJ4.js","clsx-B2t_mZQG.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-CUljsAY7.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-Cf70306N.js"]}