API References (1.0)
The current API version is 1.0
Authentication
To authenticate your account, you have to include your secret API key in the request which can be accessed in the Dashboard. You may generate your API Key via the Settings page on the Partner dashboard as described further here.
API References
API Request
The URL to the API service can be accessed through the following links:
Sandbox :
https://sandbox.idrt-gateway.rupiahtoken.com/v1
Live :
https://idrt-gateway.rupiahtoken.com/v1
Purchase
Submit Purchase
Create IDRT Purchase is a process where your user can request to purchase / deposit
IDRT via the virtual account (VA) bank transfer through this IDRT Fiat Gateway API. Once the user creates an IDRT purchase / deposit request, our system will feed the required information to process such transaction.
/submit
POST
/v1/purchase/submit
This endpoint allows you to create IDRT purchase request for your user.
Headers
Authorization
string
Bearer {API_KEY}
Request Body
name
string
Full Name
user_id
string
User ID of your user registered on your platform
amount
number
IDRT amount
bank
string
PERMATA, MANDIRI, BRI
{
"purchase_id": "iv-9Fa4ED"
}
Cancel Purchase
Cancel Purchase is a process where your user requests to cancel his/her purchase request that was created previously but has not been completed yet. A purchase request will be automatically cancelled within 24 hours. However, your user can cancel it manually by himself/herself in the case where he/she would like to create another purchase request. Your user cannot create two purchase requests at the same time. Accordingly, your user needs to complete his/her existing purchase request or cancel it to create another new purchase request.
/cancel
POST
/v1/purchase/cancel
This endpoint allows you to cancel IDRT purchase request for your user.
Headers
Authorization
string
Bearer {API_KEY}
Request Body
amount
number
IDRT Purchase amount
purchase_id
string
Purchase ID
{
"purchase_id": "iv-9Fa4ED"
}
/simulate-payment
POST
/v1/purchase/simulate-payment
You can simulate payment of your purchase in sandbox mode.
Headers
Authorization
string
Bearer {API_KEY}
Request Body
purchase_id
string
Purchase ID
amount
number
IDRT Purchase Amount
{
"code": "COMPLETED"
}
/detail
GET
/v1/purchase/:id
Get detail of a purchase.
All values for status
field :
- pending
purchase pending, waiting for bank virtual account creation by our system.
- processed
bank virtual account has been created, waiting for payment by end-user.
- failed
purchase failed, this is usually caused by the payment that was sent by the end-user past the due date or time limit")
- success
purchase success or payment has been paid
- canceled
purchase canceled
Query Parameters
id
string
Purchase ID
{
"id": "iv-sjvUMQ",
"user_id": "23142dssc2xy",
"status": "processed",
"bank_name": "PERMATA",
"bank_account_name": "Sastra Nababan",
"bank_account_number": "7050100993400703",
"amount": 30000,
"creation_date": "2020-11-27T09:52:17.451Z",
"processing_date": "2020-11-27T09:52:18.415Z",
"due_date": "2020-11-28T09:52:17.444Z"
}
Last updated
Was this helpful?