API ReferenceInvoice
invoice.create
Type: Mutation · Auth: Workspace-aware
Input
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| customerId | string | Yes | — | ID of the associated customer |
| invoiceNumber | string | Yes | — | Invoice number |
| workOrderId | unknown | No | — | ID of the associated work order |
| projectId | unknown | No | — | ID of the associated project |
| maintenancePlanId | string | No | — | ID of the associated maintenance plan |
| quoteId | unknown | No | — | ID of the associated quote |
| projectMilestoneId | string | No | — | ID of the associated project milestone |
| monitoringAccountId | unknown | No | — | ID of the associated monitoring account |
| status | enum(draft, pending_approval, approved, sent, partially_paid, paid, overdue, void, canceled) | Yes | "draft" | Status |
| issueDate | unknown | No | — | Issue date |
| dueDate | unknown | No | — | Due date |
| taxAmount | unknown | No | — | Tax amount |
| amountPaid | unknown | No | — | Amount paid |
| stripeCustomerId | string | No | — | ID of the associated stripe customer |
| contactId | unknown | No | — | ID of the associated contact |
| sentAt | unknown | No | — | Sent at |
| viewedAt | unknown | No | — | Viewed at |
| pdfS3Key | string,null | No | — | Pdf s3key |
| personalMessage | unknown | No | — | Personal message |
| stripePaymentIntentId | unknown | No | — | ID of the associated stripe payment intent |
| stripeCheckoutSessionId | unknown | No | — | ID of the associated stripe checkout session |
| paymentUrl | string,null | No | — | Payment url |
| notes | string,null | No | — | Notes |
| workspaceId | string | No | — | ID of the associated workspace |
| visibilityMode | unknown | No | — | Visibility mode |
Example
{
"customerId": "550e8400-e29b-41d4-a716-446655440000",
"invoiceNumber": "example",
"workOrderId": null,
"projectId": null,
"maintenancePlanId": "550e8400-e29b-41d4-a716-446655440000",
"quoteId": null,
"status": "draft"
}