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

# Sandbox introduction

> Test your API integration against stored fixtures without calling the real data source or spending credit.

Use sandbox mode with predetermined API payloads to retrieve every status an endpoint can return. Each payload is mapped to a specific outcome so you can confirm how your integration handles each result.

This page covers how sandbox works, the matching rules, and the shared response envelopes. The copy-paste payloads for each verification live on their own pages in this section.

## How sandbox works

Sandbox is a property of your company account, not of the URL. When your account is in sandbox mode, the same production endpoints stop calling the real upstream source and answer from stored fixtures instead. Same URLs, same tokens, same authentication.

Sandbox differs from live in exactly two ways:

* The upstream source is never called. The response comes from a fixture.
* No credit is reserved or charged.

> [!NOTE]
>
> A sandbox response is deliberately identical in shape to a live one. There is no `sandbox` or `environment` field to branch on — that is the point, so code you write against sandbox works unchanged in production.

Only endpoints with a page in this section are available in sandbox mode. Any other verification endpoint returns HTTP `400` instead of reaching the upstream source. See [Not available in sandbox](#non-verification-responses) below.

## Going live

Nothing in your integration changes. Your account is switched to live mode and the same calls begin reaching the real sources. There is no URL or token to swap.

## Authentication

Use the same Bearer token you use in live:

```http theme={null}
Authorization: Bearer <your API token>
```

Sandbox mode is resolved from the authenticated company. See [Authentication](https://docs.idmetagroup.com/api-reference/introduction.md#authentication) for how to create a token.

## Trust validations

Sandbox follows the same [process](https://docs.idmetagroup.com/api-reference/introduction.md#processes) as live. Every verification request belongs to a trust validation:

1. Use a `trustFlowId` whose trust flow has the verification enabled.
2. Create a trust validation with [Create verification](https://docs.idmetagroup.com/api-reference/processes/create-verification/overview.md) and send its ID as `trustValidationId`.
3. Run the verification with a payload from its sandbox page.

The trust validation, its status and its results are stored exactly as in live, so you can retrieve and finalize them with the usual process endpoints.

## Matching rules

Each sandbox page names the field that selects the scenario, such as `businessIdentificationNumber` for most KYB endpoints or `licenseNumber` for Philippines Driving License. Some endpoints select on more than one field, such as `clearanceNo` and `surname` for Philippines National Police, and then all of them must match. Your value for that field must match one of the documented requests exactly to get that scenario's response.

Australia DVS endpoints match on every field in the request body instead of one, so the whole payload must match a documented request.

| Rule | Behaviour |
| - | - |
| Value case | **Case-sensitive.** The value must match the documented one exactly. |
| Other fields | KYB: ignored for matching. Australia DVS: every field in the request body is matched, including optional ones. In both, `trustFlowId`, `trustValidationId` and `resultNotificationURL` only need to be valid. |
| Dates | Australia DVS accepts `dob` and `doe` as `DD-MM-YYYY` or `YYYY-MM-DD`. Every other date must be sent in the format shown on its sandbox page. |
| Unlisted values | Each sandbox page shows what a value it does not list returns. |

> [!WARNING]
>
> Testing with your own real details is expected to come back as a no-match. The sandbox has no records to check against, only the documented scenarios. This is not an error and does not mean your integration is wrong.

## PhilSys face liveness

[PhilSys Check](https://docs.idmetagroup.com/api-reference/sandbox/philippines-philsys-check-tier-2.md) and [PhilSys Check Tier 1](https://docs.idmetagroup.com/api-reference/sandbox/philippines-philsys-check-tier-1.md) require a `face_liveness_session_id`. In sandbox, any valid UUID is accepted, including the session ID from a real face liveness capture in the IDmeta SDK or web flow. The scenario is selected by `pcn`, `qr_data` or `pcnFormData` alone, so you can pair a real face scan with any documented sandbox identity.

The one exception is `00000000-0000-4000-8000-000000000000`. Send it with the documented PCN to get the liveness-failed response.

## Asynchronous endpoints

Endpoints that are asynchronous in live are also asynchronous in sandbox. The HTTP response has `verificationStatus` set to `IN_PROGRESS`, and the full result follows as a webhook to your `resultNotificationURL` and to your trust flow's webhook URL, if one is set. In sandbox the webhook is sent within a few seconds of the HTTP response.

Each sandbox page shows both the HTTP response and the webhook payload.

## Response placeholders

The sample responses on the sandbox pages use placeholders for values that change on every call:

| Field | Meaning |
| - | - |
| `trustValidationId` | The ID you sent, echoed back. |
| `trustFlowId` | The ID you sent, echoed back. The samples use `<your trust flow id>`. |
| `metadata` | The metadata stored on your trust validation. `null` if there is none. |
| `createdAt` | The UTC timestamp of your request. The literal string shown is a placeholder. |

## Non-verification responses

These responses are produced before — or instead of — a verification result, so they carry no `verificationStatus`, `verificationStatusCode`, or `data`.

> [accordion] Validation failure — HTTP 400
>
> Returned when the request body fails field validation. This happens **before** any fixture matching, so it is identical in sandbox and live. `message` is the first validation error.
>
> ```json theme={null}
> {
>   "success": false,
>   "message": "The business identification number field is required.",
>   "errors": {
>     "businessIdentificationNumber": ["The business identification number field is required."]
>   },
>   "createdAt": "<UTC timestamp of the request>"
> }
> ```

> [accordion] Not available in sandbox — HTTP 400
>
> Returned when your account is in sandbox mode and the endpoint has no sandbox page. The request is not sent to the upstream source. The plan name in `message` is the one you called.
>
> ```json theme={null}
> {
>   "success": false,
>   "message": "malaysia_kyb_lite is not available in sandbox mode",
>   "errors": [],
>   "createdAt": "<UTC timestamp of the request>"
> }
> ```

> [accordion] Trust validation not found — HTTP 404
>
> Returned when `trustValidationId` does not exist or belongs to another company.
>
> ```json theme={null}
> {
>   "success": false,
>   "message": "Trust Validation Not Found",
>   "errors": {
>     "trustValidation": "Trust Validation Not Found"
>   },
>   "createdAt": "<UTC timestamp of the request>"
> }
> ```

> [accordion] Plan not enabled — HTTP 403
>
> Returned when the authenticated company has no plan for the verification type. The plan gate is enforced in sandbox exactly as in live.
>
> ```json theme={null}
> {
>   "success": false,
>   "message": "Forbidden",
>   "createdAt": "<UTC timestamp of the request>"
> }
> ```

> [accordion] Insufficient credit — HTTP 402
>
> Live only. Sandbox reserves no credit, so this is unreachable there. Note that the field is `error_code`, not `code`.
>
> ```json theme={null}
> {
>   "success": false,
>   "error_code": "INSUFFICIENT_CREDIT",
>   "message": "Insufficient credit for plan <plan name>",
>   "plan": "<plan name>",
>   "createdAt": "<UTC timestamp of the request>"
> }
> ```

> [accordion] Unauthorized — HTTP 401
>
> Returned when the `Authorization` header is missing, malformed, or carries a token that is not valid. Authentication is resolved before anything else, so this envelope is the shortest of all.
>
> ```json theme={null}
> {
>   "message": "Unauthenticated."
> }
> ```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.