Flows

Methods:

1. Check Info

Allow partner get information about Momo wallet

Request

  • Method: POST
  • URL: api/pay/check-info
Name Type Description
requestId String Unique String for each request
walletId String Momo wallet id (phone number) need to transfer money to.
Either walletId or QRString is required, If the request have both, we using walletId
qrString String Scan the QR Code on Momo app. ()
One of walletId or QRString required, If request have both, we using walletId

Response

Name Type Level Description
requestId String L1 Unique String for each request
referenceId String L1 reference (billId,customerId...)
resultCode String L1 Result Code of request
message String L1 Result message
accountInfo JsonObject L1 JsonObject about the wallet information
name String L2 Client (Buyer) name
email String L2 Client email
mobile String L2 Phone number
senderInfo JsonObject L1 JsonObject about the sender information
name String L2 Sender name
email String L2 Sender email
mobile String L2 Sender number

Example

Request
{
    "requestId": "wqrwpo2343240xsad213",
    "walletId": "2313_e3w24_ddqwdq_dasdasda"
}
Response
{
    "requestId": "wqrwpo2343240xsad213",
    "referenceId": "2313_e3w24_ddqwdq_dasdasda",
    "resultCode": 0,
    "message": "Success",
    "accountInfo": {
        "name": "Nguyễn Văn A",
        "email": "test@gmail.com",
        "mobile": "0987654321"
    },
    "senderInfo": {
        "name": "Lê Thị B",
        "email": "test2@gmail.com",
        "mobile": "090010101"
    }
}

2. Transfer to one wallet

Allow partner transfer money from their wallet to other wallet

Request

  • Method: POST
  • URL: api/pay/transfer-one-wallet
Name Type Description
requestId String Unique String for each request
password String Static value as provide by Momo
walletId String Momo wallet id (phone number) need to transfer money to.
Either walletId or QRString is required, If the request have both, we using walletId
qrString String Scan the QR Code on Momo app. ()
Either walletId or QRString is required, If request have both, we using walletId
amount Integer Amount to transfer
created String created date (YYYY-MM-DDThh:mm:ssTZD)
description String Short description
requireConfirm Boolean default = False. (if need confirming the transaction then value is True)

Response

Name Type Description
requestId String Same with request
resultCode Integer Result Code of request
referenceId String Unique for each response
message String Result message
paymentRef String Unique String for each transfer response, using for report
preBalance Number Partner's Balance before
balance Number Current Partner's Balance

Example

Request
{
  "requestId": "wqrwpo2343240xsad213",
  "password": "123456",
  "created": "2017-03-06T19:20:30+07:00",
  "walletId": "0989990105",
  "amount": 40000,
  "description": "Transfer for something"
}
Response
{
  "requestId": "wqrwpo2343240xsad213",
  "referenceId": "2313_e3w24_ddqwdq_dasdasda",
  "resultCode": 0,
  "message": "Success",
  "paymentRef": "122434546546",
  "preBalance": 1000000,
  "balance": 960000
}

3. Check status

Allow partner get check status

Request

  • Method: POST
  • URL: api/pay/status
Name Type Description
requestId String Unique String for each request
password String Static value as provide by Momo
checkRequestId String Request Id that need to check

Response

Name Type Description
requestId String Same with request
resultCode Integer Result Code of request
referenceId String Unique for each response
message String Result message
data JsonObject Data is the same with data of the response of function that want to check

Example

Request
{
    "requestId": "wqrwpo2343240xsad213",
    "password": "123456",
    "checkRequestId": "w240xsad213"
}
Response
{
    "requestId": "wqrwpo2343240xsad213",
    "referenceId": "2313_e3w24_ddqwdq_dasdasda",
    "resultCode": 0,
    "message": "Success",
    "data": {
        "requestId": "wqrwpo2343240xsad213",
        "referenceId": "2313_e3w24_ddqwdq_dasdasda",
        "resultCode": 0,
        "paymentRef": "ewe2342424",
        "message": "Success",
        "acceptAmount": 40000
    }
}

4. Balance

Allow partner get current partner wallet’s balance

Request

  • Method: POST
  • URL: api/pay/balance
Name Type Description
requestId String Unique String for each request
password String Static value as provided by Momo

Response

Name Type Description
requestId String Same with request
resultCode Integer Result Code of request
referenceId String Unique for each response
message String Result message
amount Integer Current balance

Example

Request
{
    "requestId": "wqrwpo2343240xsad213",
    "password": "a1234567890"
}
Response
{
    "requestId": "wqrwpo2343240xsad213",
    "referenceId": "2313_e3w24_ddqwdq_dasdasda",
    "resultCode": 0,
    "message": "Success",
    "amount": 100000000
}

5. Get Trans

Allow partner get all transaction of the day

Request

  • Method: POST
  • URL: api/pay/get-trans
