Skip to content

Generate Checkout URL

Information

Checkout Transaction is a feature used to confirm the installment tenure and payment with Indodana BNPL.

Path/v1.0/bnpl/generate-checkout-url
HTTP MethodPOST
Service Code91
Type FormatJSON

Request Body

ParameterData TypeMandatoryLengthDescription
partnerReferenceNoStringM64Transaction identifiers are generated by the merchant and must be unique per request. Allowed alphanumeric and special characters.
paymentDetailsObjectM
paymentDetails.amountObjectM
paymentDetails.amount.valueStringM16,2Total amount of customer’s transaction
paymentDetails.amount.currencyStringM3Currency (Format: ISO4217), fixed value: IDR
paymentDetails.isCustomerPayingFeeBooleanODefault is false
itemDetailsArray of ObjectsM
itemDetails.itemIdStringM64Can be product SKU. For item fee such as: shipping fee, admin fee etc you have to use one of these: shippingfee, adminfee, taxfee, discount, additionalfee, insurancefee.
itemDetails.nameStringM128Product name
itemDetails.amountObjectMProduct price
itemDetails.amount.valueStringM16,2If it's IDR then the value includes 2 decimal digits. e.g. IDR 10.000,- will be placed with 10000.00
itemDetails.amount.currencyStringM3Currency (Format: ISO4217), fixed value: IDR
itemDetails.urlStringM256URL of the product on the merchant’s site/platform
itemDetails.imageUrlStringO256URL of the image product on the merchant’s site/platform
itemDetails.categoryEnumM4Category of the product
itemDetails.qtyIntegerM8Quantity of the product
itemDetails.parentTypeStringMPossible values: SELLER
itemDetails.parentIdStringMIt will correspond to the SELLER ID if the parentType is SELLER
tenureStringOInstallment options chosen by the customer. Possible values: 1_months, 3_months, 6_months, 12_months, 24_months
customerDetailsObjectMCustomer details
customerDetails.firstNameStringM16Customer’s first name
customerDetails.lastNameStringO16Customer’s last name
customerDetails.emailStringM64The customer’s email that is registered in the merchant site/platform
customerDetails.phoneStringM16The customer’s phone that is registered in the merchant site/platform
sellersArray of ObjectsMDetail of the sellers. May contain more than 1 seller.
sellers.idStringM16Seller’s ID
sellers.nameStringM16Seller’s name
sellers.urlStringM256Seller’s shop URL
sellers.sellerIdNumberStringO32Seller's identifier number (KTP / SIM / etc)
sellers.emailStringM64Seller’s email
sellers.addressObjectOSeller’s address
sellers.address.firstNameStringM16Seller’s first name
sellers.address.lastNameStringO16Seller’s last name
sellers.address.addressStringM256Seller’s address
sellers.address.cityStringM32Seller’s city
sellers.address.postalCodeStringM8Seller’s postal code
sellers.address.phoneStringM16Seller’s phone number
sellers.address.countryCodeStringM16Seller’s country code, using ISO 3166-1 alpha-3 (e.g. IDN)
billingAddressObjectMCustomer billing address for the transaction
billingAddress.firstNameStringM16The first name of the customer’s billing address
billingAddress.lastNameStringO16The last name of the customer’s billing address
billingAddress.addressStringM256The address of the customer’s billing address
billingAddress.cityStringM32The city of the customer’s billing address
billingAddress.postalCodeStringM8The postal code of the customer’s billing address
billingAddress.phoneStringM16The phone number of the customer’s billing address
billingAddress.countryCodeStringM16The country code of the customer’s billing address
shippingAddressObjectMCustomer shipping address for the transaction. (Required only for goods; for service/digital product is not required)
shippingAddress.firstNameStringM16The first name of the customer’s shipping address
shippingAddress.lastNameStringO16The last name of the customer’s shipping address
shippingAddress.addressStringM256The address of the customer’s shipping address
shippingAddress.cityStringM32The city of the customer’s shipping address
shippingAddress.postalCodeStringM8The postal code of the customer’s shipping address
shippingAddress.phoneStringM16The phone number of the customer’s shipping address
shippingAddress.countryCodeStringM16The country code of the customer’s shipping address
callbackUrlStringMMerchant payment notification URL
cancelReturnUrlStringORedirect to the merchant URL if the customer chooses to cancel the payment before completion
returnUrlStringORedirect to the merchant URL after the transaction is complete
validityPeriodStringOPayment validity time (ISO-8601). Min: 15 mins, Max: 24 hours

