Skip to main content
The Strails sandbox environment lets you exercise every API endpoint with real request/response cycles without touching live funds. Use your sandbox API key (issued during onboarding) and the base URL https://api.strails.io/v1/ for all test requests. Sandbox state is isolated from production - you can freely create users, trigger transactions, and inspect webhook payloads without consequence.

Required Headers

Include these three headers on every request:
The API key header name is lowercase x-api-key. Sending X-Api-Key or Authorization will return a 401 Unauthorized error.

Test Scenarios

Work through the scenarios below in order. Each builds on the data returned by the previous step.

Postman Collection

A ready-to-import Postman collection covering all endpoints is available at github.com/wrappedcbdc/strails-docs/blob/main/postman-collection.json.
To use the collection:
  1. Download postman-collection.json from the repository.
  2. Open Postman and select Import -> Upload Files.
  3. Create a new Postman environment and add two variables:
  4. Select your new environment from the environment dropdown before sending any request.
The raw collection file contains a repository-specific first line that must be removed before importing into Newman or other CLI clients. Run sed '1d' postman-collection.json > clean-collection.json to produce a clean copy.

Testing Tips

  • Start with small amounts. Use values between ₦100 and ₦500 for onramp and offramp tests so that any misconfigured amount format (e.g. accidentally sending Naira on a token endpoint) is immediately obvious from the response.
  • Use webhook.site or ngrok to receive webhooks. Visit webhook.site to get a temporary HTTPS URL, or run ngrok http 3000 to expose a local server. Configure the URL via /setwebhook before running your onramp or offramp scenarios.
  • Test BVNs must be exactly 11 digits. Any BVN shorter or longer than 11 digits will fail validation with a 01 VALIDATION_ERROR response before the BVN lookup even runs.
  • Virtual accounts expire after 30 minutes. If your test transfer simulation times out, call /cngnonramp again to generate a fresh virtual account.