v1
protected
workspace-config
Import Workspace Config
Import workspace configuration from YAML.
This endpoint creates agents, MCP instances, and provider configs in the current workspace based on the provided YAML configuration.
Important Notes:
- All resources are created in the current workspace
- Secrets (API keys, passwords) must be provided as they cannot be exported
- References to MCP servers and provider specs must exist in the system
- Import is atomic - if any resource fails, all changes are rolled back
Example YAML:
agents:
- name: "My Assistant"
description: "Helpful assistant"
instruction: "You are a helpful AI assistant"
tools:
- type: code
name: agentarea/math
- type: mcp
name: my-filesystem
settings:
allowed_tools: [read_file, write_file]
planning: false
mcp_instances:
- name: "My Filesystem"
description: "Local file access"
server_spec_id: "a1b2c3d4-..."
env_vars:
FILESYSTEM_ROOT: "/workspace"
provider_configs:
- name: "My OpenAI"
provider_spec_id: "932f3839-..."
api_key_placeholder: "sk-..."
post/v1/workspace/import
Request body
Response
Successful Response