Create payment request by card provider
curl --request POST \
--url https://api.venlyfinance.com/v1/payment-requests \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"cardProviderReference": {
"type": "paymentology",
"referenceId": "ACC-12345"
},
"paymentRequest": {
"amount": 25,
"currency": "USD",
"externalId": "order-67890",
"description": "Order #67890",
"idempotencyKey": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
}
'import requests
url = "https://api.venlyfinance.com/v1/payment-requests"
payload = {
"cardProviderReference": {
"type": "paymentology",
"referenceId": "ACC-12345"
},
"paymentRequest": {
"amount": 25,
"currency": "USD",
"externalId": "order-67890",
"description": "Order #67890",
"idempotencyKey": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
}
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({
cardProviderReference: {type: 'paymentology', referenceId: 'ACC-12345'},
paymentRequest: {
amount: 25,
currency: 'USD',
externalId: 'order-67890',
description: 'Order #67890',
idempotencyKey: '3fa85f64-5717-4562-b3fc-2c963f66afa6'
}
})
};
fetch('https://api.venlyfinance.com/v1/payment-requests', 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.venlyfinance.com/v1/payment-requests",
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([
'cardProviderReference' => [
'type' => 'paymentology',
'referenceId' => 'ACC-12345'
],
'paymentRequest' => [
'amount' => 25,
'currency' => 'USD',
'externalId' => 'order-67890',
'description' => 'Order #67890',
'idempotencyKey' => '3fa85f64-5717-4562-b3fc-2c963f66afa6'
]
]),
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.venlyfinance.com/v1/payment-requests"
payload := strings.NewReader("{\n \"cardProviderReference\": {\n \"type\": \"paymentology\",\n \"referenceId\": \"ACC-12345\"\n },\n \"paymentRequest\": {\n \"amount\": 25,\n \"currency\": \"USD\",\n \"externalId\": \"order-67890\",\n \"description\": \"Order #67890\",\n \"idempotencyKey\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\"\n }\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://api.venlyfinance.com/v1/payment-requests")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"cardProviderReference\": {\n \"type\": \"paymentology\",\n \"referenceId\": \"ACC-12345\"\n },\n \"paymentRequest\": {\n \"amount\": 25,\n \"currency\": \"USD\",\n \"externalId\": \"order-67890\",\n \"description\": \"Order #67890\",\n \"idempotencyKey\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.venlyfinance.com/v1/payment-requests")
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 \"cardProviderReference\": {\n \"type\": \"paymentology\",\n \"referenceId\": \"ACC-12345\"\n },\n \"paymentRequest\": {\n \"amount\": 25,\n \"currency\": \"USD\",\n \"externalId\": \"order-67890\",\n \"description\": \"Order #67890\",\n \"idempotencyKey\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\"\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"result": {
"id": "d4e5f6a7-b8c9-4012-8345-6789abcdef01",
"accountId": "b2a1f0e9-8c7d-4e3a-9f21-0a1b2c3d4e5f",
"amount": {
"fiat": 25,
"crypto": "25.000000"
},
"originalAmount": {
"fiat": 25,
"crypto": "25.000000"
},
"currency": "USD",
"externalId": "order-67890",
"description": "Order #67890",
"status": "RESERVED",
"executions": [
{
"id": "e5f6a7b8-c9d0-4123-9456-789abcdef012",
"walletPairId": "f6a7b8c9-d0e1-4234-a567-89abcdef0123",
"type": "AUTHORIZATION",
"chain": "BASE",
"asset": "USDC",
"amount": 25,
"exchangeRate": 1,
"status": "RESERVED",
"transactionHash": "0xa1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6c7d8e9f0a1b2",
"createdAt": "2026-01-15T09:30:00Z",
"updatedAt": "2026-01-15T09:30:02Z"
}
],
"createdAt": "2026-01-15T09:30:00Z",
"updatedAt": "2026-01-15T09:30:02Z"
}
}{
"success": false,
"errors": [
{
"code": "invalid-request",
"message": "The request contains invalid parameters."
}
]
}{
"success": false,
"errors": [
{
"code": "unauthenticated",
"message": "Please authenticate to perform this action."
}
]
}{
"success": false,
"errors": [
{
"code": "forbidden",
"message": "You do not have permission to access this resource."
}
]
}{
"success": false,
"errors": [
{
"code": "account-not-found",
"message": "The requested resource was not found."
}
]
}{
"success": false,
"errors": [
{
"code": "internal-error",
"message": "An unexpected error occurred. Please try again later."
}
]
}Payment Requests
Create a payment request by card provider
Create a payment request, resolving the account from a card-provider reference.
POST
/
payment-requests
Create payment request by card provider
curl --request POST \
--url https://api.venlyfinance.com/v1/payment-requests \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"cardProviderReference": {
"type": "paymentology",
"referenceId": "ACC-12345"
},
"paymentRequest": {
"amount": 25,
"currency": "USD",
"externalId": "order-67890",
"description": "Order #67890",
"idempotencyKey": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
}
'import requests
url = "https://api.venlyfinance.com/v1/payment-requests"
payload = {
"cardProviderReference": {
"type": "paymentology",
"referenceId": "ACC-12345"
},
"paymentRequest": {
"amount": 25,
"currency": "USD",
"externalId": "order-67890",
"description": "Order #67890",
"idempotencyKey": "3fa85f64-5717-4562-b3fc-2c963f66afa6"
}
}
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({
cardProviderReference: {type: 'paymentology', referenceId: 'ACC-12345'},
paymentRequest: {
amount: 25,
currency: 'USD',
externalId: 'order-67890',
description: 'Order #67890',
idempotencyKey: '3fa85f64-5717-4562-b3fc-2c963f66afa6'
}
})
};
fetch('https://api.venlyfinance.com/v1/payment-requests', 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.venlyfinance.com/v1/payment-requests",
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([
'cardProviderReference' => [
'type' => 'paymentology',
'referenceId' => 'ACC-12345'
],
'paymentRequest' => [
'amount' => 25,
'currency' => 'USD',
'externalId' => 'order-67890',
'description' => 'Order #67890',
'idempotencyKey' => '3fa85f64-5717-4562-b3fc-2c963f66afa6'
]
]),
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.venlyfinance.com/v1/payment-requests"
payload := strings.NewReader("{\n \"cardProviderReference\": {\n \"type\": \"paymentology\",\n \"referenceId\": \"ACC-12345\"\n },\n \"paymentRequest\": {\n \"amount\": 25,\n \"currency\": \"USD\",\n \"externalId\": \"order-67890\",\n \"description\": \"Order #67890\",\n \"idempotencyKey\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\"\n }\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://api.venlyfinance.com/v1/payment-requests")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"cardProviderReference\": {\n \"type\": \"paymentology\",\n \"referenceId\": \"ACC-12345\"\n },\n \"paymentRequest\": {\n \"amount\": 25,\n \"currency\": \"USD\",\n \"externalId\": \"order-67890\",\n \"description\": \"Order #67890\",\n \"idempotencyKey\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.venlyfinance.com/v1/payment-requests")
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 \"cardProviderReference\": {\n \"type\": \"paymentology\",\n \"referenceId\": \"ACC-12345\"\n },\n \"paymentRequest\": {\n \"amount\": 25,\n \"currency\": \"USD\",\n \"externalId\": \"order-67890\",\n \"description\": \"Order #67890\",\n \"idempotencyKey\": \"3fa85f64-5717-4562-b3fc-2c963f66afa6\"\n }\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"result": {
"id": "d4e5f6a7-b8c9-4012-8345-6789abcdef01",
"accountId": "b2a1f0e9-8c7d-4e3a-9f21-0a1b2c3d4e5f",
"amount": {
"fiat": 25,
"crypto": "25.000000"
},
"originalAmount": {
"fiat": 25,
"crypto": "25.000000"
},
"currency": "USD",
"externalId": "order-67890",
"description": "Order #67890",
"status": "RESERVED",
"executions": [
{
"id": "e5f6a7b8-c9d0-4123-9456-789abcdef012",
"walletPairId": "f6a7b8c9-d0e1-4234-a567-89abcdef0123",
"type": "AUTHORIZATION",
"chain": "BASE",
"asset": "USDC",
"amount": 25,
"exchangeRate": 1,
"status": "RESERVED",
"transactionHash": "0xa1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6c7d8e9f0a1b2",
"createdAt": "2026-01-15T09:30:00Z",
"updatedAt": "2026-01-15T09:30:02Z"
}
],
"createdAt": "2026-01-15T09:30:00Z",
"updatedAt": "2026-01-15T09:30:02Z"
}
}{
"success": false,
"errors": [
{
"code": "invalid-request",
"message": "The request contains invalid parameters."
}
]
}{
"success": false,
"errors": [
{
"code": "unauthenticated",
"message": "Please authenticate to perform this action."
}
]
}{
"success": false,
"errors": [
{
"code": "forbidden",
"message": "You do not have permission to access this resource."
}
]
}{
"success": false,
"errors": [
{
"code": "account-not-found",
"message": "The requested resource was not found."
}
]
}{
"success": false,
"errors": [
{
"code": "internal-error",
"message": "An unexpected error occurred. Please try again later."
}
]
}Creates a payment request without an account ID in the path — the account is resolved from
cardProviderReference (type + referenceId). The nested paymentRequest body matches the per-account endpoint.
Concept guide: Payment requests
The resolved account must be verified, and (self-custody) its wallet
ACTIVE with an allowance, before a payment can be reserved. See Account verification.There is no
chain field in the request — the settlement chain is determined by the wallet pair of the account resolved from cardProviderReference. The reference must map to an account that has a wallet on that chain, otherwise the request fails to find a matching wallet pair. The response shape matches the per-account endpoint (amount/originalAmount objects; no GET endpoint).Authorizations
OAuth2 client credentials flow. Token endpoints:
Body
application/json
Was this page helpful?
⌘I

