You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
subagent: custom agent spawn fails with "free tier can only be used from within OpenCode" #50806
Spawning a subagent (a custom agent) from a session fails immediately with Error from provider (Console): OpenCode's free tier can only be used from within OpenCode.
The child session never starts, so custom agents are unusable on the free tier.
Environment
opencode version: 2.0.14
OS: Linux 6.6.87.2-microsoft-standard-WSL2 (linux x64)
Active plugins: none found (no opencode.json, .opencode/plugin/, or .opencode/plugins/)
Reproduction
Launch OpenCode and open a session with the default provider (free tier).
Ask the agent to delegate a task to a subagent, e.g. call the subagent tool
with agent: "architect" (a configured custom agent), a description and a prompt.
The spawn returns an error instead of starting the child session.
Expected Behavior
The subagent session starts and the task runs, with the free-tier entitlement
applied the same way as the parent session.
Actual Behavior
The tool execution fails with:
{"error":{"type":"tool.execution","message":"Subagent failed (sessionID: ses_...):
Error from provider (Console): OpenCode's free tier can only be used from within OpenCode"}}
The provider is reported as Console. The parent session on the same provider works.
Additional Context
Reproducible: consistent (reproduced on the first attempt).
The failing call is a subagent spawn for a custom agent (agent: architect);
unclear whether built-in agents are affected too.
Hypothesis: the child session's provider request does not carry the flag/context
that marks it as "from within OpenCode", so the free-tier gate rejects it.
No recent config changes, plugins, or terminal changes prior to the error.
No workaround found yet.
Plugins
no plugins
OpenCode version
2.0.14
Steps to reproduce
Launch OpenCode and open a session with the default provider (free tier).
Ask the agent to delegate a task to a subagent, e.g. call the subagent tool
with agent: "architect" (a configured custom agent), a description and a prompt.
The spawn returns an error instead of starting the child session.
Screenshot and/or share link
No response
Operating System
Linux 6.6.87.2-microsoft-standard-WSL2 (linux x64)
Thanks for the report. We're tracking this same free-tier rejection affecting subagents in #49723, so I'm closing this as a duplicate. Please follow that issue for updates.
Activity
github-actions commentedon Sep 23, 2026
This issue might be a duplicate of existing issues. Please check:
If your issue is distinct from those, please add context explaining what differs.
Use the built-in build agent instead of a custom agent
neriousy commentedon Oct 20, 2026
Thanks for the report. We're tracking this same free-tier rejection affecting subagents in #49723, so I'm closing this as a duplicate. Please follow that issue for updates.