Skip to main content

createSupplierPayment

Requires permission purchase:payment:create.

Records a payment to a supplier (type PAYMENT), optionally allocated to the supplier's purchase invoices in the same call. Allocations must be in the payment's currency and cannot exceed an invoice's outstanding amount. An explicit idempotency key makes a retry return the original payment. Needs the supplier payments create permission.

Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.

Example:

mutation CreateSupplierPayment($input: CreateSupplierPaymentInput!) {
createSupplierPayment(input: $input) {
id
checkNumber
currencyCode
paymentNumber
referenceNumber
status
allocations {
id
invoiceNumber
paymentNumber
createdAt
amount
appliedFromAdvance
}
}
}

Variables:

{
"input": {
"amount": 0,
"currency": "string",
"paymentDate": "2025-01-15T00:00:00Z",
"paymentMethod": "BANK_TRANSFER",
"supplierId": "id"
}
}

Response:

{
"data": {
"createSupplierPayment": {
"id": "id",
"checkNumber": "string",
"currencyCode": "string",
"paymentNumber": "string",
"referenceNumber": "string",
"status": "APPROVED",
"allocations": [
{
"id": "id",
"invoiceNumber": "string",
"paymentNumber": "string",
"createdAt": "2025-01-15T00:00:00Z",
"amount": 0,
"appliedFromAdvance": true
}
]
}
}
}
createSupplierPayment(
input: CreateSupplierPaymentInput!
): Payment!

Arguments​

createSupplierPayment.input ● CreateSupplierPaymentInput! non-null input​

The supplier payment to record.

Type​

Payment object​

A payment made out to a vendor or a collection received from a customer, with its allocations to invoices.