Create Payment Request

This API endpoint is used to initiate a payment using the Key2Payment payment service. It is an HTTP POST request that should be sent to the URL https://api.key2payment.com/PaymentToken/Create. The request should include the necessary parameters to specify the transfer details. The response will provide information about the transaction, including a transaction ID, track ID, merchant ID, redirect URL and token. Please refer to the API documentation or contact the API provider for more information on the required request parameters and the expected response structure.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Sample Request

{
    "merchantid": "",
    "password": "",
    "trackid": "test",//mandatory
    "payment_method": {
        "type": "BANKCARD"
    },
    "bill_phone": "+638765432",
    "bill_currencycode": "PHP", //mandatory
    "bill_amount": "2000.00",//mandatory
    "returnUrl": "https://webhook.site/9137328e-8080-45b4-a40",
    "bill_customerip": "208.127.179.23",//mandatory
    "serverUrl": "https://webhook.site/9137328e-8080-45b4-a40e", //mandatory
    "bill_country": "PH", //mandatory
    "bill_email": "[email protected]", //mandatory
    "bill_city": "Miami", 
    "bill_state": "test", 
    "bill_address": "123 ave test", 
    "bill_zip": "123555", 
    "lang": "en"
}

Sample Response

{
    "type": "valid",
    "result": "Successful",
    "responsecode": "0",
    "transactionid": "2686080",
    "trackid": "merchanttxnid",
    "merchantid": "",
    "redirectUrl": "https://pay.key2payment.com/Index?paymenttoken=503e162e344c42d392c0079afad14f9a",
    "token": "503e162e344c42d392c0079afad14f9a",
    "error_code_tag": null,
    "error_text": null
}
Body Params
string
required

Merchant code provided by key2payment

string

Merchant password provided by key2payment

payment_method
array of objects
required
payment_method*
string
required
Defaults to 54321

transaction id should be provided by merchant

string
required

e.g PHP

string
required
Defaults to PHP
string
required
Defaults to 500
string
required
string
required
Defaults to [email protected]
string
required
Defaults to PH
string
string

This will be used to send callback to merchant once transaction is completed

string
string
string
string
string
string
Defaults to en
Response

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json