When a webhook never reaches your handler, your order isn't updated. To reconcile transactions with SePay CLI, sepay transaction list --webhook-success 0 lists those transactions so you can compare them with your own records.
The CLI suits manual lookups and scripts on your machine. An application that reconciles on its own in production calls the List Transactions API; see Reconcile transactions through the API.
transaction list and transaction get run on both sandbox and production and only read data. You need to be signed in. Production also needs the read scope (Environments).
transaction list
Lists transactions, filtered by date, direction, account or webhook status.
Parameters
| Flag | Type | Description |
|---|---|---|
--from | string | From this time. YYYY-MM-DD, YYYY-MM-DD HH:MM:SS or RFC3339, in Vietnam time |
--to | string | Up to this time, same formats. A bare date covers that whole day: --to 2026-09-22 includes a transaction at 23:59 |
--transfer-type | string | in | out |
--webhook-success | string | 0: the webhook wasn't delivered successfully; 1: it was |
--bank-account | string | Bank account xid |
--va-xid | string | VA xid |
--reference-number | string | Reference number, exact match |
--search | string | Search by reference number, content or payment code |
--transaction-date-sort | string | asc | desc. Default: newest first |
--since-id | string | Only transactions after this xid; use together with --transaction-date-sort asc |
--page, --per-page | int | Pagination; 20 rows by default, up to 100 |
--fields | string | The fields to return, comma-separated |
Run sepay transaction list --help for the other flags (amount range, --bank, --transaction-content).
A reversed range stops the command with exit code 2 before anything is sent to SePay, for example a start date after the end date:
$ sepay transaction list --from 2026-10-02 --to 2026-10-01Error: --from must not be after --toRun 'sepay transaction list --help' for usage.A minimum amount greater than the maximum is refused the same way:
$ sepay transaction list --amount-in-min 500000 --amount-in-max 100000Error: --amount-in-min must not be greater than --amount-in-maxRun 'sepay transaction list --help' for usage.Example
$ sepay transaction list --webhook-success 0 --from 2026-09-22ID DATE AMOUNT CONTENT CODE BANK WHb7d30f15-xxxx-xxxx-xxxx-fa163e2f7c98 2026-09-22 15:40:12 +120.000 DH1712 thanh toan don hang DH1712 ACB failpage 1/1 · 1 of 1| Column | Description |
|---|---|
ID | The transaction xid |
AMOUNT | + money in, - money out |
CODE | The payment code SePay read from the transfer content |
WH | Webhook delivery result: ok delivered, fail not delivered or no webhook applies to the account, - no data |
Notes
faildoesn't tell a failed delivery apart from an account with no webhook, so--webhook-success 0also lists transactions of accounts that no webhook covers.WHreflects your endpoint's response, not whether your system recorded the order: a handler can return success without having processed the payment (for example because of a bug in your code).- With
--json, the result is an array where each element is a transaction (id,transaction_date,transfer_type,amount_in,amount_out,reference_number,code,webhook_success). The array carries no pagination information. When more pages remain,stderrgets one extra line ending inmore rows remain; page through with --page/--per-page; a script should loop over--pageuntil it receives fewer rows than--per-page. --since-idwith the default order (newest first) skips transactions, so always pair it with--transaction-date-sort asc.
transaction get
Shows one transaction. The argument is the xid: the ID column, the id field in --json output, or txn= from sepay webhook listen.
$ sepay transaction get 3c9a6e41-xxxx-xxxx-xxxx-a6006ab65acaFIELD VALUEID 3c9a6e41-xxxx-xxxx-xxxx-a6006ab65acaDate 2026-09-22 15:40:12Amount +150.000Accumulated 1.150.000Content DH00012 thanh toan don hangReference FT26092212345Code DH00012Bank ACBAccount 123456789VA -Webhook failThe id field in a webhook payload is an integer, not an xid, so transaction get rejects it. To find a transaction from webhook data, look it up by the bank's reference: referenceCode in the webhook payload, reference_number in --json output and the value of --reference-number are the same code.
$ sepay transaction list --reference-number FT26092212345