# Developer Sandbox

Cash App provides a sandbox environment for developers to test integrations without moving money. This environment can be reached by using the sandbox.api.cash.app host.

This environment has a separate set of credentials from production.

The sandbox can be controlled through magic values (documented below) in order to produce certain behaviors. In other cases, API responses will represent successful actions when given valid requests.

<Note>
  We have a 5-year full backwards compatibilty guarantee that extends to our publicly documented Sandbox Magic Values listed on this page.
</Note>

## Magic Values

### [Create payment](/cash-app-pay-partner-api/api-reference/network-api/create-payment)

| Field        | Value                 | Result                                         | Description                                                                                                                                                                                                                                                                                                                                                                                                           |
| ------------ | --------------------- | ---------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| amount       | 6670                  | Connection Error                               | The payment will be created but the response will be an HTTP error. This simulates potential network failures.<br /><br />The state of the payment can be retrieved using [retrieve payment](/cash-app-pay-partner-api/api-reference/network-api/retrieve-payment). <br /><br />The request can also be  voided through the [void payment](/cash-app-pay-partner-api/api-reference/network-api/void-payment) endpoint |
| amount       | 7770                  | Payment decline: compliance failure            | The payment will be created in a declined state, with the reason PAYMENT\_DECLINED\_COMPLIANCE                                                                                                                                                                                                                                                                                                                        |
| amount       | 7771                  | Payment decline: insufficient funds            | The payment will be created in a declined state, with the reason PAYMENT\_DECLINED\_INSUFFICIENT\_FUNDS                                                                                                                                                                                                                                                                                                               |
| amount       | 7772                  | Payment decline: other                         | The payment will be created in a declined state, with the reason PAYMENT\_DECLINED\_OTHER                                                                                                                                                                                                                                                                                                                             |
| amount       | 7773                  | Payment decline: risk                          | The payment will be created in a declined state, with the reason PAYMENT\_DECLINED\_RISK                                                                                                                                                                                                                                                                                                                              |
| amount       | 7774                  | Payment decline: too large                     | The payment will be created in a declined state, with the reason PAYMENT\_INVALID\_TOO\_LARGE                                                                                                                                                                                                                                                                                                                         |
| amount       | 7775                  | Payment decline: too small                     | The payment will be created in a declined state, with the reason PAYMENT\_INVALID\_TOO\_SMALL                                                                                                                                                                                                                                                                                                                         |
| merchant\_id | MMI\_sandbox:disabled | Payment creation failure: merchant is disabled | The payment will not be created, returning an error of MERCHANT\_DISABLED.                                                                                                                                                                                                                                                                                                                                            |
| merchant\_id | MMI\_sandbox:pending  | Payment creation failure: merchant is pending  | The payment will not be created, returning an error of MERCHANT\_PENDING                                                                                                                                                                                                                                                                                                                                              |
| merchant\_id | MMI\_sandbox:missing  | Payment creation failure: merchant is missing  | The payment will not be created, returning an error of MERCHANT\_NOT\_FOUND                                                                                                                                                                                                                                                                                                                                           |
| grant\_id    | GRG\_sandbox:active   | Payment created                                | The payment will be created.                                                                                                                                                                                                                                                                                                                                                                                          |
| grant\_id    | GRG\_sandbox:consumed | Payment decline: grant error                   | The payment will be created in a declined state, with the reason GRANT\_CONSUMED                                                                                                                                                                                                                                                                                                                                      |
| grant\_id    | GRG\_sandbox:expired  | Payment decline: grant error                   | The payment will be created in a declined state, with the reason GRANT\_EXPIRED                                                                                                                                                                                                                                                                                                                                       |
| grant\_id    | GRG\_sandbox:missing  | Payment decline: grant error                   | The payment will be created in a declined state, with the reason GRANT\_NOT\_FOUND                                                                                                                                                                                                                                                                                                                                    |
| grant\_id    | GRG\_sandbox:revoked  | Payment decline: grant error                   | The payment will be created in a declined state, with the reason GRANT\_REVOKED                                                                                                                                                                                                                                                                                                                                       |
| amount       | 8801                  | Create dispute: `CD10`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `CD10`<br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                 |
| amount       | 8802                  | Create dispute: `CD11`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `CD11`<br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                 |
| amount       | 8803                  | Create dispute: `CD12`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `CD12`. <br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                               |
| amount       | 8804                  | Create dispute: `CD13`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `CD13` <br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                |
| amount       | 8811                  | Create dispute: `FR10`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `FR10` <br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                |
| amount       | 8812                  | Create dispute: `FR11`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `FR11`<br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                 |
| amount       | 8821                  | Create dispute: `PE10`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `PE10`<br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                 |
| amount       | 8822                  | Create dispute: `PE11`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `PE11`<br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                 |
| amount       | 8823                  | Create dispute: `PE12`                         | The payment will be created along with a dispute that has a disputed amount equal to the transaction amount and a reason of `PE12`<br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                 |
| amount       | 8901                  | Create dispute: differing disputed amount      | The payment will be created along with a dispute that has a disputed amount different from the payment amount<br /><br />The dispute can be queried through the [List Disputes](/cash-app-pay-partner-api/api-reference/network-api/list-disputes) API two seconds after the payment is created.                                                                                                                      |

