Listing Transactions

The List Transactions API will return an array of Transactions sorted in descending order by their creation date. A maximum of 100 Transactions will be returned at a time.

This endpoint can be used to do things like export transactions, find all Transactions that have failed or not been acknowledged, and so on.

Filtering

The results can be filtered using one or more query parameters. For example, to see all Transactions that are rejected, you would send this query:

curl --request GET \
     --url 'https://api.orderful.com/v3/transactions?acknowledgmentStatus=REJECTED' \
     --header 'accept: application/json' \
     --header 'orderful-api-key: YOUR_API_KEY'

Multiple query parameters can be combined to refine the results as necessary. As another example, if you wanted to see all Transactions that were 810 Invoices that had been rejected:

curl --request GET \
     --url 'https://api.orderful.com/v3/transactions?transactionType=810_INVOICE&acknowledgmentStatus=REJECTED' \
     --header 'accept: application/json' \
     --header 'orderful-api-key: YOUR_API_KEY'

Date and time filtering

Currently, transactions only be filtered by date and time with this specific format:

createdAt=[YYYY-MM-DDTZhh:mm:ss.sssZ,YYYY-MM-DDTZhh:mm:ss.sssZ)

For example, this query would return all Transactions created on or after 2021-09-02T00:00:00.000 but before 2021-09-04T00:00:00.000Z.

curl -g --request GET \
     --url 'https://api.orderful.com/v3/transactions?createdAt=[2021-09-02T00:00:00.000Z,2021-09-04T00:00:00.000Z)' \
     --header 'accept: application/json' \
     --header 'orderful-api-key: YOUR_API_KEY'

For more information see Filtering

Pagination

If the number of results for a given query exceeds the limit, the results will be paginated. Links to the previous and next pages will be returned in the metadata of the list object. The next page of results is indicated using a link with a nextCursor parameter, while any page after the first will also show a link to the previous paginated set of results using a prevCursor parameter.

"metadata": {
    "pagination": {
        "links": {
            "next": "https://api.orderful.com/v3/transactions?nextCursor=Mjk3NDk%3D",
            "prev": "https://api.orderful.com/v3/transactions?prevCursor=MzE0MzI%3D"
        }
    }
}

You will know that you’ve retrieved all available Transactions when the next link is null.