The sandbox environment uses a dedicated key type to ensure sandbox and production traffic are clearly separated.
Sandbox Key Format #
dmsi_sand_<40 hex characters>
Sandbox keys use the dmsi_sand_ prefix. The authentication middleware routes any token beginning with dmsi_sand_ to the sandbox key validation path before the regular API key check.
Enabling Sandbox Mode and Obtaining a Sandbox Key #
- Navigate to DDLS > Developer > Sandbox.
- Click Enable Sandbox Mode.
- A sandbox API key (
dmsi_sand_<40hex>) is generated and displayed once. Copy it immediately. - To regenerate the sandbox key, click Regenerate Key on the Sandbox screen.
Sandbox Key Behavior #
| Property | Value |
|---|---|
| Rate limiting | Bypassed entirely — sandbox requests are unlimited |
| Database routing | All read/write operations target sandbox mirror tables (dmsi_aapi_sandbox_*) |
| Scope | Sandbox key is created with admin scope |
| Environment header | All sandbox responses include X-DMSI-Environment: sandbox |
Sandbox Environment Response Header #
Every response to a sandbox-authenticated request includes the header:
X-DMSI-Environment: sandbox
This header makes it easy to verify programmatically that requests are hitting the sandbox environment rather than production data.
Sandbox Data #
The sandbox tables are pre-seeded with synthetic test data on first enable:
| Table | Default Records |
|---|---|
dmsi_aapi_sandbox_customers | 10 customers |
dmsi_aapi_sandbox_products | 5 products |
dmsi_aapi_sandbox_licenses | 20 licenses |
dmsi_aapi_sandbox_activations | 50 activations |
To reset the sandbox data to defaults, click Reset Sandbox Data on the Sandbox admin screen.
Part of the DMSI Advanced API v1.0.1 documentation set.
Cross-reference: For API key creation and management, see Part 2 – API Keys. For sandbox environment details, see Part 9 – Sandbox Environment. Note to publisher: update these cross-references to BetterDocs article slugs before publishing.
