2.6 Get Deposit And Withdraw Transaction By Time (Common)
Use for Merchant get the deposit and withdraw transactions of all members directly under the agent for a date and time range. Same result as 2.3 Get Deposit And Withdraw Transaction, but startDate / endDate carry a time and the time zone can be chosen.
Method : [Post]
Path : {{domain}}/ext/depositWithdrawTransactionHistoryByTime/{{prefix}}/{{agentUsername}}
Content-Type : application/json
Request Body
{
"agentUsername": "{{agentUsername}}",
"key": "{{key}}",
"startDate": "01-11-2026 09:00:00",
"endDate": "01-11-2026 18:29:59",
"gmt": "+07:00",
"web": "{{whiteLabel}}"
}
| Key | Type | Example Value | Description |
|---|---|---|---|
| agentUsername | String | testag | The agent's username. |
| key | String | tnyENKDWvOkBXpvm6UZVa | The agent's unique key. |
| startDate | String | 01-11-2026 09:00:00 | Start, DD-MM-YYYY HH:mm:ss. Included. |
| endDate | String | 01-11-2026 18:29:59 | End, DD-MM-YYYY HH:mm:ss. Included up to the end of that second. |
| gmt | String | +07:00 | Optional. Time zone of startDate / endDate as +HH:MM or -HH:MM (minutes 00, 15, 30 or 45; from -12:00 to +14:00). Not sent = GMT+7. |
| web | String | sportbook101 | Active websites. |
Time range rules
- The format must match exactly: two-digit day, month, hour, minute and second, for example
01-11-2026 09:05:00. A date without a time is rejected (50013). - Both ends are included, and
endDatecounts to the end of its second.01-11-2026 00:00:00→01-11-2026 23:59:59is the whole day and returns the same transactions as 2.3 with01-11-2026→02-11-2026. For back-to-back windows end one second before the next start:00:00:00–00:59:59,01:00:00–01:59:59. startDatemay equalendDate(one second) but may not be after it (50014).- The same moment sent in a different time zone gives the same result:
01-11-2026 07:00:00with+07:00=01-11-2026 00:00:00with+00:00. dateof a transaction is the exact time it was recorded, so the range is exact to the second.- Only transactions with
transaction: "success"of members directly under the agent are returned, in no particular order.
Response
{
"code": 0,
"data": [
{
"_id": "62b974f56e82c478362086bb",
"transaction": "success",
"user": "auto0859765751",
"actionBy": "API",
"currency": "THB",
"action": "DEPOSIT",
"amount": 10,
"withdraw": 0,
"from": "CASH",
"date": "2026-11-01T02:14:29.256Z",
"__v": 0,
"afterCredit": 10,
"beforeCredit": 0
}
]
}
| Key | Type | Description |
|---|---|---|
| code | Number | Response code of API. |
| data | Array | Transactions. Same fields as 2.3. Empty array when there is none. |
| data[].user | String | Member username. |
| data[].action | String | DEPOSIT or WITHDRAW. |
| data[].amount | Number | Amount. |
| data[].currency | String | Currency. |
| data[].beforeCredit / afterCredit | Number | Credit before and after. |
| data[].date | Date | Time of the transaction (UTC). |
Error Code
| Value | msg |
|---|---|
| 0 | Success |
| 100001 | Missing 'agent Username' field. |
| 100002 | Agent username is type string. |
| 100003 | Missing 'key' field. |
| 100004 | Key is type string. |
| 100012 | Key not found. |
| 100013 | Agent not found. |
| 104 | missing 'startDate' field |
| 105 | missing 'endDate' field |
| 50012 | Invalid 'gmt' field. Expected format '+07:00'. |
| 50013 | Invalid 'startDate' or 'endDate'. Expected format 'DD-MM-YYYY HH:mm:ss'. |
| 50014 | 'startDate' must not be after 'endDate'. |
| 50010 | Something went wrong please try again. (temporary error, try again) |