Skip to content

[FEATURE]: add external flag to ToolPart #21766

@micuintus

Description

@micuintus
  • I've checked that this feature hasn't been suggested before.

TL;DR

Add an optional external: boolean flag to ToolPart in the message schema, so plugins can mark tool call results as externally produced (not from the built-in tool execution pipeline).

More detail

Currently, ToolPart has no way to indicate whether the tool result was produced by the core tool runner or injected externally (e.g. by a plugin providing its own tool results via the server API). This flag enables downstream consumers (TUI, plugins) to distinguish externally-produced results.

This is a prerequisite for the server /tool endpoint (which injects external tool results into sessions).

Part of the plugin primitives work tracked in #20018 (split from #21687).

Metadata

Metadata

Assignees

Labels

coreAnything pertaining to core functionality of the application (opencode server stuff)

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions