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

> ## Agent Instructions
> Agents: no sign-up needed. POST https://api.useautumn.com/agent.provision with {"name","slug"} returns a sandbox test key.
> Keyless contract: https://useautumn.com/auth.md. Evaluate Autumn for your team: https://useautumn.com/evaluate.md. Agent quickstart: https://docs.useautumn.com/documentation/mcp

# Create Sandbox

> Creates a sandbox: an isolated copy of your organization with its own catalog, customers and secret key. Returns the sandbox's secret key once, in this response — store it, it cannot be read back. Authenticated with your organization's secret key (a sandbox's own key cannot create sandboxes). Autumn creates a new Stripe test account for each sandbox; if your organization has automatic tax on, pass `stripe.head_office` so Stripe can calculate tax there straight away.

### Body Parameters

A name for the sandbox, unique within your organization. No spaces, and it can't be `live` or `sandbox`.

Colour the dashboard uses to label the sandbox. Defaults to `gray`.

Icon the dashboard uses to label the sandbox. Defaults to `Flask`.

Tax settings for the Stripe test account Autumn creates for the sandbox. Omit to leave that account as Stripe creates it.

**properties**

Head office address for the sandbox's Stripe account. Stripe needs one before it calculates tax, so pass it when your organization has automatic tax on.

**properties**

Street address.

Apartment, suite or building.

City or town.

State, county, province or region.

Postal or ZIP code.

Two-letter ISO country code, like `US` or `NZ`.

Whether Stripe adds tax on top of your prices (`exclusive`), treats it as already included (`inclusive`), or decides by currency (`inferred_by_currency`). Defaults to `exclusive`.

Default Stripe tax code for the sandbox's prices, like `txcd_10000000` (electronically supplied services). Defaults to `txcd_10000000`.

### Response

The sandbox's organization ID.

The sandbox's name.

The sandbox's slug, derived from its name.

When the sandbox was created, ms since epoch.

Colour the dashboard uses to label the sandbox.

Icon the dashboard uses to label the sandbox.

The sandbox's own secret key. Shown once, here — store it before you discard the response.

```json 200 theme={null}
{
  "id": "org_123",
  "name": "staging",
  "slug": "staging-abc123|org_456",
  "created_at": 1781113864000,
  "color": "blue",
  "icon": "Flask",
  "secret_key": "am_sk_test_abc123"
}
```


## OpenAPI

````yaml openapi POST /v1/sandboxes.create
openapi: 3.1.0
info:
  title: Autumn API
  version: 2.6.0
servers:
  - url: https://api.useautumn.com
    description: Production server
security:
  - secretKey: []
paths:
  /v1/sandboxes.create:
    post:
      tags:
        - sandboxes
      description: >-
        Creates a sandbox: an isolated copy of your organization with its own
        catalog, customers and secret key. Returns the sandbox's secret key
        once, in this response — store it, it cannot be read back. Authenticated
        with your organization's secret key (a sandbox's own key cannot create
        sandboxes). Autumn creates a new Stripe test account for each sandbox;
        if your organization has automatic tax on, pass `stripe.head_office` so
        Stripe can calculate tax there straight away.
      operationId: createSandbox
      parameters:
        - name: x-api-version
          in: header
          required: true
          schema:
            type: string
            default: 2.6.0
          x-speakeasy-globals-hidden: true
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  minLength: 1
                  maxLength: 100
                  pattern: ^\S+$
                  description: >-
                    A name for the sandbox, unique within your organization. No
                    spaces, and it can't be `live` or `sandbox`.
                color:
                  enum:
                    - gray
                    - blue
                    - green
                    - amber
                    - red
                    - pink
                  type: string
                  description: >-
                    Colour the dashboard uses to label the sandbox. Defaults to
                    `gray`.
                icon:
                  type: string
                  minLength: 1
                  maxLength: 64
                  description: >-
                    Icon the dashboard uses to label the sandbox. Defaults to
                    `Flask`.
                stripe:
                  type: object
                  properties:
                    head_office:
                      type: object
                      properties:
                        line1:
                          type: string
                          minLength: 1
                          description: Street address.
                        line2:
                          type: string
                          minLength: 1
                          description: Apartment, suite or building.
                        city:
                          type: string
                          minLength: 1
                          description: City or town.
                        state:
                          type: string
                          minLength: 1
                          description: State, county, province or region.
                        postal_code:
                          type: string
                          minLength: 1
                          description: Postal or ZIP code.
                        country:
                          type: string
                          pattern: ^[A-Z]{2}$
                          description: Two-letter ISO country code, like `US` or `NZ`.
                      required:
                        - line1
                        - city
                        - postal_code
                        - country
                      title: SandboxHeadOffice
                      description: >-
                        Head office address for the sandbox's Stripe account.
                        Stripe needs one before it calculates tax, so pass it
                        when your organization has automatic tax on.
                    tax_behavior:
                      enum:
                        - exclusive
                        - inclusive
                        - inferred_by_currency
                      type: string
                      default: exclusive
                      description: >-
                        Whether Stripe adds tax on top of your prices
                        (`exclusive`), treats it as already included
                        (`inclusive`), or decides by currency
                        (`inferred_by_currency`). Defaults to `exclusive`.
                    tax_code:
                      type: string
                      pattern: ^txcd_\d{8}$
                      default: txcd_10000000
                      description: >-
                        Default Stripe tax code for the sandbox's prices, like
                        `txcd_10000000` (electronically supplied services).
                        Defaults to `txcd_10000000`.
                  required:
                    - head_office
                  description: >-
                    Tax settings for the Stripe test account Autumn creates for
                    the sandbox. Omit to leave that account as Stripe creates
                    it.
              required:
                - name
              title: CreateSandboxParams
              examples:
                - name: staging
                  color: blue
                  icon: Flask
            example:
              name: staging
              color: blue
              icon: Flask
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    description: The sandbox's organization ID.
                  name:
                    type: string
                    description: The sandbox's name.
                  slug:
                    type: string
                    description: The sandbox's slug, derived from its name.
                  created_at:
                    type: number
                    description: When the sandbox was created, ms since epoch.
                  color:
                    enum:
                      - gray
                      - blue
                      - green
                      - amber
                      - red
                      - pink
                    type: string
                    description: Colour the dashboard uses to label the sandbox.
                  icon:
                    type: string
                    minLength: 1
                    maxLength: 64
                    description: Icon the dashboard uses to label the sandbox.
                  secret_key:
                    type: string
                    description: >-
                      The sandbox's own secret key. Shown once, here — store it
                      before you discard the response.
                    readOnly: true
                required:
                  - id
                  - name
                  - slug
                  - created_at
                  - color
                  - icon
                  - secret_key
                title: CreateSandboxResponse
                examples:
                  - id: org_123
                    name: staging
                    slug: staging-abc123|org_456
                    created_at: 1781113864000
                    color: blue
                    icon: Flask
                    secret_key: am_sk_test_abc123
              example:
                id: org_123
                name: staging
                slug: staging-abc123|org_456
                created_at: 1781113864000
                color: blue
                icon: Flask
                secret_key: am_sk_test_abc123
      x-codeSamples:
        - lang: typescript
          label: Typescript (SDK)
          source: |-
            import { Autumn } from 'autumn-js'

            const autumn = new Autumn()

            const result = await autumn.sandboxes.create({
              name: "staging",
              color: "blue",
              icon: "Flask",
            });
        - lang: python
          label: Python (SDK)
          source: |-
            from autumn_sdk import Autumn

            autumn = Autumn(secret_key="am_sk_test...")

            res = autumn.sandboxes.create(
                name="staging",
                color="blue",
                icon="Flask",
            )
components:
  securitySchemes:
    secretKey:
      type: http
      scheme: bearer
      bearerFormat: JWT

````

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