Hooks

useToolOutput

Tool data hook from moonpeak.

View .mdEdit on GitHub
import { useToolOutput } from "moonpeak";

useToolOutput<Out>(): Out | undefined

Just the structured content your handler returned.

Example

const output = useToolOutput<{ phase: string }>();

Works in

Every MCP Apps host: ChatGPT, Claude, VS Code, Goose and the moonpeak inspector.

See all hooks in Runtime APIs.