FossaPay currently supports production access only. All requests use the production API and can create or affect live financial resources.
What you will build
By the end of this guide, your backend will be able to:- authenticate with FossaPay;
- create a merchant-scoped individual customer;
- create that customer’s dedicated NGN wallet;
- retrieve the wallet using its FossaPay ID; and
- receive and verify signed webhook events.
Prerequisites
Before making requests, you need:- a FossaPay merchant account;
- completed business verification;
- two-factor authentication enabled for API-key management;
- an active production API key from Dashboard → Settings → API Keys; and
curlor an equivalent HTTP client.
fk_production_ prefix. Complete your integration and operational readiness checks before creating financial resources.
1. Configure your environment
For local development, assign the production API URL and API key to shell variables:x-api-key.
2. Verify authentication
List customers to confirm that the key is active and the request is authenticated for the correct merchant:200 with the standard response envelope:
result and the remaining pagination fields depend on existing data. HTTP 401 means the key is missing, invalid, inactive, or unavailable to the request.
3. Create an individual customer
Customer records represent individuals served by your business. Send exactly one name in each name field, and settype to individual.
201 response has this structure:
data.id as the FossaPay customer ID. It is a UUID and is required by customer-scoped wallet and transfer operations.
Response values above are illustrative. Use identifiers and account details from your actual response.
4. Create the customer’s NGN wallet
Create one NGN wallet for the customer using the returned customer UUID:walletReference is your correlation value. Generate it in your system and retain it with the customer mapping.
An HTTP 201 response has this structure:
5. Retrieve the wallet
Retrieve the wallet withdata.walletId from the creation response:
6. Prepare webhook handling
Before accepting live deposits, configure a public HTTPS URL from Dashboard → Settings → Webhooks and store its secret securely. FossaPay signs exactlyJSON.stringify(body.data) with HMAC-SHA256. The lowercase hexadecimal result is sent in x-fossapay-Signature.
insertWebhookIfNew and queueWebhookProcessing represent your persistence and job-queue implementation. Enforce a unique database constraint on eventId; do not implement deduplication only in application memory.
See Webhooks for the event catalogue, retry schedule, signature rules, and reconciliation guidance.
Error handling
FossaPay returns errors using an HTTP status and structured JSON body:
For write requests, distinguish a confirmed rejection from an ambiguous network failure. Never create a second financial operation solely because the original response was lost.
Production readiness
Before processing customer funds:- confirm business verification and production API-key access;
- use a production HTTPS webhook endpoint;
- store API keys and webhook secrets in production secret management;
- verify signature rejection, duplicate delivery, and queue recovery behavior;
- persist FossaPay IDs and your references for every operation;
- monitor API errors, webhook delivery failures, and pending transactions; and
- begin with controlled amounts and reconcile each result.
Next steps
Authentication
Understand API-key security and idempotency.
NGN collections
Receive and reconcile customer deposits.
Checkout Wallet
Accept exact-amount, one-time NGN payments.
NGN transfers
Move customer or business funds using the correct flow.

