For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
GuidesAPI Reference
GuidesAPI Reference
  • Reference
    • Introduction
      • Contact Object
      • Consumer Object
      • Discount Object
      • Item Object
      • Money Object
      • Order Details Object
      • Payment Object
      • Payment Event Object
      • Refund Object
      • Shipping Courier Object
LogoLogo
On this page
  • Attributes
  • Example Payment object
ReferenceData Models

Payment object

Was this page helpful?
Previous

Payment Event Object

Next
Built with

Attributes

AttributeTypeDescription
idstringThe unique, permanent, Afterpay-generated Order ID.
tokenstringCheckout token that was used to complete payment.
statusstringAn order status of “APPROVED” or “DECLINED”.
createdstringThe UTC timestamp of when the payment was completed, in ISO 8601 format.
originalAmountMoneyTotal amount charged to the customer for the order.
openToCaptureAmountMoneyRemaining amount that can be captured. Will always be zero for immediate payment flow orders.
paymentStatestringCurrent state for capturing payments. Will be one of: “AUTH_APPROVED”, “AUTH_DECLINED”, “PARTIALLY_CAPTURED”, “CAPTURED”, “CAPTURE_DECLINED”,“VOIDED”.
merchantReferencestringThe merchant’s order id/reference that this payment corresponds to.
refundsRefundAn array of refunds. Note: in response to a Capture Full Payment call, this array will always be empty, since refunds cannot occur until payment is captured.
orderDetailsOrder DetailsThe details of the order bound to the payment.
eventsPayment EventOne or more payment events that have occurred against the order.

Link to Capture Full Payment

Example Payment object

1{
2 "id" : "12345678",
3 "token" : "ltqdpjhbqu3veqikk95g7p3fhvcchfvtlsiobah3u4l5nln8gii9",
4 "status" : "APPROVED",
5 "created" : "2024-01-01T00:00:00.000Z",
6 "originalAmount" : {
7 "amount" : "100.00",
8 "currency" : "USD"
9 },
10 "openToCaptureAmount" : {
11 "amount" : "100.00",
12 "currency" : "USD"
13 },
14 "paymentState" : "AUTH_APPROVED",
15 "merchantReference" : "merchantOrderId-1234",
16 "refunds" : [
17 ...
18 ],
19 "orderDetails" : {
20 ...
21 },
22 "events" : [ {
23 "id" : "1OUR16OTqL3DgJ3ELlwKowU9v6K",
24 "created" : "2024-01-01T00:00:00.000Z",
25 "expires" : "2024-01-01T00:00:00.000Z",
26 "type" : "AUTH_APPROVED",
27 "amount" : {
28 "amount" : "100.00",
29 "currency" : "USD"
30 }
31 }, ... ]
32}