Call Tools

Loading "Tools Ow1ol"
πŸ‘¨β€πŸ’Ό When users click "View Entry" on a journal entry, nothing happens. They need a way to trigger tool calls that fetch detailed data from the host application.
You're going to build upon the abstraction you and πŸ§β€β™€οΈ Kellie built in the last exercise so you can use it for tool calls as well:
await sendMcpMessage('tool', {
	toolName: 'analyze_rock_sample',
	params: { sampleId: 'mars-2024-001' },
})
You need to add the 'tool' type to sendMcpMessage and wire up the actual tool call.
Now, let's implement this to make those journal entries interactive.

Please set the playground first

Loading "Call Tools"
Loading "Call Tools"