Filtering Transaction Requests
Learn how to use filters to define what is returned by the transactions endpoint.
Overview
Every time that you submit a payment request, including, card payments, recurring payments, Apple Pay and Google Pay, you are returned a transaction_id
. You can then use the transactions endpoint to retrieve all transaction details.
If you submit a generic request such as, GET/transactions/{transaction_id}
you will be returned all the parameters within the response.
Filter parameters returned
Our /transactions endpoint allows you to filter the parameters returned within the response. You can filter by all parameters that are returned.
Example:
In this example we are filtering the response of an individual transaction to just include status
and reason
.
GET/transactions/{transaction_id}?filter=status,reason
{
"status": "declined",
"reason": "closed_account"
}
In the next example we are filtering the request to return more parameters in the response.
GET/transactions/{transaction_id}?filter=status,reason,mid,payment_product,payment_method,transaction_type
{
"status": "success",
"reason": "",
"mid": "a36c8fdb-bec8-c121-ac30-9cc41878f3d7",
"payment_product": "card",
"payment_method": "authorisation",
"transaction_type": "payment_in"
}
Updated 28 days ago