E-Money
E-Money Order API
Create E-Money order via Paylabs API.
Request Address
URL: ${ROOT_URL}/payment/v2.3/ewallet/create
HTTPMethod: POST
EndpointUrl: /payment/v2.3/ewallet/create
E-Money Order Request Parameters
Header
| Field Name | Type | Value | Required |
|---|---|---|---|
| Content-Type | String(30) | Fixed value "application/json;charset=utf-8" | Yes |
| X-TIMESTAMP | String(29) | Current time, format 2022-09-16T16:58:47.964+07:00 | Yes |
| X-SIGNATURE | String(64) | Signature. For details please check Data Signing Rules | Yes |
| X-PARTNER-ID | String(20) | Merchant ID | Yes |
| X-REQUEST-ID | String(64) | Unique ID for each request | Yes |
Body
| Parameter | Type | Required | Remarks |
|---|---|---|---|
| requestId | String(64) | Yes | Unique ID for each request |
| merchantId | String(20) | Yes | The unique identifier provided by payment gateway to the merchant |
| storeId | String(30) | No | Only if merchant has branches and wish to create order using its branch ID |
| paymentType | String(20) | Yes | Payment Type, see Payment Type |
| amount | Decimal(12,2) | Yes | Amount in Indonesia Rupiah |
| feeType | String(3) | No | Fee deduction type: BEN/OUR. Default BEN. OUR adds fees to order amount automatically. |
| merchantTradeNo | String(32) | Yes | Transaction unique identifier defined by merchant |
| notifyUrl | String(200) | No | The URL that will hit by API if payment success |
| + paymentParams | Object | No | Additional parameters specific to the channels. See Payment Type parameters. |
| productName | String(100) | Yes | The name of the transaction's goods or services |
| + productInfo | Array<Object>(30) | No | The details of the transaction's goods or services |
| - id | String(10) | Yes | Product ID |
| - name | String(32) | Yes | Product Name |
| - price | decimal(12,2) | Yes | Amount in IDR, supports two decimals |
| - type | String(20) | Yes | Product Type |
| - url | String(200) | No | Product URL |
| - quantity | Number(4) | Yes | Product Quantity |
paymentType
| Payment Type | Code |
|---|---|
| DANA E-Money (Support Refund) | DANABALANCE |
| Shopee E-Money (Support Refund) | SHOPEEBALANCE |
| Linkaja E-Money (Support Refund) | LINKAJABALANCE |
| OVO E-Money (refunds not supported) | OVOBALANCE |
| GoPay E-Money (Support Refund) | GOPAYBALANCE |
paymentParams
DANABALANCE, SHOPEEBALANCE, LINKAJABALANCE, GOPAYBALANCE
| Parameter | Type | Required | Remarks |
|---|---|---|---|
| redirectUrl | String(200) | Yes | Either the order is success or fail will redirect to this callback URL |
OVOBALANCE
| Parameter | Type | Required | Remarks |
|---|---|---|---|
| redirectUrl | String(200) | No | Either the order is success or fail will redirect to this callback URL |
| phoneNumber | String(200) | No | Customer's OVO account number; mobilePayUrl not returned when provided |
E-Money Order Response Parameters
Header
| Field Name | Type | Value | Required |
|---|---|---|---|
| Content-Type | String(30) | Fixed value "application/json;charset=utf-8" | Yes |
| X-TIMESTAMP | String(29) | Current time, format 2022-09-16T16:58:47.964+07:00 | Yes |
| X-SIGNATURE | String(64) | Signature. For details please check Data Signing Rules | Yes |
| X-PARTNER-ID | String(20) | Merchant ID | Yes |
| X-REQUEST-ID | String(64) | Unique ID for each request | Yes |
Body
| Parameter | Type | Required | Remarks |
|---|---|---|---|
| requestId | String(64) | Yes | Unique identifier on every request |
| errCode | String(32) | No | For details please see Error Code section |
| errCodeDes | String(128) | No | Error details based on error code |
| merchantId | String(20) | No | Merchant ID |
| storeId | String(30) | No | Only if using branch ID channel account |
| paymentType | String(20) | Yes | Type of payments, see Payment Type |
| requestAmount | Decimal(12,2) | No | Amount at request |
| amount | Decimal(12,2) | Yes | Transaction Amount, in IDR with two decimals. If fee type OUR is selected, fees will be added. Fee with decimals is rounded up (10,000.11 → 10,001.00). |
| merchantTradeNo | String(32) | Yes | Merchant order number |
| createTime | String(16) | Yes | yyyyMMddHHmmss |
| + paymentActions | Object | No | Payment URLs (PC, Web, etc.) |
| - pcPayUrl | String(200) | No | PC Payment URL |
| - mobilePayUrl | String(200) | No | Mobile Payment URL |
| - appDeeplink | String(200) | No | Open App directly |
| - pushPay | String(200) | No | Customer confirms payment within the app |
| platformTradeNo | String(32) | No | Paylabs Platform Transaction Number |
| successTime | String(16) | No | yyyyMMddHHmmss |
| expiredTime | String(16) | No | yyyyMMddHHmmss |
| status | String(32) | No | 01: Pending, 09: Failed, 02: Success |
| productName | String(100) | Yes | Product/service name |
| + productInfo | Array<Object>(30) | No | Product/service details |
| - id | String(10) | Yes | Product ID |
| - name | String(32) | Yes | Product Name |
| - price | decimal(12,2) | Yes | Amount in IDR, supports two decimals |
| - type | String(20) | Yes | Product Type |
| - url | String(200) | No | Product URL |
| - quantity | Number(4) | Yes | Product Quantity |
| transFeeRate | Decimal(6,6) | No | Transaction Rate, six decimals |
| transFeeAmount | Decimal(12,2) | No | Fees, two decimals |
| totalTransFee | Decimal(12,2) | No | Total transaction fee rate (excluding vatFee), two decimals |
| vatFee | Decimal(12,2) | No | Taxes, two decimals |
| payer | String(60) | No | Actual payer name if supported; otherwise null. No supported payment methods currently. Not the payer sent by merchant. |
| accountNo | String(32) | No | Actual payer account number if supported; otherwise null. No supported payment methods currently. |
paymentActions Support
| Channel | pcPayUrl | mobilePayUrl | appDeeplink | pushPay |
|---|---|---|---|---|
| Dana | Y | Y | N | N |
| Shopee | N | Y | N | N |
| Linkaja | Y | Y | N | N |
| OVO | N | C | N | C |
| GoPay | N | Y | N | N |
Example
Request
POST /payment/v2.3/ewallet/create
# HTTP Header
Content-Type: application/json;charset=utf-8
X-TIMESTAMP: 2022-09-16T16:58:47.964+07:00
X-SIGNATURE: xxxxxxxxx
X-PARTNER-ID: 010001
X-REQUEST-ID: xxxxxxxxxxxxxxxxxxxxxxxx
# HTTP Body
{
"merchantId":"0010001",
"merchantTradeNo":"100100011649755299703",
"requestId":"200100011649755299703",
"paymentType":"SHOPEEBALANCE",
"amount":"10000.00",
"productName":"Test",
"paymentParams":{
"redirectUrl": "http://google.com"
}
}Response
POST /payment/v2.3/ewallet/create
# HTTP Header
Content-Type: application/json;charset=utf-8
X-TIMESTAMP: 2022-09-16T16:58:47.964+07:00
X-SIGNATURE: xxxxxxxxx
X-PARTNER-ID: 010001
X-REQUEST-ID: xxxxxxxxxxxxxxxxxxxxxxxx
# HTTP Body
{
"amount":"10000.00",
"merchantTradeNo":"100100011649755299703",
"platformTradeNo":"2022041200000000022",
"expiredTime":"20220412162641",
"paymentType":"SHOPEEBALANCE",
"paymentActions":{
"mobilePayUrl":"https://wsa.uat.wallet.airpay.co.id/universal-link/wallet/pay?deep_and_deferred=1&token=dFhkbmR1bTBIamhWkALJbE72qKeb2LpWAmThwGAMEXu0oo6lQWWCBMbH6JezjfA"
},
"createTime":"20220412162143",
"merchantId":"0010001",
"errCode":"0",
"requestId":"200100011649755299703",
"productName":"Test",
"status":"01",
"transFeeRate":"0",
"transFeeAmount":"0",
"totalTransFee":"0",
"vatFee":"0"
}