E-Credit

Create E-Credit Order

Create E-Credit (DD) order via Paylabs API.

Request URL

URL: ${ROOT_URL}/payment/v2.3/dd/create

HTTPMethod: POST

EndpointUrl: /payment/v2.3/dd/create

Create E-Credit Order Request Parameters

Data Signing Rules

Field NameTypeValueRequired
Content-TypeString(30)Fixed value "application/json;charset=utf-8"Yes
X-TIMESTAMPString(29)Current time, format 2022-09-16T16:58:47.964+07:00Yes
X-SIGNATUREString(64)Signature. For details please check Data Signing RulesYes
X-PARTNER-IDString(20)Merchant IDYes
X-REQUEST-IDString(64)Unique ID for each requestYes

Body

ParameterTypeRequiredRemarks
requestIdString(64)YesUnique identifier on every request
merchantIdString(20)YesUnique ID provided by payment gateway to merchant
storeIdString(30)NoOnly if using branch ID
paymentTypeString(20)YesPayment type
amountDecimal(12,2)YesAmount in IDR
merchantTradeNoString(32)YesUnique identifier created by merchant for each transaction
notifyUrlString(200)NoCallback URL on payment success; see Inquiry Order for parameters
+ paymentParamsObjectNoChannel-specific extra parameters. See Payment Type.
productNameString(100)YesProduct/service name
+ productInfoArray<Object>(30)NoProduct/service details
- idString(10)YesProduct ID
- nameString(32)YesProduct Name
- pricedecimal(12,2)YesAmount in IDR, supports two decimals
- typeString(20)YesProduct Type
- urlString(200)NoProduct URL
- quantityNumber(4)YesProduct Quantity
feeTypeString(3)NoFee deduction type: BEN/OUR. Default BEN. OUR adds fee to order amount automatically.

Payment Type

Payment TypeCode
IndodanaIndodana
KredivoKredivo
AtomeAtome

paymentParams (Indodana)

ParameterTypeRequiredRemarks
redirectUrlString(200)YesRedirect after success

Create E-Credit Order Response Parameters

Header

Data Signing Rules

Field NameTypeValueRequired
Content-TypeString(30)Fixed value "application/json;charset=utf-8"Yes
X-TIMESTAMPString(29)Current time, format 2022-09-16T16:58:47.964+07:00Yes
X-SIGNATUREString(64)Signature. For details please check Data Signing RulesYes
X-PARTNER-IDString(20)Merchant IDYes
X-REQUEST-IDString(64)Unique ID for each requestYes

Body

Error Code

ParameterTypeRequiredRemarks
requestIdString(64)YesUnique identifier on every request
errCodeString(32)Yes0 means success, otherwise see Error Code
errCodeDesString(128)NoError description
merchantIdString(20)YesMerchant ID
storeIdString(30)NoOnly if using branch ID
paymentTypeString(20)YesPayment type
amountDecimal(12,2)YesAmount in IDR with 2 decimals
merchantTradeNoString(32)YesMerchant order number
createTimeString(16)NoyyyyMMddHHmmss
+ paymentActionsObjectNoPayment URLs (PC, Web, etc.)
- payUrlString(200)NoPayment URL
platformTradeNoString(32)NoPaylabs platform order number
successTimeString(16)NoyyyyMMddHHmmss
expiredTimeString(16)NoyyyyMMddHHmmss
statusString(32)No01: Pending, 09: Failed, 02: Success
productNameString(100)YesProduct/service name
+ productInfoArray<Object>(30)NoProduct/service details
- idString(10)YesProduct ID
- nameString(32)YesProduct Name
- pricedecimal(12,2)YesAmount in IDR, supports two decimals
- typeString(20)YesProduct Type
- urlString(200)NoProduct URL
- quantityNumber(4)YesProduct Quantity
transFeeRateDecimal(6,6)NoTransaction Rate, six decimals
transFeeAmountDecimal(12,2)NoFees, two decimals
totalTransFeeDecimal(12,2)NoTotal transaction fee rate (excluding vatFee), two decimals
vatFeeDecimal(12,2)NoTaxes, two decimals

Example

Request

POST /payment/v2.3/dd/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":"100100011649755017941",
  "requestId":"100100011649755017941",
  "paymentType":"Indodana",
  "amount":"10000.00",
  "productName":"Test",
  "paymentParams":{
            "phoneNumber":"0000000000",
            "successUrl":"http://google.com",
            "failedUrl":"http://google.com"
        }
}

Response

POST /payment/v2.3/dd/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":"T00100011649755017941",
  "platformTradeNo":"2022041200000000021",
  "paymentType":"Indodana",
  "paymentActions":{
            "payUrl": "https://sit-api.paylabs.co.id/payment/edd/enable/085259f66ebf1a171fc0ad7c6d19d624ad10799ff86175a82efbc88c1f5dde70"
        },
  "createTime":"20220412161700",
  "merchantId":"0010001",
  "errCode":"0",
  "requestId":"R00100011649755017941",
  "productName":"Test",
  "status":"01",
  "transFeeRate":"0",
  "transFeeAmount":"0",
  "totalTransFee":"0",
  "vatFee":"0"
}