Appearance
Get Order Details
Information
Hostname | https://api-stage.ifortepay.id |
---|---|
Path | /payment-page/payment/ |
HTTP Method | GET |
Headers
Key | Format | Required | Value |
---|---|---|---|
Content-Type | application/json | M | |
Authorization | String | M | Basic |
sub-merchant-id | String | O |
Example
Example Request
shell
curl --location 'https://api-stage.ifortepay.id/payment-page/payment/100099934' \
--header 'Authorization: Basic {{Base64encodedKey}}' \
--header 'sub-merchant-id: {{optional. contact our support for usage if you'\''re having sub merchant}}'
go
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://api-stage.ifortepay.id/payment-page/payment/100099934"
method := "GET"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Authorization", "Basic {{Base64encodedKey}}")
req.Header.Add("sub-merchant-id", "{{optional. contact our support for usage if you're having sub merchant}}")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}
js
var axios = require('axios');
var config = {
method: 'get',
maxBodyLength: Infinity,
url: 'https://api-stage.ifortepay.id/payment-page/payment/100099934',
headers: {
'Authorization': 'Basic {{Base64encodedKey}}',
'sub-merchant-id': '{{optional. contact our support for usage if you\'re having sub merchant}}'
}
};
axios(config)
.then(function (response) {
console.log(JSON.stringify(response.data));
})
.catch(function (error) {
console.log(error);
});
php
use GuzzleHttp\Client;
$client = new Client();
$headers = [
'Authorization' => 'Basic {{Base64encodedKey}}',
'sub-merchant-id' => '{{optional. contact our support for usage if you\'re having sub merchant}}'
];
$request = new Request('GET', 'https://api-stage.ifortepay.id/payment-page/payment/100099934', $headers);
$res = $client->sendAsync($request)->wait();
echo $res->getBody();
Example Response
json
{
"transaction_id": "12345678",
"order_id": "12345678",
"external_id": "100099934",
"currency": "IDR",
"transaction_status": "REQUEST",
"response_message": "Transaction still unpaid / active request",
"payment_method": null,
"payment_channel": null,
"acq": null,
"paid_date": null,
"amount": 10000,
"selected_channels": [
{
"channel": "CARD",
"acq": "BCACC"
}
],
"is_customer_paying_fee": false,
"item_details": [
{
"item_id": "item1",
"name": "test",
"amount": 5000,
"qty": 1
},
{
"item_id": "item2",
"name": "test",
"amount": 1000,
"qty": 2
},
{
"item_id": "item3",
"name": "test",
"amount": 3000,
"qty": 1
}
],
"save_card": false,
"customer_details": {
"full_name": "customer fullname",
"email": "customer@email.com",
"phone": "0888888888",
"address": "Jakarta",
"is_email_show": false,
"is_phone_show": false
},
"shipping_address": {
"full_name": "customer shipping fullname",
"phone": "0888888888",
"address": "Jakarta",
"city": "Jakarta",
"postal_code": "10240",
"country": "ID"
},
"billing_address": {
"full_name": "customer shipping fullname",
"phone": "0888888888",
"address": "Jakarta",
"city": "Jakarta",
"postal_code": "10240",
"country": "ID"
},
"callback_url": "https://merchant.callback.url",
"success_redirect_url": "https://success.merchant.url",
"failed_redirect_url": "https://failed.merchant.url",
"expired_time": "2021-07-19T09:17:05.003Z"
}