curl --request GET \
--url https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId} \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}', 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.beta.getpara.com/v1/onramp/purchases/{purchaseId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-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"
"net/http"
"io"
)
func main() {
url := "https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"status": "INITIATED",
"userId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"purchaseId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"provider": "COINBASE",
"transactionHash": "<string>",
"asset": {
"symbol": "USDC",
"name": "USD Coin",
"contractAddress": "<string>",
"type": "<string>",
"chainId": "8453",
"networkName": "Base",
"decimals": 123
},
"testMode": true,
"completedAt": "2023-11-07T05:31:56Z",
"direction": "BUY",
"paymentMethod": "WIDGET",
"assetQuantity": "<string>",
"fiatAmount": "<string>",
"fiatCurrency": "USD",
"walletId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"destinationAddress": "<string>",
"providerOrderId": "<string>",
"providerTransactionId": "<string>"
}{
"code": "INVALID_REQUEST",
"message": "type must be one of EVM, SOLANA, COSMOS, STELLAR, SUI"
}{
"code": "UNAUTHORIZED",
"message": "secret api key not provided"
}{
"code": "NOT_FOUND",
"message": "wallet not found"
}{
"code": "RATE_LIMITED",
"message": "Rate limit exceeded, try again shortly."
}{
"code": "INTERNAL_ERROR",
"message": "Internal Server Error"
}Get On-Ramp Purchase
Look up a fiat on-ramp purchase by id. Use this to reconcile a purchase you may have missed the
onramp.completed webhook for, or to check one that is still in flight.
The response is the onramp.completed webhook payload plus a status field. A purchase that has not
settled yet returns partial data — transactionHash and completedAt are null until status is
FINISHED — so read status rather than inferring completion from the hash.
Scoped to the calling partner. A purchase that does not exist, is malformed, or belongs to a different
partner all return an identical 404.
curl --request GET \
--url https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId} \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}', 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.beta.getpara.com/v1/onramp/purchases/{purchaseId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-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"
"net/http"
"io"
)
func main() {
url := "https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.beta.getpara.com/v1/onramp/purchases/{purchaseId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"status": "INITIATED",
"userId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"purchaseId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"provider": "COINBASE",
"transactionHash": "<string>",
"asset": {
"symbol": "USDC",
"name": "USD Coin",
"contractAddress": "<string>",
"type": "<string>",
"chainId": "8453",
"networkName": "Base",
"decimals": 123
},
"testMode": true,
"completedAt": "2023-11-07T05:31:56Z",
"direction": "BUY",
"paymentMethod": "WIDGET",
"assetQuantity": "<string>",
"fiatAmount": "<string>",
"fiatCurrency": "USD",
"walletId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"destinationAddress": "<string>",
"providerOrderId": "<string>",
"providerTransactionId": "<string>"
}{
"code": "INVALID_REQUEST",
"message": "type must be one of EVM, SOLANA, COSMOS, STELLAR, SUI"
}{
"code": "UNAUTHORIZED",
"message": "secret api key not provided"
}{
"code": "NOT_FOUND",
"message": "wallet not found"
}{
"code": "RATE_LIMITED",
"message": "Rate limit exceeded, try again shortly."
}{
"code": "INTERNAL_ERROR",
"message": "Internal Server Error"
}Authorizations
Path Parameters
Response
On-ramp purchase record
Lifecycle state. INITIATED = created, not yet settled. FINISHED = the provider confirmed delivery
(this is when onramp.completed fires). CANCELLED = the purchase will not settle. Treat unknown
status values as non-terminal — future versions may add states.
INITIATED, CANCELLED, FINISHED