GET
View a purchase payment
Company space For: Buyer, Accountant · Permission: purchases.retrieve, purchase_payments.retrieve Part of Pay suppliers and adjust debt.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

purchase
string
required

Identifier of the purchase (27-character KSUID).

payment
string
required

Identifier of the purchase payment, which must belong to the purchase in the path (27-character KSUID string).

Query Parameters

response
enum<string>
default:resource

Response mode. Default resource; none answers 204 No Content.

Available options:
resource
fields
string

Comma-separated JSON keys of the root resource (id is always rendered). Available: id, purchase_id, vendor_id, vendor_credit_payment_id, payment_method, cash_register_id, money_account_id, amount, discount_received, paid_at, currency_code, currency_exponent, reference, created_at, updated_at.

include
string

Comma-separated include paths, each optionally followed by its fields in parentheses: units(id,sku),units.uomUnit(id,name). Max depth 6, max 40 paths. Available: purchase, purchase.items, purchase.debtAdjustments, purchase.returns, purchase.pickups, purchase.deliveries, purchase.vendor.

Response

200 - application/json

Resource.

id

Identifier of the purchase payment (27-character KSUID string).

purchase_id

Identifier of the purchase that was paid.

vendor_id

Identifier of the supplier, copied from the purchase.

vendor_credit_payment_id

Identifier of the supplier payment this payment is a share of; null for a payment made directly on the purchase.

payment_method

How the payment was made. Only cash is accepted today.

cash_register_id

Identifier of the cash register the money came from.

money_account_id

Identifier of the money account used. Always null for payments made through the API today, which only accept cash registers.

amount
number

Amount paid to the supplier in major units (the minor-unit amount divided by 10 to the power currency_exponent), using the payment's own currency_exponent.

discount_received
number

Settlement discount granted by the supplier with this payment in major units (the minor-unit amount divided by 10 to the power currency_exponent); it reduces the debt like a payment but is not cash. 0 when none.

paid_at

Date and time of the payment (ISO 8601). Set by the server.

currency_code

Three-letter currency code of the payment (the company currency).

currency_exponent
integer

Number of decimal places of the currency (0 for XOF). An amount in minor units divided by 10 to this power gives the amount in the currency.

reference

Free reference supplied with the payment, for example a receipt number.

purchase
object

The paid purchase. Present only when requested with include=purchase.

created_at

Date and time the record was created (ISO 8601, UTC).

updated_at

Date and time the record was last changed (ISO 8601, UTC).