Example Request

Details
sh
curl --location 'https://api-stage.ifortepay.id/v1.1/bnpl/generate-checkout-url' \
--header 'Content-Type: application/json' \
--header 'X-TIMESTAMP: 2020-12-18T10:55:00+07:00' \
--header 'X-SIGNATURE: BVg81WjD/pwjOKcoG967LC+vk0BKgxAipx3a7oRLigV2Mo4eVOjgvv/GGzLRyCOBlkN5wFvC59o4ctLRgrWWDWK5o3UT49y4P084tWRZyWSHQI+LOQBtg+U7b5rCCyvoYLskw0YCAK+8gjqPjrMZ+lQI4s51EhBxc/4uMmGhmM/taN3/0xSEUtYCxQf8hkLR7lYlAKSmExG8NQvzQUltQxkcjfpQBsOoSQfVrkqa2Kg74QlidD39t2JIW9t3fCEjPt8oHB8oxOkqe5lviEVgqDn2ZZXSrpgnpNPlWJqqrH+nXRLjEhGZNs/00l4+ApTUBIDy7z2xjEhf+G5JjyIaMg==' \
--header 'X-PARTNER-ID: MC2025059906' \
--header 'X-EXTERNAL-ID: 13953302921462' \
--header 'CHANNEL-ID: PL001' \
--data-raw '{
    "partnerReferenceNo": "96943614172822",
    "paymentDetails": {
        "amount": {
            "value": "350000.00",
            "currency": "IDR"
        },
    },
    "itemDetails": [
        {
            "itemId": "FOOD01",
            "name": "RUJAK",
            "amount": {
                "value": "350000.00",
                "currency": "IDR"
            },
            "url": "https://www.google.com/",
            "imageUrl": "",
            "category": "0017",
            "qty": 1,
            "parentType": "SELLER",
            "parentId": "123"
        }
    ],
    "tenure": "",
    "customerDetails": {
        "firstName": "Quality",
        "lastName": "Assurance",
        "email": "qa@ifortepay.id",
        "phone": "089121313131"
    },
    "sellers": [
        {
            "id": "123",
            "name": "Qa Tester",
            "url": "https://www.google.com/",
            "sellerIdNumber": "121313141",
            "email": "qa@ifortepay.id",
            "address": {
                "firstName": "Quality",
                "lastName": "Assurance",
                "address": "Jakarta",
                "city": "Jaksel",
                "postalCode": "17152",
                "phone": "089121313131",
                "countryCode": "121313"
            }
        }
    ],
    "billingAddress": {
        "firstName": "Quality",
        "lastName": "Assurance",
        "address": "Jakarta",
        "city": "Jaksel",
        "postalCode": "17152",
        "phone": "089121313131",
        "countryCode": "121313"
    },
    "shippingAddress": {
        "firstName": "Quality",
        "lastName": "Assurance",
        "address": "Jakarta",
        "city": "Jaksel",
        "postalCode": "17152",
        "phone": "089121313131",
        "countryCode": "121313"
    },
    "callbackUrl": "https://mcpid.proxy.beeceptor.com/BNPL",
    "cancelReturnUrl": "https://www.google.com/",
    "returnUrl": "https://www.google.com/",
    "validityPeriod": ""
}'
go
package main

package main

import (
  "fmt"
  "strings"
  "net/http"
  "io"
)

