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

# Environments

> Use sandbox keys for integration tests and live keys for paid processing.

AI Gen Studio API keys belong to one environment.

| Environment | Prefix             | Behavior                                                                 |
| ----------- | ------------------ | ------------------------------------------------------------------------ |
| Sandbox     | `aigs_sandbox_...` | Validates requests and returns simulated jobs without consuming credits. |
| Live        | `aigs_live_...`    | Reserves paid credits and processes production jobs.                     |

## Sandbox checklist

Use sandbox keys to test:

* authentication;
* request validation;
* idempotent create retries;
* job polling;
* webhook handling;
* error parsing.

Sandbox responses use the same shape as live responses.

## Live checklist

Before switching to live keys:

* verify your backend stores `job.id` and `external_id` mappings;
* handle `partially_completed` jobs;
* verify webhook signatures;
* handle `402`, `409`, and `429` responses;
* ensure paid credits are available.
