Skip to main content
The Create Payable endpoint lets you programmatically generate a new payable (invoice) in Cleo Pay. You supply at minimum a contact and a total amount; optionally, you can attach structured line items, set issue and due dates, provide your own reference number, and add a free-text description. Newly created payables start in draft status and must proceed through your configured approval workflow before payment can be initiated.

Request

POST https://api.cleo-pay.com/v1/payables Include your bearer token and set the content type on every request:

Request Body Parameters

contact
object
required
The counterparty for this payable. Cleo Pay will match against existing contacts by email, or create a new contact record if no match is found.
totalAmountCents
number
required
Total invoice amount expressed in cents. Must be 1 or greater (e.g. pass 10000 for $100.00). If you also supply items, ensure this value equals the sum of all items[].totalCents to avoid reconciliation discrepancies.
dueDate
string
Payment due date in YYYY-MM-DD format (e.g. "2024-08-15"). Optional. When omitted, the payable is created without a due date.
issueDate
string
Invoice issue date in YYYY-MM-DD format (e.g. "2024-07-15"). Optional. Defaults to the creation date when omitted.
customNumber
string
Your own invoice or purchase-order reference number (e.g. "INV-1042"). Optional. This value is stored as-is and surfaced in the dashboard alongside the system-generated publicId.
description
string
Free-text memo or description for this payable (e.g. "Q3 software licensing fees"). Optional.
items
array
Structured line items that make up the invoice. Optional. Each element represents one line on the invoice.

Example Request

Response

A successful request returns HTTP 201 Created with the full PayableDetail object, including all line items as stored.
id
string
Internal opaque identifier for the new payable. Use this when calling other endpoints that reference a specific payable.
publicId
string
Stable public identifier shown in the Cleo Pay dashboard.
status
string
Initial lifecycle status of the payable. Newly created payables always start as draft.
paymentStatus
string
Initial payment status. Always none for newly created payables.
totalAmountCents
number
Total invoice amount in cents, as provided in the request.
amountPaidCents
number
Amount paid so far, in cents. Always 0 for newly created payables.
remainingAmountCents
number
Outstanding balance in cents. Equal to totalAmountCents for newly created payables.
dueDate
string | null
Payment due date in YYYY-MM-DD format, or null if not provided.
issueDate
string | null
Invoice issue date in YYYY-MM-DD format, or null if not provided.
customNumber
string | null
Your custom reference number as stored, or null if not provided.
description
string | null
Memo or description as stored, or null if not provided.
contact
object
Resolved contact record associated with this payable.
items
array
Line items attached to this payable, as stored.

Example Response