Documentation Index
Fetch the complete documentation index at: https://turnwise.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Conversation with Tool Usage
This example shows how to capture tool calls and their results.The Scenario
A customer is requesting a refund for a delayed order. The agent needs to look up the order and process the refund.JSON
Key Points
Agent Definition
The agent is defined with its available tools, documenting what capabilities it had.Multiple Steps
Message at sequence_number 3 has three steps:- Step 0: Calls
lookup_ordertool - Step 1: Calls
process_refundtool - Step 2: Generates the final response
Tool Call Structure
Tool Result Structure
What This Enables
With this structured data, you can evaluate:- Tool Selection: Did the agent use the right tools?
- Argument Accuracy: Were the tool arguments correct?
- Result Handling: Did the agent correctly interpret tool results?
- Response Quality: Was the final response accurate and helpful?