MCPcopy Create free account
hub / github.com/anthropics/anthropic-sdk-python / tool_result

Function tool_result

tests/lib/threads/helpers.py:196–197  ·  view source on GitHub ↗
(tool_use_id: str, content: str = "Sunny in San Francisco")

Source from the content-addressed store, hash-verified

194
195
196def tool_result(tool_use_id: str, content: str = "Sunny in San Francisco") -> BetaMessageParam:
197 return {"role": "user", "content": [{"type": "tool_result", "tool_use_id": tool_use_id, "content": content}]}
198
199
200def tool_addition(definition: BetaToolUnionParam) -> BetaMessageParam:

Calls

no outgoing calls