OpenProgram Docs

Extension gating

// agent.json
{
  "tools":  {"mode": "automatic", "disabled": ["bash", "*_dangerous"]},
  "skills": {"disabled": ["devops/*"], "allowed": [], "categories": ["research", "writing"]},
  "mcp":    {"disabled": ["slack"], "allowed": [], "required": ["drawio*"]}
}

Fields

FieldtoolsskillsmcpEffect
disabledYesYesYesMatching names are rejected
allowedYesYesYesWhen non-empty, only matches pass
categoriesNoYesNoWhen non-empty, a skill that declares a category must match
requiredNoNoYesAny pattern matching no remaining server stops the turn
modeYesNoNoautomatic (default), selected, none

Patterns use fnmatch.fnmatchcase: *, ?, [abc]; an exact name is the trivial case. mcp patterns match the server name, the part of <server>__<tool> before __. With mode: selected, tools.allowed holds exact names. Plugins are not gated: a plugin is a host-level contributor, and gating applies to the skills, tools and MCP it contributes.

Resolution order

  1. disabled: a match rejects.
  2. allowed, if non-empty: no match rejects.
  3. categories: a non-empty list rejects a categorized skill outside it.
  4. required, MCP only, checked after filtering: an unmatched pattern fails the whole turn.

Why this shape

Claude Code's per-type fields with opencode's wildcard expressiveness. Each field says what it gates; one pattern replaces five names; a new extension type is a new block of the same shape. Comparison: Reference comparison.

Examples

AgentProfileModel sees
Customer service
tools:  {disabled: [write, edit, execute_*, apply_patch]}
skills: {categories: [customer-service, writing]}
mcp:    {disabled: ["*"]}
No edit tools, only those skill categories, no MCP
DevOps
skills: {disabled: [prod-deploy, drop-database]}
mcp:    {required: ["github*", "k8s*"]}
Everything but two skills. Without GitHub and k8s MCP the turn fails before the provider runs
Research
tools:  {allowed: [read, grep, glob, web_fetch], web_search: true}
skills: {categories: [research]}
mcp:    {allowed: ["arxiv*", "scholar*"]}
Those tools plus web search, research skills, those MCP servers

web_search is outside the default tool list, so allowed alone does not add it.

When not to use gating

Default: install skills globally, configure no gates, let the model choose from each skill's description. Add a gate after observing specific bad behaviour, when:

  • a skill needs a hard wall (prod-deploy never in customer service);
  • the permitted set is shorter to list than to tune descriptions for;
  • an agent makes no sense without a given MCP server.

Implementation map · Not built · Calling unification (six-layer gating for function calling) · Skills and plugins (catalogues, discovery, hot reload)

Last updated · 2026-11-25