1// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
  2
  3package constant
  4
  5import (
  6	"encoding/json"
  7)
  8
  9type Constant[T any] interface {
 10	Default() T
 11}
 12
 13// ValueOf gives the default value of a constant from its type. It's helpful when
 14// constructing constants as variants in a one-of. Note that empty structs are
 15// marshalled by default. Usage: constant.ValueOf[constant.Foo]()
 16func ValueOf[T Constant[T]]() T {
 17	var t T
 18	return t.Default()
 19}
 20
 21type Approximate string                             // Always "approximate"
 22type Assistant string                               // Always "assistant"
 23type AssistantDeleted string                        // Always "assistant.deleted"
 24type Auto string                                    // Always "auto"
 25type Batch string                                   // Always "batch"
 26type BatchCancelled string                          // Always "batch.cancelled"
 27type BatchCompleted string                          // Always "batch.completed"
 28type BatchExpired string                            // Always "batch.expired"
 29type BatchFailed string                             // Always "batch.failed"
 30type ChatCompletion string                          // Always "chat.completion"
 31type ChatCompletionChunk string                     // Always "chat.completion.chunk"
 32type ChatCompletionDeleted string                   // Always "chat.completion.deleted"
 33type CheckpointPermission string                    // Always "checkpoint.permission"
 34type Click string                                   // Always "click"
 35type CodeInterpreter string                         // Always "code_interpreter"
 36type CodeInterpreterCall string                     // Always "code_interpreter_call"
 37type ComputerCallOutput string                      // Always "computer_call_output"
 38type ComputerScreenshot string                      // Always "computer_screenshot"
 39type ComputerUsePreview string                      // Always "computer_use_preview"
 40type ContainerFileCitation string                   // Always "container_file_citation"
 41type ContainerFile string                           // Always "container.file"
 42type Content string                                 // Always "content"
 43type Developer string                               // Always "developer"
 44type DoubleClick string                             // Always "double_click"
 45type Drag string                                    // Always "drag"
 46type Duration string                                // Always "duration"
 47type Embedding string                               // Always "embedding"
 48type Error string                                   // Always "error"
 49type EvalRunCanceled string                         // Always "eval.run.canceled"
 50type EvalRunFailed string                           // Always "eval.run.failed"
 51type EvalRunSucceeded string                        // Always "eval.run.succeeded"
 52type Exec string                                    // Always "exec"
 53type File string                                    // Always "file"
 54type FileCitation string                            // Always "file_citation"
 55type FilePath string                                // Always "file_path"
 56type FileSearch string                              // Always "file_search"
 57type FileSearchCall string                          // Always "file_search_call"
 58type Find string                                    // Always "find"
 59type FineTuningJob string                           // Always "fine_tuning.job"
 60type FineTuningJobCancelled string                  // Always "fine_tuning.job.cancelled"
 61type FineTuningJobCheckpoint string                 // Always "fine_tuning.job.checkpoint"
 62type FineTuningJobEvent string                      // Always "fine_tuning.job.event"
 63type FineTuningJobFailed string                     // Always "fine_tuning.job.failed"
 64type FineTuningJobSucceeded string                  // Always "fine_tuning.job.succeeded"
 65type Function string                                // Always "function"
 66type FunctionCall string                            // Always "function_call"
 67type FunctionCallOutput string                      // Always "function_call_output"
 68type Image string                                   // Always "image"
 69type ImageFile string                               // Always "image_file"
 70type ImageGeneration string                         // Always "image_generation"
 71type ImageGenerationCall string                     // Always "image_generation_call"
 72type ImageURL string                                // Always "image_url"
 73type InputAudio string                              // Always "input_audio"
 74type InputFile string                               // Always "input_file"
 75type InputImage string                              // Always "input_image"
 76type InputText string                               // Always "input_text"
 77type JSONObject string                              // Always "json_object"
 78type JSONSchema string                              // Always "json_schema"
 79type Keypress string                                // Always "keypress"
 80type LabelModel string                              // Always "label_model"
 81type LastActiveAt string                            // Always "last_active_at"
 82type List string                                    // Always "list"
 83type LocalShell string                              // Always "local_shell"
 84type LocalShellCall string                          // Always "local_shell_call"
 85type LocalShellCallOutput string                    // Always "local_shell_call_output"
 86type Logs string                                    // Always "logs"
 87type Mcp string                                     // Always "mcp"
 88type McpApprovalRequest string                      // Always "mcp_approval_request"
 89type McpApprovalResponse string                     // Always "mcp_approval_response"
 90type McpCall string                                 // Always "mcp_call"
 91type McpListTools string                            // Always "mcp_list_tools"
 92type Message string                                 // Always "message"
 93type MessageCreation string                         // Always "message_creation"
 94type Model string                                   // Always "model"
 95type Move string                                    // Always "move"
 96type Multi string                                   // Always "multi"
 97type OpenPage string                                // Always "open_page"
 98type Other string                                   // Always "other"
 99type OutputAudio string                             // Always "output_audio"
