Initiate a payment collection
curl --request POST \
--url https://api.tradevu.co/v1/api/deposit \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"amount": "500",
"paymentReference": "invoice-4471",
"source": "<string>",
"rateKey": "<string>",
"narration": "Invoice #4471",
"receipent": {
"network": "polygon",
"address": "<string>",
"accountNumber": "<string>",
"accountName": "<string>",
"bankCode": "<string>",
"bankName": "<string>"
}
}
'import requests
url = "https://api.tradevu.co/v1/api/deposit"
payload = {
"amount": "500",
"paymentReference": "invoice-4471",
"source": "<string>",
"rateKey": "<string>",
"narration": "Invoice #4471",
"receipent": {
"network": "polygon",
"address": "<string>",
"accountNumber": "<string>",
"accountName": "<string>",
"bankCode": "<string>",
"bankName": "<string>"
}
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
amount: '500',
paymentReference: 'invoice-4471',
source: '<string>',
rateKey: '<string>',
narration: 'Invoice #4471',
receipent: {
network: 'polygon',
address: '<string>',
accountNumber: '<string>',
accountName: '<string>',
bankCode: '<string>',
bankName: '<string>'
}
})
};
fetch('https://api.tradevu.co/v1/api/deposit', 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.tradevu.co/v1/api/deposit",
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' => '500',
'paymentReference' => 'invoice-4471',
'source' => '<string>',
'rateKey' => '<string>',
'narration' => 'Invoice #4471',
'receipent' => [
'network' => 'polygon',
'address' => '<string>',
'accountNumber' => '<string>',
'accountName' => '<string>',
'bankCode' => '<string>',
'bankName' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.tradevu.co/v1/api/deposit"
payload := strings.NewReader("{\n \"amount\": \"500\",\n \"paymentReference\": \"invoice-4471\",\n \"source\": \"<string>\",\n \"rateKey\": \"<string>\",\n \"narration\": \"Invoice #4471\",\n \"receipent\": {\n \"network\": \"polygon\",\n \"address\": \"<string>\",\n \"accountNumber\": \"<string>\",\n \"accountName\": \"<string>\",\n \"bankCode\": \"<string>\",\n \"bankName\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-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://api.tradevu.co/v1/api/deposit")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": \"500\",\n \"paymentReference\": \"invoice-4471\",\n \"source\": \"<string>\",\n \"rateKey\": \"<string>\",\n \"narration\": \"Invoice #4471\",\n \"receipent\": {\n \"network\": \"polygon\",\n \"address\": \"<string>\",\n \"accountNumber\": \"<string>\",\n \"accountName\": \"<string>\",\n \"bankCode\": \"<string>\",\n \"bankName\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tradevu.co/v1/api/deposit")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": \"500\",\n \"paymentReference\": \"invoice-4471\",\n \"source\": \"<string>\",\n \"rateKey\": \"<string>\",\n \"narration\": \"Invoice #4471\",\n \"receipent\": {\n \"network\": \"polygon\",\n \"address\": \"<string>\",\n \"accountNumber\": \"<string>\",\n \"accountName\": \"<string>\",\n \"bankCode\": \"<string>\",\n \"bankName\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"message": "Payment collection initiated successfully",
"data": {
"transactionId": "<string>",
"payRefrence": "<string>",
"amount": "<string>",
"toAmount": 123,
"fromCurrency": "<string>",
"toCurrency": "<string>",
"paymentReference": "<string>",
"rate": 123,
"fee": 123,
"totalAmount": 123,
"paymentInstruction": [
{
"narration": "Kindly use 8f21c93a1b as transfer narration or memo",
"accountNumber": "0123456789",
"accountName": "Tradevu/Acme Inc",
"bankName": "Providus Bank"
}
]
},
"error": false
}{
"statusCode": 400,
"message": "Invalid currency: XYZ",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/v1/api/balance/XYZ",
"request": {
"method": "GET",
"url": "/v1/api/balance/XYZ"
}
}Payment Collections
Initiate a payment collection
Creates a collection and returns the account details to show your customer. See the Payment Collections guide for the full flow.
POST
/
api
/
deposit
Initiate a payment collection
curl --request POST \
--url https://api.tradevu.co/v1/api/deposit \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"amount": "500",
"paymentReference": "invoice-4471",
"source": "<string>",
"rateKey": "<string>",
"narration": "Invoice #4471",
"receipent": {
"network": "polygon",
"address": "<string>",
"accountNumber": "<string>",
"accountName": "<string>",
"bankCode": "<string>",
"bankName": "<string>"
}
}
'import requests
url = "https://api.tradevu.co/v1/api/deposit"
payload = {
"amount": "500",
"paymentReference": "invoice-4471",
"source": "<string>",
"rateKey": "<string>",
"narration": "Invoice #4471",
"receipent": {
"network": "polygon",
"address": "<string>",
"accountNumber": "<string>",
"accountName": "<string>",
"bankCode": "<string>",
"bankName": "<string>"
}
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
amount: '500',
paymentReference: 'invoice-4471',
source: '<string>',
rateKey: '<string>',
narration: 'Invoice #4471',
receipent: {
network: 'polygon',
address: '<string>',
accountNumber: '<string>',
accountName: '<string>',
bankCode: '<string>',
bankName: '<string>'
}
})
};
fetch('https://api.tradevu.co/v1/api/deposit', 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.tradevu.co/v1/api/deposit",
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' => '500',
'paymentReference' => 'invoice-4471',
'source' => '<string>',
'rateKey' => '<string>',
'narration' => 'Invoice #4471',
'receipent' => [
'network' => 'polygon',
'address' => '<string>',
'accountNumber' => '<string>',
'accountName' => '<string>',
'bankCode' => '<string>',
'bankName' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.tradevu.co/v1/api/deposit"
payload := strings.NewReader("{\n \"amount\": \"500\",\n \"paymentReference\": \"invoice-4471\",\n \"source\": \"<string>\",\n \"rateKey\": \"<string>\",\n \"narration\": \"Invoice #4471\",\n \"receipent\": {\n \"network\": \"polygon\",\n \"address\": \"<string>\",\n \"accountNumber\": \"<string>\",\n \"accountName\": \"<string>\",\n \"bankCode\": \"<string>\",\n \"bankName\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-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://api.tradevu.co/v1/api/deposit")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"amount\": \"500\",\n \"paymentReference\": \"invoice-4471\",\n \"source\": \"<string>\",\n \"rateKey\": \"<string>\",\n \"narration\": \"Invoice #4471\",\n \"receipent\": {\n \"network\": \"polygon\",\n \"address\": \"<string>\",\n \"accountNumber\": \"<string>\",\n \"accountName\": \"<string>\",\n \"bankCode\": \"<string>\",\n \"bankName\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tradevu.co/v1/api/deposit")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"amount\": \"500\",\n \"paymentReference\": \"invoice-4471\",\n \"source\": \"<string>\",\n \"rateKey\": \"<string>\",\n \"narration\": \"Invoice #4471\",\n \"receipent\": {\n \"network\": \"polygon\",\n \"address\": \"<string>\",\n \"accountNumber\": \"<string>\",\n \"accountName\": \"<string>\",\n \"bankCode\": \"<string>\",\n \"bankName\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"message": "Payment collection initiated successfully",
"data": {
"transactionId": "<string>",
"payRefrence": "<string>",
"amount": "<string>",
"toAmount": 123,
"fromCurrency": "<string>",
"toCurrency": "<string>",
"paymentReference": "<string>",
"rate": 123,
"fee": 123,
"totalAmount": 123,
"paymentInstruction": [
{
"narration": "Kindly use 8f21c93a1b as transfer narration or memo",
"accountNumber": "0123456789",
"accountName": "Tradevu/Acme Inc",
"bankName": "Providus Bank"
}
]
},
"error": false
}{
"statusCode": 400,
"message": "Invalid currency: XYZ",
"timestamp": "2023-11-07T05:31:56Z",
"path": "/v1/api/balance/XYZ",
"request": {
"method": "GET",
"url": "/v1/api/balance/XYZ"
}
}Authorizations
Your business API key, generated from the dashboard. Required on every business-facing endpoint.
Body
application/json
Example:
"500"
Fiat currencies: NGN, EUR, GBP, USD, KES, UGX, GHS, CAD, XOF, XAF. Crypto currencies: USDT, USDC.
Available options:
NGN, EUR, GBP, USD, USDT, USDC, KES, UGX, GHS, CAD, XOF, XAF Fiat currencies: NGN, EUR, GBP, USD, KES, UGX, GHS, CAD, XOF, XAF. Crypto currencies: USDT, USDC.
Available options:
NGN, EUR, GBP, USD, USDT, USDC, KES, UGX, GHS, CAD, XOF, XAF Unique reference you generate. Reusing one returns a 400.
Example:
"invoice-4471"
Required when fromCurrency differs from toCurrency. Obtain from GET /api/qoutes/{fromCurrency}/{toCurrency}/{amount}.
Example:
"Invoice #4471"
Only required when the collection settles to a crypto or specific bank destination.
Show child attributes
Show child attributes
⌘I