Checkout
The following is an API endpoint to create an Order.
Used to checkout.
Endpoint
/api/v4/checkout
As for development, use the following Reference Number
Reference Number
Your unique Transaction ID
Headers
- Name
X-Client-Id
- Type
- uuid
- Description
API Key (provided by BANGJEFF or retrieve from our Reseller Portal).
Please refer to Authentication for detail
- Name
X-Request-Time
- Type
- YYYY-MM-DDTHH:mm:ssZ
- Description
Request Time should be ISO 8601 and will be used to generate Signature.
Please refer to Authentication for detail
- Name
X-Signature
- Type
- string
- Description
Signature Generated using SHA-256 algorithm.
Please refer to Authentication for detail
- Name
Content-Type
- Type
- application/json
- Description
Content type application/json
Body
- Name
region
- Type
- string
- Description
Please refer to Available Region
- Name
variantCode
- Type
- string
- Description
Variant Code from BANGJEFF
Please refer to Get Product Variants
- Name
referenceNumber
- Type
- string
- Description
Your unique Transaction ID
- Name
qty
- Type
- number
- Description
Quantity. Should be greater than 1
- Name
price
- Type
- { currency: string; value: number }
- Description
Product Variant price should be equal to your membership price
Please refer to Get Product Variants for more information
- Name
price.currency
- Type
- string
- Description
Product Variant price currency
Please refer to Available Currency and Get Product Variants for more information
- Name
price.value
- Type
- number
- Description
Product Variant price value
Please refer to Get Product Variants for more information
- Name
inputs
- Type
- Array<{ name: string; value: string }>
- Description
Topup destination.
Please refer to Get Product Detail for more information
- Name
inputs.name
- Type
- string
- Description
Topup destination name.
Please refer to Get Product Detail for more information
- Name
inputs.value
- Type
- string
- Description
Topup destination value.
Please refer to Get Product Detail for more information
Request
Example
curl --location --request POST 'https://sandbox-api.bangjeff.com/api/v4/checkout' \
--header 'X-Client-Id: {{api_key}}' \
--header 'X-Request-Time: {{request_time}}' \
--header 'X-Signature: {{signature}}' \
--header 'Content-Type: application/json' \
--data '{
"region": "ID",
"variantCode": "PUBGM_ID_30",
"referenceNumber": "TESTING-001",
"qty": 1,
"price": {
"currency": "IDR",
"value": 6500
},
"inputs": [
{
"name": "id",
"value": "123123123"
}
]
}'
Response
Example
{
"rc": "00", // Check Response Code List
"message": "Success", // Check Response Message List
"data": {
"invoiceNumber": "BJO-RAPI-EC488CBEEAF0F413880659", // Invoice Number from BANGJEFF
"referenceNumber": "TESTING-001", // Your unique Transaction ID
"productName": "PUBG Mobile",
"variantName": "30 UC Indo",
"qty": 2,
"amount": {
"currency": "IDR",
"value": 6500
},
"totalAmount": {
"currency": "IDR",
"value": 13000
},
"voucher": "",
"statusCode": "PROCESSING", // PROCESSING, SUCCESS, REFUNDED
"statusDesc": "Processing..."
}
}