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

# Initialize slack sandbox with data

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

Initialize the sandbox with slack-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

- SlackDataInput — Complete Slack sandbox data structure. Hierarchy: - Channels contain Messages - Messages can have Reactions and Replies (threads)
  - `channels` SlackChannelInput[], nullable — List of channels
    - `name` string, required — Channel name
    - `description` string, nullable — Channel description/purpose
    - `is_private` boolean — Whether the channel is private
    - `messages` SlackMessageInput[], nullable — Messages in this channel
      - `text` string, required — Message text content
      - `reactions` SlackReactionInput[], nullable — Reactions to this message
        - `name` string, required — Emoji name (without colons, e.g., 'thumbsup')
      - `replies` SlackMessageInput[], nullable — Thread replies to this message

## 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/revisions/1f05ced7280f/schema)
