> ## Documentation Index
> Fetch the complete documentation index at: https://docs.zerocash.tech/llms.txt
> Use this file to discover all available pages before exploring further.

# Testing payouts

> Sandbox account numbers that simulate successful and failed payouts.

In the sandbox, the **recipient account number** selects the outcome. Bank codes and account names
can be any value.

## Successful payouts

<CodeGroup>
  ```json Bank account theme={null}
  {
    "payoutMethod": {
      "accountName": "Test User",
      "accountNumber": "1234567890",
      "code": "07"
    }
  }
  ```

  ```json Mobile money theme={null}
  {
    "payoutMethod": {
      "accountName": "Test User",
      "accountNumber": "254712345678"
    }
  }
  ```
</CodeGroup>

| Destination  | Account number | Bank code | Account name |
| :----------- | :------------- | :-------- | :----------- |
| Bank Account | `1234567890`   | Any code  | Any name     |
| MoMo         | `254712345678` | —         | Any name     |

## Failed payouts

<CodeGroup>
  ```json Bank account theme={null}
  {
    "payoutMethod": {
      "accountName": "Test User",
      "accountNumber": "0987654321",
      "code": "07"
    }
  }
  ```

  ```json Mobile money theme={null}
  {
    "payoutMethod": {
      "accountName": "Test User",
      "accountNumber": "254787654321"
    }
  }
  ```
</CodeGroup>

| Destination  | Account number | Bank code |
| :----------- | :------------- | :-------- |
| Bank Account | `0987654321`   | Any code  |
| MoMo         | `254787654321` | —         |

## Scenario reference

| Scenario                 | Destination    | Account number | Bank code | Expected result |
| :----------------------- | :------------- | :------------- | :-------- | :-------------- |
| Successful bank transfer | `Bank Account` | `1234567890`   | any       | Success         |
| Successful mobile money  | `MoMo`         | `254712345678` | —         | Success         |
| Failed bank account      | `Bank Account` | `0987654321`   | any       | Failed          |
| Failed mobile money      | `MoMo`         | `254787654321` | —         | Failed          |

## A complete sandbox payout

```bash theme={null}
curl --request POST \
  --url https://api.zerocash.tech/api/b2b/fiat/payout \
  --header 'Authorization: Bearer YOUR_SANDBOX_BEARER_TOKEN' \
  --header 'content-type: application/json' \
  --data '{
    "amount": 100,
    "currency": "KES",
    "country": "KE",
    "externalReference": "sandbox-payout-001",
    "destination": "MoMo",
    "payoutMethod": {
      "accountName": "Test User",
      "accountNumber": "254712345678"
    }
  }'
```

<Warning>
  Use a new `externalReference` for every attempt. Reusing one returns
  `409 DUPLICATE_EXTERNAL_REFERENCE` rather than creating a second payout — correct behaviour, but
  it will look like a failure if you are not expecting it.
</Warning>

## Confirm the outcome

The initiation response is an acknowledgement, not a result. Confirm through a
`payout_updated` webhook or by polling
[Get Transaction](/api-reference/endpoint/get-transaction).

<Tip>
  Test the **failure** fixture as deliberately as the success one. Payout failures are where most
  production incidents start — make sure your reconciliation handles a `failed` status and its
  `failureReason` before you go live.
</Tip>
