AgentSkillsCN

kiro-agent-schema

完整 Kiro 代理配置架构参考。适用于创建或修改代理的 JSON 配置时使用。

SKILL.md
--- frontmatter
name: kiro-agent-schema
description: Complete Kiro agent configuration schema reference. Use when creating or modifying agent JSON configs.

Kiro Agent Configuration Schema

File Location

  • Local: .kiro/agents/<name>.json
  • Global: ~/.kiro/agents/<name>.json
  • Local takes precedence over global with same name

Fields

FieldTypeRequiredDescription
namestringyesAgent identifier
descriptionstringnoHuman-readable description
promptstringnoSystem prompt (inline or file:///path)
toolsarraynoAvailable tool names
allowedToolsarraynoAuto-approved tools (supports wildcards)
toolsSettingsobjectnoPer-tool configuration
resourcesarraynoContext files (file:// and skill:// URIs)
hooksobjectnoCommands at trigger points
mcpServersobjectnoMCP server configurations
toolAliasesobjectnoRemap tool names
modelstringnoModel ID override
keyboardShortcutstringnoKeyboard shortcut (e.g., ctrl+shift+a)
welcomeMessagestringnoMessage shown on agent switch
useLegacyMcpJsonbooleannoInclude legacy MCP configs

Tool Names

Built-in: fs_read, fs_write, execute_bash, grep, glob, code, use_aws, introspect, knowledge, thinking, todo_list, delegate

allowedTools Patterns

  • Exact: "fs_read"
  • Wildcard: "fs_*", "*_bash"
  • MCP tool: "@server/tool_name", "@server/read_*"
  • All MCP: "@server"
  • All built-in: "@builtin"

Hook Triggers

  • agentSpawn — agent initializes
  • userPromptSubmit — user sends message
  • preToolUse — before tool (supports matcher)
  • postToolUse — after tool (supports matcher)
  • stop — assistant finishes

Resources URI Schemes

  • file://path — always loaded
  • skill://path — progressively loaded (requires YAML frontmatter)
  • Both support glob patterns