func main() {

  url := "https://api-stage.ifortepay.id/v1.1/bnpl/generate-checkout-url"
  method := "POST"

  payload := strings.NewReader(`{
    "partnerReferenceNo": "96943614172822",
    "paymentDetails": {
        "amount": {
            "value": "350000.00",
            "currency": "IDR"
        },
    },
    "itemDetails": [
        {
            "itemId": "FOOD01",
            "name": "RUJAK",
            "amount": {
                "value": "350000.00",
                "currency": "IDR"
            },
            "url": "https://www.google.com/",
            "imageUrl": "",
            "category": "0017",
            "qty": 1,
            "parentType": "SELLER",
            "parentId": "123"
        }
    ],
    "tenure": "",
    "customerDetails": {
        "firstName": "Quality",
        "lastName": "Assurance",
        "email": "qa@ifortepay.id",
        "phone": "089121313131"
    },
    "sellers": [
        {
            "id": "123",
            "name": "Qa Tester",
            "url": "https://www.google.com/",
            "sellerIdNumber": "121313141",
            "email": "qa@ifortepay.id",
            "address": {
                "firstName": "Quality",
                "lastName": "Assurance",
                "address": "Jakarta",
                "city": "Jaksel",
                "postalCode": "17152",
                "phone": "089121313131",
                "countryCode": "121313"
            }
        }
    ],
    "billingAddress": {
        "firstName": "Quality",
        "lastName": "Assurance",
        "address": "Jakarta",
        "city": "Jaksel",
        "postalCode": "17152",
        "phone": "089121313131",
        "countryCode": "121313"
    },
    "shippingAddress": {
        "firstName": "Quality",
        "lastName": "Assurance",
        "address": "Jakarta",
        "city": "Jaksel",
        "postalCode": "17152",
        "phone": "089121313131",
        "countryCode": "121313"
    },
    "callbackUrl": "https://mcpid.proxy.beeceptor.com/BNPL",
    "cancelReturnUrl": "https://www.google.com/",
    "returnUrl": "https://www.google.com/",
    "validityPeriod": ""
}`)

  client := &http.Client {
  }
  req, err := http.NewRequest(method, url, payload)

  if err != nil {
    fmt.Println(err)
    return
  }
  req.Header.Add("Content-Type", "application/json")
  req.Header.Add("X-TIMESTAMP", "2020-12-18T10:55:00+07:00")
  req.Header.Add("X-SIGNATURE", "BVg81WjD/pwjOKcoG967LC+vk0BKgxAipx3a7oRLigV2Mo4eVOjgvv/GGzLRyCOBlkN5wFvC59o4ctLRgrWWDWK5o3UT49y4P084tWRZyWSHQI+LOQBtg+U7b5rCCyvoYLskw0YCAK+8gjqPjrMZ+lQI4s51EhBxc/4uMmGhmM/taN3/0xSEUtYCxQf8hkLR7lYlAKSmExG8NQvzQUltQxkcjfpQBsOoSQfVrkqa2Kg74QlidD39t2JIW9t3fCEjPt8oHB8oxOkqe5lviEVgqDn2ZZXSrpgnpNPlWJqqrH+nXRLjEhGZNs/00l4+ApTUBIDy7z2xjEhf+G5JjyIaMg==")
  req.Header.Add("X-PARTNER-ID", "MC2025059906")
  req.Header.Add("X-EXTERNAL-ID", "13953302921462")
  req.Header.Add("CHANNEL-ID", "PL001")

  res, err := client.Do(req)
  if err != nil {
    fmt.Println(err)
    return
  }
  defer res.Body.Close()

  body, err := io.ReadAll(res.Body)
  if err != nil {
    fmt.Println(err)
    return
  }
  fmt.Println(string(body))
}
js
const axios = require('axios');
let data = JSON.stringify({
  "amount": {
    "value": "70000.00",
    "currency": "IDR"
  },
  "itemDetails": [
    {
      "itemId": "BRG001",
      "name": "Sepatu",
      "amount": {
        "value": "10000.00",
        "currency": "IDR"
      },
      "url": "https://www.adidas.co.id/superstar-shoes-996083.html",
      "imageUrl": "https://www.adidas.co.id/superstar-shoes-996083.html",
      "category": "0001",
      "qty": 7,
      "parentType": "SELLER",
      "parentId": "AB001"
    }
  ]
});

let config = {
  method: 'post',
  maxBodyLength: Infinity,
  url: 'https://api-stage.ifortepay.id/v1.0/bnpl/payment-calculation',
  headers: { 
    'Content-Type': 'application/json', 
    'X-TIMESTAMP': '2020-12-18T10:55:00+07:00', 
    'X-SIGNATURE': 'd7DEdWzryB5+eVn2z76ubjuwgkDjr0W8d/rOBPzIm1u/uhTju2sh5UVl3VmNGpzOZ+Y7yxLCmo48eNXxNfjq9ssqmq1t0TWn/wY/E1LvbVVW/J7pT1uXge0vwc+WgSo9Kb3JjpoRVdhvfktRR7fpQOnBaJKnF5VeCmDwYb7Dk4sGvcRXN3dDPN1d8Z/k3JW146B/sapySKkrleStlEsnqmC8kVQZUyOXAs1H4hF9lFc7hzuCH3Gbj5dJILCkK5D+TbjN+w5sUyFbMfUj8l6dTahczwApp7EX/sX7XRZVpfrRp8khbfcNp4jCCrAgkNN7e9ZCX7D/hBHYjcIgVkgTsQ==', 
    'X-PARTNER-ID': 'MC2025059906', 
    'X-EXTERNAL-ID': '38472481552676', 
    'CHANNEL-ID': 'PL001'
  },
  data : data
};