### [Create refund](/cash-app-pay-partner-api/api-reference/network-api/create-refund)

| Field     | Value                 | Result                         | Description                                                                                                                                                                                                                                                                                                                                                                                                     |
| --------- | --------------------- | ------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| amount    | 6670                  | Connection Error               | The refund will be created but the response will be an HTTP error. This simulates potential network failures.<br /><br />The state of the refund can be retrieved using [retrieve refund](/cash-app-pay-partner-api/api-reference/network-api/retrieve-refund). <br /><br />The request can also be  voided through the [void refund](/cash-app-pay-partner-api/api-reference/network-api/void-refund) endpoint |
| amount    | 7770                  | Refund decline: compliance     | The refund will be created in a declined state, with the reason REFUND\_DECLINED\_COMPLIANCE                                                                                                                                                                                                                                                                                                                    |
| amount    | 7772                  | Refund decline: other          | The refund will be created in a declined state, with the reason REFUND\_DECLINED\_OTHER                                                                                                                                                                                                                                                                                                                         |
| amount    | 7773                  | Refund decline: risk           | The refund will be created in a declined state, with the reason REFUND\_DECLINED\_RISK                                                                                                                                                                                                                                                                                                                          |
| amount    | 7774                  | Refund decline: too large      | The refund will be created in a declined state, with the reason REFUND\_DECLINED\_TOO\_LARGE                                                                                                                                                                                                                                                                                                                    |
| amount    | 7775                  | Refund decline: too small      | The refund will be created in a declined state, with the reason REFUND\_DECLINED\_TOO\_SMALL                                                                                                                                                                                                                                                                                                                    |
| amount    |                       |                                |                                                                                                                                                                                                                                                                                                                                                                                                                 |
| grant\_id | GRG\_sandbox:consumed | Refund failure: grant consumed | The refund will be created in a declined state, with the reason GRANT\_CONSUMED                                                                                                                                                                                                                                                                                                                                 |
| grant\_id | GRG\_sandbox:expired  | Refund failure: grant expired  | The refund will be created in a declined state, with the reason GRANT\_EXPIRED                                                                                                                                                                                                                                                                                                                                  |
| grant\_id | GRG\_sandbox:missing  | Refund failure: grant missing  | The refund will be created in a declined state, with the reason GRANT\_NOT\_FOUND                                                                                                                                                                                                                                                                                                                               |
| grant\_id | GRG\_sandbox:revoked  | Refund failure: grant revoked  | The refund will be created in a declined state, with the reason GRANT\_REVOKED                                                                                                                                                                                                                                                                                                                                  |

### Create [file-](/cash-app-pay-partner-api/api-reference/network-api/create-dispute-evidence-file) or [text-](/cash-app-pay-partner-api/api-reference/network-api/create-dispute-evidence-text) based dispute evidence

| Field    | Value                                            | Result         | Description                          |
| -------- | ------------------------------------------------ | -------------- | ------------------------------------ |
| metadata | `{"sandbox:set_dispute_state": "PROCESSING"}`    | PROCESSING     | Dispute adjudicated: `PROCESSING`    |
| metadata | `{"sandbox:set_dispute_state": "WON"}`           | WON            | Dispute adjudicated: `WON`           |
| metadata | `{"sandbox:set_dispute_state": "PARTIALLY_WON"}` | PARTIALLY\_WON | Dispute adjudicated: `PARTIALLY_WON` |
| metadata | `{"sandbox:set_dispute_state": "LOST"}`          | LOST           | Dispute adjudicated: `LOST`          |

### API Key (Signed) Requests

| Header      | Value                        | Result                  | Description                                                      |
| ----------- | ---------------------------- | ----------------------- | ---------------------------------------------------------------- |
| X-Signature | sandbox:skip-signature-check | valid request signature | The request will be treated as if it contains a valid signature. |