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: 460
10 host: ""
11 body: '{"messages":[{"content":"You are a helpful assistant","role":"system"},{"content":"What''s the weather in Florence,Italy?","role":"user"}],"model":"o4-mini","max_completion_tokens":4000,"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"}]}'
12 headers:
13 Accept:
14 - application/json
15 Content-Type:
16 - application/json
17 User-Agent:
18 - Charm-Fantasy/0.12.2 (https://charm.land/fantasy)
19 url: https://api.openai.com/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 uncompressed: true
27 body: |
28 {
29 "id": "chatcmpl-DIgPjH4PSJNZtaCUtWht6f93kVI2o",
30 "object": "chat.completion",
31 "created": 1773345315,
32 "model": "o4-mini-2025-04-16",
33 "choices": [
34 {
35 "index": 0,
36 "message": {
37 "role": "assistant",
38 "content": null,
39 "tool_calls": [
40 {
41 "id": "call_Uto0Xgr2iYWOHzkWGoNNoYTb",
42 "type": "function",
43 "function": {
44 "name": "weather",
45 "arguments": "{\"location\":\"Florence, Italy\"}"
46 }
47 }
48 ],
49 "refusal": null,
50 "annotations": []
51 },
52 "finish_reason": "tool_calls"
53 }
54 ],
55 "usage": {
56 "prompt_tokens": 64,
57 "completion_tokens": 89,
58 "total_tokens": 153,
59 "prompt_tokens_details": {
60 "cached_tokens": 0,
61 "audio_tokens": 0
62 },
63 "completion_tokens_details": {
64 "reasoning_tokens": 64,
65 "audio_tokens": 0,
66 "accepted_prediction_tokens": 0,
67 "rejected_prediction_tokens": 0
68 }
69 },
70 "service_tier": "default",
71 "system_fingerprint": null
72 }
73 headers:
74 Content-Type:
75 - application/json
76 status: 200 OK
77 code: 200
78 duration: 1.500324417s
79- id: 1
80 request:
81 proto: HTTP/1.1
82 proto_major: 1
83 proto_minor: 1
84 content_length: 712
85 host: ""
86 body: '{"messages":[{"content":"You are a helpful assistant","role":"system"},{"content":"What''s the weather in Florence,Italy?","role":"user"},{"tool_calls":[{"id":"call_Uto0Xgr2iYWOHzkWGoNNoYTb","function":{"arguments":"{\"location\":\"Florence, Italy\"}","name":"weather"},"type":"function"}],"role":"assistant"},{"content":"40 C","tool_call_id":"call_Uto0Xgr2iYWOHzkWGoNNoYTb","role":"tool"}],"model":"o4-mini","max_completion_tokens":4000,"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"}]}'
87 headers:
88 Accept:
89 - application/json
90 Content-Type:
91 - application/json
92 User-Agent:
93 - Charm-Fantasy/0.12.2 (https://charm.land/fantasy)
94 url: https://api.openai.com/v1/chat/completions
95 method: POST
96 response:
97 proto: HTTP/2.0
98 proto_major: 2
99 proto_minor: 0
100 content_length: -1
101 uncompressed: true
102 body: |
103 {
104 "id": "chatcmpl-DIgPkGqw5A5Sl65TfoTZrI4dgSUHd",
105 "object": "chat.completion",
106 "created": 1773345316,
107 "model": "o4-mini-2025-04-16",
108 "choices": [
109 {
110 "index": 0,
111 "message": {
112 "role": "assistant",
113 "content": "The current temperature in Florence, Italy is 40 °C.",
114 "refusal": null,
115 "annotations": []
116 },
117 "finish_reason": "stop"
118 }
119 ],
120 "usage": {
121 "prompt_tokens": 95,
122 "completion_tokens": 25,
123 "total_tokens": 120,
124 "prompt_tokens_details": {
125 "cached_tokens": 0,
126 "audio_tokens": 0
127 },
128 "completion_tokens_details": {
129 "reasoning_tokens": 0,
130 "audio_tokens": 0,
131 "accepted_prediction_tokens": 0,
132 "rejected_prediction_tokens": 0
133 }
134 },
135 "service_tier": "default",
136 "system_fingerprint": null
137 }
138 headers:
139 Content-Type:
140 - application/json
141 status: 200 OK
142 code: 200
143 duration: 872.285291ms