1---
2version: 2
3interactions:
4- id: 0
5 request:
6 proto: HTTP/1.1
7 proto_major: 1
8 proto_minor: 1
9 content_length: 561
10 host: ""
11 body: '{"messages":[{"content":"You are a helpful assistant","role":"system"},{"content":"What''s the weather in Florence, Italy?","role":"user"}],"model":"anthropic/claude-sonnet-4","stream_options":{"include_usage":true},"tool_choice":"auto","tools":[{"function":{"name":"weather","strict":false,"description":"Get weather information for a location","parameters":{"properties":{"location":{"description":"the city","type":"string"}},"required":["location"],"type":"object"}},"type":"function"}],"usage":{"include":true},"reasoning":{"effort":"medium"},"stream":true}'
12 headers:
13 Accept:
14 - application/json
15 Content-Type:
16 - application/json
17 User-Agent:
18 - OpenAI/Go 2.3.0
19 url: https://openrouter.ai/api/v1/chat/completions
20 method: POST
21 response:
22 proto: HTTP/2.0
23 proto_major: 2
24 proto_minor: 0
25 content_length: -1
26 body: |+
27 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
28
29 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[{"type":"reasoning.text","text":"","signature":"","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
30
31 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":"The user is asking for weather","reasoning_details":[{"type":"reasoning.text","text":"The user is asking for weather","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
32
33 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":" information for Florence, Italy. I have","reasoning_details":[{"type":"reasoning.text","text":" information for Florence, Italy. I have","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
34
35 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":" access to a","reasoning_details":[{"type":"reasoning.text","text":" access to a","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
36
37 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":" weather function that takes","reasoning_details":[{"type":"reasoning.text","text":" weather function that takes","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
38
39 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":" a location parameter. The","reasoning_details":[{"type":"reasoning.text","text":" a location parameter. The","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
40
41 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":" user has","reasoning_details":[{"type":"reasoning.text","text":" user has","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
42
43 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":" provided the location as \"Florence, Italy","reasoning_details":[{"type":"reasoning.text","text":" provided the location as \"Florence, Italy","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
44
45 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":"\". I have","reasoning_details":[{"type":"reasoning.text","text":"\". I have","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
46
47 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":" all the required parameters to make this function call","reasoning_details":[{"type":"reasoning.text","text":" all the required parameters to make this function call","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
48
49 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":".","reasoning_details":[{"type":"reasoning.text","text":".","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
50
51 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[{"type":"reasoning.text","signature":"EqgDCkgICBACGAIqQBvYK+UwzOLw+Jn8uxD4xoXAM70ym9hFuly64akWaZWJmCZFKC5FUckRcFdakI9/WwJTg2/OdypSRSFtMKW4iDYSDO/nr2VAX0H38rwvVBoMGmA90GevrflKVI+2IjAaYbpmfuJrp4R5Ap+X2vce48qmvVIjm1tGm6N+6PLTaEGwm4VAA+tx3OoJRle2O2wqjQJzWKdpBUkeisbCajt+0xhXCAXefGEhPMouvrlwpE/5IVEbMX6+eC1EDF04jKtfzH9RYEuuTUSaBNLqwprkOlmx9Rd1UYKvGM0f19WF9+nb57CUpOem9Spk9271t8jW5ubFGwiBn4/DyLDOx4wVUCfftQ0DyOAa3NQW1/aovUNNi18jwCyKlNCpsH7bT11twILBRYd3ZUDFlpIonEIYtWxPBbO0KVmECdH8a9gXGPhd0tIJD527yrJi6C4BnloHR7xSZJd3oe03y2mN2UsgF6R+SWE23z3jN+4hPpdOoVX3Kp9D3h160pfDvHTB9FN+xCr8xNUaevSab5J3qHquEjBCQSSyzxrZZasXhD3TThgB","format":"anthropic-claude-v1","index":0}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
52
53 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
54
55 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"id":"toolu_vrtx_01At9zaYnKY1m26hYkz63qwH","index":0,"type":"function","function":{"name":"weather","arguments":""}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
56
57 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"index":0,"type":"function","function":{"arguments":""}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
58
59 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"index":0,"type":"function","function":{"arguments":"{\"l"}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
60
61 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"index":0,"type":"function","function":{"arguments":"oc"}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
62
63 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"index":0,"type":"function","function":{"arguments":"ation"}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
64
65 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"index":0,"type":"function","function":{"arguments":"\": "}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
66
67 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"index":0,"type":"function","function":{"arguments":"\"Florence, "}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
68
69 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"index":0,"type":"function","function":{"arguments":"It"}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
70
71 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":null,"tool_calls":[{"index":0,"type":"function","function":{"arguments":"aly\"}"}}]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
72
73 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
74
75 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[]},"finish_reason":"tool_calls","native_finish_reason":"tool_calls","logprobs":null}]}
76
77 data: {"id":"gen-1758885067-Z9yGX7RRqfUmNTcUxT2X","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885067,"choices":[{"index":0,"delta":{"role":"assistant","content":""},"finish_reason":null,"native_finish_reason":null,"logprobs":null}],"usage":{"prompt_tokens":423,"completion_tokens":111,"total_tokens":534,"cost":0.002934,"is_byok":false,"prompt_tokens_details":{"cached_tokens":0,"audio_tokens":0},"cost_details":{"upstream_inference_cost":null,"upstream_inference_prompt_cost":0.001269,"upstream_inference_completions_cost":0.001665},"completion_tokens_details":{"reasoning_tokens":63,"image_tokens":0}}}
78
79 data: [DONE]
80
81 headers:
82 Content-Type:
83 - text/event-stream
84 status: 200 OK
85 code: 200
86 duration: 2.014668667s
87- id: 1
88 request:
89 proto: HTTP/1.1
90 proto_major: 1
91 proto_minor: 1
92 content_length: 826
93 host: ""
94 body: '{"messages":[{"content":"You are a helpful assistant","role":"system"},{"content":"What''s the weather in Florence, Italy?","role":"user"},{"tool_calls":[{"id":"toolu_vrtx_01At9zaYnKY1m26hYkz63qwH","function":{"arguments":"{\"location\": \"Florence, Italy\"}","name":"weather"},"type":"function"}],"role":"assistant"},{"content":"40 C","tool_call_id":"toolu_vrtx_01At9zaYnKY1m26hYkz63qwH","role":"tool"}],"model":"anthropic/claude-sonnet-4","stream_options":{"include_usage":true},"tool_choice":"auto","tools":[{"function":{"name":"weather","strict":false,"description":"Get weather information for a location","parameters":{"properties":{"location":{"description":"the city","type":"string"}},"required":["location"],"type":"object"}},"type":"function"}],"usage":{"include":true},"reasoning":{"effort":"medium"},"stream":true}'
95 headers:
96 Accept:
97 - application/json
98 Content-Type:
99 - application/json
100 User-Agent:
101 - OpenAI/Go 2.3.0
102 url: https://openrouter.ai/api/v1/chat/completions
103 method: POST
104 response:
105 proto: HTTP/2.0
106 proto_major: 2
107 proto_minor: 0
108 content_length: -1
109 body: |+
110 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
111
112 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
113
114 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":"The current","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
115
116 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":" weather in Florence, Italy is 40","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
117
118 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":"°C (104°F). That","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
119
120 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":"'s quite","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
121
122 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":" hot","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
123
124 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":"! It seems","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
125
126 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":" like Florence","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
127
128 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":" is experiencing a very","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
129
130 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":" warm day","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
131
132 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":".","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
133
134 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[]},"finish_reason":null,"native_finish_reason":null,"logprobs":null}]}
135
136 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":"","reasoning":null,"reasoning_details":[]},"finish_reason":"stop","native_finish_reason":"stop","logprobs":null}]}
137
138 data: {"id":"gen-1758885071-0qadQTT2R2P1Xlmtggzx","provider":"Google","model":"anthropic/claude-sonnet-4","object":"chat.completion.chunk","created":1758885071,"choices":[{"index":0,"delta":{"role":"assistant","content":""},"finish_reason":null,"native_finish_reason":null,"logprobs":null}],"usage":{"prompt_tokens":463,"completion_tokens":36,"total_tokens":499,"cost":0.001929,"is_byok":false,"prompt_tokens_details":{"cached_tokens":0,"audio_tokens":0},"cost_details":{"upstream_inference_cost":null,"upstream_inference_prompt_cost":0.001389,"upstream_inference_completions_cost":0.00054},"completion_tokens_details":{"reasoning_tokens":0,"image_tokens":0}}}
139
140 data: [DONE]
141
142 headers:
143 Content-Type:
144 - text/event-stream
145 status: 200 OK
146 code: 200
147 duration: 1.956100209s