v1

latestOpenAPI 3.0.02026-08-0696238481.7 KB
Payments

List payment transaction(s)

List the transaction(s) for a particular payment

get/payment-sessions/{paymentSessionId}/transactions

Path parameters

paymentSessionIdstring required

Payment Id to list transactions for

Query parameters

startTimestampinteger
Example:1641859200

The timestamp when to return transactions from (inclusive). If provided, endTimestamp must also be provided.

endTimestampinteger
Example:1641945599

The timestamp when to return transactions up to (inclusive). If provided, startTimestamp must also be provided.

ascendingboolean

Control the order (newest or oldest) in which the transactions are returned. false will arrange the results with newest first, whereas true shows oldest first. The default is false.

limitinteger
Example:10

Control how many items are return in a given page The max limit we allow is 50. The default is 10.

startsAfterstring
Example:txn_01FCTS1XMKH9FF43CAFA4CXT3P_01FCTS1XMKH9FF43CAFA4CXT3P

A token to identify the item to start querying after. This is most commonly used to get the next page of results after a previous response did not return all items, due to the imposed limit. The value of the paginationToken field from that response should be supplied here as startsAfter, to retrieve the next page of results for that timestamp range.

Headers

Accountstring
Example:ac_3fe8398f-8cdb-43a3-9be2-806c4f84c327

The linked accountId (use this when operating on payments related to a linked account)

Response

Request Ok

paginationTokenstring nullable

A token to use for getting the next page of results - send the same request with this value in the 'startsAfter' query parameter. This field is null when there are no further items to return

Example response

{
  "items": [
    {
      "id": "txn_01FCTS1XMKH9FF43CAFA4CXT3P_01FCTS1XMKH9FF43CAFA4CXT3P",
      "paymentSessionId": "ps_01FCTS1XMKH9FF43CAFA4CXT3P",
      "amount": 250,
      "currency": "GBP",
      "type": "Capture",
      "status": "Succeeded",
      "refundedAmount": 50,
      "platformFee": 50,
      "platformFeeRefundedAmount": 50,
      "processingFee": 7,
      "reason": "Requested by the customer",
      "captureType": "Final",
      "paymentMethod": {
        "type": "Card",
        "tokenizedDetails": {
          "id": "pmt_01G0EYVFR02KBBVE2YWQ8AKMGJ",
          "stored": true
        },
        "card": {
          "scheme": "Mastercard",
          "last4": "4242",
          "binDetails": {
            "issuer": "Ryft Bank Ltd",
            "issuerCountry": "GB",
            "fundingType": "Debit",
            "productType": "Consumer"
          }
        },
        "wallet": {
          "type": "ApplePay"
        },
        "billingAddress": {
          "firstName": "Nathan",
          "lastName": "Jones",
          "lineOne": "123 Test Street",
          "lineTwo": "456 Lane",
          "city": "Manchester",
          "country": "GB",
          "postalCode": "SP4 7DE",
          "region": "NY"
        },
        "checks": {
          "avsResponseCode": "Y",
          "cvvResponseCode": "M"
        }
      },
      "splitPaymentDetail": {
        "items": [
          {
            "id": "sp_01FCTS1XMKH9FF43CAFA4CXT3P",
            "accountId": "ac_b83f2653-06d7-44a9-a548-5825e8186004",
            "amount": 50,
            "fee": {
              "amount": 50
            },
            "description": "2 x The Selfish Gene",
            "metadata": {
              "productId": "123",
              "productDescription": "The Selfish Gene"
            }
          }
        ]
      },
      "processingDetail": {
        "issuerResponseCode": "00",
        "authorizationCode": "123456",
        "acquirerReferenceNumber": "12093810928309123"
      },
      "inPersonDetail": {
        "terminalDetail": {
          "id": "tml_01FCTS1XMKH9FF43CAFA4CXT3P"
        }
      },
      "createdTimestamp": 1470989538,
      "lastUpdatedTimestamp": 1470989538
    }
  ],
  "paginationToken": "txn_01FCTS1XMKH9FF43CAFA4CXT3P_01FCTS1XMKH9FF43CAFA4CXT3P"
}