Query parameters
NameDescription
pageDefault
1items_per_pagePage size. The API caps values above 100 at 100.
Default
20statusAn order made with an API key starts as pending, and Gravv debits its source at once. It then becomes completed, or cancelled if the debit fails. waiting_approval is for orders made in the Dashboard.
Possible values: waiting_approval, pending, completed, rejected, cancelled
Response
Returns 200 OK. A page of orders
NameDescription
dataShow 5 child attributesobject
itemsShow 19 child attributesobject[]
idquote_idstatusAn order made with an API key starts as pending, and Gravv debits its source at once. It then becomes completed, or cancelled if the debit fails. waiting_approval is for orders made in the Dashboard.
Possible values: waiting_approval, pending, completed, rejected, cancelled
from_currencyto_currencypair_coderatesource_amountThe amount sold
destination_amountThe amount bought
source_typePossible values:
internal_account, internal_crypto_walletsource_iddestination_typePossible values:
internal_account, internal_crypto_wallet, external_accountdestination_idorder_typePossible values:
marketquote_sourceWhich rate table priced the order
trade_desk_request_idOnly on orders made through the trade desk
client_referencemetadatacreated_atitems_per_pagepagetotal_itemstotal_pageserrorErrors
| Status | Meaning |
|---|---|
| 200 | A page of orders |
| 400 | The request failed. Every FX error is a 400, including not-found and outages. Read error. |
Was this page helpful? Yes No
Previous
Next
Request
cURLJavaScriptPythonGoRubyPHPJavaC#cURL
curl --request GET \
--url 'https://api.gravv.xyz/v1/fx/orders?page=1&items_per_page=20&status=pending' \
--header 'Api-Key: <api-key>'
const response = await fetch('https://api.gravv.xyz/v1/fx/orders?page=1&items_per_page=20&status=pending', {
method: 'GET',
headers: {
'Api-Key': '<api-key>',
},
});
const data = await response.json();
console.log(response.status, data);
import requests
url = "https://api.gravv.xyz/v1/fx/orders?page=1&items_per_page=20&status=pending"
headers = {
"Api-Key": "<api-key>",
}
response = requests.get(url, headers=headers)
print(response.status_code)
print(response.json())
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, err := http.NewRequest("GET", "https://api.gravv.xyz/v1/fx/orders?page=1&items_per_page=20&status=pending", nil)
if err != nil {
panic(err)
}
req.Header.Set("Api-Key", "<api-key>")
res, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer res.Body.Close()
body, err := io.ReadAll(res.Body)
if err != nil {
panic(err)
}
fmt.Println(res.Status)
fmt.Println(string(body))
}
require "net/http"
require "uri"
uri = URI("https://api.gravv.xyz/v1/fx/orders?page=1&items_per_page=20&status=pending")
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == "https"
request = Net::HTTP::Get.new(uri)
request["Api-Key"] = "<api-key>"
response = http.request(request)
puts response.code
puts response.body
<?php
$ch = curl_init();
curl_setopt_array($ch, [
CURLOPT_URL => 'https://api.gravv.xyz/v1/fx/orders?page=1&items_per_page=20&status=pending',
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Api-Key: <api-key>',
],
]);
$response = curl_exec($ch);
if ($response === false) {
throw new RuntimeException(curl_error($ch));
}
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
curl_close($ch);
echo $status, PHP_EOL, $response, PHP_EOL;
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
public class Main {
public static void main(String[] args) throws Exception {
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.gravv.xyz/v1/fx/orders?page=1&items_per_page=20&status=pending"))
.header("Api-Key", "<api-key>")
.GET()
.build();
HttpResponse<String> response = HttpClient.newHttpClient()
.send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(response.statusCode());
System.out.println(response.body());
}
}
using System.Net.Http;
using System.Text;
using var client = new HttpClient();
using var request = new HttpRequestMessage(HttpMethod.Get, "https://api.gravv.xyz/v1/fx/orders?page=1&items_per_page=20&status=pending");
request.Headers.TryAddWithoutValidation("Api-Key", "<api-key>");
using var response = await client.SendAsync(request);
Console.WriteLine((int)response.StatusCode);
Console.WriteLine(await response.Content.ReadAsStringAsync());
Responseapplication/json
200400OK
{
"data": {
"items": [
{
"id": "2d4f6a8c-1b3d-4e5f-8a7b-9c0d1e2f3a4b",
"quote_id": "GRVOTC_3F9A1C",
"status": "pending",
"from_currency": "USD",
"to_currency": "XAF",
"rate": "605.25",
"source_amount": "10000",
"destination_amount": "6052500",
"source_type": "internal_account",
"source_id": "4b3a2c1d-0e9f-4a8b-9c7d-6e5f4a3b2c1d",
"destination_type": "external_account",
"destination_id": "b7e1c2d3-4f5a-4b6c-9d8e-7f6a5b4c3d2e",
"order_type": "market",
"client_reference": "inv-2026-1042",
"metadata": {
"desk": "treasury"
},
"created_at": "2026-10-12T09:21:04Z"
}
],
"items_per_page": 20,
"page": 1,
"total_items": 1,
"total_pages": 1
},
"error": null
}
{
"data": null,
"error": "order not found"
}