Onramp
Get quote
This endpoint allows you to get quote for onramps.
POST
/
quote
/
onramp
Get quote
curl --request POST \
--url https://processor-prod.up.railway.app/quote/onramp \
--header 'Content-Type: application/json' \
--header 'x-service-key: <api-key>' \
--data '
{
"amount": 10000,
"currency": "NGN",
"asset": "base:usdc",
"is_exact_output": false
}
'import requests
url = "https://processor-prod.up.railway.app/quote/onramp"
payload = {
"amount": 10000,
"currency": "NGN",
"asset": "base:usdc",
"is_exact_output": False
}
headers = {
"x-service-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-service-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({amount: 10000, currency: 'NGN', asset: 'base:usdc', is_exact_output: false})
};
fetch('https://processor-prod.up.railway.app/quote/onramp', 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://processor-prod.up.railway.app/quote/onramp",
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' => 10000,
'currency' => 'NGN',
'asset' => 'base:usdc',
'is_exact_output' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-service-key: <api-key>"
],
]);
$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://processor-prod.up.railway.app/quote/onramp"
payload := strings.NewReader("{\n \"amount\": 10000,\n \"currency\": \"NGN\",\n \"asset\": \"base:usdc\",\n \"is_exact_output\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-service-key", "<api-key>")
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://processor-prod.up.railway.app/quote/onramp")
.header("x-service-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": 10000,\n \"currency\": \"NGN\",\n \"asset\": \"base:usdc\",\n \"is_exact_output\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://processor-prod.up.railway.app/quote/onramp")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-service-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": 10000,\n \"currency\": \"NGN\",\n \"asset\": \"base:usdc\",\n \"is_exact_output\": false\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"status": 200,
"message": "Onramp quote fetched successfully",
"timestamp": "2025-09-09T23:00:02.682Z",
"data": {
"type": "onramp",
"fee": 0,
"expiry": "2025-09-09T23:02:02.682Z",
"currency": "NGN",
"rate": 1521,
"input_amount": 10000,
"output_amount": 6.574621959237344
}
}Authorizations
Body
application/json
The fiat amount to to deposit for onramp
Example:
10000
The fiat currency to deposit for onramp
Available options:
NGN Example:
"NGN"
The crypto asset to receive after onramp
Available options:
ethereum:usdc, base:usdc, arbitrum:usdc, solana:usdc, bsc:usdc, polygon:usdc, optimism:usdc, avalanche:usdc, ethereum:usdt, arbitrum:usdt, solana:usdt, polygon:usdt, bsc:usdt, optimism:usdt, avalanche:usdt, base:cngn, bsc:cngn Example:
"base:usdc"
Whether the amount specified is the exact output amount in crypto asset
Example:
false
⌘I
Get quote
curl --request POST \
--url https://processor-prod.up.railway.app/quote/onramp \
--header 'Content-Type: application/json' \
--header 'x-service-key: <api-key>' \
--data '
{
"amount": 10000,
"currency": "NGN",
"asset": "base:usdc",
"is_exact_output": false
}
'import requests
url = "https://processor-prod.up.railway.app/quote/onramp"
payload = {
"amount": 10000,
"currency": "NGN",
"asset": "base:usdc",
"is_exact_output": False
}
headers = {
"x-service-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-service-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({amount: 10000, currency: 'NGN', asset: 'base:usdc', is_exact_output: false})
};
fetch('https://processor-prod.up.railway.app/quote/onramp', 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://processor-prod.up.railway.app/quote/onramp",
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' => 10000,
'currency' => 'NGN',
'asset' => 'base:usdc',
'is_exact_output' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-service-key: <api-key>"
],
]);
$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://processor-prod.up.railway.app/quote/onramp"
payload := strings.NewReader("{\n \"amount\": 10000,\n \"currency\": \"NGN\",\n \"asset\": \"base:usdc\",\n \"is_exact_output\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-service-key", "<api-key>")
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://processor-prod.up.railway.app/quote/onramp")
.header("x-service-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": 10000,\n \"currency\": \"NGN\",\n \"asset\": \"base:usdc\",\n \"is_exact_output\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://processor-prod.up.railway.app/quote/onramp")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-service-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": 10000,\n \"currency\": \"NGN\",\n \"asset\": \"base:usdc\",\n \"is_exact_output\": false\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"status": 200,
"message": "Onramp quote fetched successfully",
"timestamp": "2025-09-09T23:00:02.682Z",
"data": {
"type": "onramp",
"fee": 0,
"expiry": "2025-09-09T23:02:02.682Z",
"currency": "NGN",
"rate": 1521,
"input_amount": 10000,
"output_amount": 6.574621959237344
}
}