Skip to main content
Choose where each call reads and writes, use your sandbox test money, and know what sandbox can’t exercise before you rely on it. For developers deciding where to build and test an integration before going live.
Agents: fetch this page as plain markdown at https://docs.usecleff.com/concepts/environments.md.

Choose an environment

Every Business operates in two parallel environments at once:
  • Sandbox: no money moves and no fees accrue. Open to every Business once its email is verified and its business profile is submitted. Every sandbox payout stops at disbursed. See Know the limits of sandbox.
  • Production: money moves. Open once your Business’s verification (KYB) is approved. See Go live.
Both environments hold the same kinds of data (Beneficiaries, destinations, payouts, webhook endpoints) as two disjoint sets. Nothing you create in sandbox exists in production, and vice versa.

Select the environment with the credential

There is no environment parameter anywhere in the API. The environment comes from the credential making the call:
What a key can see is covered in Scope a key to one Business and environment.

Test the whole payout loop in sandbox

Sandbox runs the complete payout loop: funding, Beneficiary onboarding, approval, dispatch, disbursement and webhooks. Two things work differently by design: Build and test your whole integration in sandbox first; going live is then a credential swap plus a real funding path, not a rewrite.

Use your sandbox test money

Once you create your account and submit your business profile, your sandbox has $1,000,000.00 USD of test money. Sandbox payouts never draw it down. Read the balance with GET /v1/funding/account:
Your sandbox holds $1,000,000.00 USD; available_balance_minor is 100000000 because amounts are in minor units. Set a different balance with POST /v1/business/funding-account/sandbox-balance, using a key with the business_admin role:
Your sandbox now holds $50,000.00 USD. The call sets the balance rather than adding to it, so setting 0 brings SANDBOX_WALLET_UNFUNDED back: sandbox payout creation is refused until you set a balance above zero again. Sent payouts never draw the sandbox balance down. The top-up works only in sandbox: a production key is refused with SANDBOX_ONLY, and a production balance changes only through real deposits to your Cleff Account.

Know the limits of sandbox

Some production behaviour has no sandbox equivalent. Plan to see it for the first time in production, with a small payout:

Next steps

Authentication

Get an API key and send it with every request.

Idempotency

Retry a request safely after a timeout or a 5xx.

Errors

What each error code means and how to fix it.

Webhooks

Receive signed payout and beneficiary events instead of polling.