Skip to content

Get Payment Options

An endpoint to get all available payment options under the integrator’s account that
will be used to process payment for checkout and direct integrations.

To get payment options, send the following request header parameter via GET.

GET/options

Options

HEADER PARAMETERS

Authorization required
string
Unique identifier of the integrator.

Request Samples

curl
    -X GET "https://test-api.tlpe.io/options" \
    -H "Content-Type: application/json" \
    -H "Authorization: {integratorToken}" \
public JArray Options()
        {
            JArray responseData;
            string url = "https://test-api.tlpe.io/options";
            HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(url);
            request.Method = "GET";
            request.Headers["Authorization"] = "{integratorToken}";
            request.ContentType = "application/json";

        using (HttpWebResponse response = (HttpWebResponse)request.GetResponse())
            {
            Stream responseStream = response.GetResponseStream();
            StreamReader reader = new StreamReader(responseStream);
            StringReader sr = new StringReader(reader.ReadToEnd());

            JsonReader jreader = new JsonTextReader(sr);
            JsonSerializer jss = new JsonSerializer();
            responseData = jss.Deserialize<JArray>(jreader);
            reader.Close();
            responseStream.Close();
            }

        return responseData;
}
Public Function Options() As JValue
    Dim url As String = "https://test-api.tlpe.io/options"
    Dim request As WebRequest = WebRequest.Create(url)
    request.Method = "GET"
    request.Headers.Add("Authorization", "{integratorToken}")
    request.ContentType = "application/json"

    Dim response As WebResponse = request.GetResponse()
    Dim responseStream = response.GetResponseStream()
    Dim reader As New StreamReader(responseStream)
    Dim responseData As JValue = reader.ReadToEnd()
    reader.Close()
    responseStream.Close()

    Return responseData
End Function
import http.client
import json

conn = http.client.HTTPSConnection("test-api.tlpe.io")
payload = ""
headers = {"Authorization": "{integratorToken}", "Content-Type": "application/json"}
conn.request("GET", "/options", payload, headers)
res = conn.getresponse()
data = res.read()
print data.decode("utf-8")
<?php
$curl = curl_init();

curl_setopt_array($curl, array(
    CURLOPT_URL => 'https://test-api.tlpe.io/options',
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_ENCODING => '',
    CURLOPT_MAXREDIRS => 10,
    CURLOPT_TIMEOUT => 0,
    CURLOPT_FOLLOWLOCATION => true,
    CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
    CURLOPT_CUSTOMREQUEST => 'GET',
    CURLOPT_HTTPHEADER => array(
        'Authorization: {integratorToken}',
        'Content-Type: application/json'
    ) ,
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
require 'rest-client'
require 'json'

response = RestClient::Request.execute(
method:  :get, 
url:     "https://test-api.tlpe.io/options",
headers: { authorization: '{integratorToken}', content_type: 'application/json', accept: 'application/json'}
)

responseJson = JSON.parse(response)

puts JSON.pretty_generate(responseJson)
var request = require('request');
var headers = {
    'Content-Type': 'application/json',
    'Authorization': '{integratorToken}'
};
var options = {
    url: 'https://test-api.tlpe.io/options',
    headers: headers
};

function callback(error, response, body) {
    if (!error && response.statusCode == 200) {
        console.log(body);
    }
}
request(options, callback);

Download Postman request here

200 Successful Response

RESPONSE SCHEMA: application/json

code
string
Random generated JSON Web Token (JWT) to be used in checkout or direct payment

value
string
Payment brand name to be displayed by integrator

image
string
Director where the brand logo is located and can be used by the integrator

Response Samples

[
    {
     "code": "{generatedOptionKey}",
     "value": "GCash",
     "image": "{logoUrl}"
    },
    {
     "code": "{generatedOptionKey}",
     "value": "Visa",
     "image": "{logoUrl}"
    }
 ]