Get started
Make your first request
A list request changes nothing, so it is a safe first call. It confirms that your key, your environment, and your HTTP client work.
Send the request#
List one transaction. This needs the transactions:read scope. A key created without a choice of scopes holds this scope by default. If your key holds only the checkout scopes, list checkout sessions instead: GET /v1/checkout-sessions?limit=1 with checkout:read.
curl "https://api.merxian.com/v1/transactions?limit=1" \
-H "Authorization: Bearer $MERXIAN_API_KEY" \
-iThe -i option prints the response headers.
Read the response#
A list response has the items in data and the paging state in pagination. An account without transactions gets an empty data array.
{
"data": [
{
"id": "txn_0F8mQ2rXbT4kL9pZa",
"status": "completed",
"currency": "EUR",
"amounts": { "subtotal": 12000, "discount": 0, "net": 12000, "tax": 2280, "total": 14280 },
"paymentStatus": "paid",
"createdAt": "2026-09-14T09:21:07Z"
}
],
"pagination": { "nextCursor": "eyJpZCI6InR4bl8wRjhtUTJyWGJUNGtMOXBaYSJ9" }
}The example shows some fields only. Amounts are integers in the minor unit of the currency: 14280 in EUR is €142.80. See Money and currencies.
pagination is {} on the last page. To read the next page, send nextCursor as the cursor query parameter. See Pagination and filters.
Keep the request ID#
Every response has an X-Request-Id header. Log it with the request. It identifies the request if you need help from Merxian.
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 1f6c8a52-7d3e-4b9a-a0c4-5e2d9b7f3a61If the key is wrong#
A missing, malformed, revoked, or unknown key gets 401:
{
"errorCode": "AuthenticationRequired",
"message": "A valid API key is required.",
"fieldErrors": []
}The response also has the header WWW-Authenticate: Bearer. Check that:
- The header is
Authorization: Bearerfollowed by the key. - The key starts with
mx_sandbox_for sandbox. - The key has no extra spaces or line breaks.
A key without the required scope gets 403 with InsufficientScope. See the error reference.