100type OutputText string                              // Always "output_text"
101type Python string                                  // Always "python"
102type Reasoning string                               // Always "reasoning"
103type Refusal string                                 // Always "refusal"
104type Response string                                // Always "response"
105type ResponseAudioDelta string                      // Always "response.audio.delta"
106type ResponseAudioDone string                       // Always "response.audio.done"
107type ResponseAudioTranscriptDelta string            // Always "response.audio.transcript.delta"
108type ResponseAudioTranscriptDone string             // Always "response.audio.transcript.done"
109type ResponseCancelled string                       // Always "response.cancelled"
110type ResponseCodeInterpreterCallCodeDelta string    // Always "response.code_interpreter_call_code.delta"
111type ResponseCodeInterpreterCallCodeDone string     // Always "response.code_interpreter_call_code.done"
112type ResponseCodeInterpreterCallCompleted string    // Always "response.code_interpreter_call.completed"
113type ResponseCodeInterpreterCallInProgress string   // Always "response.code_interpreter_call.in_progress"
114type ResponseCodeInterpreterCallInterpreting string // Always "response.code_interpreter_call.interpreting"
115type ResponseCompleted string                       // Always "response.completed"
116type ResponseContentPartAdded string                // Always "response.content_part.added"
117type ResponseContentPartDone string                 // Always "response.content_part.done"
118type ResponseCreated string                         // Always "response.created"
119type ResponseFailed string                          // Always "response.failed"
120type ResponseFileSearchCallCompleted string         // Always "response.file_search_call.completed"
121type ResponseFileSearchCallInProgress string        // Always "response.file_search_call.in_progress"
122type ResponseFileSearchCallSearching string         // Always "response.file_search_call.searching"
123type ResponseFunctionCallArgumentsDelta string      // Always "response.function_call_arguments.delta"
124type ResponseFunctionCallArgumentsDone string       // Always "response.function_call_arguments.done"
125type ResponseImageGenerationCallCompleted string    // Always "response.image_generation_call.completed"
126type ResponseImageGenerationCallGenerating string   // Always "response.image_generation_call.generating"
127type ResponseImageGenerationCallInProgress string   // Always "response.image_generation_call.in_progress"
128type ResponseImageGenerationCallPartialImage string // Always "response.image_generation_call.partial_image"
129type ResponseInProgress string                      // Always "response.in_progress"
130type ResponseIncomplete string                      // Always "response.incomplete"
131type ResponseMcpCallArgumentsDelta string           // Always "response.mcp_call.arguments_delta"
132type ResponseMcpCallArgumentsDone string            // Always "response.mcp_call.arguments_done"
133type ResponseMcpCallCompleted string                // Always "response.mcp_call.completed"
134type ResponseMcpCallFailed string                   // Always "response.mcp_call.failed"
135type ResponseMcpCallInProgress string               // Always "response.mcp_call.in_progress"
136type ResponseMcpListToolsCompleted string           // Always "response.mcp_list_tools.completed"
137type ResponseMcpListToolsFailed string              // Always "response.mcp_list_tools.failed"
138type ResponseMcpListToolsInProgress string          // Always "response.mcp_list_tools.in_progress"
139type ResponseOutputItemAdded string                 // Always "response.output_item.added"
140type ResponseOutputItemDone string                  // Always "response.output_item.done"
141type ResponseOutputTextAnnotationAdded string       // Always "response.output_text_annotation.added"
142type ResponseOutputTextDelta string                 // Always "response.output_text.delta"
143type ResponseOutputTextDone string                  // Always "response.output_text.done"
144type ResponseQueued string                          // Always "response.queued"
145type ResponseReasoningSummaryPartAdded string       // Always "response.reasoning_summary_part.added"
146type ResponseReasoningSummaryPartDone string        // Always "response.reasoning_summary_part.done"
147type ResponseReasoningSummaryTextDelta string       // Always "response.reasoning_summary_text.delta"
148type ResponseReasoningSummaryTextDone string        // Always "response.reasoning_summary_text.done"
149type ResponseReasoningSummaryDelta string           // Always "response.reasoning_summary.delta"
150type ResponseReasoningSummaryDone string            // Always "response.reasoning_summary.done"
151type ResponseReasoningDelta string                  // Always "response.reasoning.delta"
152type ResponseReasoningDone string                   // Always "response.reasoning.done"
153type ResponseRefusalDelta string                    // Always "response.refusal.delta"
154type ResponseRefusalDone string                     // Always "response.refusal.done"
155type ResponseWebSearchCallCompleted string          // Always "response.web_search_call.completed"
156type ResponseWebSearchCallInProgress string         // Always "response.web_search_call.in_progress"
157type ResponseWebSearchCallSearching string          // Always "response.web_search_call.searching"
158type ScoreModel string                              // Always "score_model"
159type Screenshot string                              // Always "screenshot"
160type Scroll string                                  // Always "scroll"
161type Search string                                  // Always "search"
162type Static string                                  // Always "static"
163type StringCheck string                             // Always "string_check"
164type SubmitToolOutputs string                       // Always "submit_tool_outputs"
165type SummaryText string                             // Always "summary_text"
166type System string                                  // Always "system"
167type Text string                                    // Always "text"
168type TextCompletion string                          // Always "text_completion"
169type TextSimilarity string                          // Always "text_similarity"
170type Thread string                                  // Always "thread"
171type ThreadCreated string                           // Always "thread.created"
172type ThreadDeleted string                           // Always "thread.deleted"
173type ThreadMessage string                           // Always "thread.message"
174type ThreadMessageCompleted string                  // Always "thread.message.completed"
175type ThreadMessageCreated string                    // Always "thread.message.created"
176type ThreadMessageDeleted string                    // Always "thread.message.deleted"
177type ThreadMessageDelta string                      // Always "thread.message.delta"
178type ThreadMessageInProgress string                 // Always "thread.message.in_progress"
179type ThreadMessageIncomplete string                 // Always "thread.message.incomplete"
180type ThreadRun string                               // Always "thread.run"
181type ThreadRunCancelled string                      // Always "thread.run.cancelled"
182type ThreadRunCancelling string                     // Always "thread.run.cancelling"
183type ThreadRunCompleted string                      // Always "thread.run.completed"
184type ThreadRunCreated string                        // Always "thread.run.created"
185type ThreadRunExpired string                        // Always "thread.run.expired"
186type ThreadRunFailed string                         // Always "thread.run.failed"
187type ThreadRunInProgress string                     // Always "thread.run.in_progress"
188type ThreadRunIncomplete string                     // Always "thread.run.incomplete"
189type ThreadRunQueued string                         // Always "thread.run.queued"
190type ThreadRunRequiresAction string                 // Always "thread.run.requires_action"
191type ThreadRunStep string                           // Always "thread.run.step"
192type ThreadRunStepCancelled string                  // Always "thread.run.step.cancelled"
193type ThreadRunStepCompleted string                  // Always "thread.run.step.completed"
194type ThreadRunStepCreated string                    // Always "thread.run.step.created"
195type ThreadRunStepDelta string                      // Always "thread.run.step.delta"
196type ThreadRunStepExpired string                    // Always "thread.run.step.expired"
197type ThreadRunStepFailed string                     // Always "thread.run.step.failed"
198type ThreadRunStepInProgress string                 // Always "thread.run.step.in_progress"
199type Tokens string                                  // Always "tokens"
200type Tool string                                    // Always "tool"
201type ToolCalls string                               // Always "tool_calls"
202type TranscriptTextDelta string                     // Always "transcript.text.delta"
203type TranscriptTextDone string                      // Always "transcript.text.done"
204type Type string                                    // Always "type"
205type Upload string                                  // Always "upload"
206type UploadPart string                              // Always "upload.part"
207type URLCitation string                             // Always "url_citation"
208type User string                                    // Always "user"
209type VectorStore string                             // Always "vector_store"
210type VectorStoreDeleted string                      // Always "vector_store.deleted"
211type VectorStoreFile string                         // Always "vector_store.file"
212type VectorStoreFileContentPage string              // Always "vector_store.file_content.page"
213type VectorStoreFileDeleted string                  // Always "vector_store.file.deleted"
214type VectorStoreFilesBatch string                   // Always "vector_store.files_batch"
215type VectorStoreSearchResultsPage string            // Always "vector_store.search_results.page"
216type Wait string                                    // Always "wait"
217type Wandb string                                   // Always "wandb"
218type WebSearchCall string                           // Always "web_search_call"
219
220func (c Approximate) Default() Approximate                       { return "approximate" }
221func (c Assistant) Default() Assistant                           { return "assistant" }
222func (c AssistantDeleted) Default() AssistantDeleted             { return "assistant.deleted" }
223func (c Auto) Default() Auto                                     { return "auto" }
224func (c Batch) Default() Batch                                   { return "batch" }
225func (c BatchCancelled) Default() BatchCancelled                 { return "batch.cancelled" }
226func (c BatchCompleted) Default() BatchCompleted                 { return "batch.completed" }
227func (c BatchExpired) Default() BatchExpired                     { return "batch.expired" }
228func (c BatchFailed) Default() BatchFailed                       { return "batch.failed" }
229func (c ChatCompletion) Default() ChatCompletion                 { return "chat.completion" }
230func (c ChatCompletionChunk) Default() ChatCompletionChunk       { return "chat.completion.chunk" }
231func (c ChatCompletionDeleted) Default() ChatCompletionDeleted   { return "chat.completion.deleted" }
232func (c CheckpointPermission) Default() CheckpointPermission     { return "checkpoint.permission" }
233func (c Click) Default() Click                                   { return "click" }
234func (c CodeInterpreter) Default() CodeInterpreter               { return "code_interpreter" }
235func (c CodeInterpreterCall) Default() CodeInterpreterCall       { return "code_interpreter_call" }
236func (c ComputerCallOutput) Default() ComputerCallOutput         { return "computer_call_output" }
237func (c ComputerScreenshot) Default() ComputerScreenshot         { return "computer_screenshot" }
238func (c ComputerUsePreview) Default() ComputerUsePreview         { return "computer_use_preview" }
239func (c ContainerFileCitation) Default() ContainerFileCitation   { return "container_file_citation" }
240func (c ContainerFile) Default() ContainerFile                   { return "container.file" }
241func (c Content) Default() Content                               { return "content" }
242func (c Developer) Default() Developer                           { return "developer" }
243func (c DoubleClick) Default() DoubleClick                       { return "double_click" }
244func (c Drag) Default() Drag                                     { return "drag" }
245func (c Duration) Default() Duration                             { return "duration" }
246func (c Embedding) Default() Embedding                           { return "embedding" }
247func (c Error) Default() Error                                   { return "error" }
248func (c EvalRunCanceled) Default() EvalRunCanceled               { return "eval.run.canceled" }
249func (c EvalRunFailed) Default() EvalRunFailed                   { return "eval.run.failed" }
250func (c EvalRunSucceeded) Default() EvalRunSucceeded             { return "eval.run.succeeded" }
251func (c Exec) Default() Exec                                     { return "exec" }
252func (c File) Default() File                                     { return "file" }
253func (c FileCitation) Default() FileCitation                     { return "file_citation" }
254func (c FilePath) Default() FilePath                             { return "file_path" }
255func (c FileSearch) Default() FileSearch                         { return "file_search" }
256func (c FileSearchCall) Default() FileSearchCall                 { return "file_search_call" }
257func (c Find) Default() Find                                     { return "find" }
258func (c FineTuningJob) Default() FineTuningJob                   { return "fine_tuning.job" }
259func (c FineTuningJobCancelled) Default() FineTuningJobCancelled { return "fine_tuning.job.cancelled" }
260func (c FineTuningJobCheckpoint) Default() FineTuningJobCheckpoint {
261	return "fine_tuning.job.checkpoint"
262}
263func (c FineTuningJobEvent) Default() FineTuningJobEvent         { return "fine_tuning.job.event" }
264func (c FineTuningJobFailed) Default() FineTuningJobFailed       { return "fine_tuning.job.failed" }
265func (c FineTuningJobSucceeded) Default() FineTuningJobSucceeded { return "fine_tuning.job.succeeded" }
266func (c Function) Default() Function                             { return "function" }
267func (c FunctionCall) Default() FunctionCall                     { return "function_call" }
268func (c FunctionCallOutput) Default() FunctionCallOutput         { return "function_call_output" }
269func (c Image) Default() Image                                   { return "image" }
270func (c ImageFile) Default() ImageFile                           { return "image_file" }
271func (c ImageGeneration) Default() ImageGeneration               { return "image_generation" }
272func (c ImageGenerationCall) Default() ImageGenerationCall       { return "image_generation_call" }
273func (c ImageURL) Default() ImageURL                             { return "image_url" }
274func (c InputAudio) Default() InputAudio                         { return "input_audio" }
275func (c InputFile) Default() InputFile                           { return "input_file" }
276func (c InputImage) Default() InputImage                         { return "input_image" }
277func (c InputText) Default() InputText                           { return "input_text" }
278func (c JSONObject) Default() JSONObject                         { return "json_object" }
279func (c JSONSchema) Default() JSONSchema                         { return "json_schema" }
280func (c Keypress) Default() Keypress                             { return "keypress" }
281func (c LabelModel) Default() LabelModel                         { return "label_model" }
282func (c LastActiveAt) Default() LastActiveAt                     { return "last_active_at" }
283func (c List) Default() List                                     { return "list" }
284func (c LocalShell) Default() LocalShell                         { return "local_shell" }
285func (c LocalShellCall) Default() LocalShellCall                 { return "local_shell_call" }
286func (c LocalShellCallOutput) Default() LocalShellCallOutput     { return "local_shell_call_output" }
287func (c Logs) Default() Logs                                     { return "logs" }
288func (c Mcp) Default() Mcp                                       { return "mcp" }
289func (c McpApprovalRequest) Default() McpApprovalRequest         { return "mcp_approval_request" }
290func (c McpApprovalResponse) Default() McpApprovalResponse       { return "mcp_approval_response" }
291func (c McpCall) Default() McpCall                               { return "mcp_call" }
292func (c McpListTools) Default() McpListTools                     { return "mcp_list_tools" }
293func (c Message) Default() Message                               { return "message" }
294func (c MessageCreation) Default() MessageCreation               { return "message_creation" }
295func (c Model) Default() Model                                   { return "model" }
296func (c Move) Default() Move                                     { return "move" }
297func (c Multi) Default() Multi                                   { return "multi" }
298func (c OpenPage) Default() OpenPage                             { return "open_page" }
299func (c Other) Default() Other                                   { return "other" }
300func (c OutputAudio) Default() OutputAudio                       { return "output_audio" }
301func (c OutputText) Default() OutputText                         { return "output_text" }
302func (c Python) Default() Python                                 { return "python" }
303func (c Reasoning) Default() Reasoning                           { return "reasoning" }
304func (c Refusal) Default() Refusal                               { return "refusal" }
305func (c Response) Default() Response                             { return "response" }
306func (c ResponseAudioDelta) Default() ResponseAudioDelta         { return "response.audio.delta" }
307func (c ResponseAudioDone) Default() ResponseAudioDone           { return "response.audio.done" }
308func (c ResponseAudioTranscriptDelta) Default() ResponseAudioTranscriptDelta {
309	return "response.audio.transcript.delta"
310}
311func (c ResponseAudioTranscriptDone) Default() ResponseAudioTranscriptDone {
312	return "response.audio.transcript.done"
313}
314func (c ResponseCancelled) Default() ResponseCancelled { return "response.cancelled" }
315func (c ResponseCodeInterpreterCallCodeDelta) Default() ResponseCodeInterpreterCallCodeDelta {
316	return "response.code_interpreter_call_code.delta"
317}
318func (c ResponseCodeInterpreterCallCodeDone) Default() ResponseCodeInterpreterCallCodeDone {
319	return "response.code_interpreter_call_code.done"
320}
321func (c ResponseCodeInterpreterCallCompleted) Default() ResponseCodeInterpreterCallCompleted {
322	return "response.code_interpreter_call.completed"
323}
324func (c ResponseCodeInterpreterCallInProgress) Default() ResponseCodeInterpreterCallInProgress {
325	return "response.code_interpreter_call.in_progress"
326}
327func (c ResponseCodeInterpreterCallInterpreting) Default() ResponseCodeInterpreterCallInterpreting {
328	return "response.code_interpreter_call.interpreting"
329}
330func (c ResponseCompleted) Default() ResponseCompleted { return "response.completed" }
331func (c ResponseContentPartAdded) Default() ResponseContentPartAdded {
332	return "response.content_part.added"
333}
334func (c ResponseContentPartDone) Default() ResponseContentPartDone {
335	return "response.content_part.done"
336}
337func (c ResponseCreated) Default() ResponseCreated { return "response.created" }
338func (c ResponseFailed) Default() ResponseFailed   { return "response.failed" }
339func (c ResponseFileSearchCallCompleted) Default() ResponseFileSearchCallCompleted {
340	return "response.file_search_call.completed"
341}
342func (c ResponseFileSearchCallInProgress) Default() ResponseFileSearchCallInProgress {
343	return "response.file_search_call.in_progress"
344}
345func (c ResponseFileSearchCallSearching) Default() ResponseFileSearchCallSearching {
346	return "response.file_search_call.searching"
347}
348func (c ResponseFunctionCallArgumentsDelta) Default() ResponseFunctionCallArgumentsDelta {
349	return "response.function_call_arguments.delta"
350}
351func (c ResponseFunctionCallArgumentsDone) Default() ResponseFunctionCallArgumentsDone {
352	return "response.function_call_arguments.done"
353}
354func (c ResponseImageGenerationCallCompleted) Default() ResponseImageGenerationCallCompleted {
355	return "response.image_generation_call.completed"
356}
357func (c ResponseImageGenerationCallGenerating) Default() ResponseImageGenerationCallGenerating {
358	return "response.image_generation_call.generating"
359}
360func (c ResponseImageGenerationCallInProgress) Default() ResponseImageGenerationCallInProgress {
361	return "response.image_generation_call.in_progress"
362}
363func (c ResponseImageGenerationCallPartialImage) Default() ResponseImageGenerationCallPartialImage {
364	return "response.image_generation_call.partial_image"
365}
366func (c ResponseInProgress) Default() ResponseInProgress { return "response.in_progress" }
367func (c ResponseIncomplete) Default() ResponseIncomplete { return "response.incomplete" }
368func (c ResponseMcpCallArgumentsDelta) Default() ResponseMcpCallArgumentsDelta {
369	return "response.mcp_call.arguments_delta"
370}
371func (c ResponseMcpCallArgumentsDone) Default() ResponseMcpCallArgumentsDone {
372	return "response.mcp_call.arguments_done"
373}
374func (c ResponseMcpCallCompleted) Default() ResponseMcpCallCompleted {
375	return "response.mcp_call.completed"
376}
377func (c ResponseMcpCallFailed) Default() ResponseMcpCallFailed { return "response.mcp_call.failed" }
378func (c ResponseMcpCallInProgress) Default() ResponseMcpCallInProgress {
379	return "response.mcp_call.in_progress"
380}
381func (c ResponseMcpListToolsCompleted) Default() ResponseMcpListToolsCompleted {
382	return "response.mcp_list_tools.completed"
383}
384func (c ResponseMcpListToolsFailed) Default() ResponseMcpListToolsFailed {
385	return "response.mcp_list_tools.failed"
386}
387func (c ResponseMcpListToolsInProgress) Default() ResponseMcpListToolsInProgress {
388	return "response.mcp_list_tools.in_progress"
389}
390func (c ResponseOutputItemAdded) Default() ResponseOutputItemAdded {
391	return "response.output_item.added"
392}
393func (c ResponseOutputItemDone) Default() ResponseOutputItemDone { return "response.output_item.done" }
394func (c ResponseOutputTextAnnotationAdded) Default() ResponseOutputTextAnnotationAdded {
395	return "response.output_text_annotation.added"
396}
397func (c ResponseOutputTextDelta) Default() ResponseOutputTextDelta {
398	return "response.output_text.delta"
399}
400func (c ResponseOutputTextDone) Default() ResponseOutputTextDone { return "response.output_text.done" }
401func (c ResponseQueued) Default() ResponseQueued                 { return "response.queued" }
402func (c ResponseReasoningSummaryPartAdded) Default() ResponseReasoningSummaryPartAdded {
403	return "response.reasoning_summary_part.added"
404}
405func (c ResponseReasoningSummaryPartDone) Default() ResponseReasoningSummaryPartDone {
406	return "response.reasoning_summary_part.done"
407}
408func (c ResponseReasoningSummaryTextDelta) Default() ResponseReasoningSummaryTextDelta {
409	return "response.reasoning_summary_text.delta"
410}
411func (c ResponseReasoningSummaryTextDone) Default() ResponseReasoningSummaryTextDone {
412	return "response.reasoning_summary_text.done"
413}
414func (c ResponseReasoningSummaryDelta) Default() ResponseReasoningSummaryDelta {
415	return "response.reasoning_summary.delta"
416}
417func (c ResponseReasoningSummaryDone) Default() ResponseReasoningSummaryDone {
418	return "response.reasoning_summary.done"
419}
420func (c ResponseReasoningDelta) Default() ResponseReasoningDelta { return "response.reasoning.delta" }
421func (c ResponseReasoningDone) Default() ResponseReasoningDone   { return "response.reasoning.done" }
422func (c ResponseRefusalDelta) Default() ResponseRefusalDelta     { return "response.refusal.delta" }
423func (c ResponseRefusalDone) Default() ResponseRefusalDone       { return "response.refusal.done" }
424func (c ResponseWebSearchCallCompleted) Default() ResponseWebSearchCallCompleted {
425	return "response.web_search_call.completed"
426}
427func (c ResponseWebSearchCallInProgress) Default() ResponseWebSearchCallInProgress {
428	return "response.web_search_call.in_progress"
429}
430func (c ResponseWebSearchCallSearching) Default() ResponseWebSearchCallSearching {
431	return "response.web_search_call.searching"
432}
433func (c ScoreModel) Default() ScoreModel                         { return "score_model" }
434func (c Screenshot) Default() Screenshot                         { return "screenshot" }
435func (c Scroll) Default() Scroll                                 { return "scroll" }
436func (c Search) Default() Search                                 { return "search" }
437func (c Static) Default() Static                                 { return "static" }
438func (c StringCheck) Default() StringCheck                       { return "string_check" }
439func (c SubmitToolOutputs) Default() SubmitToolOutputs           { return "submit_tool_outputs" }
440func (c SummaryText) Default() SummaryText                       { return "summary_text" }
441func (c System) Default() System                                 { return "system" }
442func (c Text) Default() Text                                     { return "text" }
443func (c TextCompletion) Default() TextCompletion                 { return "text_completion" }
444func (c TextSimilarity) Default() TextSimilarity                 { return "text_similarity" }
445func (c Thread) Default() Thread                                 { return "thread" }
446func (c ThreadCreated) Default() ThreadCreated                   { return "thread.created" }
447func (c ThreadDeleted) Default() ThreadDeleted                   { return "thread.deleted" }
448func (c ThreadMessage) Default() ThreadMessage                   { return "thread.message" }
449func (c ThreadMessageCompleted) Default() ThreadMessageCompleted { return "thread.message.completed" }
450func (c ThreadMessageCreated) Default() ThreadMessageCreated     { return "thread.message.created" }
451func (c ThreadMessageDeleted) Default() ThreadMessageDeleted     { return "thread.message.deleted" }
452func (c ThreadMessageDelta) Default() ThreadMessageDelta         { return "thread.message.delta" }
453func (c ThreadMessageInProgress) Default() ThreadMessageInProgress {
454	return "thread.message.in_progress"
455}
456func (c ThreadMessageIncomplete) Default() ThreadMessageIncomplete {
457	return "thread.message.incomplete"
458}
459func (c ThreadRun) Default() ThreadRun                     { return "thread.run" }
460func (c ThreadRunCancelled) Default() ThreadRunCancelled   { return "thread.run.cancelled" }
461func (c ThreadRunCancelling) Default() ThreadRunCancelling { return "thread.run.cancelling" }
462func (c ThreadRunCompleted) Default() ThreadRunCompleted   { return "thread.run.completed" }
463func (c ThreadRunCreated) Default() ThreadRunCreated       { return "thread.run.created" }
464func (c ThreadRunExpired) Default() ThreadRunExpired       { return "thread.run.expired" }
465func (c ThreadRunFailed) Default() ThreadRunFailed         { return "thread.run.failed" }
466func (c ThreadRunInProgress) Default() ThreadRunInProgress { return "thread.run.in_progress" }
467func (c ThreadRunIncomplete) Default() ThreadRunIncomplete { return "thread.run.incomplete" }
468func (c ThreadRunQueued) Default() ThreadRunQueued         { return "thread.run.queued" }
469func (c ThreadRunRequiresAction) Default() ThreadRunRequiresAction {
470	return "thread.run.requires_action"
471}
472func (c ThreadRunStep) Default() ThreadRunStep                   { return "thread.run.step" }
473func (c ThreadRunStepCancelled) Default() ThreadRunStepCancelled { return "thread.run.step.cancelled" }
474func (c ThreadRunStepCompleted) Default() ThreadRunStepCompleted { return "thread.run.step.completed" }
475func (c ThreadRunStepCreated) Default() ThreadRunStepCreated     { return "thread.run.step.created" }
476func (c ThreadRunStepDelta) Default() ThreadRunStepDelta         { return "thread.run.step.delta" }
477func (c ThreadRunStepExpired) Default() ThreadRunStepExpired     { return "thread.run.step.expired" }
478func (c ThreadRunStepFailed) Default() ThreadRunStepFailed       { return "thread.run.step.failed" }
479func (c ThreadRunStepInProgress) Default() ThreadRunStepInProgress {
480	return "thread.run.step.in_progress"
481}
482func (c Tokens) Default() Tokens                           { return "tokens" }
483func (c Tool) Default() Tool                               { return "tool" }
484func (c ToolCalls) Default() ToolCalls                     { return "tool_calls" }
485func (c TranscriptTextDelta) Default() TranscriptTextDelta { return "transcript.text.delta" }
486func (c TranscriptTextDone) Default() TranscriptTextDone   { return "transcript.text.done" }
487func (c Type) Default() Type                               { return "type" }
488func (c Upload) Default() Upload                           { return "upload" }
489func (c UploadPart) Default() UploadPart                   { return "upload.part" }
490func (c URLCitation) Default() URLCitation                 { return "url_citation" }
491func (c User) Default() User                               { return "user" }
492func (c VectorStore) Default() VectorStore                 { return "vector_store" }
493func (c VectorStoreDeleted) Default() VectorStoreDeleted   { return "vector_store.deleted" }
494func (c VectorStoreFile) Default() VectorStoreFile         { return "vector_store.file" }
495func (c VectorStoreFileContentPage) Default() VectorStoreFileContentPage {
496	return "vector_store.file_content.page"
497}
498func (c VectorStoreFileDeleted) Default() VectorStoreFileDeleted { return "vector_store.file.deleted" }
499func (c VectorStoreFilesBatch) Default() VectorStoreFilesBatch   { return "vector_store.files_batch" }
500func (c VectorStoreSearchResultsPage) Default() VectorStoreSearchResultsPage {
501	return "vector_store.search_results.page"
502}
503func (c Wait) Default() Wait                   { return "wait" }
504func (c Wandb) Default() Wandb                 { return "wandb" }
505func (c WebSearchCall) Default() WebSearchCall { return "web_search_call" }
506
507func (c Approximate) MarshalJSON() ([]byte, error)                           { return marshalString(c) }
508func (c Assistant) MarshalJSON() ([]byte, error)                             { return marshalString(c) }
509func (c AssistantDeleted) MarshalJSON() ([]byte, error)                      { return marshalString(c) }
510func (c Auto) MarshalJSON() ([]byte, error)                                  { return marshalString(c) }
511func (c Batch) MarshalJSON() ([]byte, error)                                 { return marshalString(c) }
512func (c BatchCancelled) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
513func (c BatchCompleted) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
514func (c BatchExpired) MarshalJSON() ([]byte, error)                          { return marshalString(c) }
515func (c BatchFailed) MarshalJSON() ([]byte, error)                           { return marshalString(c) }
516func (c ChatCompletion) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
517func (c ChatCompletionChunk) MarshalJSON() ([]byte, error)                   { return marshalString(c) }
518func (c ChatCompletionDeleted) MarshalJSON() ([]byte, error)                 { return marshalString(c) }
519func (c CheckpointPermission) MarshalJSON() ([]byte, error)                  { return marshalString(c) }
520func (c Click) MarshalJSON() ([]byte, error)                                 { return marshalString(c) }
521func (c CodeInterpreter) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
522func (c CodeInterpreterCall) MarshalJSON() ([]byte, error)                   { return marshalString(c) }
523func (c ComputerCallOutput) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
524func (c ComputerScreenshot) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
525func (c ComputerUsePreview) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
526func (c ContainerFileCitation) MarshalJSON() ([]byte, error)                 { return marshalString(c) }
527func (c ContainerFile) MarshalJSON() ([]byte, error)                         { return marshalString(c) }
528func (c Content) MarshalJSON() ([]byte, error)                               { return marshalString(c) }
529func (c Developer) MarshalJSON() ([]byte, error)                             { return marshalString(c) }
530func (c DoubleClick) MarshalJSON() ([]byte, error)                           { return marshalString(c) }
531func (c Drag) MarshalJSON() ([]byte, error)                                  { return marshalString(c) }
532func (c Duration) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
533func (c Embedding) MarshalJSON() ([]byte, error)                             { return marshalString(c) }
534func (c Error) MarshalJSON() ([]byte, error)                                 { return marshalString(c) }
535func (c EvalRunCanceled) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
536func (c EvalRunFailed) MarshalJSON() ([]byte, error)                         { return marshalString(c) }
537func (c EvalRunSucceeded) MarshalJSON() ([]byte, error)                      { return marshalString(c) }
538func (c Exec) MarshalJSON() ([]byte, error)                                  { return marshalString(c) }
539func (c File) MarshalJSON() ([]byte, error)                                  { return marshalString(c) }
540func (c FileCitation) MarshalJSON() ([]byte, error)                          { return marshalString(c) }
541func (c FilePath) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
542func (c FileSearch) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
543func (c FileSearchCall) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
544func (c Find) MarshalJSON() ([]byte, error)                                  { return marshalString(c) }
545func (c FineTuningJob) MarshalJSON() ([]byte, error)                         { return marshalString(c) }
546func (c FineTuningJobCancelled) MarshalJSON() ([]byte, error)                { return marshalString(c) }
547func (c FineTuningJobCheckpoint) MarshalJSON() ([]byte, error)               { return marshalString(c) }
548func (c FineTuningJobEvent) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
549func (c FineTuningJobFailed) MarshalJSON() ([]byte, error)                   { return marshalString(c) }
550func (c FineTuningJobSucceeded) MarshalJSON() ([]byte, error)                { return marshalString(c) }
551func (c Function) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
552func (c FunctionCall) MarshalJSON() ([]byte, error)                          { return marshalString(c) }
553func (c FunctionCallOutput) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
554func (c Image) MarshalJSON() ([]byte, error)                                 { return marshalString(c) }
555func (c ImageFile) MarshalJSON() ([]byte, error)                             { return marshalString(c) }
556func (c ImageGeneration) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
557func (c ImageGenerationCall) MarshalJSON() ([]byte, error)                   { return marshalString(c) }
558func (c ImageURL) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
559func (c InputAudio) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
560func (c InputFile) MarshalJSON() ([]byte, error)                             { return marshalString(c) }
561func (c InputImage) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
562func (c InputText) MarshalJSON() ([]byte, error)                             { return marshalString(c) }
563func (c JSONObject) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
564func (c JSONSchema) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
565func (c Keypress) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
566func (c LabelModel) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
567func (c LastActiveAt) MarshalJSON() ([]byte, error)                          { return marshalString(c) }
568func (c List) MarshalJSON() ([]byte, error)                                  { return marshalString(c) }
569func (c LocalShell) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
570func (c LocalShellCall) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
571func (c LocalShellCallOutput) MarshalJSON() ([]byte, error)                  { return marshalString(c) }
572func (c Logs) MarshalJSON() ([]byte, error)                                  { return marshalString(c) }
573func (c Mcp) MarshalJSON() ([]byte, error)                                   { return marshalString(c) }
574func (c McpApprovalRequest) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
575func (c McpApprovalResponse) MarshalJSON() ([]byte, error)                   { return marshalString(c) }
576func (c McpCall) MarshalJSON() ([]byte, error)                               { return marshalString(c) }
577func (c McpListTools) MarshalJSON() ([]byte, error)                          { return marshalString(c) }
578func (c Message) MarshalJSON() ([]byte, error)                               { return marshalString(c) }
579func (c MessageCreation) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
580func (c Model) MarshalJSON() ([]byte, error)                                 { return marshalString(c) }
581func (c Move) MarshalJSON() ([]byte, error)                                  { return marshalString(c) }
582func (c Multi) MarshalJSON() ([]byte, error)                                 { return marshalString(c) }
583func (c OpenPage) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
584func (c Other) MarshalJSON() ([]byte, error)                                 { return marshalString(c) }
585func (c OutputAudio) MarshalJSON() ([]byte, error)                           { return marshalString(c) }
586func (c OutputText) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
587func (c Python) MarshalJSON() ([]byte, error)                                { return marshalString(c) }
588func (c Reasoning) MarshalJSON() ([]byte, error)                             { return marshalString(c) }
589func (c Refusal) MarshalJSON() ([]byte, error)                               { return marshalString(c) }
590func (c Response) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
591func (c ResponseAudioDelta) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
592func (c ResponseAudioDone) MarshalJSON() ([]byte, error)                     { return marshalString(c) }
593func (c ResponseAudioTranscriptDelta) MarshalJSON() ([]byte, error)          { return marshalString(c) }
594func (c ResponseAudioTranscriptDone) MarshalJSON() ([]byte, error)           { return marshalString(c) }
595func (c ResponseCancelled) MarshalJSON() ([]byte, error)                     { return marshalString(c) }
596func (c ResponseCodeInterpreterCallCodeDelta) MarshalJSON() ([]byte, error)  { return marshalString(c) }
597func (c ResponseCodeInterpreterCallCodeDone) MarshalJSON() ([]byte, error)   { return marshalString(c) }
598func (c ResponseCodeInterpreterCallCompleted) MarshalJSON() ([]byte, error)  { return marshalString(c) }
599func (c ResponseCodeInterpreterCallInProgress) MarshalJSON() ([]byte, error) { return marshalString(c) }
600func (c ResponseCodeInterpreterCallInterpreting) MarshalJSON() ([]byte, error) {
601	return marshalString(c)
602}
603func (c ResponseCompleted) MarshalJSON() ([]byte, error)                     { return marshalString(c) }
604func (c ResponseContentPartAdded) MarshalJSON() ([]byte, error)              { return marshalString(c) }
605func (c ResponseContentPartDone) MarshalJSON() ([]byte, error)               { return marshalString(c) }
606func (c ResponseCreated) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
607func (c ResponseFailed) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
608func (c ResponseFileSearchCallCompleted) MarshalJSON() ([]byte, error)       { return marshalString(c) }
609func (c ResponseFileSearchCallInProgress) MarshalJSON() ([]byte, error)      { return marshalString(c) }
610func (c ResponseFileSearchCallSearching) MarshalJSON() ([]byte, error)       { return marshalString(c) }
611func (c ResponseFunctionCallArgumentsDelta) MarshalJSON() ([]byte, error)    { return marshalString(c) }
612func (c ResponseFunctionCallArgumentsDone) MarshalJSON() ([]byte, error)     { return marshalString(c) }
613func (c ResponseImageGenerationCallCompleted) MarshalJSON() ([]byte, error)  { return marshalString(c) }
614func (c ResponseImageGenerationCallGenerating) MarshalJSON() ([]byte, error) { return marshalString(c) }
615func (c ResponseImageGenerationCallInProgress) MarshalJSON() ([]byte, error) { return marshalString(c) }
616func (c ResponseImageGenerationCallPartialImage) MarshalJSON() ([]byte, error) {
617	return marshalString(c)
618}
619func (c ResponseInProgress) MarshalJSON() ([]byte, error)                { return marshalString(c) }
620func (c ResponseIncomplete) MarshalJSON() ([]byte, error)                { return marshalString(c) }
621func (c ResponseMcpCallArgumentsDelta) MarshalJSON() ([]byte, error)     { return marshalString(c) }
622func (c ResponseMcpCallArgumentsDone) MarshalJSON() ([]byte, error)      { return marshalString(c) }
623func (c ResponseMcpCallCompleted) MarshalJSON() ([]byte, error)          { return marshalString(c) }
624func (c ResponseMcpCallFailed) MarshalJSON() ([]byte, error)             { return marshalString(c) }
625func (c ResponseMcpCallInProgress) MarshalJSON() ([]byte, error)         { return marshalString(c) }
626func (c ResponseMcpListToolsCompleted) MarshalJSON() ([]byte, error)     { return marshalString(c) }
627func (c ResponseMcpListToolsFailed) MarshalJSON() ([]byte, error)        { return marshalString(c) }
628func (c ResponseMcpListToolsInProgress) MarshalJSON() ([]byte, error)    { return marshalString(c) }
629func (c ResponseOutputItemAdded) MarshalJSON() ([]byte, error)           { return marshalString(c) }
630func (c ResponseOutputItemDone) MarshalJSON() ([]byte, error)            { return marshalString(c) }
631func (c ResponseOutputTextAnnotationAdded) MarshalJSON() ([]byte, error) { return marshalString(c) }
632func (c ResponseOutputTextDelta) MarshalJSON() ([]byte, error)           { return marshalString(c) }
633func (c ResponseOutputTextDone) MarshalJSON() ([]byte, error)            { return marshalString(c) }
634func (c ResponseQueued) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
635func (c ResponseReasoningSummaryPartAdded) MarshalJSON() ([]byte, error) { return marshalString(c) }
636func (c ResponseReasoningSummaryPartDone) MarshalJSON() ([]byte, error)  { return marshalString(c) }
637func (c ResponseReasoningSummaryTextDelta) MarshalJSON() ([]byte, error) { return marshalString(c) }
638func (c ResponseReasoningSummaryTextDone) MarshalJSON() ([]byte, error)  { return marshalString(c) }
639func (c ResponseReasoningSummaryDelta) MarshalJSON() ([]byte, error)     { return marshalString(c) }
640func (c ResponseReasoningSummaryDone) MarshalJSON() ([]byte, error)      { return marshalString(c) }
641func (c ResponseReasoningDelta) MarshalJSON() ([]byte, error)            { return marshalString(c) }
642func (c ResponseReasoningDone) MarshalJSON() ([]byte, error)             { return marshalString(c) }
643func (c ResponseRefusalDelta) MarshalJSON() ([]byte, error)              { return marshalString(c) }
644func (c ResponseRefusalDone) MarshalJSON() ([]byte, error)               { return marshalString(c) }
645func (c ResponseWebSearchCallCompleted) MarshalJSON() ([]byte, error)    { return marshalString(c) }
646func (c ResponseWebSearchCallInProgress) MarshalJSON() ([]byte, error)   { return marshalString(c) }
647func (c ResponseWebSearchCallSearching) MarshalJSON() ([]byte, error)    { return marshalString(c) }
648func (c ScoreModel) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
649func (c Screenshot) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
650func (c Scroll) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
651func (c Search) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
652func (c Static) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
653func (c StringCheck) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
654func (c SubmitToolOutputs) MarshalJSON() ([]byte, error)                 { return marshalString(c) }
655func (c SummaryText) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
656func (c System) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
657func (c Text) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
658func (c TextCompletion) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
659func (c TextSimilarity) MarshalJSON() ([]byte, error)                    { return marshalString(c) }
660func (c Thread) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
661func (c ThreadCreated) MarshalJSON() ([]byte, error)                     { return marshalString(c) }
662func (c ThreadDeleted) MarshalJSON() ([]byte, error)                     { return marshalString(c) }
663func (c ThreadMessage) MarshalJSON() ([]byte, error)                     { return marshalString(c) }
664func (c ThreadMessageCompleted) MarshalJSON() ([]byte, error)            { return marshalString(c) }
665func (c ThreadMessageCreated) MarshalJSON() ([]byte, error)              { return marshalString(c) }
666func (c ThreadMessageDeleted) MarshalJSON() ([]byte, error)              { return marshalString(c) }
667func (c ThreadMessageDelta) MarshalJSON() ([]byte, error)                { return marshalString(c) }
668func (c ThreadMessageInProgress) MarshalJSON() ([]byte, error)           { return marshalString(c) }
669func (c ThreadMessageIncomplete) MarshalJSON() ([]byte, error)           { return marshalString(c) }
670func (c ThreadRun) MarshalJSON() ([]byte, error)                         { return marshalString(c) }
671func (c ThreadRunCancelled) MarshalJSON() ([]byte, error)                { return marshalString(c) }
672func (c ThreadRunCancelling) MarshalJSON() ([]byte, error)               { return marshalString(c) }
673func (c ThreadRunCompleted) MarshalJSON() ([]byte, error)                { return marshalString(c) }
674func (c ThreadRunCreated) MarshalJSON() ([]byte, error)                  { return marshalString(c) }
675func (c ThreadRunExpired) MarshalJSON() ([]byte, error)                  { return marshalString(c) }
676func (c ThreadRunFailed) MarshalJSON() ([]byte, error)                   { return marshalString(c) }
677func (c ThreadRunInProgress) MarshalJSON() ([]byte, error)               { return marshalString(c) }
678func (c ThreadRunIncomplete) MarshalJSON() ([]byte, error)               { return marshalString(c) }
679func (c ThreadRunQueued) MarshalJSON() ([]byte, error)                   { return marshalString(c) }
680func (c ThreadRunRequiresAction) MarshalJSON() ([]byte, error)           { return marshalString(c) }
681func (c ThreadRunStep) MarshalJSON() ([]byte, error)                     { return marshalString(c) }
682func (c ThreadRunStepCancelled) MarshalJSON() ([]byte, error)            { return marshalString(c) }
683func (c ThreadRunStepCompleted) MarshalJSON() ([]byte, error)            { return marshalString(c) }
684func (c ThreadRunStepCreated) MarshalJSON() ([]byte, error)              { return marshalString(c) }
685func (c ThreadRunStepDelta) MarshalJSON() ([]byte, error)                { return marshalString(c) }
686func (c ThreadRunStepExpired) MarshalJSON() ([]byte, error)              { return marshalString(c) }
687func (c ThreadRunStepFailed) MarshalJSON() ([]byte, error)               { return marshalString(c) }
688func (c ThreadRunStepInProgress) MarshalJSON() ([]byte, error)           { return marshalString(c) }
689func (c Tokens) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
690func (c Tool) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
691func (c ToolCalls) MarshalJSON() ([]byte, error)                         { return marshalString(c) }
692func (c TranscriptTextDelta) MarshalJSON() ([]byte, error)               { return marshalString(c) }
693func (c TranscriptTextDone) MarshalJSON() ([]byte, error)                { return marshalString(c) }
694func (c Type) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
695func (c Upload) MarshalJSON() ([]byte, error)                            { return marshalString(c) }
696func (c UploadPart) MarshalJSON() ([]byte, error)                        { return marshalString(c) }
697func (c URLCitation) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
698func (c User) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
699func (c VectorStore) MarshalJSON() ([]byte, error)                       { return marshalString(c) }
700func (c VectorStoreDeleted) MarshalJSON() ([]byte, error)                { return marshalString(c) }
701func (c VectorStoreFile) MarshalJSON() ([]byte, error)                   { return marshalString(c) }
702func (c VectorStoreFileContentPage) MarshalJSON() ([]byte, error)        { return marshalString(c) }
703func (c VectorStoreFileDeleted) MarshalJSON() ([]byte, error)            { return marshalString(c) }
704func (c VectorStoreFilesBatch) MarshalJSON() ([]byte, error)             { return marshalString(c) }
705func (c VectorStoreSearchResultsPage) MarshalJSON() ([]byte, error)      { return marshalString(c) }
706func (c Wait) MarshalJSON() ([]byte, error)                              { return marshalString(c) }
707func (c Wandb) MarshalJSON() ([]byte, error)                             { return marshalString(c) }
708func (c WebSearchCall) MarshalJSON() ([]byte, error)                     { return marshalString(c) }
709
710type constant[T any] interface {
711	Constant[T]
712	*T
713}
714
715func marshalString[T ~string, PT constant[T]](v T) ([]byte, error) {
716	var zero T
717	if v == zero {
718		v = PT(&v).Default()
719	}
720	return json.Marshal(string(v))
721}