GoCardlessDeveloper Docs
Create a sandbox account

Payment Account Transaction

View as Markdown

Payment account transactions represent movements of funds on a given payment account. The payment account is provisioned by GoCardless and is used to fund outbound payments.

Get a single payment account transaction#

GET/payment_account_transactions/{payment_account_transaction_id}

Retrieves the details of an existing payment account transaction.

Path Parameters

NameTypeDescription
payment_account_transaction_idrequiredstring

The payment account transaction id

GET https://api.gocardless.com/payment_account_transactions/PATR1234
@client.payment_account_transactions.get("PATR1234")
client.payment_account_transactions.get("PATR1234")
const resp = await client.paymentAccountTransactions.find("PATR1234");
$client->paymentAccountTransactions()->get("PATR1234");
client.paymentAccountTransactions().get("PATR1234").execute();
transaction, err := client.PaymentAccountTransactions.Get(ctx, "PATR1234")
var resp = await client.PaymentAccountTransactions.GetAsync("PATR1234");
Responsehttp
HTTP/1.1 200 OK
Content-Type: application/json
{
  "payment_account_transactions": {
    "id": "PATR1234",
    "currency": "GBP",
    "value_date": "2014-05-08",
    "description": "Reward Payment (August 2024)",
    "reference": "GC-058408d9",
    "balance_after_transaction": 1,
    "amount": 1000,
    "counterparty_name": "Acme Ltd",
    "direction": "debit",
    "links": {
      "outbound_payment": "OUT123",
      "payment_bank_account": "BA123"
    }
  }
}
Response 200

Successful response

payment_account_transactionsobject
10 properties
idstring

The unique ID of the payment account transaction.

value_datestring

The date of when the transaction occurred.

referencestring

The reference of the transaction. This is typically supplied by the sender.

descriptionstring

The description of the transaction, if available

counterparty_namestring

The name of the counterparty of the transaction. The counterparty is the recipient for a credit, or the sender for a debit.

linksobject
3 properties
payoutstring

ID of the payout linked to the transaction.

outbound_paymentstring

ID of the outbound_payment linked to the transaction

payment_bank_accountstring

ID of the payment bank account.

currencystring

The currency of the transaction.

GBP
directionstring

The direction of the transaction. Debits mean money leaving the account (e.g. outbound payment), while credits signify money coming in (e.g. manual top-up).

creditdebit
amountinteger

Amount, in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR).

balance_after_transactioninteger

Balance after transaction, in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR).

Errors 400401404422500
400

Bad Request

401

Unauthorised

404

Not found

422

Validation Error

500

Internal Error

Error Body
codeinteger
documentation_urlstring
errorsarray
2 properties
reasonstring
messagestring
messagestring
request_idstring
typestring
metadataobject
linksobject

List payment account transactions#

GET/payment_accounts/{payment_account_transaction_id}/transactions

List transactions for a given payment account.

Path Parameters

NameTypeDescription
payment_account_transaction_idrequiredstring

The payment account transaction id

GET https://api.gocardless.com/payment_accounts/BA12345/transactions
@client.payment_account_transactions.list(
  "BA12345",
  params: {
    value_date_from: "2024-01-01",
    value_date_to: "2024-01-31"
  }
)
client.payment_account_transactions.list("BA12345", params={
  "value_date_from": "2024-01-01",
  "value_date_to": "2024-01-31"
})
const resp = await client.paymentAccountTransactions.list("BA12345", {
  value_date_from: "2024-01-01",
  value_date_to: "2024-01-31"
});
$client->paymentAccountTransactions()->list("BA12345", [
  "params" => [
    "value_date_from" => "2024-01-01",
    "value_date_to" => "2024-01-31"
  ]
]);
client.paymentAccountTransactions().list("BA12345")
  .withValueDateFrom("2024-01-01")
  .withValueDateTo("2024-01-31")
  .execute();
paymentAccountTransactionListParams := gocardless.PaymentAccountTransactionListParams{
  ValueDateFrom: "2024-01-01",
  ValueDateTo: "2024-01-31",
}

transactionListResult, err := client.PaymentAccountTransactions.List(ctx, "BA12345", paymentAccountTransactionListParams)
var request = new GoCardless.Services.PaymentAccountTransactionListRequest()
{
  ValueDateFrom = "2024-01-01",
  ValueDateTo = "2024-01-31"
};

var resp = await client.PaymentAccountTransactions.ListAsync("BA12345", request);
Responsehttp
HTTP/1.1 200
Content-Type: application/json
{
  "payment_account_transactions": [
    {
      "id": "PATR1234",
      "currency": "GBP",
      "value_date": "2014-05-08",
      "description": "Reward Payment (August 2024)",
      "reference": "GC-058408d9",
      "balance_after_transaction": 1,
      "amount": 1000,
      "counterparty_name": "Acme Ltd",
      "direction": "debit",
      "links": {
        "outbound_payment": "OUT123",
        "payment_bank_account": "BA123125"
      }
    },
    {
      "id": "PATR1235",
      "currency": "GBP",
      "value_date": "2014-05-08",
      "description": "Payout",
      "reference": "GC-058408d9",
      "amount": 10000,
      "balance_after_transaction": 10000,
      "counterparty_name": "GoCardless Ltd",
      "direction": "credit",
      "links": {
        "payout": "PO1234",
        "payment_bank_account": "BA123125"
      }
    }
  ]
}
Response 200

Successful response

payment_account_transactionsarray
10 properties
idstring

The unique ID of the payment account transaction.

value_datestring

The date of when the transaction occurred.

referencestring

The reference of the transaction. This is typically supplied by the sender.

descriptionstring

The description of the transaction, if available

counterparty_namestring

The name of the counterparty of the transaction. The counterparty is the recipient for a credit, or the sender for a debit.

linksobject
3 properties
payoutstring

ID of the payout linked to the transaction.

outbound_paymentstring

ID of the outbound_payment linked to the transaction

payment_bank_accountstring

ID of the payment bank account.

currencystring

The currency of the transaction.

GBP
directionstring

The direction of the transaction. Debits mean money leaving the account (e.g. outbound payment), while credits signify money coming in (e.g. manual top-up).

creditdebit
amountinteger

Amount, in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR).

balance_after_transactioninteger

Balance after transaction, in the lowest denomination for the currency (e.g. pence in GBP, cents in EUR).

metaobject
2 properties
limitinteger
cursorsobject
2 properties
beforestring

Cursor pointing to the end of the desired set.

afterstring

Cursor pointing to the start of the desired set.

Errors 400401404422500
400

Bad Request

401

Unauthorised

404

Not found

422

Validation Error

500

Internal Error

Error Body
codeinteger
documentation_urlstring
errorsarray
2 properties
reasonstring
messagestring
messagestring
request_idstring
typestring
metadataobject
linksobject