---
title: "Initialize dropbox sandbox with data"
method: POST
path: "/sandbox/dropbox/{sandbox_id}/initialize"
tags: ["sandbox"]
---

# Initialize dropbox sandbox with data

`POST /sandbox/dropbox/{sandbox_id}/initialize`

Initialize the sandbox with dropbox-specific data following the defined schema.

## Path parameters

- `sandbox_id` string, required — The unique sandbox identifier

## Query parameters

- `init_default_data` boolean — If true, use default test data for initialization

## Request body

- DropboxData — Complete Dropbox sandbox data structure Describes the folder and file structure to be created in the sandbox. Folders are created in the order specified, and files are uploaded after all folders have been created. Note: The root folder /SandboxTest is always created first automatically. Additional folders should be nested within /SandboxTest.
  - `folders` string[], nullable — List of folder paths to create (e.g., ['/SandboxTest', '/SandboxTest/Documents'])
  - `files` DropboxFile[], nullable — List of files to create with their content
    - `path` string, required — Full path to the file (must start with /SandboxTest/)
    - `content` string, required — Text content of the file

## Response `200`

Successful Response

- InitializeSandboxResponse — Response model for sandbox initialization
  - `sandbox_id` string, required — Sandbox identifier
  - `status` 'idle' | 'occupied' | 'error', required — Status of a sandbox instance - matches database enum
  - `message` string, required — Initialization result message

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/klavis-ai/apis/klavis-ai-https-www-klavis-ai.md) · [All operations](https://skmtc.net/klavis-ai/apis/klavis-ai-https-www-klavis-ai/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/klavis-ai/klavis-ai-https-www-klavis-ai/versions/1f05ced7280f/schema)