axios.request(config)
.then((response) => {
  console.log(JSON.stringify(response.data));
})
.catch((error) => {
  console.log(error);
});
php
<?php
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://api-stage.ifortepay.id/v1.0/bnpl/payment-calculation',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS =>'{
    "amount": {
        "value": "70000.00",
        "currency": "IDR"
    },
    "itemDetails": [
        {
            "itemId": "BRG001",
            "name": "Sepatu",
            "amount": {
                "value": "10000.00",
                "currency": "IDR"
            },
            "url": "https://www.adidas.co.id/superstar-shoes-996083.html",
            "imageUrl": "https://www.adidas.co.id/superstar-shoes-996083.html",
            "category": "0001",
            "qty": 7,
            "parentType": "SELLER",
            "parentId": "AB001"
        }
    ]
}',
  CURLOPT_HTTPHEADER => array(
    'Content-Type: application/json',
    'X-TIMESTAMP: 2020-12-18T10:55:00+07:00',
    'X-SIGNATURE: d7DEdWzryB5+eVn2z76ubjuwgkDjr0W8d/rOBPzIm1u/uhTju2sh5UVl3VmNGpzOZ+Y7yxLCmo48eNXxNfjq9ssqmq1t0TWn/wY/E1LvbVVW/J7pT1uXge0vwc+WgSo9Kb3JjpoRVdhvfktRR7fpQOnBaJKnF5VeCmDwYb7Dk4sGvcRXN3dDPN1d8Z/k3JW146B/sapySKkrleStlEsnqmC8kVQZUyOXAs1H4hF9lFc7hzuCH3Gbj5dJILCkK5D+TbjN+w5sUyFbMfUj8l6dTahczwApp7EX/sX7XRZVpfrRp8khbfcNp4jCCrAgkNN7e9ZCX7D/hBHYjcIgVkgTsQ==',
    'X-PARTNER-ID: MC2025059906',
    'X-EXTERNAL-ID: 38472481552676',
    'CHANNEL-ID: PL001'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;

Response

ParameterData TypeMandatoryLengthDescription
responseCodeStringM7Response code
responseMessageStringM150Response description
partnerReferenceNoStringM64ID transaction generated by the merchant
referenceNoStringM64ID transaction generated by Ifortepay
paymentChannelStringM30Description name payment channel
paymentDetailsObjectM
paymentDetails.amountObjectMAmount of the transaction
paymentDetails.amount.valueStringM16,2
paymentDetails.amount.currencyStringM3
paymentDetails.totalAmountObjectM
paymentDetails.totalAmount.valueStringM16,2Total amount of the transaction. If IDR, then includes 2 decimal digits. e.g. IDR 10,000 = 10000.00
paymentDetails.totalAmount.currencyStringM3Currency
redirectUrlStringMCheckout payment page URL to display for the customer
latestTransactionStatusStringM2Refer to Appendix 1 - Transaction Status for specific transaction statuses
transactionStatusDescStringM50Description of transaction status
createdAtStringM25Created time
validityPeriodStringM25The time when the payment page URL is valid

Example Response

Details
{
    "responseCode": "2009100",
    "responseMessage": "Successful",
    "partnerReferenceNo": "96943614172822",
    "referenceNo": "01970fd2-9277-743e-b87b-843a10c949a5",
    "paymentChannel": "INDODANA",
    "paymentDetails": {
        "amount": {
            "value": "350000.00",
            "currency": "IDR"
        },
        "totalAmount": {
            "value": "350000.00",
            "currency": "IDR"
        }
    },
    "redirectUrl": "https://sandbox01.indodanafinance.co.id/product-installment/payment?purchaseTransactionId=25778199-3aac-11f0-8b92-47f1cfaa47d3&pid=IFORTE%20Chain%20I&c=checkout&utm_source=IFORTE%20Chain%20I&utm_campaign=IFORTE%20Chain%20I",
    "latestTransactionStatus": "01",
    "transactionStatusDesc": "Initiated",
    "createdAt": "2025-05-27T10:39:08+07:00",
    "validityPeriod": "2025-05-27T10:54:07+07:00"
}

iFortepay API Documentation