Initiate Payment
curl --request POST \
--url https://quickei.io/pay/sandbox/api/v1/payment/create \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"amount": 123,
"currency": "<string>",
"return_url": "<string>",
"cancel_url": "<string>",
"product_name": "<string>",
"order_number": "<string>",
"custom": "<string>"
}
'import requests
url = "https://quickei.io/pay/sandbox/api/v1/payment/create"
payload = {
"amount": 123,
"currency": "<string>",
"return_url": "<string>",
"cancel_url": "<string>",
"product_name": "<string>",
"order_number": "<string>",
"custom": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
amount: 123,
currency: '<string>',
return_url: '<string>',
cancel_url: '<string>',
product_name: '<string>',
order_number: '<string>',
custom: '<string>'
})
};
fetch('https://quickei.io/pay/sandbox/api/v1/payment/create', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://quickei.io/pay/sandbox/api/v1/payment/create",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'amount' => 123,
'currency' => '<string>',
'return_url' => '<string>',
'cancel_url' => '<string>',
'product_name' => '<string>',
'order_number' => '<string>',
'custom' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://quickei.io/pay/sandbox/api/v1/payment/create"
payload := strings.NewReader("{\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"return_url\": \"<string>\",\n \"cancel_url\": \"<string>\",\n \"product_name\": \"<string>\",\n \"order_number\": \"<string>\",\n \"custom\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://quickei.io/pay/sandbox/api/v1/payment/create")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"return_url\": \"<string>\",\n \"cancel_url\": \"<string>\",\n \"product_name\": \"<string>\",\n \"order_number\": \"<string>\",\n \"custom\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://quickei.io/pay/sandbox/api/v1/payment/create")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"return_url\": \"<string>\",\n \"cancel_url\": \"<string>\",\n \"product_name\": \"<string>\",\n \"order_number\": \"<string>\",\n \"custom\": \"<string>\"\n}"
response = http.request(request)
puts response.read_bodyAPI Reference
Initiate Payment
Create a new payment transaction
POST
/
payment
/
create
Initiate Payment
curl --request POST \
--url https://quickei.io/pay/sandbox/api/v1/payment/create \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"amount": 123,
"currency": "<string>",
"return_url": "<string>",
"cancel_url": "<string>",
"product_name": "<string>",
"order_number": "<string>",
"custom": "<string>"
}
'import requests
url = "https://quickei.io/pay/sandbox/api/v1/payment/create"
payload = {
"amount": 123,
"currency": "<string>",
"return_url": "<string>",
"cancel_url": "<string>",
"product_name": "<string>",
"order_number": "<string>",
"custom": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
amount: 123,
currency: '<string>',
return_url: '<string>',
cancel_url: '<string>',
product_name: '<string>',
order_number: '<string>',
custom: '<string>'
})
};
fetch('https://quickei.io/pay/sandbox/api/v1/payment/create', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://quickei.io/pay/sandbox/api/v1/payment/create",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'amount' => 123,
'currency' => '<string>',
'return_url' => '<string>',
'cancel_url' => '<string>',
'product_name' => '<string>',
'order_number' => '<string>',
'custom' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://quickei.io/pay/sandbox/api/v1/payment/create"
payload := strings.NewReader("{\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"return_url\": \"<string>\",\n \"cancel_url\": \"<string>\",\n \"product_name\": \"<string>\",\n \"order_number\": \"<string>\",\n \"custom\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://quickei.io/pay/sandbox/api/v1/payment/create")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"return_url\": \"<string>\",\n \"cancel_url\": \"<string>\",\n \"product_name\": \"<string>\",\n \"order_number\": \"<string>\",\n \"custom\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://quickei.io/pay/sandbox/api/v1/payment/create")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": 123,\n \"currency\": \"<string>\",\n \"return_url\": \"<string>\",\n \"cancel_url\": \"<string>\",\n \"product_name\": \"<string>\",\n \"order_number\": \"<string>\",\n \"custom\": \"<string>\"\n}"
response = http.request(request)
puts response.read_bodyInitiates a new payment transaction.
Endpoint
POST https://quickei.io/pay/sandbox/api/v1/payment/create
Parameters
decimal
required
Amount to charge, rounded to 2 decimal places
string
required
Currency code in uppercase (ISO 4217 Alpha-3)
string
required
Your return/success URL
string
Your cancel/failure URL
string
required
Product name or short description
string
required
Your internal order reference
string
Custom transaction ID for your records
Request Example — Guzzle (PHP)
<?php
require_once('vendor/autoload.php');
$client = new \GuzzleHttp\Client();
$response = $client->request('POST',
'https://quickei.io/pay/sandbox/api/v1/payment/create', [
'json' => [
'amount' => '100.00',
'currency' => 'USD',
'return_url' => 'https://yoursite.com/success',
'cancel_url' => 'https://yoursite.com/cancel',
'product_name' => 'MacBook Air',
'order_number' => 'ORD-2024-001234',
'custom' => '123456789ABCD',
],
'headers' => [
'Authorization' => 'Bearer {{access_token}}',
'accept' => 'application/json',
'content-type' => 'application/json',
],
]);
echo $response->getBody();
Response — 200 OK
{
"message": {
"code": 200,
"success": ["CREATED"]
},
"data": {
"token": "2zMRmT3KeYT2BWMAyGhq...",
"payment_url": "https://quickei.io/pay/..."
},
"type": "success"
}
Error Response — 403 FAILED
{
"message": {
"code": 403,
"error": ["Requested with invalid token!"]
},
"data": [],
"type": "error"
}

