Topup for a user
Topup for a user
- application/json
- application/xml
- application/x-www-form-urlencoded
Request Body required
Topup for a user
- app_id int64 required
The unique ID of the partner will be provided after the partner registered successfully with Zalopay
- payment_id string required
The unique ID of the partner will be provided after the partner registered successfully with Zalopay
- partner_order_id string required
The unique id, generate in partner system. Using for reconcile
- m_u_id string required
The user's identity in the response of QueryUser API
- amount int64 required
The amount top-up to receiver’s wallet
- description string required
Extend information
- partner_embed_data string required
Partner's specify info, a json string.
Example: “{\“store_id\”:\“s2\”,\“store_name\”:\ “name\”}
- reference_id string
Zalopay reference id response in query user response
- extra_info string required
Using for extend purpose, a json string
- time int64 required
Requests timestamp in ms
- sig string required
It’s calculated by following input: hmacinput = (app_id + “|” + payment_id + “|” + partner_order_id + “|” + m_u_id + “|” + amount + “|” + description + “|” + partner_embed_data + “|” + extra_info + “|” + time) and use sha256 with app’s hmac key then RSA with app’s private key Zalopay provide.
Please refer to secure data transmission for detailed information.
Request Body required
Topup for a user
- app_id int64 required
The unique ID of the partner will be provided after the partner registered successfully with Zalopay
- payment_id string required
The unique ID of the partner will be provided after the partner registered successfully with Zalopay
- partner_order_id string required
The unique id, generate in partner system. Using for reconcile
- m_u_id string required
The user's identity in the response of QueryUser API
- amount int64 required
The amount top-up to receiver’s wallet
- description string required
Extend information
- partner_embed_data string required
Partner's specify info, a json string.
Example: “{\“store_id\”:\“s2\”,\“store_name\”:\ “name\”}
- reference_id string
Zalopay reference id response in query user response
- extra_info string required
Using for extend purpose, a json string
- time int64 required
Requests timestamp in ms
- sig string required
It’s calculated by following input: hmacinput = (app_id + “|” + payment_id + “|” + partner_order_id + “|” + m_u_id + “|” + amount + “|” + description + “|” + partner_embed_data + “|” + extra_info + “|” + time) and use sha256 with app’s hmac key then RSA with app’s private key Zalopay provide.
Please refer to secure data transmission for detailed information.
Request Body required
Topup for a user
- app_id int64 required
The unique ID of the partner will be provided after the partner registered successfully with Zalopay
- payment_id string required
The unique ID of the partner will be provided after the partner registered successfully with Zalopay
- partner_order_id string required
The unique id, generate in partner system. Using for reconcile
- m_u_id string required
The user's identity in the response of QueryUser API
- amount int64 required
The amount top-up to receiver’s wallet
- description string required
Extend information
- partner_embed_data string required
Partner's specify info, a json string.
Example: “{\“store_id\”:\“s2\”,\“store_name\”:\ “name\”}
- reference_id string
Zalopay reference id response in query user response
- extra_info string required
Using for extend purpose, a json string
- time int64 required
Requests timestamp in ms
- sig string required
It’s calculated by following input: hmacinput = (app_id + “|” + payment_id + “|” + partner_order_id + “|” + m_u_id + “|” + amount + “|” + description + “|” + partner_embed_data + “|” + extra_info + “|” + time) and use sha256 with app’s hmac key then RSA with app’s private key Zalopay provide.
Please refer to secure data transmission for detailed information.
- 200
OK
- application/json
- Schema
- Example (from schema)
Schema
- return_code integer
1 - SUCCESS
2 - FAIL
- return_message string
Return code description
- sub_return_code integer
-68 - Duplicate resource
-101 - User wallet account not exists
-401 - Request param illegal
-402 - Unauthorized
-406 - User wallet reaches a fund-in limitation
-500 - Zalopay system error
-503 - The system is maintenance
- sub_return_message string
Sub return code description
data object
order_id stringMerchant transaction code
status integer1 – SUCCESS
2 – FAIL
3 – PROCESSING: Has to repeat query order status in a period of time until final status (configured interval and number of query)
4 – PENDING: Pending transactions, needs to be manually fixed by internal teams
m_u_id stringUser's identity
phone stringUser’s phone
amount int64Transaction amount
description stringTransaction description
partner_fee int64Partner fee
zlp_fee int64Zalopay fee
extra_info stringOrder extra info, json string
time int64Transaction timestamp in millisecond
upgrade_url stringZalopay middle_page url to upgrade for users with fund-in limit
Displayed when receiving return_code = 2 and sub_return_code = -406.
{
"return_code": 0,
"return_message": "string",
"sub_return_code": 0,
"sub_return_message": "string",
"data": {
"order_id": "string",
"status": 0,
"m_u_id": "string",
"phone": "string",
"amount": 0,
"description": "string",
"partner_fee": 0,
"zlp_fee": 0,
"extra_info": "string",
"time": 0,
"upgrade_url": "string"
}
}