Skip to content

DotCraft Configuration Guide

This page is for the first configuration pass: where config files live, how they merge, and which fields matter most. For every field, see Full Configuration Reference. For file, shell, sandbox, and network boundaries, see Security Configuration.

Quick Start

A minimal working configuration only needs model provider details:

json
{
  "ApiKey": "sk-your-api-key",
  "Model": "gpt-4o-mini",
  "EndPoint": "https://api.openai.com/v1"
}

Recommended placement:

SettingLocationWhy
API key~/.craft/config.jsonKeeps secrets out of project repositories
Project model overrides<workspace>/.craft/config.jsonLets each project choose its own model and tools
Dashboard / Automations / Gateway<workspace>/.craft/config.jsonThese usually belong to the project workflow

If you are unsure: put the API key globally and project-specific behavior in the workspace.

Configuration

DotCraft reads two configuration layers:

Config filePathPurpose
Global config~/.craft/config.jsonPersonal defaults such as API key, model, and language
Workspace config<workspace>/.craft/config.jsonProject-specific model overrides, tools, entry points, and automations

Merge Rules

  • Global config provides the base.
  • Workspace config overrides global config.
  • Fields missing from the workspace keep the global value.

Example

Global config stores your default API key and model:

json
{
  "ApiKey": "sk-your-default-api-key",
  "Model": "gpt-4o-mini",
  "EndPoint": "https://api.openai.com/v1"
}

Workspace config overrides the current project:

json
{
  "Model": "deepseek-chat",
  "EndPoint": "https://api.deepseek.com/v1",
  "DashBoard": {
    "Enabled": true
  },
  "Automations": {
    "Enabled": true
  }
}

DotCraft will use the global ApiKey and the workspace Model, EndPoint, Dashboard, and Automations settings.

Common Fields

FieldDescriptionDefault
ApiKeyOpenAI-compatible API keyEmpty
ModelDefault model namegpt-4o-mini
EndPointAPI endpoint URLhttps://api.openai.com/v1
LanguageUI language: Chinese / EnglishChinese
EnabledToolsGlobally enabled tool names. Empty enables all tools[]
DebugModePrints untruncated tool arguments in the consolefalse

DotCraft's base identity is built in. To customize project instructions, working norms, or long-term memory, prefer workspace files such as .craft/AGENTS.md, .craft/SOUL.md, and .craft/MEMORY.md.

Usage Examples

GoalNext step
Configure API key and default modelEdit global ~/.craft/config.json
Use a different model for one projectEdit that project's .craft/config.json
Limit file, shell, or network capabilityRead Security Configuration
Configure SubAgent roles, profiles, and recursion depthRead SubAgent Configuration Guide
See every configuration fieldRead Full Configuration Reference
Inspect merged configuration in the UIOpen the Settings page in Dashboard

Advanced Topics

Startup Settings

AppServer, Gateway, API, AG-UI, external channels, ports, and Dashboard listen addresses are read when a Host starts. Restart the relevant Host or Desktop background process after changing them.

Runtime Settings

Model, tool filtering, language, and some Agent behavior usually affect new sessions. Whether an existing session changes immediately depends on the entry point and client reload behavior.

Security Boundary

File access, shell execution, sandboxing, blacklists, and outside-workspace approval are security boundaries. Read Security Configuration before exposing DotCraft through external channels, automations, or network-accessible services.

Troubleshooting

Config is written but not applied

Check the layer first: personal defaults go in global config, project behavior goes in workspace config. Startup settings require restarting the relevant Host.

You do not want API keys committed to the repository

Put ApiKey in global ~/.craft/config.json. Keep workspace config limited to model, endpoint, and project features.

Dashboard or API ports conflict

Change DashBoard.Port, Api.Port, AgUi.Port, or use Gateway to share a port. Port fields are startup settings and require a restart.

Tool access is rejected

Check Security.BlacklistedPaths, Tools.File.RequireApprovalOutsideWorkspace, Tools.Shell.RequireApprovalOutsideWorkspace, and sandbox settings.

Apache License 2.0