bml to fahipay and MIB to fahipay support
Auto Tag on Version Change / check-version (push) Successful in 3s

This commit is contained in:
2026-12-05 22:58:03 +05:00
parent 77297a1eb2
commit ec879ad7ca
11 changed files with 353 additions and 37 deletions
+75 -1
View File
@@ -265,9 +265,83 @@ Called by the official app when opening the transfer screen. Not consumed by thi
---
## WebView IPS Transfer (Fahipay)
The MIB app pays **Fahipay** accounts (12 digits starting with `5`) from its WebView "Quick Transfer" page, not through `B40`/`T51`. Both calls are plain form posts on the WebView host with the usual session cookies and AJAX headers (see [README](README.md)), plus `Referer: https://faisamobilex-wv-v2.mib.com.mv/transferIps/quick?dashurl=1`. Loading the page itself (`GET /transferIps/quick?dashurl=1`) isn't needed: the AJAX calls carry no token from it. HTTP `419` means the session has expired. Client: `MibIpsWebClient.kt`.
The page picks the destination bank explicitly from a dropdown. Each option has a BIC and a **bank list ID**, which is sent as `bankNo`. This is not the same `bankNo` as T50/T51, where `3` means "local bank":
| Bank | BIC | Bank list ID |
|---|---|---|
| Bank of Maldives (BML) | `MALBMVMV` | `1` |
| State Bank of India (SBI) | `SBINMVMV` | `2` |
| Maldives Islamic Bank (MIB) | `MADVMVMV` | `3` |
| Bank of Ceylon (BOC) | `BCEYMVMV` | `4` |
| The Mauritius Commercial Bank (MCB) | `MCBLMVMV` | `7` |
| Dhiraagu Fintech (DHI) | `DHIRMVMV` | `8` |
| Habib Bank Limited (HBL) | `HABBMVMV` | `9` |
| Commercial Bank of Maldives (CBMV) | `CBMVMVMV` | `10` |
| FahiPay (FHI) | `FAHIMVMV` | `13` |
Only Fahipay goes through this page in the app. Other banks still use `B40`/`T51`.
### Lookup
```
POST https://faisamobilex-wv-v2.mib.com.mv/AjaxAlias/getIPSAccount
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
benefBank=FAHIMVMV&benefAccount=500000000000
```
```json
{"success":true,"responseCode":"2","reasonCode":"201","reasonText":"Request Successful. Account Found","accountName":"Account Holder Name","bankBic":"FAHIMVMV"}
```
No currency is returned: the page fixes the transfer currency to MVR (`462`). Errors come back as a non-2xx status with the same JSON shape; `reasonText` explains why. `reasonCode` `220` makes the page let the user type the name.
### Transfer
```
POST https://faisamobilex-wv-v2.mib.com.mv/ajaxIPSTransfer/transferIPSLocal
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
benefName=Account+Holder+Name&benefNo=0&fromAccountNo=90100000000001000&fromAccountName=Sender+Name
&benefAccountNo=500000000000&transferCy=462&benefCurrencyCode=&amount=1&bankNo=13&purpose=-
&otp=123456&otpType=3&bankBic=FAHIMVMV
```
| Field | Value |
|---|---|
| `benefNo` | `0`: no saved contact needed |
| `fromAccountName` | Sender's name |
| `transferCy` | `462` (MVR) |
| `benefCurrencyCode` | Empty |
| `bankNo` | Bank list ID (`13`) |
| `purpose` | `-` when empty |
| `otpType` | `3` (TOTP) |
| `bankBic` | `FAHIMVMV` |
```json
{"success":true,"responseCode":"2","reasonText":"Favara request transfer completed","reasonCode":"2011","data":[{"date":"2026-01-01 12:00:00","trxId":"800000000"}]}
```
How the page reads a `success: true` response:
| Condition | Meaning |
|---|---|
| `data[0].trxId == 0` or `data[0].date == null` | Being processed |
| `reasonCode` `2011` / `2012` | Completed |
| `reasonCode` `2091` | Submitted, not completed yet |
| Any other `reasonCode` | Awaiting approval |
All of these mean the transfer was accepted, so the client reports success for every one of them. It never shows a failure that would invite the user to send again.
---
## `MibIpsAccountInfo` (client model)
`B40` lookups are mapped into this structure (`MibModels.kt`):
`B40` and WebView IPS lookups are mapped into this structure (`MibModels.kt`):
| Field | Description |
|---|---|