Create an NGN wallet for a customer
curl --request POST \
--url https://api-production.fossapay.com/api/v1/wallets/fiat/create \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"customerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletName": "<string>",
"walletReference": "<string>"
}
'import requests
url = "https://api-production.fossapay.com/api/v1/wallets/fiat/create"
payload = {
"customerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletName": "<string>",
"walletReference": "<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({
customerId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
walletName: '<string>',
walletReference: '<string>'
})
};
fetch('https://api-production.fossapay.com/api/v1/wallets/fiat/create', 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-production.fossapay.com/api/v1/wallets/fiat/create",
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([
'customerId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'walletName' => '<string>',
'walletReference' => '<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-production.fossapay.com/api/v1/wallets/fiat/create"
payload := strings.NewReader("{\n \"customerId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletName\": \"<string>\",\n \"walletReference\": \"<string>\"\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-production.fossapay.com/api/v1/wallets/fiat/create")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"customerId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletName\": \"<string>\",\n \"walletReference\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-production.fossapay.com/api/v1/wallets/fiat/create")
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 \"customerId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletName\": \"<string>\",\n \"walletReference\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"status": "success",
"statusCode": 201,
"message": "Fiat wallet created successfully",
"data": {
"walletId": "33333333-3333-4333-8333-333333333333",
"bankName": "Example Bank",
"bankCode": "000000",
"accountName": "John Doe",
"accountNumber": "9710000000"
}
}
{
"status": "error",
"statusCode": 400,
"message": "Wallet already found for customer"
}
Virtual Wallets
Create Wallet
Provision the single NGN wallet allowed for a merchant-owned customer
POST
/
api
/
v1
/
wallets
/
fiat
/
create
Create an NGN wallet for a customer
curl --request POST \
--url https://api-production.fossapay.com/api/v1/wallets/fiat/create \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"customerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletName": "<string>",
"walletReference": "<string>"
}
'import requests
url = "https://api-production.fossapay.com/api/v1/wallets/fiat/create"
payload = {
"customerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"walletName": "<string>",
"walletReference": "<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({
customerId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
walletName: '<string>',
walletReference: '<string>'
})
};
fetch('https://api-production.fossapay.com/api/v1/wallets/fiat/create', 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-production.fossapay.com/api/v1/wallets/fiat/create",
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([
'customerId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'walletName' => '<string>',
'walletReference' => '<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-production.fossapay.com/api/v1/wallets/fiat/create"
payload := strings.NewReader("{\n \"customerId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletName\": \"<string>\",\n \"walletReference\": \"<string>\"\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-production.fossapay.com/api/v1/wallets/fiat/create")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"customerId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletName\": \"<string>\",\n \"walletReference\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-production.fossapay.com/api/v1/wallets/fiat/create")
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 \"customerId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"walletName\": \"<string>\",\n \"walletReference\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"status": "success",
"statusCode": 201,
"message": "Fiat wallet created successfully",
"data": {
"walletId": "33333333-3333-4333-8333-333333333333",
"bankName": "Example Bank",
"bankCode": "000000",
"accountName": "John Doe",
"accountNumber": "9710000000"
}
}
{
"status": "error",
"statusCode": 400,
"message": "Wallet already found for customer"
}
Request
string
required
Active production API key belonging to the customer’s merchant.
string
required
FossaPay customer UUID. The customer must belong to the authenticated merchant.
string
required
Non-empty wallet display name.
string
required
Non-empty correlation reference generated and stored by your system.
Request Example
curl -X POST https://api-production.fossapay.com/api/v1/wallets/fiat/create \
-H "x-api-key: $FOSSAPAY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"customerId": "11111111-1111-4111-8111-111111111111",
"walletName": "John Doe",
"walletReference": "wallet-customer-1042"
}'
const response = await fetch('https://api-production.fossapay.com/api/v1/wallets/fiat/create', {
method: 'POST',
headers: {
'x-api-key': process.env.FOSSAPAY_API_KEY,
'Content-Type': 'application/json'
},
body: JSON.stringify({
customerId: '11111111-1111-4111-8111-111111111111',
walletName: 'John Doe',
walletReference: 'wallet-customer-1042'
})
});
const data = await response.json();
const wallet = data.data;
import os
import requests
url = "https://api-production.fossapay.com/api/v1/wallets/fiat/create"
headers = {
"x-api-key": os.environ["FOSSAPAY_API_KEY"],
"Content-Type": "application/json"
}
data = {
"customerId": "11111111-1111-4111-8111-111111111111",
"walletName": "John Doe",
"walletReference": "wallet-customer-1042"
}
response = requests.post(url, headers=headers, json=data)
data = response.json()
wallet = data["data"]
Response
string
success for a successful request.number
HTTP status code. Successful creation returns
201.string
Human-readable response message
object
Response Example
{
"status": "success",
"statusCode": 201,
"message": "Fiat wallet created successfully",
"data": {
"walletId": "33333333-3333-4333-8333-333333333333",
"bankName": "Example Bank",
"bankCode": "000000",
"accountName": "John Doe",
"accountNumber": "9710000000"
}
}
{
"status": "error",
"statusCode": 400,
"message": "Wallet already found for customer"
}
Errors
| Status | Typical cause |
|---|---|
400 | Customer not found, existing wallet, missing provider reference, or wallet provider failure |
401 | Missing or invalid API key |
422 | Invalid customer UUID or missing request field |
5xx | Temporary platform or provider failure; reconcile before retrying |
Store the wallet ID, assigned account details, and your wallet reference. Wallet creation does not provide idempotency semantics.
Authorizations
Body
application/json