Name Type Description
requestId String Unique String for each request
password String Static value as provided by Momo
date String Date to get all trans (yyyy-MM-dd)

Response

Name Type Level Description
requestId String L1 Same with request
resultCode Integer L1 Result Code of request
referenceId String L1 Unique for each response
message String L1 Result message
data JsonArray L1 Array of JsonObject include these information
requestId String L2 Transfer request id
walletId String L2 Momo wallet Id (mobile phone)
amount Integer L2 Transfer amount
paymentDate String L2 Transfer date
paymentRef String L2 Reference Number
resultCode Int L2 Result Code
message String L2 Result Message

Example

Request
{
    "requestId": "wqrwpo2343240xsad213",
    "password": "a1234567890",
    "date": "2017-12-04"
}
Response
{
"requestId": "wqrwpo2343240xsad213",
"referenceId": "2313_e3w24_ddqwdq_dasdasda",
"resultCode": 0,
"message": "Success",
"data": [
    {
        "requestId": "122345",
        "walletId": "0989990105",
        "amount": 400000,
        "paymentDate": "2017-03-06T19:20:30+07:00",
        "paymentRef": "2313r3r34r",                         
        "resultCode": 0,
        "message": "Success"
    },
    {
        "requestId": "122346",
        "walletId": "0989990106",
        "amount": 100000,
        "paymentDate": "2017-03-06T19:20:30+07:00",
        "paymentRef": "2313r3r34r",
        "resultCode": 0,
        "message": "Insufficient funds"
    }   
    ]
}

6. Cancel

Allow partner send request to cancel perious Transfer to one wallet. Note that system just create a ticket for Customer Service.

Request

  • Method: POST
  • URL: api/pay/cancel
Name Type Description
requestId String Unique String for each request
amount Integer Original amount
created String created date (YYYY-MM-DDThh:mm:ssTZD)
paymentRef String MomoPaymentRef of tran that need to cancel
description String Define the cancel reasons.

Response

Name Type Level Description
requestId String L1 Same with request
resultCode Integer L1 Result Code of request
referenceId String L1 Unique for each response
message String L1 Result message

Example

Request
{
    "requestId": "wqrwpo2343240xsad213",
    "amount": 10000,
    "paymentRef": "43242423",
    "Description": "nạp nhầm tiền",
    "created": "2017-03-06T19:20:30+07:00",
}
Response
{
    "requestId": "wqrwpo2343240xsad213",
    "referenceId": "2313_e3w24_ddqwdq_dasdasda",
    "resultCode": 0,
    "message": "Success"
}

7. Confirm Transfer Transaction

Allow partner confirmed transfering money of the init transaction from their wallet to other wallet

Request

  • Method: POST
  • URL: api/pay/confirm-transfer-one-wallet
Name Type Description
requestId String Unique String for each request
requestIdRef String Amount to transfer
paymentRef String paymentRef in the response of init transfer-one-wallet transaction which need confirmed
description String Short description

Response

Name Type Description
requestId String Same with request
resultCode Integer Result Code of request
referenceId String Unique for each response
message String Result message
paymentRef String the same with paymentRef in request
requestIdRef String the same with requestIdRef in request

Example

Request
{
  "requestId": "wqrwpo2343240xsad213",
  "paymentRef": "542321545",
  "requestIdRef": "sfgsgdgfgfgf3544",
  "description": "confirm transfer for something"
}
Response
{
  "requestId": "wqrwpo2343240xsad213",
  "referenceId": "CONFIRM__ddqwdq_dasdasda",
  "resultCode": 0,
  "message": "Success",
  "paymentRef":"542321545",
  "requestIdRef": "sfgsgdgfgfgf3544"
}

Glossary

Error Code

Code Message Function Status
0 success All Success
2 Cannot decrypt message All Fail
4 Invalid wallet Id transfer-one-wallet, Fail
5 Invalid password All Fail
7 Insufficient funds transfer-one-wallet Fail
8 Duplicate request Id All Fail
9 Invalid partner code All Fail
10 Unknown result. All Check by hand, or call check status to get the final result
11 Other error All Fail
17 According to State Bank of Vietnam's regulations, it is forbidden to transfer money to non-verified users.You could show them to add bank accounts so that they can receive money from you. See more at: http://bit.ly/huongdan-nhantien All Fail
501 Invalid capset per transaction transfer-one-wallet Fail
502 Invalid amount transfer-one-wallet Fail
506 Reject by Momo rule transfer-one-wallet Fail
507 Request Id not found All Fail
508 On process All Check by hand, or call check status to get the final result
510 Invalid PaymentRef Cancel Fail
511 Ticket has created before Cancel The cancel request have been created for this payment ref.
512 Cancel rejected Cancel Fail
513 Cancel accepted Cancel Cancel request have record and and on process
611 Wallet balance exceeded Transfer Fail
612 Wallet cap exceeded Transfer Fail

QR String

Get QR String on Momo app: