Sandbox Guide

Test your Payzava integration without real money

The sandbox environment lets you test your Payzava integration without processing real transactions. No real money moves in sandbox mode.

Sandbox base URL

https://sandbox.payzava.com/cp/api/v1

Getting a sandbox API key

  1. Log in to the Sandbox Dashboard
  2. Navigate to Settings → Development Info
  3. Copy your sandbox API key

Sandbox keys follow the format sk_sandbox_XXX-XXXXXXXXXXXX-XXX. They only work with the sandbox base URL.

Sandbox header

When making sandbox requests, include the following header:

x-api-key: sk_sandbox_X7k-aB3cDeFgHiJkL-mN9
Content-Type: application/json

The API automatically detects sandbox keys and routes requests to the sandbox environment.

Simulating payments

In sandbox mode, payments are not processed through real MFS providers. Instead, you can trigger a payment completion manually.

Trigger payment completion

POST /sandbox/trigger-payment
const axios = require("axios");

await axios.post(
  "https://sandbox.payzava.com/cp/api/v1/sandbox/trigger-payment",
  {
    transactionId: "YOUR_TRANSACTION_ID",
  },
  {
    headers: {
      "Content-Type": "application/json",
      "x-api-key": "sk_sandbox_X7k-aB3cDeFgHiJkL-mN9",
    },
  }
);

After triggering, call the retrieve endpoint to confirm the status changed to Completed.

Simulating payouts

Similarly, you can trigger payout completion in sandbox mode.

Trigger payout completion

POST /sandbox/trigger-payout
const axios = require("axios");

await axios.post(
  "https://sandbox.payzava.com/cp/api/v1/sandbox/trigger-payout",
  {
    payoutId: "YOUR_PAYOUT_ID",
  },
  {
    headers: {
      "Content-Type": "application/json",
      "x-api-key": "sk_sandbox_X7k-aB3cDeFgHiJkL-mN9",
    },
  }
);

Sandbox info endpoint

You can check your sandbox account details:

GET /sandbox/info
const response = await axios.get(
  "https://sandbox.payzava.com/cp/api/v1/sandbox/info",
  {
    headers: { "x-api-key": "sk_sandbox_X7k-aB3cDeFgHiJkL-mN9" },
  }
);

console.log(response.data);

Differences between sandbox and production

FeatureSandboxProduction
Real moneyNoYes
API key prefixsk_sandbox_public-
Payment processingSimulatedReal MFS providers
Trigger endpointsAvailableNot available

Moving to production

When you are ready to go live:

  1. Log in to the Production Dashboard
  2. Generate your production API key (format: public-XXX-XXXXXXXXXXXX-XXX)
  3. Update your base URL to https://prod.payzava.com/cp/api/v1
  4. Replace your sandbox key with the production key