curl --request PUT \
--url https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"poolId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"amount": 0,
"amountDirection": "source"
}
'import requests
url = "https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add"
payload = {
"poolId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"amount": 0,
"amountDirection": "source"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
poolId: '3fa85f64-5717-4562-b3fc-2c963f66afa6',
amount: 0,
amountDirection: 'source'
})
};
fetch('https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add', 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://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'poolId' => '3fa85f64-5717-4562-b3fc-2c963f66afa6',
'amount' => 0,
'amountDirection' => 'source'
]),
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://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add"
payload := strings.NewReader("{\n \"poolId\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\",\n \"amount\": 0,\n \"amountDirection\": \"source\"\n}")
req, _ := http.NewRequest("PUT", 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.put("https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"poolId\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\",\n \"amount\": 0,\n \"amountDirection\": \"source\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"poolId\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\",\n \"amount\": 0,\n \"amountDirection\": \"source\"\n}"
response = http.request(request)
puts response.read_body{
"quoteId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"status": "pending",
"source": "NGN",
"destination": "USDT",
"chain": "BASE",
"amount": 50000,
"totalSourceAmount": 50000,
"totalDestinationAmount": 31.65,
"clientId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"mode": "live",
"ttl": 300,
"allocationResult": {
"totalSourceAmount": 50000,
"weightedAverageRate": 1580.5,
"totalDestinationAmount": 31.65,
"allocations": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"clientId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"poolId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"poolAccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"allocatedAmount": 31.65,
"sourceAmount": 50000,
"rate": 1580.5,
"reference": "REF-001",
"metadata": {}
}
]
},
"metadata": {
"bankPayIn": {
"accountName": "Spotflow Ltd",
"accountNumber": "0123456789",
"bankName": "Access Bank",
"reference": "PAY-REF-001"
},
"cryptoPayIn": {
"addressId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"address": "0x95222290dd7278aa3ddd389cc1e1d165cc4bafe5",
"chain": "BASE",
"token": "USDT",
"addressType": "deposit",
"expectedAmount": 50000,
"externalReference": "<string>",
"status": "active",
"createdAt": "2026-04-01T10:55:46.254Z",
"expiresAt": "2026-04-01T10:55:46.256Z",
"virtualAccountId": "<string>",
"derivationIndex": 0,
"warningMessage": "<string>"
}
},
"chatMetadata": {
"conversationId": "<string>",
"chatQuoteId": "<string>",
"listingId": "<string>",
"initialListingRate": "<string>",
"negotiationStartedAt": "2023-11-07T05:31:56Z",
"quoteSentAt": "2023-11-07T05:31:56Z",
"acceptedAt": "2023-11-07T05:31:56Z"
}
}{
"code": "INVALID_CURRENCY",
"message": "Invalid source currency. Supported: NGN, GHS",
"details": {}
}Edit Quote
Updates an existing quote session by adding or modifying the pool allocation details, including amount and direction.
curl --request PUT \
--url https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"poolId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"amount": 0,
"amountDirection": "source"
}
'import requests
url = "https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add"
payload = {
"poolId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"amount": 0,
"amountDirection": "source"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
poolId: '3fa85f64-5717-4562-b3fc-2c963f66afa6',
amount: 0,
amountDirection: 'source'
})
};
fetch('https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add', 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://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'poolId' => '3fa85f64-5717-4562-b3fc-2c963f66afa6',
'amount' => 0,
'amountDirection' => 'source'
]),
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://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add"
payload := strings.NewReader("{\n \"poolId\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\",\n \"amount\": 0,\n \"amountDirection\": \"source\"\n}")
req, _ := http.NewRequest("PUT", 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.put("https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"poolId\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\",\n \"amount\": 0,\n \"amountDirection\": \"source\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hyperrails.io/api/v1/partners/marketplace/quote/{id}/add")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"poolId\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\",\n \"amount\": 0,\n \"amountDirection\": \"source\"\n}"
response = http.request(request)
puts response.read_body{
"quoteId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"status": "pending",
"source": "NGN",
"destination": "USDT",
"chain": "BASE",
"amount": 50000,
"totalSourceAmount": 50000,
"totalDestinationAmount": 31.65,
"clientId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"mode": "live",
"ttl": 300,
"allocationResult": {
"totalSourceAmount": 50000,
"weightedAverageRate": 1580.5,
"totalDestinationAmount": 31.65,
"allocations": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"clientId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"poolId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"poolAccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"allocatedAmount": 31.65,
"sourceAmount": 50000,
"rate": 1580.5,
"reference": "REF-001",
"metadata": {}
}
]
},
"metadata": {
"bankPayIn": {
"accountName": "Spotflow Ltd",
"accountNumber": "0123456789",
"bankName": "Access Bank",
"reference": "PAY-REF-001"
},
"cryptoPayIn": {
"addressId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"address": "0x95222290dd7278aa3ddd389cc1e1d165cc4bafe5",
"chain": "BASE",
"token": "USDT",
"addressType": "deposit",
"expectedAmount": 50000,
"externalReference": "<string>",
"status": "active",
"createdAt": "2026-04-01T10:55:46.254Z",
"expiresAt": "2026-04-01T10:55:46.256Z",
"virtualAccountId": "<string>",
"derivationIndex": 0,
"warningMessage": "<string>"
}
},
"chatMetadata": {
"conversationId": "<string>",
"chatQuoteId": "<string>",
"listingId": "<string>",
"initialListingRate": "<string>",
"negotiationStartedAt": "2023-11-07T05:31:56Z",
"quoteSentAt": "2023-11-07T05:31:56Z",
"acceptedAt": "2023-11-07T05:31:56Z"
}
}{
"code": "INVALID_CURRENCY",
"message": "Invalid source currency. Supported: NGN, GHS",
"details": {}
}Authorizations
API key authentication using Bearer token
Path Parameters
The unique identifier (UUID) of the quote session.
"3fa85f64-5717-4562-b3fc-2c963f66afa6"
Body
The unique identifier of the liquidity pool.
"3fa85f64-5717-4562-b3fc-2c963f66afa6"
The amount to be allocated.
0
Specifies if the amount refers to the source or destination currency.
source, destination "source"
Response
Pool allocation added successfully
Unique quote identifier
"3fa85f64-5717-4562-b3fc-2c963f66afa6"
Quote status
pending, awaiting_payment, completed, expired, cancelled "pending"
Source currency
"NGN"
Destination currency
"USDT"
Blockchain network
"BASE"
Requested amount
50000
Total amount in source currency
50000
Total amount in destination currency
31.65
Client identifier
Operating mode
live, sandbox "live"
Time to live in seconds
300
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Metadata for chat-based quote negotiation
Show child attributes
Show child attributes
Was this page helpful?