SCB Payment Service API Documentation - MUMT-IT/mis2018 GitHub Wiki
Base URL for the APIs
BASE_URL=https://mumtmis.herokuapp.com/
Get credentials
A user must contact the administrator and request a client ID and secret for his/her access.
Acquire an access token
| API name |
Login |
| Method |
POST |
| URL |
{BASE_URL}/scb_payment/api/v1.0/login |
| Request parameters |
Data type |
Required |
Description |
| Header |
|
|
|
| Content type |
application/json |
|
|
| Request body |
|
|
|
| client_id |
String |
Yes |
|
| client_secret |
String |
Yes |
|
| Response |
|
|
|
| access_token |
String |
|
A short-lived token for accessing a protected endpoint |
| refresh_token |
String |
|
Used for getting a new access token |
Acquire a refreshed access token
| API name |
Refresh |
| Method |
POST |
| URL |
{BASE_URL}/scb_payment/api/v1.0/refresh |
| Request parameters |
Data type |
Required |
Description |
| Header |
|
|
|
| Content type |
application/json |
|
|
| Authorization |
String |
Yes |
Bearer {refresh_token} |
| Response |
|
|
|
| access_token |
String |
|
|
Testing Login with an access token
| API name |
Login Testing |
| Method |
GET |
| URL |
{BASE_URL}/scb_payment/api/v1.0/test-login |
| Request parameters |
Data type |
Required |
Description |
| Header |
|
|
|
| Content type |
application/json |
|
|
| Authorization |
String |
Yes |
Bearer {access_token} |
| Response |
|
|
|
| logged_in_as |
json |
|
|
Create QR Code for payment
| API name |
Create QR Code |
| Method |
POST |
| URL |
{BASE_URL}/scb_payment/api/v1.0/qrcode/create |
| Request parameters |
Data type |
Required |
Description |
| Header |
|
|
|
| Content type |
application/json |
|
|
| Authorization |
String |
Yes |
Bearer {access_token} |
| Request body |
|
|
|
| amount |
String |
Yes |
|
| ref1 |
String |
Yes |
|
| ref2 |
String |
Yes |
|
| customer1 |
String |
|
|
| customer2 |
String |
|
|
| service |
String |
|
|
| expire_datetime |
String format 'YYYY-MM-DD HH:mm:ss' |
|
Default to 24 weeks from the current date at 00:00:00. |
| Response |
|
|
|
| data.qrImage |
String |
Base 64 encoded |
|
Confirm payment response
| API name |
Confirm Payment |
| Method |
GET |
| URL |
{BASE_URL}/scb_payment/api/v1.0/payment-confirm |
| Request parameters |
Data type |
Required |
Description |
| resCode |
String |
Yes |
Fix:00 |
| resDesc |
String |
Yes |
Fix:success |
| transactionId |
String |
Yes |
Echo "transactionId" value from Payment Confirmation |
| confirmId |
String |
|
Optional |
Slip Verification of a QR 30
| API name |
Verify Slip |
| Method |
GET |
| URL |
{BASE_URL}/scb_payment/verify-slip |
| Request parameters |
Data type |
Required |
Description |
| Header |
|
|
|
| Content type |
application/json |
|
|
| resourceOwnerId |
String |
Yes |
The system identifier, use the value of api key |
| requestUId |
String |
Yes |
A unique identifier the client can generate to track the current request call |
| authorization |
String |
Yes |
Bearer {access_token} |
| Query String |
|
|
|
| transRef |
String |
Yes |
Transaction Slip ID |
| sendingBank |
String |
Yes |
Use 014 |
Check Payment.
| API name |
Check Payment |
| Method |
GET |
| URL |
{BASE_URL}/scb_payment/api/v1.0/check-payment |
| Request parameters |
Data type |
Required |
Description |
| Header |
|
|
|
| Authorization |
String |
Yes |
Bearer {access_token} |
| Request body |
|
|
|
| bill_payment_ref1 |
String |
Yes |
Reference Number 1 , up to 20 characters |
| bill_payment_ref2 |
String |
Yes |
Reference Number 2 , up to 20 characters |