Skip to content

[FEATURE]: pass sessionID into tool.definition hooks #17334

@ian-pascoe

Description

@ian-pascoe

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

tool.definition hooks should always receive the active sessionID when tool definitions are built.

Right now that session context is not available consistently across tool listing paths, which makes it hard for plugins to customize tool descriptions or schemas per session. The need is the same across prompt resolution, batch execution, debug tool listing, and /experimental/tool, so those entry points should use one session-aware contract instead of each path behaving differently.

This would also keep the plugin hook contract and generated SDK types aligned with the API behavior.

Metadata

Metadata

Assignees

Labels

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

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions