forked from shihaam/thijooree
update docs
This commit is contained in:
@@ -0,0 +1,107 @@
|
||||
# Transaction History
|
||||
|
||||
Fetch paginated transaction history for a single MIB account. Served from the WebView subdomain.
|
||||
|
||||
---
|
||||
|
||||
## Endpoint
|
||||
|
||||
```
|
||||
POST https://faisamobilex-wv.mib.com.mv/ajaxAccounts/trxHistory
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Authentication
|
||||
|
||||
See [README](README.md) for cookie and AJAX header format.
|
||||
|
||||
```
|
||||
Referer: https://faisamobilex-wv.mib.com.mv//accountDetails?trxh=1&dashurl=1&accountNo=<accountNo>
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Request Body (form-urlencoded)
|
||||
|
||||
| Field | Example | Description |
|
||||
|---|---|---|
|
||||
| `accountNo` | `90101000000001000` | Account number to fetch history for |
|
||||
| `trxNo` | `` | Transaction number filter (empty = all) |
|
||||
| `trxType` | `0` | Transaction type filter (`0` = all) |
|
||||
| `sortTrx` | `date` | Sort field |
|
||||
| `sortDir` | `desc` | Sort direction |
|
||||
| `fromDate` | `` | From date filter (empty = no filter) |
|
||||
| `toDate` | `` | To date filter (empty = no filter) |
|
||||
| `start` | `1` | Start record index (1-based) |
|
||||
| `end` | `20` | End record index (`start + pageSize - 1`) |
|
||||
| `includeCount` | `1` | Include `total_count` in response |
|
||||
|
||||
### Pagination
|
||||
|
||||
Page size is 20. Compute `start`/`end` per page:
|
||||
|
||||
| Page | `start` | `end` |
|
||||
|---|---|---|
|
||||
| 1 | `1` | `20` |
|
||||
| 2 | `21` | `40` |
|
||||
| N | `(N-1)*20 + 1` | `N*20` |
|
||||
|
||||
Stop when total fetched equals `total_count` or `data` is empty.
|
||||
|
||||
---
|
||||
|
||||
## Response
|
||||
|
||||
```json
|
||||
{
|
||||
"success": true,
|
||||
"total_count": "87",
|
||||
"data": [
|
||||
{
|
||||
"trxNumber": "TXN20260516001",
|
||||
"trxDate": "2026-05-16",
|
||||
"descr1": "Transfer Debit",
|
||||
"baseAmount": "-500.00",
|
||||
"curCodeDesc": "MVR",
|
||||
"benefName": "Mohamed Ali",
|
||||
"trxNumber2": "FT20260516001"
|
||||
},
|
||||
{
|
||||
"trxNumber": "TXN20260515001",
|
||||
"trxDate": "2026-05-15",
|
||||
"descr1": "Transfer Credit",
|
||||
"baseAmount": "1000.00",
|
||||
"curCodeDesc": "MVR",
|
||||
"benefName": "",
|
||||
"trxNumber2": ""
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
| Field | Type | Description |
|
||||
|---|---|---|
|
||||
| `success` | `bool` | `true` on success |
|
||||
| `total_count` | `string` | Total transaction count — parse to `int` |
|
||||
| `data` | `array` | Transactions for this page |
|
||||
|
||||
### Transaction Object
|
||||
|
||||
| Field | Type | Description |
|
||||
|---|---|---|
|
||||
| `trxNumber` | `string` | Unique transaction ID |
|
||||
| `trxDate` | `string` | Transaction date (`YYYY-MM-DD`) |
|
||||
| `descr1` | `string` | Transaction description — trim whitespace |
|
||||
| `baseAmount` | `string` | Decimal string — **negative = debit, positive = credit** |
|
||||
| `curCodeDesc` | `string` | Currency code (e.g. `"MVR"`, `"USD"`) |
|
||||
| `benefName` | `string` | Counterparty name — blank or literal `"null"` means none |
|
||||
| `trxNumber2` | `string` | Secondary reference; may be blank |
|
||||
|
||||
---
|
||||
|
||||
|
||||
|
||||
---
|
||||
|
||||
[← Accounts](03-accounts.md) **Next →** [Cards](05-cards.md)
|
||||
Reference in New Issue
Block a user