Repository Public
1# Evals23> For the complete documentation index, see [llms.txt](/llms.txt). Markdown versions of documentation pages are available by appending `.md` to the page URL.45## Create eval67**post** `/evals`89Create the structure of an evaluation that can be used to test a model's performance.10An evaluation is a set of testing criteria and the config for a data source, which dictates the schema of the data used in the evaluation. After creating an evaluation, you can run it on different models and model parameters. We support several types of graders and datasources.11For more information, see the [Evals guide](/api/docs/guides/evals).1213### Body Parameters1415- `data_source_config: object { item_schema, type, include_sample_schema } or object { type, metadata } or object { type, metadata }`1617 The configuration for the data source used for the evaluation runs. Dictates the schema of the data used in the evaluation.1819 - `CustomDataSourceConfig object { item_schema, type, include_sample_schema }`2021 A CustomDataSourceConfig object that defines the schema for the data source used for the evaluation runs.22 This schema is used to define the shape of the data that will be:2324 - Used to define your testing criteria and25 - What data is required when creating a run2627 - `item_schema: map[unknown]`2829 The json schema for each row in the data source.3031 - `type: "custom"`3233 The type of data source. Always `custom`.3435 - `"custom"`3637 - `include_sample_schema: optional boolean`3839 Whether the eval should expect you to populate the sample namespace (ie, by generating responses off of your data source)4041 - `LogsDataSourceConfig object { type, metadata }`4243 A data source config which specifies the metadata property of your logs query.44 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.4546 - `type: "logs"`4748 The type of data source. Always `logs`.4950 - `"logs"`5152 - `metadata: optional map[unknown]`5354 Metadata filters for the logs data source.5556 - `StoredCompletionsDataSourceConfig object { type, metadata }`5758 Deprecated in favor of LogsDataSourceConfig.5960 - `type: "stored_completions"`6162 The type of data source. Always `stored_completions`.6364 - `"stored_completions"`6566 - `metadata: optional map[unknown]`6768 Metadata filters for the stored completions data source.6970- `testing_criteria: array of object { input, labels, model, 3 more } or StringCheckGrader or TextSimilarityGrader or 2 more`7172 A list of graders for all eval runs in this group. Graders can reference variables in the data source using double curly braces notation, like `{{item.variable_name}}`. To reference the model's output, use the `sample` namespace (ie, `{{sample.output_text}}`).7374 - `LabelModelGrader object { input, labels, model, 3 more }`7576 A LabelModelGrader object which uses a model to assign labels to each item77 in the evaluation.7879 - `input: array of object { content, role } or object { content, role, type }`8081 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.8283 - `SimpleInputMessage object { content, role }`8485 - `content: string`8687 The content of the message.8889 - `role: string`9091 The role of the message (e.g. "system", "assistant", "user").9293 - `EvalMessageObject object { content, role, type }`9495 A message input to the model with a role indicating instruction following96 hierarchy. Instructions given with the `developer` or `system` role take97 precedence over instructions given with the `user` role. Messages with the98 `assistant` role are presumed to have been generated by the model in previous99 interactions.100101 - `content: string or ResponseInputText or object { text, type } or 3 more`102103 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.104105 - `TextInput = string`106107 A text input to the model.108109 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`110111 A text input to the model.112113 - `text: string`114115 The text input to the model.116117 - `type: "input_text"`118119 The type of the input item. Always `input_text`.120121 - `"input_text"`122123 - `prompt_cache_breakpoint: optional object { mode }`124125 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.126127 - `mode: "explicit"`128129 The breakpoint mode. Always `explicit`.130131 - `"explicit"`132133 - `OutputText object { text, type }`134135 A text output from the model.136137 - `text: string`138139 The text output from the model.140141 - `type: "output_text"`142143 The type of the output text. Always `output_text`.144145 - `"output_text"`146147 - `InputImage object { image_url, type, detail }`148149 An image input block used within EvalItem content arrays.150151 - `image_url: string`152153 The URL of the image input.154155 - `type: "input_image"`156157 The type of the image input. Always `input_image`.158159 - `"input_image"`160161 - `detail: optional string`162163 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.164165 - `ResponseInputAudio object { input_audio, type }`166167 An audio input to the model.168169 - `input_audio: object { data, format }`170171 - `data: string`172173 Base64-encoded audio data.174175 - `format: "mp3" or "wav"`176177 The format of the audio data. Currently supported formats are `mp3` and178 `wav`.179180 - `"mp3"`181182 - `"wav"`183184 - `type: "input_audio"`185186 The type of the input item. Always `input_audio`.187188 - `"input_audio"`189190 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`191192 A list of inputs, each of which may be either an input text, output text, input193 image, or input audio object.194195 - `TextInput = string`196197 A text input to the model.198199 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`200201 A text input to the model.202203 - `OutputText object { text, type }`204205 A text output from the model.206207 - `text: string`208209 The text output from the model.210211 - `type: "output_text"`212213 The type of the output text. Always `output_text`.214215 - `"output_text"`216217 - `InputImage object { image_url, type, detail }`218219 An image input block used within EvalItem content arrays.220221 - `image_url: string`222223 The URL of the image input.224225 - `type: "input_image"`226227 The type of the image input. Always `input_image`.228229 - `"input_image"`230231 - `detail: optional string`232233 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.234235 - `ResponseInputAudio object { input_audio, type }`236237 An audio input to the model.238239 - `role: "user" or "assistant" or "system" or "developer"`240241 The role of the message input. One of `user`, `assistant`, `system`, or242 `developer`.243244 - `"user"`245246 - `"assistant"`247248 - `"system"`249250 - `"developer"`251252 - `type: optional "message"`253254 The type of the message input. Always `message`.255256 - `"message"`257258 - `labels: array of string`259260 The labels to classify to each item in the evaluation.261262 - `model: string`263264 The model to use for the evaluation. Must support structured outputs.265266 - `name: string`267268 The name of the grader.269270 - `passing_labels: array of string`271272 The labels that indicate a passing result. Must be a subset of labels.273274 - `type: "label_model"`275276 The object type, which is always `label_model`.277278 - `"label_model"`279280 - `StringCheckGrader object { input, name, operation, 2 more }`281282 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.283284 - `input: string`285286 The input text. This may include template strings.287288 - `name: string`289290 The name of the grader.291292 - `operation: "eq" or "ne" or "like" or "ilike"`293294 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.295296 - `"eq"`297298 - `"ne"`299300 - `"like"`301302 - `"ilike"`303304 - `reference: string`305306 The reference text. This may include template strings.307308 - `type: "string_check"`309310 The object type, which is always `string_check`.311312 - `"string_check"`313314 - `TextSimilarity = TextSimilarityGrader`315316 A TextSimilarityGrader object which grades text based on similarity metrics.317318 - `pass_threshold: number`319320 The threshold for the score.321322 - `Python = PythonGrader`323324 A PythonGrader object that runs a python script on the input.325326 - `pass_threshold: optional number`327328 The threshold for the score.329330 - `ScoreModel = ScoreModelGrader`331332 A ScoreModelGrader object that uses a model to assign a score to the input.333334 - `pass_threshold: optional number`335336 The threshold for the score.337338- `metadata: optional Metadata or null`339340 Set of 16 key-value pairs that can be attached to an object. This can be341 useful for storing additional information about the object in a structured342 format, and querying for objects via API or the dashboard.343344 Keys are strings with a maximum length of 64 characters. Values are strings345 with a maximum length of 512 characters.346347- `name: optional string`348349 The name of the evaluation.350351### Returns352353- `id: string`354355 Unique identifier for the evaluation.356357- `created_at: number`358359 The Unix timestamp (in seconds) for when the eval was created.360361- `data_source_config: EvalCustomDataSourceConfig or object { schema, type, metadata } or EvalStoredCompletionsDataSourceConfig`362363 Configuration of data sources used in runs of the evaluation.364365 - `EvalCustomDataSourceConfig object { schema, type }`366367 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.368 The response schema defines the shape of the data that will be:369370 - Used to define your testing criteria and371 - What data is required when creating a run372373 - `schema: map[unknown]`374375 The json schema for the run data source items.376 Learn how to build JSON schemas [here](https://json-schema.org/).377378 - `type: "custom"`379380 The type of data source. Always `custom`.381382 - `"custom"`383384 - `LogsDataSourceConfig object { schema, type, metadata }`385386 A LogsDataSourceConfig which specifies the metadata property of your logs query.387 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.388 The schema returned by this data source config is used to defined what variables are available in your evals.389 `item` and `sample` are both defined when using this data source config.390391 - `schema: map[unknown]`392393 The json schema for the run data source items.394 Learn how to build JSON schemas [here](https://json-schema.org/).395396 - `type: "logs"`397398 The type of data source. Always `logs`.399400 - `"logs"`401402 - `metadata: optional Metadata or null`403404 Set of 16 key-value pairs that can be attached to an object. This can be405 useful for storing additional information about the object in a structured406 format, and querying for objects via API or the dashboard.407408 Keys are strings with a maximum length of 64 characters. Values are strings409 with a maximum length of 512 characters.410411 - `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`412413 Deprecated in favor of LogsDataSourceConfig.414415 - `schema: map[unknown]`416417 The json schema for the run data source items.418 Learn how to build JSON schemas [here](https://json-schema.org/).419420 - `type: "stored_completions"`421422 The type of data source. Always `stored_completions`.423424 - `"stored_completions"`425426 - `metadata: optional Metadata or null`427428 Set of 16 key-value pairs that can be attached to an object. This can be429 useful for storing additional information about the object in a structured430 format, and querying for objects via API or the dashboard.431432 Keys are strings with a maximum length of 64 characters. Values are strings433 with a maximum length of 512 characters.434435- `metadata: Metadata or null`436437 Set of 16 key-value pairs that can be attached to an object. This can be438 useful for storing additional information about the object in a structured439 format, and querying for objects via API or the dashboard.440441 Keys are strings with a maximum length of 64 characters. Values are strings442 with a maximum length of 512 characters.443444- `name: string`445446 The name of the evaluation.447448- `object: "eval"`449450 The object type.451452 - `"eval"`453454- `testing_criteria: array of LabelModelGrader or StringCheckGrader or TextSimilarityGrader or 2 more`455456 A list of testing criteria.457458 - `LabelModelGrader object { input, labels, model, 3 more }`459460 A LabelModelGrader object which uses a model to assign labels to each item461 in the evaluation.462463 - `input: array of object { content, role, type }`464465 - `content: string or ResponseInputText or object { text, type } or 3 more`466467 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.468469 - `TextInput = string`470471 A text input to the model.472473 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`474475 A text input to the model.476477 - `text: string`478479 The text input to the model.480481 - `type: "input_text"`482483 The type of the input item. Always `input_text`.484485 - `"input_text"`486487 - `prompt_cache_breakpoint: optional object { mode }`488489 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.490491 - `mode: "explicit"`492493 The breakpoint mode. Always `explicit`.494495 - `"explicit"`496497 - `OutputText object { text, type }`498499 A text output from the model.500501 - `text: string`502503 The text output from the model.504505 - `type: "output_text"`506507 The type of the output text. Always `output_text`.508509 - `"output_text"`510511 - `InputImage object { image_url, type, detail }`512513 An image input block used within EvalItem content arrays.514515 - `image_url: string`516517 The URL of the image input.518519 - `type: "input_image"`520521 The type of the image input. Always `input_image`.522523 - `"input_image"`524525 - `detail: optional string`526527 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.528529 - `ResponseInputAudio object { input_audio, type }`530531 An audio input to the model.532533 - `input_audio: object { data, format }`534535 - `data: string`536537 Base64-encoded audio data.538539 - `format: "mp3" or "wav"`540541 The format of the audio data. Currently supported formats are `mp3` and542 `wav`.543544 - `"mp3"`545546 - `"wav"`547548 - `type: "input_audio"`549550 The type of the input item. Always `input_audio`.551552 - `"input_audio"`553554 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`555556 A list of inputs, each of which may be either an input text, output text, input557 image, or input audio object.558559 - `TextInput = string`560561 A text input to the model.562563 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`564565 A text input to the model.566567 - `OutputText object { text, type }`568569 A text output from the model.570571 - `text: string`572573 The text output from the model.574575 - `type: "output_text"`576577 The type of the output text. Always `output_text`.578579 - `"output_text"`580581 - `InputImage object { image_url, type, detail }`582583 An image input block used within EvalItem content arrays.584585 - `image_url: string`586587 The URL of the image input.588589 - `type: "input_image"`590591 The type of the image input. Always `input_image`.592593 - `"input_image"`594595 - `detail: optional string`596597 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.598599 - `ResponseInputAudio object { input_audio, type }`600601 An audio input to the model.602603 - `role: "user" or "assistant" or "system" or "developer"`604605 The role of the message input. One of `user`, `assistant`, `system`, or606 `developer`.607608 - `"user"`609610 - `"assistant"`611612 - `"system"`613614 - `"developer"`615616 - `type: optional "message"`617618 The type of the message input. Always `message`.619620 - `"message"`621622 - `labels: array of string`623624 The labels to assign to each item in the evaluation.625626 - `model: string`627628 The model to use for the evaluation. Must support structured outputs.629630 - `name: string`631632 The name of the grader.633634 - `passing_labels: array of string`635636 The labels that indicate a passing result. Must be a subset of labels.637638 - `type: "label_model"`639640 The object type, which is always `label_model`.641642 - `"label_model"`643644 - `StringCheckGrader object { input, name, operation, 2 more }`645646 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.647648 - `input: string`649650 The input text. This may include template strings.651652 - `name: string`653654 The name of the grader.655656 - `operation: "eq" or "ne" or "like" or "ilike"`657658 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.659660 - `"eq"`661662 - `"ne"`663664 - `"like"`665666 - `"ilike"`667668 - `reference: string`669670 The reference text. This may include template strings.671672 - `type: "string_check"`673674 The object type, which is always `string_check`.675676 - `"string_check"`677678 - `TextSimilarityGrader = TextSimilarityGrader`679680 A TextSimilarityGrader object which grades text based on similarity metrics.681682 - `pass_threshold: number`683684 The threshold for the score.685686 - `PythonGrader = PythonGrader`687688 A PythonGrader object that runs a python script on the input.689690 - `pass_threshold: optional number`691692 The threshold for the score.693694 - `ScoreModelGrader = ScoreModelGrader`695696 A ScoreModelGrader object that uses a model to assign a score to the input.697698 - `pass_threshold: optional number`699700 The threshold for the score.701702### Example703704```http705curl https://api.openai.com/v1/evals \706 -H 'Content-Type: application/json' \707 -H "Authorization: Bearer $OPENAI_API_KEY" \708 -d '{709 "data_source_config": {710 "item_schema": {711 "foo": "bar"712 },713 "type": "custom"714 },715 "testing_criteria": [716 {717 "input": [718 {719 "content": "content",720 "role": "role"721 }722 ],723 "labels": [724 "string"725 ],726 "model": "model",727 "name": "name",728 "passing_labels": [729 "string"730 ],731 "type": "label_model"732 }733 ]734 }'735```736737#### Response738739```json740{741 "id": "id",742 "created_at": 0,743 "data_source_config": {744 "schema": {745 "foo": "bar"746 },747 "type": "custom"748 },749 "metadata": {750 "foo": "string"751 },752 "name": "Chatbot effectiveness Evaluation",753 "object": "eval",754 "testing_criteria": [755 {756 "input": [757 {758 "content": "string",759 "role": "user",760 "type": "message"761 }762 ],763 "labels": [764 "string"765 ],766 "model": "model",767 "name": "name",768 "passing_labels": [769 "string"770 ],771 "type": "label_model"772 }773 ]774}775```776777### Example778779```http780curl https://api.openai.com/v1/evals \781 -H "Authorization: Bearer $OPENAI_API_KEY" \782 -H "Content-Type: application/json" \783 -d '{784 "name": "Sentiment",785 "data_source_config": {786 "type": "stored_completions",787 "metadata": {788 "usecase": "chatbot"789 }790 },791 "testing_criteria": [792 {793 "type": "label_model",794 "model": "o3-mini",795 "input": [796 {797 "role": "developer",798 "content": "Classify the sentiment of the following statement as one of 'positive', 'neutral', or 'negative'"799 },800 {801 "role": "user",802 "content": "Statement: {{item.input}}"803 }804 ],805 "passing_labels": [806 "positive"807 ],808 "labels": [809 "positive",810 "neutral",811 "negative"812 ],813 "name": "Example label grader"814 }815 ]816 }'817```818819#### Response820821```json822{823 "object": "eval",824 "id": "eval_67b7fa9a81a88190ab4aa417e397ea21",825 "data_source_config": {826 "type": "stored_completions",827 "metadata": {828 "usecase": "chatbot"829 },830 "schema": {831 "type": "object",832 "properties": {833 "item": {834 "type": "object"835 },836 "sample": {837 "type": "object"838 }839 },840 "required": [841 "item",842 "sample"843 ]844 },845 "testing_criteria": [846 {847 "name": "Example label grader",848 "type": "label_model",849 "model": "o3-mini",850 "input": [851 {852 "type": "message",853 "role": "developer",854 "content": {855 "type": "input_text",856 "text": "Classify the sentiment of the following statement as one of positive, neutral, or negative"857 }858 },859 {860 "type": "message",861 "role": "user",862 "content": {863 "type": "input_text",864 "text": "Statement: {{item.input}}"865 }866 }867 ],868 "passing_labels": [869 "positive"870 ],871 "labels": [872 "positive",873 "neutral",874 "negative"875 ]876 }877 ],878 "name": "Sentiment",879 "created_at": 1740110490,880 "metadata": {881 "description": "An eval for sentiment analysis"882 }883}884```885886## Delete an eval887888**delete** `/evals/{eval_id}`889890Delete an evaluation.891892### Path Parameters893894- `eval_id: string`895896### Returns897898- `deleted: boolean`899900- `eval_id: string`901902- `object: string`903904### Example905906```http907curl https://api.openai.com/v1/evals/$EVAL_ID \908 -X DELETE \909 -H "Authorization: Bearer $OPENAI_API_KEY"910```911912#### Response913914```json915{916 "deleted": true,917 "eval_id": "eval_abc123",918 "object": "eval.deleted"919}920```921922### Example923924```http925curl https://api.openai.com/v1/evals/eval_abc123 \926 -X DELETE \927 -H "Authorization: Bearer $OPENAI_API_KEY"928```929930#### Response931932```json933{934 "object": "eval.deleted",935 "deleted": true,936 "eval_id": "eval_abc123"937}938```939940## List evals941942**get** `/evals`943944List evaluations for a project.945946### Query Parameters947948- `after: optional string`949950 Identifier for the last eval from the previous pagination request.951952- `limit: optional number`953954 Number of evals to retrieve.955956- `order: optional "asc" or "desc"`957958 Sort order for evals by timestamp. Use `asc` for ascending order or `desc` for descending order.959960 - `"asc"`961962 - `"desc"`963964- `order_by: optional "created_at" or "updated_at"`965966 Evals can be ordered by creation time or last updated time. Use967 `created_at` for creation time or `updated_at` for last updated time.968969 - `"created_at"`970971 - `"updated_at"`972973### Returns974975- `data: array of object { id, created_at, data_source_config, 4 more }`976977 An array of eval objects.978979 - `id: string`980981 Unique identifier for the evaluation.982983 - `created_at: number`984985 The Unix timestamp (in seconds) for when the eval was created.986987 - `data_source_config: EvalCustomDataSourceConfig or object { schema, type, metadata } or EvalStoredCompletionsDataSourceConfig`988989 Configuration of data sources used in runs of the evaluation.990991 - `EvalCustomDataSourceConfig object { schema, type }`992993 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.994 The response schema defines the shape of the data that will be:995996 - Used to define your testing criteria and997 - What data is required when creating a run998999 - `schema: map[unknown]`10001001 The json schema for the run data source items.1002 Learn how to build JSON schemas [here](https://json-schema.org/).10031004 - `type: "custom"`10051006 The type of data source. Always `custom`.10071008 - `"custom"`10091010 - `LogsDataSourceConfig object { schema, type, metadata }`10111012 A LogsDataSourceConfig which specifies the metadata property of your logs query.1013 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.1014 The schema returned by this data source config is used to defined what variables are available in your evals.1015 `item` and `sample` are both defined when using this data source config.10161017 - `schema: map[unknown]`10181019 The json schema for the run data source items.1020 Learn how to build JSON schemas [here](https://json-schema.org/).10211022 - `type: "logs"`10231024 The type of data source. Always `logs`.10251026 - `"logs"`10271028 - `metadata: optional Metadata or null`10291030 Set of 16 key-value pairs that can be attached to an object. This can be1031 useful for storing additional information about the object in a structured1032 format, and querying for objects via API or the dashboard.10331034 Keys are strings with a maximum length of 64 characters. Values are strings1035 with a maximum length of 512 characters.10361037 - `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`10381039 Deprecated in favor of LogsDataSourceConfig.10401041 - `schema: map[unknown]`10421043 The json schema for the run data source items.1044 Learn how to build JSON schemas [here](https://json-schema.org/).10451046 - `type: "stored_completions"`10471048 The type of data source. Always `stored_completions`.10491050 - `"stored_completions"`10511052 - `metadata: optional Metadata or null`10531054 Set of 16 key-value pairs that can be attached to an object. This can be1055 useful for storing additional information about the object in a structured1056 format, and querying for objects via API or the dashboard.10571058 Keys are strings with a maximum length of 64 characters. Values are strings1059 with a maximum length of 512 characters.10601061 - `metadata: Metadata or null`10621063 Set of 16 key-value pairs that can be attached to an object. This can be1064 useful for storing additional information about the object in a structured1065 format, and querying for objects via API or the dashboard.10661067 Keys are strings with a maximum length of 64 characters. Values are strings1068 with a maximum length of 512 characters.10691070 - `name: string`10711072 The name of the evaluation.10731074 - `object: "eval"`10751076 The object type.10771078 - `"eval"`10791080 - `testing_criteria: array of LabelModelGrader or StringCheckGrader or TextSimilarityGrader or 2 more`10811082 A list of testing criteria.10831084 - `LabelModelGrader object { input, labels, model, 3 more }`10851086 A LabelModelGrader object which uses a model to assign labels to each item1087 in the evaluation.10881089 - `input: array of object { content, role, type }`10901091 - `content: string or ResponseInputText or object { text, type } or 3 more`10921093 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.10941095 - `TextInput = string`10961097 A text input to the model.10981099 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`11001101 A text input to the model.11021103 - `text: string`11041105 The text input to the model.11061107 - `type: "input_text"`11081109 The type of the input item. Always `input_text`.11101111 - `"input_text"`11121113 - `prompt_cache_breakpoint: optional object { mode }`11141115 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.11161117 - `mode: "explicit"`11181119 The breakpoint mode. Always `explicit`.11201121 - `"explicit"`11221123 - `OutputText object { text, type }`11241125 A text output from the model.11261127 - `text: string`11281129 The text output from the model.11301131 - `type: "output_text"`11321133 The type of the output text. Always `output_text`.11341135 - `"output_text"`11361137 - `InputImage object { image_url, type, detail }`11381139 An image input block used within EvalItem content arrays.11401141 - `image_url: string`11421143 The URL of the image input.11441145 - `type: "input_image"`11461147 The type of the image input. Always `input_image`.11481149 - `"input_image"`11501151 - `detail: optional string`11521153 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.11541155 - `ResponseInputAudio object { input_audio, type }`11561157 An audio input to the model.11581159 - `input_audio: object { data, format }`11601161 - `data: string`11621163 Base64-encoded audio data.11641165 - `format: "mp3" or "wav"`11661167 The format of the audio data. Currently supported formats are `mp3` and1168 `wav`.11691170 - `"mp3"`11711172 - `"wav"`11731174 - `type: "input_audio"`11751176 The type of the input item. Always `input_audio`.11771178 - `"input_audio"`11791180 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`11811182 A list of inputs, each of which may be either an input text, output text, input1183 image, or input audio object.11841185 - `TextInput = string`11861187 A text input to the model.11881189 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`11901191 A text input to the model.11921193 - `OutputText object { text, type }`11941195 A text output from the model.11961197 - `text: string`11981199 The text output from the model.12001201 - `type: "output_text"`12021203 The type of the output text. Always `output_text`.12041205 - `"output_text"`12061207 - `InputImage object { image_url, type, detail }`12081209 An image input block used within EvalItem content arrays.12101211 - `image_url: string`12121213 The URL of the image input.12141215 - `type: "input_image"`12161217 The type of the image input. Always `input_image`.12181219 - `"input_image"`12201221 - `detail: optional string`12221223 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.12241225 - `ResponseInputAudio object { input_audio, type }`12261227 An audio input to the model.12281229 - `role: "user" or "assistant" or "system" or "developer"`12301231 The role of the message input. One of `user`, `assistant`, `system`, or1232 `developer`.12331234 - `"user"`12351236 - `"assistant"`12371238 - `"system"`12391240 - `"developer"`12411242 - `type: optional "message"`12431244 The type of the message input. Always `message`.12451246 - `"message"`12471248 - `labels: array of string`12491250 The labels to assign to each item in the evaluation.12511252 - `model: string`12531254 The model to use for the evaluation. Must support structured outputs.12551256 - `name: string`12571258 The name of the grader.12591260 - `passing_labels: array of string`12611262 The labels that indicate a passing result. Must be a subset of labels.12631264 - `type: "label_model"`12651266 The object type, which is always `label_model`.12671268 - `"label_model"`12691270 - `StringCheckGrader object { input, name, operation, 2 more }`12711272 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.12731274 - `input: string`12751276 The input text. This may include template strings.12771278 - `name: string`12791280 The name of the grader.12811282 - `operation: "eq" or "ne" or "like" or "ilike"`12831284 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.12851286 - `"eq"`12871288 - `"ne"`12891290 - `"like"`12911292 - `"ilike"`12931294 - `reference: string`12951296 The reference text. This may include template strings.12971298 - `type: "string_check"`12991300 The object type, which is always `string_check`.13011302 - `"string_check"`13031304 - `TextSimilarityGrader = TextSimilarityGrader`13051306 A TextSimilarityGrader object which grades text based on similarity metrics.13071308 - `pass_threshold: number`13091310 The threshold for the score.13111312 - `PythonGrader = PythonGrader`13131314 A PythonGrader object that runs a python script on the input.13151316 - `pass_threshold: optional number`13171318 The threshold for the score.13191320 - `ScoreModelGrader = ScoreModelGrader`13211322 A ScoreModelGrader object that uses a model to assign a score to the input.13231324 - `pass_threshold: optional number`13251326 The threshold for the score.13271328- `first_id: string`13291330 The identifier of the first eval in the data array.13311332- `has_more: boolean`13331334 Indicates whether there are more evals available.13351336- `last_id: string`13371338 The identifier of the last eval in the data array.13391340- `object: "list"`13411342 The type of this object. It is always set to "list".13431344 - `"list"`13451346### Example13471348```http1349curl https://api.openai.com/v1/evals \1350 -H "Authorization: Bearer $OPENAI_API_KEY"1351```13521353#### Response13541355```json1356{1357 "data": [1358 {1359 "id": "id",1360 "created_at": 0,1361 "data_source_config": {1362 "schema": {1363 "foo": "bar"1364 },1365 "type": "custom"1366 },1367 "metadata": {1368 "foo": "string"1369 },1370 "name": "Chatbot effectiveness Evaluation",1371 "object": "eval",1372 "testing_criteria": [1373 {1374 "input": [1375 {1376 "content": "string",1377 "role": "user",1378 "type": "message"1379 }1380 ],1381 "labels": [1382 "string"1383 ],1384 "model": "model",1385 "name": "name",1386 "passing_labels": [1387 "string"1388 ],1389 "type": "label_model"1390 }1391 ]1392 }1393 ],1394 "first_id": "first_id",1395 "has_more": true,1396 "last_id": "last_id",1397 "object": "list"1398}1399```14001401### Example14021403```http1404curl https://api.openai.com/v1/evals?limit=1 \1405 -H "Authorization: Bearer $OPENAI_API_KEY" \1406 -H "Content-Type: application/json"1407```14081409#### Response14101411```json1412{1413 "object": "list",1414 "data": [1415 {1416 "id": "eval_67abd54d9b0081909a86353f6fb9317a",1417 "object": "eval",1418 "data_source_config": {1419 "type": "stored_completions",1420 "metadata": {1421 "usecase": "push_notifications_summarizer"1422 },1423 "schema": {1424 "type": "object",1425 "properties": {1426 "item": {1427 "type": "object"1428 },1429 "sample": {1430 "type": "object"1431 }1432 },1433 "required": [1434 "item",1435 "sample"1436 ]1437 }1438 },1439 "testing_criteria": [1440 {1441 "name": "Push Notification Summary Grader",1442 "id": "Push Notification Summary Grader-9b876f24-4762-4be9-aff4-db7a9b31c673",1443 "type": "label_model",1444 "model": "o3-mini",1445 "input": [1446 {1447 "type": "message",1448 "role": "developer",1449 "content": {1450 "type": "input_text",1451 "text": "\nLabel the following push notification summary as either correct or incorrect.\nThe push notification and the summary will be provided below.\nA good push notificiation summary is concise and snappy.\nIf it is good, then label it as correct, if not, then incorrect.\n"1452 }1453 },1454 {1455 "type": "message",1456 "role": "user",1457 "content": {1458 "type": "input_text",1459 "text": "\nPush notifications: {{item.input}}\nSummary: {{sample.output_text}}\n"1460 }1461 }1462 ],1463 "passing_labels": [1464 "correct"1465 ],1466 "labels": [1467 "correct",1468 "incorrect"1469 ],1470 "sampling_params": null1471 }1472 ],1473 "name": "Push Notification Summary Grader",1474 "created_at": 1739314509,1475 "metadata": {1476 "description": "A stored completions eval for push notification summaries"1477 }1478 }1479 ],1480 "first_id": "eval_67abd54d9b0081909a86353f6fb9317a",1481 "last_id": "eval_67aa884cf6688190b58f657d4441c8b7",1482 "has_more": true1483}1484```14851486## Get an eval14871488**get** `/evals/{eval_id}`14891490Get an evaluation by ID.14911492### Path Parameters14931494- `eval_id: string`14951496### Returns14971498- `id: string`14991500 Unique identifier for the evaluation.15011502- `created_at: number`15031504 The Unix timestamp (in seconds) for when the eval was created.15051506- `data_source_config: EvalCustomDataSourceConfig or object { schema, type, metadata } or EvalStoredCompletionsDataSourceConfig`15071508 Configuration of data sources used in runs of the evaluation.15091510 - `EvalCustomDataSourceConfig object { schema, type }`15111512 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.1513 The response schema defines the shape of the data that will be:15141515 - Used to define your testing criteria and1516 - What data is required when creating a run15171518 - `schema: map[unknown]`15191520 The json schema for the run data source items.1521 Learn how to build JSON schemas [here](https://json-schema.org/).15221523 - `type: "custom"`15241525 The type of data source. Always `custom`.15261527 - `"custom"`15281529 - `LogsDataSourceConfig object { schema, type, metadata }`15301531 A LogsDataSourceConfig which specifies the metadata property of your logs query.1532 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.1533 The schema returned by this data source config is used to defined what variables are available in your evals.1534 `item` and `sample` are both defined when using this data source config.15351536 - `schema: map[unknown]`15371538 The json schema for the run data source items.1539 Learn how to build JSON schemas [here](https://json-schema.org/).15401541 - `type: "logs"`15421543 The type of data source. Always `logs`.15441545 - `"logs"`15461547 - `metadata: optional Metadata or null`15481549 Set of 16 key-value pairs that can be attached to an object. This can be1550 useful for storing additional information about the object in a structured1551 format, and querying for objects via API or the dashboard.15521553 Keys are strings with a maximum length of 64 characters. Values are strings1554 with a maximum length of 512 characters.15551556 - `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`15571558 Deprecated in favor of LogsDataSourceConfig.15591560 - `schema: map[unknown]`15611562 The json schema for the run data source items.1563 Learn how to build JSON schemas [here](https://json-schema.org/).15641565 - `type: "stored_completions"`15661567 The type of data source. Always `stored_completions`.15681569 - `"stored_completions"`15701571 - `metadata: optional Metadata or null`15721573 Set of 16 key-value pairs that can be attached to an object. This can be1574 useful for storing additional information about the object in a structured1575 format, and querying for objects via API or the dashboard.15761577 Keys are strings with a maximum length of 64 characters. Values are strings1578 with a maximum length of 512 characters.15791580- `metadata: Metadata or null`15811582 Set of 16 key-value pairs that can be attached to an object. This can be1583 useful for storing additional information about the object in a structured1584 format, and querying for objects via API or the dashboard.15851586 Keys are strings with a maximum length of 64 characters. Values are strings1587 with a maximum length of 512 characters.15881589- `name: string`15901591 The name of the evaluation.15921593- `object: "eval"`15941595 The object type.15961597 - `"eval"`15981599- `testing_criteria: array of LabelModelGrader or StringCheckGrader or TextSimilarityGrader or 2 more`16001601 A list of testing criteria.16021603 - `LabelModelGrader object { input, labels, model, 3 more }`16041605 A LabelModelGrader object which uses a model to assign labels to each item1606 in the evaluation.16071608 - `input: array of object { content, role, type }`16091610 - `content: string or ResponseInputText or object { text, type } or 3 more`16111612 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.16131614 - `TextInput = string`16151616 A text input to the model.16171618 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`16191620 A text input to the model.16211622 - `text: string`16231624 The text input to the model.16251626 - `type: "input_text"`16271628 The type of the input item. Always `input_text`.16291630 - `"input_text"`16311632 - `prompt_cache_breakpoint: optional object { mode }`16331634 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.16351636 - `mode: "explicit"`16371638 The breakpoint mode. Always `explicit`.16391640 - `"explicit"`16411642 - `OutputText object { text, type }`16431644 A text output from the model.16451646 - `text: string`16471648 The text output from the model.16491650 - `type: "output_text"`16511652 The type of the output text. Always `output_text`.16531654 - `"output_text"`16551656 - `InputImage object { image_url, type, detail }`16571658 An image input block used within EvalItem content arrays.16591660 - `image_url: string`16611662 The URL of the image input.16631664 - `type: "input_image"`16651666 The type of the image input. Always `input_image`.16671668 - `"input_image"`16691670 - `detail: optional string`16711672 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.16731674 - `ResponseInputAudio object { input_audio, type }`16751676 An audio input to the model.16771678 - `input_audio: object { data, format }`16791680 - `data: string`16811682 Base64-encoded audio data.16831684 - `format: "mp3" or "wav"`16851686 The format of the audio data. Currently supported formats are `mp3` and1687 `wav`.16881689 - `"mp3"`16901691 - `"wav"`16921693 - `type: "input_audio"`16941695 The type of the input item. Always `input_audio`.16961697 - `"input_audio"`16981699 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`17001701 A list of inputs, each of which may be either an input text, output text, input1702 image, or input audio object.17031704 - `TextInput = string`17051706 A text input to the model.17071708 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`17091710 A text input to the model.17111712 - `OutputText object { text, type }`17131714 A text output from the model.17151716 - `text: string`17171718 The text output from the model.17191720 - `type: "output_text"`17211722 The type of the output text. Always `output_text`.17231724 - `"output_text"`17251726 - `InputImage object { image_url, type, detail }`17271728 An image input block used within EvalItem content arrays.17291730 - `image_url: string`17311732 The URL of the image input.17331734 - `type: "input_image"`17351736 The type of the image input. Always `input_image`.17371738 - `"input_image"`17391740 - `detail: optional string`17411742 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.17431744 - `ResponseInputAudio object { input_audio, type }`17451746 An audio input to the model.17471748 - `role: "user" or "assistant" or "system" or "developer"`17491750 The role of the message input. One of `user`, `assistant`, `system`, or1751 `developer`.17521753 - `"user"`17541755 - `"assistant"`17561757 - `"system"`17581759 - `"developer"`17601761 - `type: optional "message"`17621763 The type of the message input. Always `message`.17641765 - `"message"`17661767 - `labels: array of string`17681769 The labels to assign to each item in the evaluation.17701771 - `model: string`17721773 The model to use for the evaluation. Must support structured outputs.17741775 - `name: string`17761777 The name of the grader.17781779 - `passing_labels: array of string`17801781 The labels that indicate a passing result. Must be a subset of labels.17821783 - `type: "label_model"`17841785 The object type, which is always `label_model`.17861787 - `"label_model"`17881789 - `StringCheckGrader object { input, name, operation, 2 more }`17901791 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.17921793 - `input: string`17941795 The input text. This may include template strings.17961797 - `name: string`17981799 The name of the grader.18001801 - `operation: "eq" or "ne" or "like" or "ilike"`18021803 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.18041805 - `"eq"`18061807 - `"ne"`18081809 - `"like"`18101811 - `"ilike"`18121813 - `reference: string`18141815 The reference text. This may include template strings.18161817 - `type: "string_check"`18181819 The object type, which is always `string_check`.18201821 - `"string_check"`18221823 - `TextSimilarityGrader = TextSimilarityGrader`18241825 A TextSimilarityGrader object which grades text based on similarity metrics.18261827 - `pass_threshold: number`18281829 The threshold for the score.18301831 - `PythonGrader = PythonGrader`18321833 A PythonGrader object that runs a python script on the input.18341835 - `pass_threshold: optional number`18361837 The threshold for the score.18381839 - `ScoreModelGrader = ScoreModelGrader`18401841 A ScoreModelGrader object that uses a model to assign a score to the input.18421843 - `pass_threshold: optional number`18441845 The threshold for the score.18461847### Example18481849```http1850curl https://api.openai.com/v1/evals/$EVAL_ID \1851 -H "Authorization: Bearer $OPENAI_API_KEY"1852```18531854#### Response18551856```json1857{1858 "id": "id",1859 "created_at": 0,1860 "data_source_config": {1861 "schema": {1862 "foo": "bar"1863 },1864 "type": "custom"1865 },1866 "metadata": {1867 "foo": "string"1868 },1869 "name": "Chatbot effectiveness Evaluation",1870 "object": "eval",1871 "testing_criteria": [1872 {1873 "input": [1874 {1875 "content": "string",1876 "role": "user",1877 "type": "message"1878 }1879 ],1880 "labels": [1881 "string"1882 ],1883 "model": "model",1884 "name": "name",1885 "passing_labels": [1886 "string"1887 ],1888 "type": "label_model"1889 }1890 ]1891}1892```18931894### Example18951896```http1897curl https://api.openai.com/v1/evals/eval_67abd54d9b0081909a86353f6fb9317a \1898 -H "Authorization: Bearer $OPENAI_API_KEY" \1899 -H "Content-Type: application/json"1900```19011902#### Response19031904```json1905{1906 "object": "eval",1907 "id": "eval_67abd54d9b0081909a86353f6fb9317a",1908 "data_source_config": {1909 "type": "custom",1910 "schema": {1911 "type": "object",1912 "properties": {1913 "item": {1914 "type": "object",1915 "properties": {1916 "input": {1917 "type": "string"1918 },1919 "ground_truth": {1920 "type": "string"1921 }1922 },1923 "required": [1924 "input",1925 "ground_truth"1926 ]1927 }1928 },1929 "required": [1930 "item"1931 ]1932 }1933 },1934 "testing_criteria": [1935 {1936 "name": "String check",1937 "id": "String check-2eaf2d8d-d649-4335-8148-9535a7ca73c2",1938 "type": "string_check",1939 "input": "{{item.input}}",1940 "reference": "{{item.ground_truth}}",1941 "operation": "eq"1942 }1943 ],1944 "name": "External Data Eval",1945 "created_at": 1739314509,1946 "metadata": {},1947}1948```19491950## Update an eval19511952**post** `/evals/{eval_id}`19531954Update certain properties of an evaluation.19551956### Path Parameters19571958- `eval_id: string`19591960### Body Parameters19611962- `metadata: optional Metadata or null`19631964 Set of 16 key-value pairs that can be attached to an object. This can be1965 useful for storing additional information about the object in a structured1966 format, and querying for objects via API or the dashboard.19671968 Keys are strings with a maximum length of 64 characters. Values are strings1969 with a maximum length of 512 characters.19701971- `name: optional string`19721973 Rename the evaluation.19741975### Returns19761977- `id: string`19781979 Unique identifier for the evaluation.19801981- `created_at: number`19821983 The Unix timestamp (in seconds) for when the eval was created.19841985- `data_source_config: EvalCustomDataSourceConfig or object { schema, type, metadata } or EvalStoredCompletionsDataSourceConfig`19861987 Configuration of data sources used in runs of the evaluation.19881989 - `EvalCustomDataSourceConfig object { schema, type }`19901991 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.1992 The response schema defines the shape of the data that will be:19931994 - Used to define your testing criteria and1995 - What data is required when creating a run19961997 - `schema: map[unknown]`19981999 The json schema for the run data source items.2000 Learn how to build JSON schemas [here](https://json-schema.org/).20012002 - `type: "custom"`20032004 The type of data source. Always `custom`.20052006 - `"custom"`20072008 - `LogsDataSourceConfig object { schema, type, metadata }`20092010 A LogsDataSourceConfig which specifies the metadata property of your logs query.2011 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.2012 The schema returned by this data source config is used to defined what variables are available in your evals.2013 `item` and `sample` are both defined when using this data source config.20142015 - `schema: map[unknown]`20162017 The json schema for the run data source items.2018 Learn how to build JSON schemas [here](https://json-schema.org/).20192020 - `type: "logs"`20212022 The type of data source. Always `logs`.20232024 - `"logs"`20252026 - `metadata: optional Metadata or null`20272028 Set of 16 key-value pairs that can be attached to an object. This can be2029 useful for storing additional information about the object in a structured2030 format, and querying for objects via API or the dashboard.20312032 Keys are strings with a maximum length of 64 characters. Values are strings2033 with a maximum length of 512 characters.20342035 - `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`20362037 Deprecated in favor of LogsDataSourceConfig.20382039 - `schema: map[unknown]`20402041 The json schema for the run data source items.2042 Learn how to build JSON schemas [here](https://json-schema.org/).20432044 - `type: "stored_completions"`20452046 The type of data source. Always `stored_completions`.20472048 - `"stored_completions"`20492050 - `metadata: optional Metadata or null`20512052 Set of 16 key-value pairs that can be attached to an object. This can be2053 useful for storing additional information about the object in a structured2054 format, and querying for objects via API or the dashboard.20552056 Keys are strings with a maximum length of 64 characters. Values are strings2057 with a maximum length of 512 characters.20582059- `metadata: Metadata or null`20602061 Set of 16 key-value pairs that can be attached to an object. This can be2062 useful for storing additional information about the object in a structured2063 format, and querying for objects via API or the dashboard.20642065 Keys are strings with a maximum length of 64 characters. Values are strings2066 with a maximum length of 512 characters.20672068- `name: string`20692070 The name of the evaluation.20712072- `object: "eval"`20732074 The object type.20752076 - `"eval"`20772078- `testing_criteria: array of LabelModelGrader or StringCheckGrader or TextSimilarityGrader or 2 more`20792080 A list of testing criteria.20812082 - `LabelModelGrader object { input, labels, model, 3 more }`20832084 A LabelModelGrader object which uses a model to assign labels to each item2085 in the evaluation.20862087 - `input: array of object { content, role, type }`20882089 - `content: string or ResponseInputText or object { text, type } or 3 more`20902091 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.20922093 - `TextInput = string`20942095 A text input to the model.20962097 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`20982099 A text input to the model.21002101 - `text: string`21022103 The text input to the model.21042105 - `type: "input_text"`21062107 The type of the input item. Always `input_text`.21082109 - `"input_text"`21102111 - `prompt_cache_breakpoint: optional object { mode }`21122113 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.21142115 - `mode: "explicit"`21162117 The breakpoint mode. Always `explicit`.21182119 - `"explicit"`21202121 - `OutputText object { text, type }`21222123 A text output from the model.21242125 - `text: string`21262127 The text output from the model.21282129 - `type: "output_text"`21302131 The type of the output text. Always `output_text`.21322133 - `"output_text"`21342135 - `InputImage object { image_url, type, detail }`21362137 An image input block used within EvalItem content arrays.21382139 - `image_url: string`21402141 The URL of the image input.21422143 - `type: "input_image"`21442145 The type of the image input. Always `input_image`.21462147 - `"input_image"`21482149 - `detail: optional string`21502151 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.21522153 - `ResponseInputAudio object { input_audio, type }`21542155 An audio input to the model.21562157 - `input_audio: object { data, format }`21582159 - `data: string`21602161 Base64-encoded audio data.21622163 - `format: "mp3" or "wav"`21642165 The format of the audio data. Currently supported formats are `mp3` and2166 `wav`.21672168 - `"mp3"`21692170 - `"wav"`21712172 - `type: "input_audio"`21732174 The type of the input item. Always `input_audio`.21752176 - `"input_audio"`21772178 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`21792180 A list of inputs, each of which may be either an input text, output text, input2181 image, or input audio object.21822183 - `TextInput = string`21842185 A text input to the model.21862187 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`21882189 A text input to the model.21902191 - `OutputText object { text, type }`21922193 A text output from the model.21942195 - `text: string`21962197 The text output from the model.21982199 - `type: "output_text"`22002201 The type of the output text. Always `output_text`.22022203 - `"output_text"`22042205 - `InputImage object { image_url, type, detail }`22062207 An image input block used within EvalItem content arrays.22082209 - `image_url: string`22102211 The URL of the image input.22122213 - `type: "input_image"`22142215 The type of the image input. Always `input_image`.22162217 - `"input_image"`22182219 - `detail: optional string`22202221 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.22222223 - `ResponseInputAudio object { input_audio, type }`22242225 An audio input to the model.22262227 - `role: "user" or "assistant" or "system" or "developer"`22282229 The role of the message input. One of `user`, `assistant`, `system`, or2230 `developer`.22312232 - `"user"`22332234 - `"assistant"`22352236 - `"system"`22372238 - `"developer"`22392240 - `type: optional "message"`22412242 The type of the message input. Always `message`.22432244 - `"message"`22452246 - `labels: array of string`22472248 The labels to assign to each item in the evaluation.22492250 - `model: string`22512252 The model to use for the evaluation. Must support structured outputs.22532254 - `name: string`22552256 The name of the grader.22572258 - `passing_labels: array of string`22592260 The labels that indicate a passing result. Must be a subset of labels.22612262 - `type: "label_model"`22632264 The object type, which is always `label_model`.22652266 - `"label_model"`22672268 - `StringCheckGrader object { input, name, operation, 2 more }`22692270 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.22712272 - `input: string`22732274 The input text. This may include template strings.22752276 - `name: string`22772278 The name of the grader.22792280 - `operation: "eq" or "ne" or "like" or "ilike"`22812282 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.22832284 - `"eq"`22852286 - `"ne"`22872288 - `"like"`22892290 - `"ilike"`22912292 - `reference: string`22932294 The reference text. This may include template strings.22952296 - `type: "string_check"`22972298 The object type, which is always `string_check`.22992300 - `"string_check"`23012302 - `TextSimilarityGrader = TextSimilarityGrader`23032304 A TextSimilarityGrader object which grades text based on similarity metrics.23052306 - `pass_threshold: number`23072308 The threshold for the score.23092310 - `PythonGrader = PythonGrader`23112312 A PythonGrader object that runs a python script on the input.23132314 - `pass_threshold: optional number`23152316 The threshold for the score.23172318 - `ScoreModelGrader = ScoreModelGrader`23192320 A ScoreModelGrader object that uses a model to assign a score to the input.23212322 - `pass_threshold: optional number`23232324 The threshold for the score.23252326### Example23272328```http2329curl https://api.openai.com/v1/evals/$EVAL_ID \2330 -H 'Content-Type: application/json' \2331 -H "Authorization: Bearer $OPENAI_API_KEY" \2332 -d '{}'2333```23342335#### Response23362337```json2338{2339 "id": "id",2340 "created_at": 0,2341 "data_source_config": {2342 "schema": {2343 "foo": "bar"2344 },2345 "type": "custom"2346 },2347 "metadata": {2348 "foo": "string"2349 },2350 "name": "Chatbot effectiveness Evaluation",2351 "object": "eval",2352 "testing_criteria": [2353 {2354 "input": [2355 {2356 "content": "string",2357 "role": "user",2358 "type": "message"2359 }2360 ],2361 "labels": [2362 "string"2363 ],2364 "model": "model",2365 "name": "name",2366 "passing_labels": [2367 "string"2368 ],2369 "type": "label_model"2370 }2371 ]2372}2373```23742375### Example23762377```http2378curl https://api.openai.com/v1/evals/eval_67abd54d9b0081909a86353f6fb9317a \2379 -H "Authorization: Bearer $OPENAI_API_KEY" \2380 -H "Content-Type: application/json" \2381 -d '{"name": "Updated Eval", "metadata": {"description": "Updated description"}}'2382```23832384#### Response23852386```json2387{2388 "object": "eval",2389 "id": "eval_67abd54d9b0081909a86353f6fb9317a",2390 "data_source_config": {2391 "type": "custom",2392 "schema": {2393 "type": "object",2394 "properties": {2395 "item": {2396 "type": "object",2397 "properties": {2398 "input": {2399 "type": "string"2400 },2401 "ground_truth": {2402 "type": "string"2403 }2404 },2405 "required": [2406 "input",2407 "ground_truth"2408 ]2409 }2410 },2411 "required": [2412 "item"2413 ]2414 }2415 },2416 "testing_criteria": [2417 {2418 "name": "String check",2419 "id": "String check-2eaf2d8d-d649-4335-8148-9535a7ca73c2",2420 "type": "string_check",2421 "input": "{{item.input}}",2422 "reference": "{{item.ground_truth}}",2423 "operation": "eq"2424 }2425 ],2426 "name": "Updated Eval",2427 "created_at": 1739314509,2428 "metadata": {"description": "Updated description"},2429}2430```24312432## Domain Types24332434### Eval Create Response24352436- `EvalCreateResponse object { id, created_at, data_source_config, 4 more }`24372438 An Eval object with a data source config and testing criteria.2439 An Eval represents a task to be done for your LLM integration.2440 Like:24412442 - Improve the quality of my chatbot2443 - See how well my chatbot handles customer support2444 - Check if o4-mini is better at my usecase than gpt-6-astra24452446 - `id: string`24472448 Unique identifier for the evaluation.24492450 - `created_at: number`24512452 The Unix timestamp (in seconds) for when the eval was created.24532454 - `data_source_config: EvalCustomDataSourceConfig or object { schema, type, metadata } or EvalStoredCompletionsDataSourceConfig`24552456 Configuration of data sources used in runs of the evaluation.24572458 - `EvalCustomDataSourceConfig object { schema, type }`24592460 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.2461 The response schema defines the shape of the data that will be:24622463 - Used to define your testing criteria and2464 - What data is required when creating a run24652466 - `schema: map[unknown]`24672468 The json schema for the run data source items.2469 Learn how to build JSON schemas [here](https://json-schema.org/).24702471 - `type: "custom"`24722473 The type of data source. Always `custom`.24742475 - `"custom"`24762477 - `LogsDataSourceConfig object { schema, type, metadata }`24782479 A LogsDataSourceConfig which specifies the metadata property of your logs query.2480 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.2481 The schema returned by this data source config is used to defined what variables are available in your evals.2482 `item` and `sample` are both defined when using this data source config.24832484 - `schema: map[unknown]`24852486 The json schema for the run data source items.2487 Learn how to build JSON schemas [here](https://json-schema.org/).24882489 - `type: "logs"`24902491 The type of data source. Always `logs`.24922493 - `"logs"`24942495 - `metadata: optional Metadata or null`24962497 Set of 16 key-value pairs that can be attached to an object. This can be2498 useful for storing additional information about the object in a structured2499 format, and querying for objects via API or the dashboard.25002501 Keys are strings with a maximum length of 64 characters. Values are strings2502 with a maximum length of 512 characters.25032504 - `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`25052506 Deprecated in favor of LogsDataSourceConfig.25072508 - `schema: map[unknown]`25092510 The json schema for the run data source items.2511 Learn how to build JSON schemas [here](https://json-schema.org/).25122513 - `type: "stored_completions"`25142515 The type of data source. Always `stored_completions`.25162517 - `"stored_completions"`25182519 - `metadata: optional Metadata or null`25202521 Set of 16 key-value pairs that can be attached to an object. This can be2522 useful for storing additional information about the object in a structured2523 format, and querying for objects via API or the dashboard.25242525 Keys are strings with a maximum length of 64 characters. Values are strings2526 with a maximum length of 512 characters.25272528 - `metadata: Metadata or null`25292530 Set of 16 key-value pairs that can be attached to an object. This can be2531 useful for storing additional information about the object in a structured2532 format, and querying for objects via API or the dashboard.25332534 Keys are strings with a maximum length of 64 characters. Values are strings2535 with a maximum length of 512 characters.25362537 - `name: string`25382539 The name of the evaluation.25402541 - `object: "eval"`25422543 The object type.25442545 - `"eval"`25462547 - `testing_criteria: array of LabelModelGrader or StringCheckGrader or TextSimilarityGrader or 2 more`25482549 A list of testing criteria.25502551 - `LabelModelGrader object { input, labels, model, 3 more }`25522553 A LabelModelGrader object which uses a model to assign labels to each item2554 in the evaluation.25552556 - `input: array of object { content, role, type }`25572558 - `content: string or ResponseInputText or object { text, type } or 3 more`25592560 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.25612562 - `TextInput = string`25632564 A text input to the model.25652566 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`25672568 A text input to the model.25692570 - `text: string`25712572 The text input to the model.25732574 - `type: "input_text"`25752576 The type of the input item. Always `input_text`.25772578 - `"input_text"`25792580 - `prompt_cache_breakpoint: optional object { mode }`25812582 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.25832584 - `mode: "explicit"`25852586 The breakpoint mode. Always `explicit`.25872588 - `"explicit"`25892590 - `OutputText object { text, type }`25912592 A text output from the model.25932594 - `text: string`25952596 The text output from the model.25972598 - `type: "output_text"`25992600 The type of the output text. Always `output_text`.26012602 - `"output_text"`26032604 - `InputImage object { image_url, type, detail }`26052606 An image input block used within EvalItem content arrays.26072608 - `image_url: string`26092610 The URL of the image input.26112612 - `type: "input_image"`26132614 The type of the image input. Always `input_image`.26152616 - `"input_image"`26172618 - `detail: optional string`26192620 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.26212622 - `ResponseInputAudio object { input_audio, type }`26232624 An audio input to the model.26252626 - `input_audio: object { data, format }`26272628 - `data: string`26292630 Base64-encoded audio data.26312632 - `format: "mp3" or "wav"`26332634 The format of the audio data. Currently supported formats are `mp3` and2635 `wav`.26362637 - `"mp3"`26382639 - `"wav"`26402641 - `type: "input_audio"`26422643 The type of the input item. Always `input_audio`.26442645 - `"input_audio"`26462647 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`26482649 A list of inputs, each of which may be either an input text, output text, input2650 image, or input audio object.26512652 - `TextInput = string`26532654 A text input to the model.26552656 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`26572658 A text input to the model.26592660 - `OutputText object { text, type }`26612662 A text output from the model.26632664 - `text: string`26652666 The text output from the model.26672668 - `type: "output_text"`26692670 The type of the output text. Always `output_text`.26712672 - `"output_text"`26732674 - `InputImage object { image_url, type, detail }`26752676 An image input block used within EvalItem content arrays.26772678 - `image_url: string`26792680 The URL of the image input.26812682 - `type: "input_image"`26832684 The type of the image input. Always `input_image`.26852686 - `"input_image"`26872688 - `detail: optional string`26892690 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.26912692 - `ResponseInputAudio object { input_audio, type }`26932694 An audio input to the model.26952696 - `role: "user" or "assistant" or "system" or "developer"`26972698 The role of the message input. One of `user`, `assistant`, `system`, or2699 `developer`.27002701 - `"user"`27022703 - `"assistant"`27042705 - `"system"`27062707 - `"developer"`27082709 - `type: optional "message"`27102711 The type of the message input. Always `message`.27122713 - `"message"`27142715 - `labels: array of string`27162717 The labels to assign to each item in the evaluation.27182719 - `model: string`27202721 The model to use for the evaluation. Must support structured outputs.27222723 - `name: string`27242725 The name of the grader.27262727 - `passing_labels: array of string`27282729 The labels that indicate a passing result. Must be a subset of labels.27302731 - `type: "label_model"`27322733 The object type, which is always `label_model`.27342735 - `"label_model"`27362737 - `StringCheckGrader object { input, name, operation, 2 more }`27382739 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.27402741 - `input: string`27422743 The input text. This may include template strings.27442745 - `name: string`27462747 The name of the grader.27482749 - `operation: "eq" or "ne" or "like" or "ilike"`27502751 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.27522753 - `"eq"`27542755 - `"ne"`27562757 - `"like"`27582759 - `"ilike"`27602761 - `reference: string`27622763 The reference text. This may include template strings.27642765 - `type: "string_check"`27662767 The object type, which is always `string_check`.27682769 - `"string_check"`27702771 - `TextSimilarityGrader = TextSimilarityGrader`27722773 A TextSimilarityGrader object which grades text based on similarity metrics.27742775 - `pass_threshold: number`27762777 The threshold for the score.27782779 - `PythonGrader = PythonGrader`27802781 A PythonGrader object that runs a python script on the input.27822783 - `pass_threshold: optional number`27842785 The threshold for the score.27862787 - `ScoreModelGrader = ScoreModelGrader`27882789 A ScoreModelGrader object that uses a model to assign a score to the input.27902791 - `pass_threshold: optional number`27922793 The threshold for the score.27942795### Eval Custom Data Source Config27962797- `EvalCustomDataSourceConfig object { schema, type }`27982799 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.2800 The response schema defines the shape of the data that will be:28012802 - Used to define your testing criteria and2803 - What data is required when creating a run28042805 - `schema: map[unknown]`28062807 The json schema for the run data source items.2808 Learn how to build JSON schemas [here](https://json-schema.org/).28092810 - `type: "custom"`28112812 The type of data source. Always `custom`.28132814 - `"custom"`28152816### Eval Delete Response28172818- `EvalDeleteResponse object { deleted, eval_id, object }`28192820 - `deleted: boolean`28212822 - `eval_id: string`28232824 - `object: string`28252826### Eval List Response28272828- `EvalListResponse object { id, created_at, data_source_config, 4 more }`28292830 An Eval object with a data source config and testing criteria.2831 An Eval represents a task to be done for your LLM integration.2832 Like:28332834 - Improve the quality of my chatbot2835 - See how well my chatbot handles customer support2836 - Check if o4-mini is better at my usecase than gpt-6-astra28372838 - `id: string`28392840 Unique identifier for the evaluation.28412842 - `created_at: number`28432844 The Unix timestamp (in seconds) for when the eval was created.28452846 - `data_source_config: EvalCustomDataSourceConfig or object { schema, type, metadata } or EvalStoredCompletionsDataSourceConfig`28472848 Configuration of data sources used in runs of the evaluation.28492850 - `EvalCustomDataSourceConfig object { schema, type }`28512852 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.2853 The response schema defines the shape of the data that will be:28542855 - Used to define your testing criteria and2856 - What data is required when creating a run28572858 - `schema: map[unknown]`28592860 The json schema for the run data source items.2861 Learn how to build JSON schemas [here](https://json-schema.org/).28622863 - `type: "custom"`28642865 The type of data source. Always `custom`.28662867 - `"custom"`28682869 - `LogsDataSourceConfig object { schema, type, metadata }`28702871 A LogsDataSourceConfig which specifies the metadata property of your logs query.2872 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.2873 The schema returned by this data source config is used to defined what variables are available in your evals.2874 `item` and `sample` are both defined when using this data source config.28752876 - `schema: map[unknown]`28772878 The json schema for the run data source items.2879 Learn how to build JSON schemas [here](https://json-schema.org/).28802881 - `type: "logs"`28822883 The type of data source. Always `logs`.28842885 - `"logs"`28862887 - `metadata: optional Metadata or null`28882889 Set of 16 key-value pairs that can be attached to an object. This can be2890 useful for storing additional information about the object in a structured2891 format, and querying for objects via API or the dashboard.28922893 Keys are strings with a maximum length of 64 characters. Values are strings2894 with a maximum length of 512 characters.28952896 - `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`28972898 Deprecated in favor of LogsDataSourceConfig.28992900 - `schema: map[unknown]`29012902 The json schema for the run data source items.2903 Learn how to build JSON schemas [here](https://json-schema.org/).29042905 - `type: "stored_completions"`29062907 The type of data source. Always `stored_completions`.29082909 - `"stored_completions"`29102911 - `metadata: optional Metadata or null`29122913 Set of 16 key-value pairs that can be attached to an object. This can be2914 useful for storing additional information about the object in a structured2915 format, and querying for objects via API or the dashboard.29162917 Keys are strings with a maximum length of 64 characters. Values are strings2918 with a maximum length of 512 characters.29192920 - `metadata: Metadata or null`29212922 Set of 16 key-value pairs that can be attached to an object. This can be2923 useful for storing additional information about the object in a structured2924 format, and querying for objects via API or the dashboard.29252926 Keys are strings with a maximum length of 64 characters. Values are strings2927 with a maximum length of 512 characters.29282929 - `name: string`29302931 The name of the evaluation.29322933 - `object: "eval"`29342935 The object type.29362937 - `"eval"`29382939 - `testing_criteria: array of LabelModelGrader or StringCheckGrader or TextSimilarityGrader or 2 more`29402941 A list of testing criteria.29422943 - `LabelModelGrader object { input, labels, model, 3 more }`29442945 A LabelModelGrader object which uses a model to assign labels to each item2946 in the evaluation.29472948 - `input: array of object { content, role, type }`29492950 - `content: string or ResponseInputText or object { text, type } or 3 more`29512952 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.29532954 - `TextInput = string`29552956 A text input to the model.29572958 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`29592960 A text input to the model.29612962 - `text: string`29632964 The text input to the model.29652966 - `type: "input_text"`29672968 The type of the input item. Always `input_text`.29692970 - `"input_text"`29712972 - `prompt_cache_breakpoint: optional object { mode }`29732974 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.29752976 - `mode: "explicit"`29772978 The breakpoint mode. Always `explicit`.29792980 - `"explicit"`29812982 - `OutputText object { text, type }`29832984 A text output from the model.29852986 - `text: string`29872988 The text output from the model.29892990 - `type: "output_text"`29912992 The type of the output text. Always `output_text`.29932994 - `"output_text"`29952996 - `InputImage object { image_url, type, detail }`29972998 An image input block used within EvalItem content arrays.29993000 - `image_url: string`30013002 The URL of the image input.30033004 - `type: "input_image"`30053006 The type of the image input. Always `input_image`.30073008 - `"input_image"`30093010 - `detail: optional string`30113012 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.30133014 - `ResponseInputAudio object { input_audio, type }`30153016 An audio input to the model.30173018 - `input_audio: object { data, format }`30193020 - `data: string`30213022 Base64-encoded audio data.30233024 - `format: "mp3" or "wav"`30253026 The format of the audio data. Currently supported formats are `mp3` and3027 `wav`.30283029 - `"mp3"`30303031 - `"wav"`30323033 - `type: "input_audio"`30343035 The type of the input item. Always `input_audio`.30363037 - `"input_audio"`30383039 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`30403041 A list of inputs, each of which may be either an input text, output text, input3042 image, or input audio object.30433044 - `TextInput = string`30453046 A text input to the model.30473048 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`30493050 A text input to the model.30513052 - `OutputText object { text, type }`30533054 A text output from the model.30553056 - `text: string`30573058 The text output from the model.30593060 - `type: "output_text"`30613062 The type of the output text. Always `output_text`.30633064 - `"output_text"`30653066 - `InputImage object { image_url, type, detail }`30673068 An image input block used within EvalItem content arrays.30693070 - `image_url: string`30713072 The URL of the image input.30733074 - `type: "input_image"`30753076 The type of the image input. Always `input_image`.30773078 - `"input_image"`30793080 - `detail: optional string`30813082 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.30833084 - `ResponseInputAudio object { input_audio, type }`30853086 An audio input to the model.30873088 - `role: "user" or "assistant" or "system" or "developer"`30893090 The role of the message input. One of `user`, `assistant`, `system`, or3091 `developer`.30923093 - `"user"`30943095 - `"assistant"`30963097 - `"system"`30983099 - `"developer"`31003101 - `type: optional "message"`31023103 The type of the message input. Always `message`.31043105 - `"message"`31063107 - `labels: array of string`31083109 The labels to assign to each item in the evaluation.31103111 - `model: string`31123113 The model to use for the evaluation. Must support structured outputs.31143115 - `name: string`31163117 The name of the grader.31183119 - `passing_labels: array of string`31203121 The labels that indicate a passing result. Must be a subset of labels.31223123 - `type: "label_model"`31243125 The object type, which is always `label_model`.31263127 - `"label_model"`31283129 - `StringCheckGrader object { input, name, operation, 2 more }`31303131 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.31323133 - `input: string`31343135 The input text. This may include template strings.31363137 - `name: string`31383139 The name of the grader.31403141 - `operation: "eq" or "ne" or "like" or "ilike"`31423143 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.31443145 - `"eq"`31463147 - `"ne"`31483149 - `"like"`31503151 - `"ilike"`31523153 - `reference: string`31543155 The reference text. This may include template strings.31563157 - `type: "string_check"`31583159 The object type, which is always `string_check`.31603161 - `"string_check"`31623163 - `TextSimilarityGrader = TextSimilarityGrader`31643165 A TextSimilarityGrader object which grades text based on similarity metrics.31663167 - `pass_threshold: number`31683169 The threshold for the score.31703171 - `PythonGrader = PythonGrader`31723173 A PythonGrader object that runs a python script on the input.31743175 - `pass_threshold: optional number`31763177 The threshold for the score.31783179 - `ScoreModelGrader = ScoreModelGrader`31803181 A ScoreModelGrader object that uses a model to assign a score to the input.31823183 - `pass_threshold: optional number`31843185 The threshold for the score.31863187### Eval Retrieve Response31883189- `EvalRetrieveResponse object { id, created_at, data_source_config, 4 more }`31903191 An Eval object with a data source config and testing criteria.3192 An Eval represents a task to be done for your LLM integration.3193 Like:31943195 - Improve the quality of my chatbot3196 - See how well my chatbot handles customer support3197 - Check if o4-mini is better at my usecase than gpt-6-astra31983199 - `id: string`32003201 Unique identifier for the evaluation.32023203 - `created_at: number`32043205 The Unix timestamp (in seconds) for when the eval was created.32063207 - `data_source_config: EvalCustomDataSourceConfig or object { schema, type, metadata } or EvalStoredCompletionsDataSourceConfig`32083209 Configuration of data sources used in runs of the evaluation.32103211 - `EvalCustomDataSourceConfig object { schema, type }`32123213 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.3214 The response schema defines the shape of the data that will be:32153216 - Used to define your testing criteria and3217 - What data is required when creating a run32183219 - `schema: map[unknown]`32203221 The json schema for the run data source items.3222 Learn how to build JSON schemas [here](https://json-schema.org/).32233224 - `type: "custom"`32253226 The type of data source. Always `custom`.32273228 - `"custom"`32293230 - `LogsDataSourceConfig object { schema, type, metadata }`32313232 A LogsDataSourceConfig which specifies the metadata property of your logs query.3233 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.3234 The schema returned by this data source config is used to defined what variables are available in your evals.3235 `item` and `sample` are both defined when using this data source config.32363237 - `schema: map[unknown]`32383239 The json schema for the run data source items.3240 Learn how to build JSON schemas [here](https://json-schema.org/).32413242 - `type: "logs"`32433244 The type of data source. Always `logs`.32453246 - `"logs"`32473248 - `metadata: optional Metadata or null`32493250 Set of 16 key-value pairs that can be attached to an object. This can be3251 useful for storing additional information about the object in a structured3252 format, and querying for objects via API or the dashboard.32533254 Keys are strings with a maximum length of 64 characters. Values are strings3255 with a maximum length of 512 characters.32563257 - `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`32583259 Deprecated in favor of LogsDataSourceConfig.32603261 - `schema: map[unknown]`32623263 The json schema for the run data source items.3264 Learn how to build JSON schemas [here](https://json-schema.org/).32653266 - `type: "stored_completions"`32673268 The type of data source. Always `stored_completions`.32693270 - `"stored_completions"`32713272 - `metadata: optional Metadata or null`32733274 Set of 16 key-value pairs that can be attached to an object. This can be3275 useful for storing additional information about the object in a structured3276 format, and querying for objects via API or the dashboard.32773278 Keys are strings with a maximum length of 64 characters. Values are strings3279 with a maximum length of 512 characters.32803281 - `metadata: Metadata or null`32823283 Set of 16 key-value pairs that can be attached to an object. This can be3284 useful for storing additional information about the object in a structured3285 format, and querying for objects via API or the dashboard.32863287 Keys are strings with a maximum length of 64 characters. Values are strings3288 with a maximum length of 512 characters.32893290 - `name: string`32913292 The name of the evaluation.32933294 - `object: "eval"`32953296 The object type.32973298 - `"eval"`32993300 - `testing_criteria: array of LabelModelGrader or StringCheckGrader or TextSimilarityGrader or 2 more`33013302 A list of testing criteria.33033304 - `LabelModelGrader object { input, labels, model, 3 more }`33053306 A LabelModelGrader object which uses a model to assign labels to each item3307 in the evaluation.33083309 - `input: array of object { content, role, type }`33103311 - `content: string or ResponseInputText or object { text, type } or 3 more`33123313 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.33143315 - `TextInput = string`33163317 A text input to the model.33183319 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`33203321 A text input to the model.33223323 - `text: string`33243325 The text input to the model.33263327 - `type: "input_text"`33283329 The type of the input item. Always `input_text`.33303331 - `"input_text"`33323333 - `prompt_cache_breakpoint: optional object { mode }`33343335 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.33363337 - `mode: "explicit"`33383339 The breakpoint mode. Always `explicit`.33403341 - `"explicit"`33423343 - `OutputText object { text, type }`33443345 A text output from the model.33463347 - `text: string`33483349 The text output from the model.33503351 - `type: "output_text"`33523353 The type of the output text. Always `output_text`.33543355 - `"output_text"`33563357 - `InputImage object { image_url, type, detail }`33583359 An image input block used within EvalItem content arrays.33603361 - `image_url: string`33623363 The URL of the image input.33643365 - `type: "input_image"`33663367 The type of the image input. Always `input_image`.33683369 - `"input_image"`33703371 - `detail: optional string`33723373 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.33743375 - `ResponseInputAudio object { input_audio, type }`33763377 An audio input to the model.33783379 - `input_audio: object { data, format }`33803381 - `data: string`33823383 Base64-encoded audio data.33843385 - `format: "mp3" or "wav"`33863387 The format of the audio data. Currently supported formats are `mp3` and3388 `wav`.33893390 - `"mp3"`33913392 - `"wav"`33933394 - `type: "input_audio"`33953396 The type of the input item. Always `input_audio`.33973398 - `"input_audio"`33993400 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`34013402 A list of inputs, each of which may be either an input text, output text, input3403 image, or input audio object.34043405 - `TextInput = string`34063407 A text input to the model.34083409 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`34103411 A text input to the model.34123413 - `OutputText object { text, type }`34143415 A text output from the model.34163417 - `text: string`34183419 The text output from the model.34203421 - `type: "output_text"`34223423 The type of the output text. Always `output_text`.34243425 - `"output_text"`34263427 - `InputImage object { image_url, type, detail }`34283429 An image input block used within EvalItem content arrays.34303431 - `image_url: string`34323433 The URL of the image input.34343435 - `type: "input_image"`34363437 The type of the image input. Always `input_image`.34383439 - `"input_image"`34403441 - `detail: optional string`34423443 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.34443445 - `ResponseInputAudio object { input_audio, type }`34463447 An audio input to the model.34483449 - `role: "user" or "assistant" or "system" or "developer"`34503451 The role of the message input. One of `user`, `assistant`, `system`, or3452 `developer`.34533454 - `"user"`34553456 - `"assistant"`34573458 - `"system"`34593460 - `"developer"`34613462 - `type: optional "message"`34633464 The type of the message input. Always `message`.34653466 - `"message"`34673468 - `labels: array of string`34693470 The labels to assign to each item in the evaluation.34713472 - `model: string`34733474 The model to use for the evaluation. Must support structured outputs.34753476 - `name: string`34773478 The name of the grader.34793480 - `passing_labels: array of string`34813482 The labels that indicate a passing result. Must be a subset of labels.34833484 - `type: "label_model"`34853486 The object type, which is always `label_model`.34873488 - `"label_model"`34893490 - `StringCheckGrader object { input, name, operation, 2 more }`34913492 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.34933494 - `input: string`34953496 The input text. This may include template strings.34973498 - `name: string`34993500 The name of the grader.35013502 - `operation: "eq" or "ne" or "like" or "ilike"`35033504 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.35053506 - `"eq"`35073508 - `"ne"`35093510 - `"like"`35113512 - `"ilike"`35133514 - `reference: string`35153516 The reference text. This may include template strings.35173518 - `type: "string_check"`35193520 The object type, which is always `string_check`.35213522 - `"string_check"`35233524 - `TextSimilarityGrader = TextSimilarityGrader`35253526 A TextSimilarityGrader object which grades text based on similarity metrics.35273528 - `pass_threshold: number`35293530 The threshold for the score.35313532 - `PythonGrader = PythonGrader`35333534 A PythonGrader object that runs a python script on the input.35353536 - `pass_threshold: optional number`35373538 The threshold for the score.35393540 - `ScoreModelGrader = ScoreModelGrader`35413542 A ScoreModelGrader object that uses a model to assign a score to the input.35433544 - `pass_threshold: optional number`35453546 The threshold for the score.35473548### Eval Stored Completions Data Source Config35493550- `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`35513552 Deprecated in favor of LogsDataSourceConfig.35533554 - `schema: map[unknown]`35553556 The json schema for the run data source items.3557 Learn how to build JSON schemas [here](https://json-schema.org/).35583559 - `type: "stored_completions"`35603561 The type of data source. Always `stored_completions`.35623563 - `"stored_completions"`35643565 - `metadata: optional Metadata or null`35663567 Set of 16 key-value pairs that can be attached to an object. This can be3568 useful for storing additional information about the object in a structured3569 format, and querying for objects via API or the dashboard.35703571 Keys are strings with a maximum length of 64 characters. Values are strings3572 with a maximum length of 512 characters.35733574### Eval Update Response35753576- `EvalUpdateResponse object { id, created_at, data_source_config, 4 more }`35773578 An Eval object with a data source config and testing criteria.3579 An Eval represents a task to be done for your LLM integration.3580 Like:35813582 - Improve the quality of my chatbot3583 - See how well my chatbot handles customer support3584 - Check if o4-mini is better at my usecase than gpt-6-astra35853586 - `id: string`35873588 Unique identifier for the evaluation.35893590 - `created_at: number`35913592 The Unix timestamp (in seconds) for when the eval was created.35933594 - `data_source_config: EvalCustomDataSourceConfig or object { schema, type, metadata } or EvalStoredCompletionsDataSourceConfig`35953596 Configuration of data sources used in runs of the evaluation.35973598 - `EvalCustomDataSourceConfig object { schema, type }`35993600 A CustomDataSourceConfig which specifies the schema of your `item` and optionally `sample` namespaces.3601 The response schema defines the shape of the data that will be:36023603 - Used to define your testing criteria and3604 - What data is required when creating a run36053606 - `schema: map[unknown]`36073608 The json schema for the run data source items.3609 Learn how to build JSON schemas [here](https://json-schema.org/).36103611 - `type: "custom"`36123613 The type of data source. Always `custom`.36143615 - `"custom"`36163617 - `LogsDataSourceConfig object { schema, type, metadata }`36183619 A LogsDataSourceConfig which specifies the metadata property of your logs query.3620 This is usually metadata like `usecase=chatbot` or `prompt-version=v2`, etc.3621 The schema returned by this data source config is used to defined what variables are available in your evals.3622 `item` and `sample` are both defined when using this data source config.36233624 - `schema: map[unknown]`36253626 The json schema for the run data source items.3627 Learn how to build JSON schemas [here](https://json-schema.org/).36283629 - `type: "logs"`36303631 The type of data source. Always `logs`.36323633 - `"logs"`36343635 - `metadata: optional Metadata or null`36363637 Set of 16 key-value pairs that can be attached to an object. This can be3638 useful for storing additional information about the object in a structured3639 format, and querying for objects via API or the dashboard.36403641 Keys are strings with a maximum length of 64 characters. Values are strings3642 with a maximum length of 512 characters.36433644 - `EvalStoredCompletionsDataSourceConfig object { schema, type, metadata }`36453646 Deprecated in favor of LogsDataSourceConfig.36473648 - `schema: map[unknown]`36493650 The json schema for the run data source items.3651 Learn how to build JSON schemas [here](https://json-schema.org/).36523653 - `type: "stored_completions"`36543655 The type of data source. Always `stored_completions`.36563657 - `"stored_completions"`36583659 - `metadata: optional Metadata or null`36603661 Set of 16 key-value pairs that can be attached to an object. This can be3662 useful for storing additional information about the object in a structured3663 format, and querying for objects via API or the dashboard.36643665 Keys are strings with a maximum length of 64 characters. Values are strings3666 with a maximum length of 512 characters.36673668 - `metadata: Metadata or null`36693670 Set of 16 key-value pairs that can be attached to an object. This can be3671 useful for storing additional information about the object in a structured3672 format, and querying for objects via API or the dashboard.36733674 Keys are strings with a maximum length of 64 characters. Values are strings3675 with a maximum length of 512 characters.36763677 - `name: string`36783679 The name of the evaluation.36803681 - `object: "eval"`36823683 The object type.36843685 - `"eval"`36863687 - `testing_criteria: array of LabelModelGrader or StringCheckGrader or TextSimilarityGrader or 2 more`36883689 A list of testing criteria.36903691 - `LabelModelGrader object { input, labels, model, 3 more }`36923693 A LabelModelGrader object which uses a model to assign labels to each item3694 in the evaluation.36953696 - `input: array of object { content, role, type }`36973698 - `content: string or ResponseInputText or object { text, type } or 3 more`36993700 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.37013702 - `TextInput = string`37033704 A text input to the model.37053706 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`37073708 A text input to the model.37093710 - `text: string`37113712 The text input to the model.37133714 - `type: "input_text"`37153716 The type of the input item. Always `input_text`.37173718 - `"input_text"`37193720 - `prompt_cache_breakpoint: optional object { mode }`37213722 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.37233724 - `mode: "explicit"`37253726 The breakpoint mode. Always `explicit`.37273728 - `"explicit"`37293730 - `OutputText object { text, type }`37313732 A text output from the model.37333734 - `text: string`37353736 The text output from the model.37373738 - `type: "output_text"`37393740 The type of the output text. Always `output_text`.37413742 - `"output_text"`37433744 - `InputImage object { image_url, type, detail }`37453746 An image input block used within EvalItem content arrays.37473748 - `image_url: string`37493750 The URL of the image input.37513752 - `type: "input_image"`37533754 The type of the image input. Always `input_image`.37553756 - `"input_image"`37573758 - `detail: optional string`37593760 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.37613762 - `ResponseInputAudio object { input_audio, type }`37633764 An audio input to the model.37653766 - `input_audio: object { data, format }`37673768 - `data: string`37693770 Base64-encoded audio data.37713772 - `format: "mp3" or "wav"`37733774 The format of the audio data. Currently supported formats are `mp3` and3775 `wav`.37763777 - `"mp3"`37783779 - `"wav"`37803781 - `type: "input_audio"`37823783 The type of the input item. Always `input_audio`.37843785 - `"input_audio"`37863787 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`37883789 A list of inputs, each of which may be either an input text, output text, input3790 image, or input audio object.37913792 - `TextInput = string`37933794 A text input to the model.37953796 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`37973798 A text input to the model.37993800 - `OutputText object { text, type }`38013802 A text output from the model.38033804 - `text: string`38053806 The text output from the model.38073808 - `type: "output_text"`38093810 The type of the output text. Always `output_text`.38113812 - `"output_text"`38133814 - `InputImage object { image_url, type, detail }`38153816 An image input block used within EvalItem content arrays.38173818 - `image_url: string`38193820 The URL of the image input.38213822 - `type: "input_image"`38233824 The type of the image input. Always `input_image`.38253826 - `"input_image"`38273828 - `detail: optional string`38293830 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.38313832 - `ResponseInputAudio object { input_audio, type }`38333834 An audio input to the model.38353836 - `role: "user" or "assistant" or "system" or "developer"`38373838 The role of the message input. One of `user`, `assistant`, `system`, or3839 `developer`.38403841 - `"user"`38423843 - `"assistant"`38443845 - `"system"`38463847 - `"developer"`38483849 - `type: optional "message"`38503851 The type of the message input. Always `message`.38523853 - `"message"`38543855 - `labels: array of string`38563857 The labels to assign to each item in the evaluation.38583859 - `model: string`38603861 The model to use for the evaluation. Must support structured outputs.38623863 - `name: string`38643865 The name of the grader.38663867 - `passing_labels: array of string`38683869 The labels that indicate a passing result. Must be a subset of labels.38703871 - `type: "label_model"`38723873 The object type, which is always `label_model`.38743875 - `"label_model"`38763877 - `StringCheckGrader object { input, name, operation, 2 more }`38783879 A StringCheckGrader object that performs a string comparison between input and reference using a specified operation.38803881 - `input: string`38823883 The input text. This may include template strings.38843885 - `name: string`38863887 The name of the grader.38883889 - `operation: "eq" or "ne" or "like" or "ilike"`38903891 The string check operation to perform. One of `eq`, `ne`, `like`, or `ilike`.38923893 - `"eq"`38943895 - `"ne"`38963897 - `"like"`38983899 - `"ilike"`39003901 - `reference: string`39023903 The reference text. This may include template strings.39043905 - `type: "string_check"`39063907 The object type, which is always `string_check`.39083909 - `"string_check"`39103911 - `TextSimilarityGrader = TextSimilarityGrader`39123913 A TextSimilarityGrader object which grades text based on similarity metrics.39143915 - `pass_threshold: number`39163917 The threshold for the score.39183919 - `PythonGrader = PythonGrader`39203921 A PythonGrader object that runs a python script on the input.39223923 - `pass_threshold: optional number`39243925 The threshold for the score.39263927 - `ScoreModelGrader = ScoreModelGrader`39283929 A ScoreModelGrader object that uses a model to assign a score to the input.39303931 - `pass_threshold: optional number`39323933 The threshold for the score.39343935# Runs39363937## Cancel eval run39383939**post** `/evals/{eval_id}/runs/{run_id}`39403941Cancel an ongoing evaluation run.39423943### Path Parameters39443945- `eval_id: string`39463947- `run_id: string`39483949### Returns39503951- `id: string`39523953 Unique identifier for the evaluation run.39543955- `created_at: number`39563957 Unix timestamp (in seconds) when the evaluation run was created.39583959- `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`39603961 Information about the run's data source.39623963 - `CreateEvalJSONLRunDataSource object { source, type }`39643965 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval39663967 - `source: object { content, type } or object { id, type }`39683969 Determines what populates the `item` namespace in the data source.39703971 - `EvalJSONLFileContentSource object { content, type }`39723973 - `content: array of object { item, sample }`39743975 The content of the jsonl file.39763977 - `item: map[unknown]`39783979 - `sample: optional map[unknown]`39803981 - `type: "file_content"`39823983 The type of jsonl source. Always `file_content`.39843985 - `"file_content"`39863987 - `EvalJSONLFileIDSource object { id, type }`39883989 - `id: string`39903991 The identifier of the file.39923993 - `type: "file_id"`39943995 The type of jsonl source. Always `file_id`.39963997 - `"file_id"`39983999 - `type: "jsonl"`40004001 The type of data source. Always `jsonl`.40024003 - `"jsonl"`40044005 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`40064007 A CompletionsRunDataSource object describing a model sampling configuration.40084009 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`40104011 Determines what populates the `item` namespace in this run's data source.40124013 - `EvalJSONLFileContentSource object { content, type }`40144015 - `content: array of object { item, sample }`40164017 The content of the jsonl file.40184019 - `item: map[unknown]`40204021 - `sample: optional map[unknown]`40224023 - `type: "file_content"`40244025 The type of jsonl source. Always `file_content`.40264027 - `"file_content"`40284029 - `EvalJSONLFileIDSource object { id, type }`40304031 - `id: string`40324033 The identifier of the file.40344035 - `type: "file_id"`40364037 The type of jsonl source. Always `file_id`.40384039 - `"file_id"`40404041 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`40424043 A StoredCompletionsRunDataSource configuration describing a set of filters40444045 - `type: "stored_completions"`40464047 The type of source. Always `stored_completions`.40484049 - `"stored_completions"`40504051 - `created_after: optional number or null`40524053 An optional Unix timestamp to filter items created after this time.40544055 - `created_before: optional number or null`40564057 An optional Unix timestamp to filter items created before this time.40584059 - `limit: optional number or null`40604061 An optional maximum number of items to return.40624063 - `metadata: optional Metadata or null`40644065 Set of 16 key-value pairs that can be attached to an object. This can be4066 useful for storing additional information about the object in a structured4067 format, and querying for objects via API or the dashboard.40684069 Keys are strings with a maximum length of 64 characters. Values are strings4070 with a maximum length of 512 characters.40714072 - `model: optional string or null`40734074 An optional model to filter by (e.g., 'gpt-6-astra').40754076 - `type: "completions"`40774078 The type of run data source. Always `completions`.40794080 - `"completions"`40814082 - `input_messages: optional object { template, type } or object { item_reference, type }`40834084 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.40854086 - `TemplateInputMessages object { template, type }`40874088 - `template: array of EasyInputMessage or object { content, role, type }`40894090 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.40914092 - `EasyInputMessage object { content, role, phase, type }`40934094 A message input to the model with a role indicating instruction following4095 hierarchy. Instructions given with the `developer` or `system` role take4096 precedence over instructions given with the `user` role. Messages with the4097 `assistant` role are presumed to have been generated by the model in previous4098 interactions.40994100 - `content: string or ResponseInputMessageContentList`41014102 Text, image, or audio input to the model, used to generate a response.4103 Can also contain previous assistant responses.41044105 - `TextInput = string`41064107 A text input to the model.41084109 - `ResponseInputMessageContentList = array of ResponseInputContent`41104111 A list of one or many input items to the model, containing different content4112 types.41134114 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`41154116 A text input to the model.41174118 - `text: string`41194120 The text input to the model.41214122 - `type: "input_text"`41234124 The type of the input item. Always `input_text`.41254126 - `"input_text"`41274128 - `prompt_cache_breakpoint: optional object { mode }`41294130 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.41314132 - `mode: "explicit"`41334134 The breakpoint mode. Always `explicit`.41354136 - `"explicit"`41374138 - `ResponseInputImage object { detail, type, file_id, 2 more }`41394140 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).41414142 - `detail: ImageDetail`41434144 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.41454146 - `"low"`41474148 - `"high"`41494150 - `"auto"`41514152 - `"original"`41534154 - `type: "input_image"`41554156 The type of the input item. Always `input_image`.41574158 - `"input_image"`41594160 - `file_id: optional string or null`41614162 The ID of the file to be sent to the model.41634164 - `image_url: optional string or null`41654166 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.41674168 - `prompt_cache_breakpoint: optional object { mode }`41694170 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.41714172 - `mode: "explicit"`41734174 The breakpoint mode. Always `explicit`.41754176 - `"explicit"`41774178 - `ResponseInputFile object { type, detail, file_data, 4 more }`41794180 A file input to the model.41814182 - `type: "input_file"`41834184 The type of the input item. Always `input_file`.41854186 - `"input_file"`41874188 - `detail: optional "auto" or "low" or "high"`41894190 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.41914192 - `"auto"`41934194 - `"low"`41954196 - `"high"`41974198 - `file_data: optional string`41994200 The content of the file to be sent to the model.42014202 - `file_id: optional string or null`42034204 The ID of the file to be sent to the model.42054206 - `file_url: optional string`42074208 The URL of the file to be sent to the model.42094210 - `filename: optional string`42114212 The name of the file to be sent to the model.42134214 - `prompt_cache_breakpoint: optional object { mode }`42154216 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.42174218 - `mode: "explicit"`42194220 The breakpoint mode. Always `explicit`.42214222 - `"explicit"`42234224 - `role: "user" or "assistant" or "system" or "developer"`42254226 The role of the message input. One of `user`, `assistant`, `system`, or4227 `developer`.42284229 - `"user"`42304231 - `"assistant"`42324233 - `"system"`42344235 - `"developer"`42364237 - `phase: optional "commentary" or "final_answer" or null`42384239 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).4240 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend4241 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.42424243 - `"commentary"`42444245 - `"final_answer"`42464247 - `type: optional "message"`42484249 The type of the message input. Always `message`.42504251 - `"message"`42524253 - `EvalMessageObject object { content, role, type }`42544255 A message input to the model with a role indicating instruction following4256 hierarchy. Instructions given with the `developer` or `system` role take4257 precedence over instructions given with the `user` role. Messages with the4258 `assistant` role are presumed to have been generated by the model in previous4259 interactions.42604261 - `content: string or ResponseInputText or object { text, type } or 3 more`42624263 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.42644265 - `TextInput = string`42664267 A text input to the model.42684269 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`42704271 A text input to the model.42724273 - `OutputText object { text, type }`42744275 A text output from the model.42764277 - `text: string`42784279 The text output from the model.42804281 - `type: "output_text"`42824283 The type of the output text. Always `output_text`.42844285 - `"output_text"`42864287 - `InputImage object { image_url, type, detail }`42884289 An image input block used within EvalItem content arrays.42904291 - `image_url: string`42924293 The URL of the image input.42944295 - `type: "input_image"`42964297 The type of the image input. Always `input_image`.42984299 - `"input_image"`43004301 - `detail: optional string`43024303 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.43044305 - `ResponseInputAudio object { input_audio, type }`43064307 An audio input to the model.43084309 - `input_audio: object { data, format }`43104311 - `data: string`43124313 Base64-encoded audio data.43144315 - `format: "mp3" or "wav"`43164317 The format of the audio data. Currently supported formats are `mp3` and4318 `wav`.43194320 - `"mp3"`43214322 - `"wav"`43234324 - `type: "input_audio"`43254326 The type of the input item. Always `input_audio`.43274328 - `"input_audio"`43294330 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`43314332 A list of inputs, each of which may be either an input text, output text, input4333 image, or input audio object.43344335 - `TextInput = string`43364337 A text input to the model.43384339 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`43404341 A text input to the model.43424343 - `OutputText object { text, type }`43444345 A text output from the model.43464347 - `text: string`43484349 The text output from the model.43504351 - `type: "output_text"`43524353 The type of the output text. Always `output_text`.43544355 - `"output_text"`43564357 - `InputImage object { image_url, type, detail }`43584359 An image input block used within EvalItem content arrays.43604361 - `image_url: string`43624363 The URL of the image input.43644365 - `type: "input_image"`43664367 The type of the image input. Always `input_image`.43684369 - `"input_image"`43704371 - `detail: optional string`43724373 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.43744375 - `ResponseInputAudio object { input_audio, type }`43764377 An audio input to the model.43784379 - `role: "user" or "assistant" or "system" or "developer"`43804381 The role of the message input. One of `user`, `assistant`, `system`, or4382 `developer`.43834384 - `"user"`43854386 - `"assistant"`43874388 - `"system"`43894390 - `"developer"`43914392 - `type: optional "message"`43934394 The type of the message input. Always `message`.43954396 - `"message"`43974398 - `type: "template"`43994400 The type of input messages. Always `template`.44014402 - `"template"`44034404 - `ItemReferenceInputMessages object { item_reference, type }`44054406 - `item_reference: string`44074408 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"44094410 - `type: "item_reference"`44114412 The type of input messages. Always `item_reference`.44134414 - `"item_reference"`44154416 - `model: optional string`44174418 The name of the model to use for generating completions (e.g. "o3-mini").44194420 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`44214422 - `max_completion_tokens: optional number`44234424 The maximum number of tokens in the generated output.44254426 - `reasoning_effort: optional ReasoningEffort or null`44274428 Constrains effort on reasoning for reasoning models. Currently supported4429 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.4430 Reducing reasoning effort can result in faster responses and fewer tokens4431 used on reasoning in a response. Not all reasoning models support every4432 value. See the4433 [reasoning guide](/api/docs/guides/reasoning)4434 for model-specific support.44354436 - `"none"`44374438 - `"minimal"`44394440 - `"low"`44414442 - `"medium"`44434444 - `"high"`44454446 - `"xhigh"`44474448 - `"max"`44494450 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`44514452 An object specifying the format that the model must output.44534454 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables4455 Structured Outputs which ensures the model will match your supplied JSON4456 schema. Learn more in the [Structured Outputs4457 guide](/api/docs/guides/structured-outputs).44584459 Setting to `{ "type": "json_object" }` enables the older JSON mode, which4460 ensures the message the model generates is valid JSON. Using `json_schema`4461 is preferred for models that support it.44624463 - `ResponseFormatText object { type }`44644465 Default response format. Used to generate text responses.44664467 - `type: "text"`44684469 The type of response format being defined. Always `text`.44704471 - `"text"`44724473 - `ResponseFormatJSONSchema object { json_schema, type }`44744475 JSON Schema response format. Used to generate structured JSON responses.4476 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).44774478 - `json_schema: object { name, description, schema, strict }`44794480 Structured Outputs configuration options, including a JSON Schema.44814482 - `name: string`44834484 The name of the response format. Must be a-z, A-Z, 0-9, or contain4485 underscores and dashes, with a maximum length of 64.44864487 - `description: optional string`44884489 A description of what the response format is for, used by the model to4490 determine how to respond in the format.44914492 - `schema: optional map[unknown]`44934494 The schema for the response format, described as a JSON Schema object.4495 Learn how to build JSON schemas [here](https://json-schema.org/).44964497 - `strict: optional boolean or null`44984499 Whether to enable strict schema adherence when generating the output.4500 If set to true, the model will always follow the exact schema defined4501 in the `schema` field. Only a subset of JSON Schema is supported when4502 `strict` is `true`. To learn more, read the [Structured Outputs4503 guide](/api/docs/guides/structured-outputs).45044505 - `type: "json_schema"`45064507 The type of response format being defined. Always `json_schema`.45084509 - `"json_schema"`45104511 - `ResponseFormatJSONObject object { type }`45124513 JSON object response format. An older method of generating JSON responses.4514 Using `json_schema` is recommended for models that support it. Note that the4515 model will not generate JSON without a system or user message instructing it4516 to do so.45174518 - `type: "json_object"`45194520 The type of response format being defined. Always `json_object`.45214522 - `"json_object"`45234524 - `seed: optional number`45254526 A seed value to initialize the randomness, during sampling.45274528 - `temperature: optional number`45294530 A higher temperature increases randomness in the outputs.45314532 - `tools: optional array of ChatCompletionFunctionTool`45334534 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.45354536 - `function: FunctionDefinition`45374538 - `name: string`45394540 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.45414542 - `description: optional string`45434544 A description of what the function does, used by the model to choose when and how to call the function.45454546 - `parameters: optional FunctionParameters`45474548 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.45494550 Omitting `parameters` defines a function with an empty parameter list.45514552 - `strict: optional boolean or null`45534554 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).45554556 - `type: "function"`45574558 The type of the tool. Currently, only `function` is supported.45594560 - `"function"`45614562 - `top_p: optional number`45634564 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.45654566 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`45674568 A ResponsesRunDataSource object describing a model sampling configuration.45694570 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`45714572 Determines what populates the `item` namespace in this run's data source.45734574 - `EvalJSONLFileContentSource object { content, type }`45754576 - `content: array of object { item, sample }`45774578 The content of the jsonl file.45794580 - `item: map[unknown]`45814582 - `sample: optional map[unknown]`45834584 - `type: "file_content"`45854586 The type of jsonl source. Always `file_content`.45874588 - `"file_content"`45894590 - `EvalJSONLFileIDSource object { id, type }`45914592 - `id: string`45934594 The identifier of the file.45954596 - `type: "file_id"`45974598 The type of jsonl source. Always `file_id`.45994600 - `"file_id"`46014602 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`46034604 A EvalResponsesSource object describing a run data source configuration.46054606 - `type: "responses"`46074608 The type of run data source. Always `responses`.46094610 - `"responses"`46114612 - `created_after: optional number or null`46134614 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.46154616 - `created_before: optional number or null`46174618 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.46194620 - `instructions_search: optional string or null`46214622 Optional string to search the 'instructions' field. This is a query parameter used to select responses.46234624 - `metadata: optional unknown or null`46254626 Metadata filter for the responses. This is a query parameter used to select responses.46274628 - `model: optional string or null`46294630 The name of the model to find responses for. This is a query parameter used to select responses.46314632 - `reasoning_effort: optional ReasoningEffort or null`46334634 Constrains effort on reasoning for reasoning models. Currently supported4635 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.4636 Reducing reasoning effort can result in faster responses and fewer tokens4637 used on reasoning in a response. Not all reasoning models support every4638 value. See the4639 [reasoning guide](/api/docs/guides/reasoning)4640 for model-specific support.46414642 - `temperature: optional number or null`46434644 Sampling temperature. This is a query parameter used to select responses.46454646 - `tools: optional array of string or null`46474648 List of tool names. This is a query parameter used to select responses.46494650 - `top_p: optional number or null`46514652 Nucleus sampling parameter. This is a query parameter used to select responses.46534654 - `users: optional array of string or null`46554656 List of user identifiers. This is a query parameter used to select responses.46574658 - `type: "responses"`46594660 The type of run data source. Always `responses`.46614662 - `"responses"`46634664 - `input_messages: optional object { template, type } or object { item_reference, type }`46654666 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.46674668 - `InputMessagesTemplate object { template, type }`46694670 - `template: array of object { content, role } or object { content, role, type }`46714672 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.46734674 - `ChatMessage object { content, role }`46754676 - `content: string`46774678 The content of the message.46794680 - `role: string`46814682 The role of the message (e.g. "system", "assistant", "user").46834684 - `EvalMessageObject object { content, role, type }`46854686 A message input to the model with a role indicating instruction following4687 hierarchy. Instructions given with the `developer` or `system` role take4688 precedence over instructions given with the `user` role. Messages with the4689 `assistant` role are presumed to have been generated by the model in previous4690 interactions.46914692 - `content: string or ResponseInputText or object { text, type } or 3 more`46934694 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.46954696 - `TextInput = string`46974698 A text input to the model.46994700 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`47014702 A text input to the model.47034704 - `OutputText object { text, type }`47054706 A text output from the model.47074708 - `text: string`47094710 The text output from the model.47114712 - `type: "output_text"`47134714 The type of the output text. Always `output_text`.47154716 - `"output_text"`47174718 - `InputImage object { image_url, type, detail }`47194720 An image input block used within EvalItem content arrays.47214722 - `image_url: string`47234724 The URL of the image input.47254726 - `type: "input_image"`47274728 The type of the image input. Always `input_image`.47294730 - `"input_image"`47314732 - `detail: optional string`47334734 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.47354736 - `ResponseInputAudio object { input_audio, type }`47374738 An audio input to the model.47394740 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`47414742 A list of inputs, each of which may be either an input text, output text, input4743 image, or input audio object.47444745 - `role: "user" or "assistant" or "system" or "developer"`47464747 The role of the message input. One of `user`, `assistant`, `system`, or4748 `developer`.47494750 - `"user"`47514752 - `"assistant"`47534754 - `"system"`47554756 - `"developer"`47574758 - `type: optional "message"`47594760 The type of the message input. Always `message`.47614762 - `"message"`47634764 - `type: "template"`47654766 The type of input messages. Always `template`.47674768 - `"template"`47694770 - `InputMessagesItemReference object { item_reference, type }`47714772 - `item_reference: string`47734774 A reference to a variable in the `item` namespace. Ie, "item.name"47754776 - `type: "item_reference"`47774778 The type of input messages. Always `item_reference`.47794780 - `"item_reference"`47814782 - `model: optional string`47834784 The name of the model to use for generating completions (e.g. "o3-mini").47854786 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`47874788 - `max_completion_tokens: optional number`47894790 The maximum number of tokens in the generated output.47914792 - `reasoning_effort: optional ReasoningEffort or null`47934794 Constrains effort on reasoning for reasoning models. Currently supported4795 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.4796 Reducing reasoning effort can result in faster responses and fewer tokens4797 used on reasoning in a response. Not all reasoning models support every4798 value. See the4799 [reasoning guide](/api/docs/guides/reasoning)4800 for model-specific support.48014802 - `seed: optional number`48034804 A seed value to initialize the randomness, during sampling.48054806 - `temperature: optional number`48074808 A higher temperature increases randomness in the outputs.48094810 - `text: optional object { format }`48114812 Configuration options for a text response from the model. Can be plain4813 text or structured JSON data. Learn more:48144815 - [Text inputs and outputs](/api/docs/guides/text)4816 - [Structured Outputs](/api/docs/guides/structured-outputs)48174818 - `format: optional ResponseFormatTextConfig`48194820 An object specifying the format that the model must output.48214822 Configuring `{ "type": "json_schema" }` enables Structured Outputs,4823 which ensures the model will match your supplied JSON schema. Learn more in the4824 [Structured Outputs guide](/api/docs/guides/structured-outputs).48254826 The default format is `{ "type": "text" }` with no additional options.48274828 **Not recommended for gpt-4o and newer models:**48294830 Setting to `{ "type": "json_object" }` enables the older JSON mode, which4831 ensures the message the model generates is valid JSON. Using `json_schema`4832 is preferred for models that support it.48334834 - `ResponseFormatText object { type }`48354836 Default response format. Used to generate text responses.48374838 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`48394840 JSON Schema response format. Used to generate structured JSON responses.4841 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).48424843 - `name: string`48444845 The name of the response format. Must be a-z, A-Z, 0-9, or contain4846 underscores and dashes, with a maximum length of 64.48474848 - `schema: map[unknown]`48494850 The schema for the response format, described as a JSON Schema object.4851 Learn how to build JSON schemas [here](https://json-schema.org/).48524853 - `type: "json_schema"`48544855 The type of response format being defined. Always `json_schema`.48564857 - `"json_schema"`48584859 - `description: optional string`48604861 A description of what the response format is for, used by the model to4862 determine how to respond in the format.48634864 - `strict: optional boolean or null`48654866 Whether to enable strict schema adherence when generating the output.4867 If set to true, the model will always follow the exact schema defined4868 in the `schema` field. Only a subset of JSON Schema is supported when4869 `strict` is `true`. To learn more, read the [Structured Outputs4870 guide](/api/docs/guides/structured-outputs).48714872 - `ResponseFormatJSONObject object { type }`48734874 JSON object response format. An older method of generating JSON responses.4875 Using `json_schema` is recommended for models that support it. Note that the4876 model will not generate JSON without a system or user message instructing it4877 to do so.48784879 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`48804881 An array of tools the model may call while generating a response. You4882 can specify which tool to use by setting the `tool_choice` parameter.48834884 The two categories of tools you can provide the model are:48854886 - **Built-in tools**: Tools that are provided by OpenAI that extend the4887 model's capabilities, like [web search](/api/docs/guides/tools-web-search)4888 or [file search](/api/docs/guides/tools-file-search). Learn more about4889 [built-in tools](/api/docs/guides/tools).4890 - **Function calls (custom tools)**: Functions that are defined by you,4891 enabling the model to call your own code. Learn more about4892 [function calling](/api/docs/guides/function-calling).48934894 - `Function object { name, parameters, strict, 6 more }`48954896 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).48974898 - `name: string`48994900 The name of the function to call.49014902 - `parameters: map[unknown] or null`49034904 A JSON schema object describing the parameters of the function.49054906 - `strict: boolean or null`49074908 Whether strict parameter validation is enforced for this function tool.49094910 - `type: "function"`49114912 The type of the function tool. Always `function`.49134914 - `"function"`49154916 - `allowed_callers: optional array of "direct" or "programmatic" or null`49174918 The tool invocation context(s).49194920 - `"direct"`49214922 - `"programmatic"`49234924 - `async: optional boolean`49254926 - `defer_loading: optional boolean`49274928 Whether this function is deferred and loaded via tool search.49294930 - `description: optional string or null`49314932 A description of the function. Used by the model to determine whether or not to call the function.49334934 - `output_schema: optional map[unknown] or null`49354936 A JSON schema object describing the JSON value encoded in string outputs for this function.49374938 - `FileSearch object { type, vector_store_ids, filters, 2 more }`49394940 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).49414942 - `type: "file_search"`49434944 The type of the file search tool. Always `file_search`.49454946 - `"file_search"`49474948 - `vector_store_ids: array of string`49494950 The IDs of the vector stores to search.49514952 - `filters: optional ComparisonFilter or CompoundFilter or null`49534954 A filter to apply.49554956 - `ComparisonFilter object { key, type, value }`49574958 A filter used to compare a specified attribute key to a given value using a defined comparison operation.49594960 - `key: string`49614962 The key to compare against the value.49634964 - `type: "eq" or "ne" or "gt" or 5 more`49654966 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.49674968 - `eq`: equals4969 - `ne`: not equal4970 - `gt`: greater than4971 - `gte`: greater than or equal4972 - `lt`: less than4973 - `lte`: less than or equal4974 - `in`: in4975 - `nin`: not in49764977 - `"eq"`49784979 - `"ne"`49804981 - `"gt"`49824983 - `"gte"`49844985 - `"lt"`49864987 - `"lte"`49884989 - `"in"`49904991 - `"nin"`49924993 - `value: string or number or boolean or array of string or number`49944995 The value to compare against the attribute key; supports string, number, or boolean types.49964997 - `string`49984999 - `number`50005001 - `boolean`50025003 - `array of string or number`50045005 - `string`50065007 - `number`50085009 - `CompoundFilter object { filters, type }`50105011 Combine multiple filters using `and` or `or`.50125013 - `filters: array of ComparisonFilter or unknown`50145015 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.50165017 - `ComparisonFilter object { key, type, value }`50185019 A filter used to compare a specified attribute key to a given value using a defined comparison operation.50205021 - `unknown`50225023 - `type: "and" or "or"`50245025 Type of operation: `and` or `or`.50265027 - `"and"`50285029 - `"or"`50305031 - `max_num_results: optional number`50325033 The maximum number of results to return. This number should be between 1 and 50 inclusive.50345035 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`50365037 Ranking options for search.50385039 - `hybrid_search: optional object { embedding_weight, text_weight }`50405041 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.50425043 - `embedding_weight: number`50445045 The weight of the embedding in the reciprocal ranking fusion.50465047 - `text_weight: number`50485049 The weight of the text in the reciprocal ranking fusion.50505051 - `ranker: optional "auto" or "default-2024-11-15"`50525053 The ranker to use for the file search.50545055 - `"auto"`50565057 - `"default-2024-11-15"`50585059 - `score_threshold: optional number`50605061 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.50625063 - `Computer object { type }`50645065 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).50665067 - `type: "computer"`50685069 The type of the computer tool. Always `computer`.50705071 - `"computer"`50725073 - `ComputerUsePreview object { display_height, display_width, environment, type }`50745075 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).50765077 - `display_height: number`50785079 The height of the computer display.50805081 - `display_width: number`50825083 The width of the computer display.50845085 - `environment: "windows" or "mac" or "linux" or 2 more`50865087 The type of computer environment to control.50885089 - `"windows"`50905091 - `"mac"`50925093 - `"linux"`50945095 - `"ubuntu"`50965097 - `"browser"`50985099 - `type: "computer_use_preview"`51005101 The type of the computer use tool. Always `computer_use_preview`.51025103 - `"computer_use_preview"`51045105 - `WebSearch object { type, external_web_access, filters, 2 more }`51065107 Search the Internet for sources related to the prompt. Learn more about the5108 [web search tool](/api/docs/guides/tools-web-search).51095110 - `type: "web_search" or "web_search_2025_08_26"`51115112 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.51135114 - `"web_search"`51155116 - `"web_search_2025_08_26"`51175118 - `external_web_access: optional boolean`51195120 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.51215122 - `filters: optional object { allowed_domains } or null`51235124 Filters for the search.51255126 - `allowed_domains: optional array of string or null`51275128 Allowed domains for the search. If not provided, all domains are allowed.5129 Subdomains of the provided domains are allowed as well.51305131 Example: `["pubmed.ncbi.nlm.nih.gov"]`51325133 - `search_context_size: optional "low" or "medium" or "high"`51345135 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.51365137 - `"low"`51385139 - `"medium"`51405141 - `"high"`51425143 - `user_location: optional object { city, country, region, 2 more } or null`51445145 The approximate location of the user.51465147 - `city: optional string or null`51485149 Free text input for the city of the user, e.g. `San Francisco`.51505151 - `country: optional string or null`51525153 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.51545155 - `region: optional string or null`51565157 Free text input for the region of the user, e.g. `California`.51585159 - `timezone: optional string or null`51605161 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.51625163 - `type: optional "approximate"`51645165 The type of location approximation. Always `approximate`.51665167 - `"approximate"`51685169 - `Mcp object { server_label, type, allowed_callers, 9 more }`51705171 Give the model access to additional tools via remote Model Context Protocol5172 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).51735174 - `server_label: string`51755176 A label for this MCP server, used to identify it in tool calls.51775178 - `type: "mcp"`51795180 The type of the MCP tool. Always `mcp`.51815182 - `"mcp"`51835184 - `allowed_callers: optional array of "direct" or "programmatic" or null`51855186 The tool invocation context(s).51875188 - `"direct"`51895190 - `"programmatic"`51915192 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`51935194 List of allowed tool names or a filter object.51955196 - `McpAllowedTools = array of string`51975198 A string array of allowed tool names51995200 - `McpToolFilter object { read_only, tool_names }`52015202 A filter object to specify which tools are allowed.52035204 - `read_only: optional boolean`52055206 Indicates whether or not a tool modifies data or is read-only. If an5207 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),5208 it will match this filter.52095210 - `tool_names: optional array of string`52115212 List of allowed tool names.52135214 - `authorization: optional string`52155216 An OAuth access token that can be used with a remote MCP server, either5217 with a custom MCP server URL or a service connector. Your application5218 must handle the OAuth authorization flow and provide the token here.52195220 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`52215222 Identifier for service connectors, like those available in ChatGPT. One of5223 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more5224 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).52255226 This field is deprecated for models released after September 1, 2026.5227 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to5228 connect through a Secure MCP Tunnel.52295230 Currently supported `connector_id` values are:52315232 - Dropbox: `connector_dropbox`5233 - Gmail: `connector_gmail`5234 - Google Calendar: `connector_googlecalendar`5235 - Google Drive: `connector_googledrive`5236 - Microsoft Teams: `connector_microsoftteams`5237 - Outlook Calendar: `connector_outlookcalendar`5238 - Outlook Email: `connector_outlookemail`5239 - SharePoint: `connector_sharepoint`52405241 - `"connector_dropbox"`52425243 - `"connector_gmail"`52445245 - `"connector_googlecalendar"`52465247 - `"connector_googledrive"`52485249 - `"connector_microsoftteams"`52505251 - `"connector_outlookcalendar"`52525253 - `"connector_outlookemail"`52545255 - `"connector_sharepoint"`52565257 - `defer_loading: optional boolean`52585259 Whether this MCP tool is deferred and discovered via tool search.52605261 - `headers: optional map[string] or null`52625263 Optional HTTP headers to send to the MCP server. Use for authentication5264 or other purposes.52655266 - `require_approval: optional object { always, never } or "always" or "never" or null`52675268 Specify which of the MCP server's tools require approval.52695270 - `McpToolApprovalFilter object { always, never }`52715272 Specify which of the MCP server's tools require approval. Can be5273 `always`, `never`, or a filter object associated with tools5274 that require approval.52755276 - `always: optional object { read_only, tool_names }`52775278 A filter object to specify which tools are allowed.52795280 - `read_only: optional boolean`52815282 Indicates whether or not a tool modifies data or is read-only. If an5283 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),5284 it will match this filter.52855286 - `tool_names: optional array of string`52875288 List of allowed tool names.52895290 - `never: optional object { read_only, tool_names }`52915292 A filter object to specify which tools are allowed.52935294 - `read_only: optional boolean`52955296 Indicates whether or not a tool modifies data or is read-only. If an5297 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),5298 it will match this filter.52995300 - `tool_names: optional array of string`53015302 List of allowed tool names.53035304 - `McpToolApprovalSetting = "always" or "never"`53055306 Specify a single approval policy for all tools. One of `always` or5307 `never`. When set to `always`, all tools will require approval. When5308 set to `never`, all tools will not require approval.53095310 - `"always"`53115312 - `"never"`53135314 - `server_description: optional string`53155316 Optional description of the MCP server, used to provide more context.53175318 - `server_url: optional string`53195320 The URL for the MCP server. One of `server_url`, `connector_id`, or5321 `tunnel_id` must be provided.53225323 - `tunnel_id: optional string`53245325 The Secure MCP Tunnel ID to use instead of a direct server URL. One of5326 `server_url`, `connector_id`, or `tunnel_id` must be provided.53275328 - `CodeInterpreter object { container, type, allowed_callers }`53295330 A tool that runs Python code to help generate a response to a prompt.53315332 - `container: string or object { type, file_ids, memory_limit, network_policy }`53335334 The code interpreter container. Can be a container ID or an object that5335 specifies uploaded file IDs to make available to your code, along with an5336 optional `memory_limit` setting.53375338 - `string`53395340 The container ID.53415342 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`53435344 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.53455346 - `type: "auto"`53475348 Always `auto`.53495350 - `"auto"`53515352 - `file_ids: optional array of string`53535354 An optional list of uploaded files to make available to your code.53555356 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`53575358 The memory limit for the code interpreter container.53595360 - `"1g"`53615362 - `"4g"`53635364 - `"16g"`53655366 - `"64g"`53675368 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`53695370 Network access policy for the container.53715372 - `ContainerNetworkPolicyDisabled object { type }`53735374 - `type: "disabled"`53755376 Disable outbound network access. Always `disabled`.53775378 - `"disabled"`53795380 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`53815382 - `allowed_domains: array of string`53835384 A list of allowed domains when type is `allowlist`.53855386 - `type: "allowlist"`53875388 Allow outbound network access only to specified domains. Always `allowlist`.53895390 - `"allowlist"`53915392 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`53935394 Optional domain-scoped secrets for allowlisted domains.53955396 - `domain: string`53975398 The domain associated with the secret.53995400 - `name: string`54015402 The name of the secret to inject for the domain.54035404 - `value: string`54055406 The secret value to inject for the domain.54075408 - `type: "code_interpreter"`54095410 The type of the code interpreter tool. Always `code_interpreter`.54115412 - `"code_interpreter"`54135414 - `allowed_callers: optional array of "direct" or "programmatic" or null`54155416 The tool invocation context(s).54175418 - `"direct"`54195420 - `"programmatic"`54215422 - `ProgrammaticToolCalling object { type }`54235424 - `type: "programmatic_tool_calling"`54255426 The type of the tool. Always `programmatic_tool_calling`.54275428 - `"programmatic_tool_calling"`54295430 - `ImageGeneration object { type, action, background, 9 more }`54315432 A tool that generates images using the GPT image models.54335434 - `type: "image_generation"`54355436 The type of the image generation tool. Always `image_generation`.54375438 - `"image_generation"`54395440 - `action: optional "generate" or "edit" or "auto"`54415442 Whether to generate a new image or edit an existing image. Default: `auto`.54435444 - `"generate"`54455446 - `"edit"`54475448 - `"auto"`54495450 - `background: optional "transparent" or "opaque" or "auto"`54515452 Set the background of the generated image. One of `transparent`, `opaque`,5453 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including5454 their `2026-09-08` snapshots, support `opaque` and `transparent`5455 backgrounds. Transparent backgrounds are available for supported GPT Image5456 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in5457 preview. When using `transparent`, set the output format to `png` or `webp`.5458 Default: `auto`.54595460 - `"transparent"`54615462 - `"opaque"`54635464 - `"auto"`54655466 - `input_fidelity: optional "high" or "low" or null`54675468 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.54695470 - `"high"`54715472 - `"low"`54735474 - `input_image_mask: optional object { file_id, image_url }`54755476 Optional mask for inpainting. Contains `image_url`5477 (string, optional) and `file_id` (string, optional).54785479 - `file_id: optional string`54805481 File ID for the mask image.54825483 - `image_url: optional string`54845485 Base64-encoded mask image.54865487 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`54885489 The image generation model to use. One of `gpt-image-1`,5490 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,5491 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,5492 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,5493 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:5494 `gpt-image-1`.54955496 - `string`54975498 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`54995500 The image generation model to use. One of `gpt-image-1`,5501 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,5502 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,5503 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,5504 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:5505 `gpt-image-1`.55065507 - `"gpt-image-1"`55085509 - `"gpt-image-1-mini"`55105511 - `"gpt-image-1.5"`55125513 - `"gpt-image-2"`55145515 - `"gpt-image-2-2026-04-21"`55165517 - `"gpt-image-2.5-sunburst"`55185519 - `"gpt-image-2.5-sunburst-2026-09-08"`55205521 - `"gpt-image-2.5-flare"`55225523 - `"gpt-image-2.5-flare-2026-09-08"`55245525 - `moderation: optional "auto" or "low"`55265527 Moderation level for the generated image. Default: `auto`.55285529 - `"auto"`55305531 - `"low"`55325533 - `output_compression: optional number`55345535 Compression level for the output image. Default: 100.55365537 - `output_format: optional "png" or "webp" or "jpeg"`55385539 The output format of the generated image. One of `png`, `webp`, or5540 `jpeg`. Default: `png`.55415542 - `"png"`55435544 - `"webp"`55455546 - `"jpeg"`55475548 - `partial_images: optional number`55495550 Number of partial images to generate in streaming mode, from 0 (default value) to 3.55515552 - `quality: optional "low" or "medium" or "high" or 3 more`55535554 The quality of the generated image. The GPT image models support `low`,5555 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,5556 including their `2026-09-08` snapshots, also support `xhigh` and `max`.5557 Default: `auto`.55585559 - `"low"`55605561 - `"medium"`55625563 - `"high"`55645565 - `"xhigh"`55665567 - `"max"`55685569 - `"auto"`55705571 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`55725573 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.55745575 - `string`55765577 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`55785579 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.55805581 - `"1024x1024"`55825583 - `"1024x1536"`55845585 - `"1536x1024"`55865587 - `"auto"`55885589 - `LocalShell object { type }`55905591 A tool that allows the model to execute shell commands in a local environment.55925593 - `type: "local_shell"`55945595 The type of the local shell tool. Always `local_shell`.55965597 - `"local_shell"`55985599 - `Shell object { type, allowed_callers, environment }`56005601 A tool that allows the model to execute shell commands.56025603 - `type: "shell"`56045605 The type of the shell tool. Always `shell`.56065607 - `"shell"`56085609 - `allowed_callers: optional array of "direct" or "programmatic" or null`56105611 The tool invocation context(s).56125613 - `"direct"`56145615 - `"programmatic"`56165617 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`56185619 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`56205621 - `type: "container_auto"`56225623 Automatically creates a container for this request56245625 - `"container_auto"`56265627 - `file_ids: optional array of string`56285629 An optional list of uploaded files to make available to your code.56305631 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`56325633 The memory limit for the container.56345635 - `"1g"`56365637 - `"4g"`56385639 - `"16g"`56405641 - `"64g"`56425643 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`56445645 Network access policy for the container.56465647 - `ContainerNetworkPolicyDisabled object { type }`56485649 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`56505651 - `skills: optional array of SkillReference or InlineSkill`56525653 An optional list of skills referenced by id or inline data.56545655 - `SkillReference object { skill_id, type, version }`56565657 - `skill_id: string`56585659 The ID of the referenced skill.56605661 - `type: "skill_reference"`56625663 References a skill created with the /v1/skills endpoint.56645665 - `"skill_reference"`56665667 - `version: optional string`56685669 Optional skill version. Use a positive integer or 'latest'. Omit for default.56705671 - `InlineSkill object { description, name, source, type }`56725673 - `description: string`56745675 The description of the skill.56765677 - `name: string`56785679 The name of the skill.56805681 - `source: InlineSkillSource`56825683 Inline skill payload56845685 - `data: string`56865687 Base64-encoded skill zip bundle.56885689 - `media_type: "application/zip"`56905691 The media type of the inline skill payload. Must be `application/zip`.56925693 - `"application/zip"`56945695 - `type: "base64"`56965697 The type of the inline skill source. Must be `base64`.56985699 - `"base64"`57005701 - `type: "inline"`57025703 Defines an inline skill for this request.57045705 - `"inline"`57065707 - `LocalEnvironment object { type, skills }`57085709 - `type: "local"`57105711 Use a local computer environment.57125713 - `"local"`57145715 - `skills: optional array of LocalSkill`57165717 An optional list of skills.57185719 - `description: string`57205721 The description of the skill.57225723 - `name: string`57245725 The name of the skill.57265727 - `path: string`57285729 The path to the directory containing the skill.57305731 - `ContainerReference object { container_id, type }`57325733 - `container_id: string`57345735 The ID of the referenced container.57365737 - `type: "container_reference"`57385739 References a container created with the /v1/containers endpoint57405741 - `"container_reference"`57425743 - `Custom object { name, type, allowed_callers, 4 more }`57445745 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)57465747 - `name: string`57485749 The name of the custom tool, used to identify it in tool calls.57505751 - `type: "custom"`57525753 The type of the custom tool. Always `custom`.57545755 - `"custom"`57565757 - `allowed_callers: optional array of "direct" or "programmatic" or null`57585759 The tool invocation context(s).57605761 - `"direct"`57625763 - `"programmatic"`57645765 - `async: optional boolean`57665767 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.57685769 - `defer_loading: optional boolean`57705771 Whether this tool should be deferred and discovered via tool search.57725773 - `description: optional string`57745775 Optional description of the custom tool, used to provide more context.57765777 - `format: optional CustomToolInputFormat`57785779 The input format for the custom tool. Default is unconstrained text.57805781 - `Text object { type }`57825783 Unconstrained free-form text.57845785 - `type: "text"`57865787 Unconstrained text format. Always `text`.57885789 - `"text"`57905791 - `Grammar object { definition, syntax, type }`57925793 A grammar defined by the user.57945795 - `definition: string`57965797 The grammar definition.57985799 - `syntax: "lark" or "regex"`58005801 The syntax of the grammar definition. One of `lark` or `regex`.58025803 - `"lark"`58045805 - `"regex"`58065807 - `type: "grammar"`58085809 Grammar format. Always `grammar`.58105811 - `"grammar"`58125813 - `Namespace object { description, name, tools, type }`58145815 Groups function/custom tools under a shared namespace.58165817 - `description: string`58185819 A description of the namespace shown to the model.58205821 - `name: string`58225823 The namespace name used in tool calls (for example, `crm`).58245825 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`58265827 The function/custom tools available inside this namespace.58285829 - `Function object { name, type, allowed_callers, 6 more }`58305831 - `name: string`58325833 - `type: "function"`58345835 - `"function"`58365837 - `allowed_callers: optional array of "direct" or "programmatic" or null`58385839 The tool invocation context(s).58405841 - `"direct"`58425843 - `"programmatic"`58445845 - `async: optional boolean`58465847 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.58485849 - `defer_loading: optional boolean`58505851 Whether this function should be deferred and discovered via tool search.58525853 - `description: optional string or null`58545855 - `output_schema: optional map[unknown] or null`58565857 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.58585859 - `parameters: optional unknown or null`58605861 - `strict: optional boolean or null`58625863 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.58645865 - `Custom object { name, type, allowed_callers, 4 more }`58665867 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)58685869 - `name: string`58705871 The name of the custom tool, used to identify it in tool calls.58725873 - `type: "custom"`58745875 The type of the custom tool. Always `custom`.58765877 - `"custom"`58785879 - `allowed_callers: optional array of "direct" or "programmatic" or null`58805881 The tool invocation context(s).58825883 - `"direct"`58845885 - `"programmatic"`58865887 - `async: optional boolean`58885889 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.58905891 - `defer_loading: optional boolean`58925893 Whether this tool should be deferred and discovered via tool search.58945895 - `description: optional string`58965897 Optional description of the custom tool, used to provide more context.58985899 - `format: optional CustomToolInputFormat`59005901 The input format for the custom tool. Default is unconstrained text.59025903 - `type: "namespace"`59045905 The type of the tool. Always `namespace`.59065907 - `"namespace"`59085909 - `ToolSearch object { type, description, execution, parameters }`59105911 Hosted or BYOT tool search configuration for deferred tools.59125913 - `type: "tool_search"`59145915 The type of the tool. Always `tool_search`.59165917 - `"tool_search"`59185919 - `description: optional string or null`59205921 Description shown to the model for a client-executed tool search tool.59225923 - `execution: optional "server" or "client"`59245925 Whether tool search is executed by the server or by the client.59265927 - `"server"`59285929 - `"client"`59305931 - `parameters: optional unknown or null`59325933 Parameter schema for a client-executed tool search tool.59345935 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`59365937 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).59385939 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`59405941 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.59425943 - `"web_search_preview"`59445945 - `"web_search_preview_2025_03_11"`59465947 - `search_content_types: optional array of "text" or "image"`59485949 - `"text"`59505951 - `"image"`59525953 - `search_context_size: optional "low" or "medium" or "high"`59545955 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.59565957 - `"low"`59585959 - `"medium"`59605961 - `"high"`59625963 - `user_location: optional object { type, city, country, 2 more } or null`59645965 The user's location.59665967 - `type: "approximate"`59685969 The type of location approximation. Always `approximate`.59705971 - `"approximate"`59725973 - `city: optional string or null`59745975 Free text input for the city of the user, e.g. `San Francisco`.59765977 - `country: optional string or null`59785979 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.59805981 - `region: optional string or null`59825983 Free text input for the region of the user, e.g. `California`.59845985 - `timezone: optional string or null`59865987 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.59885989 - `ApplyPatch object { type, allowed_callers }`59905991 Allows the assistant to create, delete, or update files using unified diffs.59925993 - `type: "apply_patch"`59945995 The type of the tool. Always `apply_patch`.59965997 - `"apply_patch"`59985999 - `allowed_callers: optional array of "direct" or "programmatic" or null`60006001 The tool invocation context(s).60026003 - `"direct"`60046005 - `"programmatic"`60066007 - `top_p: optional number`60086009 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.60106011- `error: EvalAPIError`60126013 An object representing an error response from the Eval API.60146015 - `code: string`60166017 The error code.60186019 - `message: string`60206021 The error message.60226023- `eval_id: string`60246025 The identifier of the associated evaluation.60266027- `metadata: Metadata or null`60286029 Set of 16 key-value pairs that can be attached to an object. This can be6030 useful for storing additional information about the object in a structured6031 format, and querying for objects via API or the dashboard.60326033 Keys are strings with a maximum length of 64 characters. Values are strings6034 with a maximum length of 512 characters.60356036- `model: string`60376038 The model that is evaluated, if applicable.60396040- `name: string`60416042 The name of the evaluation run.60436044- `object: "eval.run"`60456046 The type of the object. Always "eval.run".60476048 - `"eval.run"`60496050- `per_model_usage: array of object { cached_tokens, completion_tokens, invocation_count, 3 more }`60516052 Usage statistics for each model during the evaluation run.60536054 - `cached_tokens: number`60556056 The number of tokens retrieved from cache.60576058 - `completion_tokens: number`60596060 The number of completion tokens generated.60616062 - `invocation_count: number`60636064 The number of invocations.60656066 - `model_name: string`60676068 The name of the model.60696070 - `prompt_tokens: number`60716072 The number of prompt tokens used.60736074 - `total_tokens: number`60756076 The total number of tokens used.60776078- `per_testing_criteria_results: array of object { failed, passed, testing_criteria }`60796080 Results per testing criteria applied during the evaluation run.60816082 - `failed: number`60836084 Number of tests failed for this criteria.60856086 - `passed: number`60876088 Number of tests passed for this criteria.60896090 - `testing_criteria: string`60916092 A description of the testing criteria.60936094- `report_url: string`60956096 The URL to the rendered evaluation run report on the UI dashboard.60976098- `result_counts: object { errored, failed, passed, total }`60996100 Counters summarizing the outcomes of the evaluation run.61016102 - `errored: number`61036104 Number of output items that resulted in an error.61056106 - `failed: number`61076108 Number of output items that failed to pass the evaluation.61096110 - `passed: number`61116112 Number of output items that passed the evaluation.61136114 - `total: number`61156116 Total number of executed output items.61176118- `status: string`61196120 The status of the evaluation run.61216122### Example61236124```http6125curl https://api.openai.com/v1/evals/$EVAL_ID/runs/$RUN_ID \6126 -X POST \6127 -H "Authorization: Bearer $OPENAI_API_KEY"6128```61296130#### Response61316132```json6133{6134 "id": "id",6135 "created_at": 0,6136 "data_source": {6137 "source": {6138 "content": [6139 {6140 "item": {6141 "foo": "bar"6142 },6143 "sample": {6144 "foo": "bar"6145 }6146 }6147 ],6148 "type": "file_content"6149 },6150 "type": "jsonl"6151 },6152 "error": {6153 "code": "code",6154 "message": "message"6155 },6156 "eval_id": "eval_id",6157 "metadata": {6158 "foo": "string"6159 },6160 "model": "model",6161 "name": "name",6162 "object": "eval.run",6163 "per_model_usage": [6164 {6165 "cached_tokens": 0,6166 "completion_tokens": 0,6167 "invocation_count": 0,6168 "model_name": "model_name",6169 "prompt_tokens": 0,6170 "total_tokens": 06171 }6172 ],6173 "per_testing_criteria_results": [6174 {6175 "failed": 0,6176 "passed": 0,6177 "testing_criteria": "testing_criteria"6178 }6179 ],6180 "report_url": "https://example.com",6181 "result_counts": {6182 "errored": 0,6183 "failed": 0,6184 "passed": 0,6185 "total": 06186 },6187 "status": "status"6188}6189```61906191### Example61926193```http6194curl https://api.openai.com/v1/evals/eval_67abd54d9b0081909a86353f6fb9317a/runs/evalrun_67abd54d60ec8190832b46859da808f7/cancel \6195 -X POST \6196 -H "Authorization: Bearer $OPENAI_API_KEY" \6197 -H "Content-Type: application/json"6198```61996200#### Response62016202```json6203{6204 "object": "eval.run",6205 "id": "evalrun_67abd54d60ec8190832b46859da808f7",6206 "eval_id": "eval_67abd54d9b0081909a86353f6fb9317a",6207 "report_url": "https://platform.openai.com/evaluations/eval_67abd54d9b0081909a86353f6fb9317a?run_id=evalrun_67abd54d60ec8190832b46859da808f7",6208 "status": "canceled",6209 "model": "gpt-6-astra",6210 "name": "gpt-6-astra",6211 "created_at": 1743092069,6212 "result_counts": {6213 "total": 0,6214 "errored": 0,6215 "failed": 0,6216 "passed": 06217 },6218 "per_model_usage": null,6219 "per_testing_criteria_results": null,6220 "data_source": {6221 "type": "completions",6222 "source": {6223 "type": "file_content",6224 "content": [6225 {6226 "item": {6227 "input": "Tech Company Launches Advanced Artificial Intelligence Platform",6228 "ground_truth": "Technology"6229 }6230 },6231 {6232 "item": {6233 "input": "Central Bank Increases Interest Rates Amid Inflation Concerns",6234 "ground_truth": "Markets"6235 }6236 },6237 {6238 "item": {6239 "input": "International Summit Addresses Climate Change Strategies",6240 "ground_truth": "World"6241 }6242 },6243 {6244 "item": {6245 "input": "Major Retailer Reports Record-Breaking Holiday Sales",6246 "ground_truth": "Business"6247 }6248 },6249 {6250 "item": {6251 "input": "National Team Qualifies for World Championship Finals",6252 "ground_truth": "Sports"6253 }6254 },6255 {6256 "item": {6257 "input": "Stock Markets Rally After Positive Economic Data Released",6258 "ground_truth": "Markets"6259 }6260 },6261 {6262 "item": {6263 "input": "Global Manufacturer Announces Merger with Competitor",6264 "ground_truth": "Business"6265 }6266 },6267 {6268 "item": {6269 "input": "Breakthrough in Renewable Energy Technology Unveiled",6270 "ground_truth": "Technology"6271 }6272 },6273 {6274 "item": {6275 "input": "World Leaders Sign Historic Climate Agreement",6276 "ground_truth": "World"6277 }6278 },6279 {6280 "item": {6281 "input": "Professional Athlete Sets New Record in Championship Event",6282 "ground_truth": "Sports"6283 }6284 },6285 {6286 "item": {6287 "input": "Financial Institutions Adapt to New Regulatory Requirements",6288 "ground_truth": "Business"6289 }6290 },6291 {6292 "item": {6293 "input": "Tech Conference Showcases Advances in Artificial Intelligence",6294 "ground_truth": "Technology"6295 }6296 },6297 {6298 "item": {6299 "input": "Global Markets Respond to Oil Price Fluctuations",6300 "ground_truth": "Markets"6301 }6302 },6303 {6304 "item": {6305 "input": "International Cooperation Strengthened Through New Treaty",6306 "ground_truth": "World"6307 }6308 },6309 {6310 "item": {6311 "input": "Sports League Announces Revised Schedule for Upcoming Season",6312 "ground_truth": "Sports"6313 }6314 }6315 ]6316 },6317 "input_messages": {6318 "type": "template",6319 "template": [6320 {6321 "type": "message",6322 "role": "developer",6323 "content": {6324 "type": "input_text",6325 "text": "Categorize a given news headline into one of the following topics: Technology, Markets, World, Business, or Sports.\n\n# Steps\n\n1. Analyze the content of the news headline to understand its primary focus.\n2. Extract the subject matter, identifying any key indicators or keywords.\n3. Use the identified indicators to determine the most suitable category out of the five options: Technology, Markets, World, Business, or Sports.\n4. Ensure only one category is selected per headline.\n\n# Output Format\n\nRespond with the chosen category as a single word. For instance: \"Technology\", \"Markets\", \"World\", \"Business\", or \"Sports\".\n\n# Examples\n\n**Input**: \"Apple Unveils New iPhone Model, Featuring Advanced AI Features\" \n**Output**: \"Technology\"\n\n**Input**: \"Global Stocks Mixed as Investors Await Central Bank Decisions\" \n**Output**: \"Markets\"\n\n**Input**: \"War in Ukraine: Latest Updates on Negotiation Status\" \n**Output**: \"World\"\n\n**Input**: \"Microsoft in Talks to Acquire Gaming Company for $2 Billion\" \n**Output**: \"Business\"\n\n**Input**: \"Manchester United Secures Win in Premier League Football Match\" \n**Output**: \"Sports\" \n\n# Notes\n\n- If the headline appears to fit into more than one category, choose the most dominant theme.\n- Keywords or phrases such as \"stocks\", \"company acquisition\", \"match\", or technological brands can be good indicators for classification.\n"6326 }6327 },6328 {6329 "type": "message",6330 "role": "user",6331 "content": {6332 "type": "input_text",6333 "text": "{{item.input}}"6334 }6335 }6336 ]6337 },6338 "model": "gpt-6-astra",6339 "sampling_params": {6340 "max_completions_tokens": 20486341 }6342 },6343 "error": null,6344 "metadata": {}6345}6346```63476348## Create eval run63496350**post** `/evals/{eval_id}/runs`63516352Kicks off a new run for a given evaluation, specifying the data source, and what model configuration to use to test. The datasource will be validated against the schema specified in the config of the evaluation.63536354### Path Parameters63556356- `eval_id: string`63576358### Body Parameters63596360- `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`63616362 Details about the run's data source.63636364 - `CreateEvalJSONLRunDataSource object { source, type }`63656366 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval63676368 - `source: object { content, type } or object { id, type }`63696370 Determines what populates the `item` namespace in the data source.63716372 - `EvalJSONLFileContentSource object { content, type }`63736374 - `content: array of object { item, sample }`63756376 The content of the jsonl file.63776378 - `item: map[unknown]`63796380 - `sample: optional map[unknown]`63816382 - `type: "file_content"`63836384 The type of jsonl source. Always `file_content`.63856386 - `"file_content"`63876388 - `EvalJSONLFileIDSource object { id, type }`63896390 - `id: string`63916392 The identifier of the file.63936394 - `type: "file_id"`63956396 The type of jsonl source. Always `file_id`.63976398 - `"file_id"`63996400 - `type: "jsonl"`64016402 The type of data source. Always `jsonl`.64036404 - `"jsonl"`64056406 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`64076408 A CompletionsRunDataSource object describing a model sampling configuration.64096410 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`64116412 Determines what populates the `item` namespace in this run's data source.64136414 - `EvalJSONLFileContentSource object { content, type }`64156416 - `content: array of object { item, sample }`64176418 The content of the jsonl file.64196420 - `item: map[unknown]`64216422 - `sample: optional map[unknown]`64236424 - `type: "file_content"`64256426 The type of jsonl source. Always `file_content`.64276428 - `"file_content"`64296430 - `EvalJSONLFileIDSource object { id, type }`64316432 - `id: string`64336434 The identifier of the file.64356436 - `type: "file_id"`64376438 The type of jsonl source. Always `file_id`.64396440 - `"file_id"`64416442 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`64436444 A StoredCompletionsRunDataSource configuration describing a set of filters64456446 - `type: "stored_completions"`64476448 The type of source. Always `stored_completions`.64496450 - `"stored_completions"`64516452 - `created_after: optional number or null`64536454 An optional Unix timestamp to filter items created after this time.64556456 - `created_before: optional number or null`64576458 An optional Unix timestamp to filter items created before this time.64596460 - `limit: optional number or null`64616462 An optional maximum number of items to return.64636464 - `metadata: optional Metadata or null`64656466 Set of 16 key-value pairs that can be attached to an object. This can be6467 useful for storing additional information about the object in a structured6468 format, and querying for objects via API or the dashboard.64696470 Keys are strings with a maximum length of 64 characters. Values are strings6471 with a maximum length of 512 characters.64726473 - `model: optional string or null`64746475 An optional model to filter by (e.g., 'gpt-6-astra').64766477 - `type: "completions"`64786479 The type of run data source. Always `completions`.64806481 - `"completions"`64826483 - `input_messages: optional object { template, type } or object { item_reference, type }`64846485 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.64866487 - `TemplateInputMessages object { template, type }`64886489 - `template: array of EasyInputMessage or object { content, role, type }`64906491 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.64926493 - `EasyInputMessage object { content, role, phase, type }`64946495 A message input to the model with a role indicating instruction following6496 hierarchy. Instructions given with the `developer` or `system` role take6497 precedence over instructions given with the `user` role. Messages with the6498 `assistant` role are presumed to have been generated by the model in previous6499 interactions.65006501 - `content: string or ResponseInputMessageContentList`65026503 Text, image, or audio input to the model, used to generate a response.6504 Can also contain previous assistant responses.65056506 - `TextInput = string`65076508 A text input to the model.65096510 - `ResponseInputMessageContentList = array of ResponseInputContent`65116512 A list of one or many input items to the model, containing different content6513 types.65146515 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`65166517 A text input to the model.65186519 - `text: string`65206521 The text input to the model.65226523 - `type: "input_text"`65246525 The type of the input item. Always `input_text`.65266527 - `"input_text"`65286529 - `prompt_cache_breakpoint: optional object { mode }`65306531 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.65326533 - `mode: "explicit"`65346535 The breakpoint mode. Always `explicit`.65366537 - `"explicit"`65386539 - `ResponseInputImage object { detail, type, file_id, 2 more }`65406541 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).65426543 - `detail: ImageDetail`65446545 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.65466547 - `"low"`65486549 - `"high"`65506551 - `"auto"`65526553 - `"original"`65546555 - `type: "input_image"`65566557 The type of the input item. Always `input_image`.65586559 - `"input_image"`65606561 - `file_id: optional string or null`65626563 The ID of the file to be sent to the model.65646565 - `image_url: optional string or null`65666567 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.65686569 - `prompt_cache_breakpoint: optional object { mode }`65706571 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.65726573 - `mode: "explicit"`65746575 The breakpoint mode. Always `explicit`.65766577 - `"explicit"`65786579 - `ResponseInputFile object { type, detail, file_data, 4 more }`65806581 A file input to the model.65826583 - `type: "input_file"`65846585 The type of the input item. Always `input_file`.65866587 - `"input_file"`65886589 - `detail: optional "auto" or "low" or "high"`65906591 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.65926593 - `"auto"`65946595 - `"low"`65966597 - `"high"`65986599 - `file_data: optional string`66006601 The content of the file to be sent to the model.66026603 - `file_id: optional string or null`66046605 The ID of the file to be sent to the model.66066607 - `file_url: optional string`66086609 The URL of the file to be sent to the model.66106611 - `filename: optional string`66126613 The name of the file to be sent to the model.66146615 - `prompt_cache_breakpoint: optional object { mode }`66166617 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.66186619 - `mode: "explicit"`66206621 The breakpoint mode. Always `explicit`.66226623 - `"explicit"`66246625 - `role: "user" or "assistant" or "system" or "developer"`66266627 The role of the message input. One of `user`, `assistant`, `system`, or6628 `developer`.66296630 - `"user"`66316632 - `"assistant"`66336634 - `"system"`66356636 - `"developer"`66376638 - `phase: optional "commentary" or "final_answer" or null`66396640 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).6641 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend6642 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.66436644 - `"commentary"`66456646 - `"final_answer"`66476648 - `type: optional "message"`66496650 The type of the message input. Always `message`.66516652 - `"message"`66536654 - `EvalMessageObject object { content, role, type }`66556656 A message input to the model with a role indicating instruction following6657 hierarchy. Instructions given with the `developer` or `system` role take6658 precedence over instructions given with the `user` role. Messages with the6659 `assistant` role are presumed to have been generated by the model in previous6660 interactions.66616662 - `content: string or ResponseInputText or object { text, type } or 3 more`66636664 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.66656666 - `TextInput = string`66676668 A text input to the model.66696670 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`66716672 A text input to the model.66736674 - `OutputText object { text, type }`66756676 A text output from the model.66776678 - `text: string`66796680 The text output from the model.66816682 - `type: "output_text"`66836684 The type of the output text. Always `output_text`.66856686 - `"output_text"`66876688 - `InputImage object { image_url, type, detail }`66896690 An image input block used within EvalItem content arrays.66916692 - `image_url: string`66936694 The URL of the image input.66956696 - `type: "input_image"`66976698 The type of the image input. Always `input_image`.66996700 - `"input_image"`67016702 - `detail: optional string`67036704 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.67056706 - `ResponseInputAudio object { input_audio, type }`67076708 An audio input to the model.67096710 - `input_audio: object { data, format }`67116712 - `data: string`67136714 Base64-encoded audio data.67156716 - `format: "mp3" or "wav"`67176718 The format of the audio data. Currently supported formats are `mp3` and6719 `wav`.67206721 - `"mp3"`67226723 - `"wav"`67246725 - `type: "input_audio"`67266727 The type of the input item. Always `input_audio`.67286729 - `"input_audio"`67306731 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`67326733 A list of inputs, each of which may be either an input text, output text, input6734 image, or input audio object.67356736 - `TextInput = string`67376738 A text input to the model.67396740 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`67416742 A text input to the model.67436744 - `OutputText object { text, type }`67456746 A text output from the model.67476748 - `text: string`67496750 The text output from the model.67516752 - `type: "output_text"`67536754 The type of the output text. Always `output_text`.67556756 - `"output_text"`67576758 - `InputImage object { image_url, type, detail }`67596760 An image input block used within EvalItem content arrays.67616762 - `image_url: string`67636764 The URL of the image input.67656766 - `type: "input_image"`67676768 The type of the image input. Always `input_image`.67696770 - `"input_image"`67716772 - `detail: optional string`67736774 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.67756776 - `ResponseInputAudio object { input_audio, type }`67776778 An audio input to the model.67796780 - `role: "user" or "assistant" or "system" or "developer"`67816782 The role of the message input. One of `user`, `assistant`, `system`, or6783 `developer`.67846785 - `"user"`67866787 - `"assistant"`67886789 - `"system"`67906791 - `"developer"`67926793 - `type: optional "message"`67946795 The type of the message input. Always `message`.67966797 - `"message"`67986799 - `type: "template"`68006801 The type of input messages. Always `template`.68026803 - `"template"`68046805 - `ItemReferenceInputMessages object { item_reference, type }`68066807 - `item_reference: string`68086809 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"68106811 - `type: "item_reference"`68126813 The type of input messages. Always `item_reference`.68146815 - `"item_reference"`68166817 - `model: optional string`68186819 The name of the model to use for generating completions (e.g. "o3-mini").68206821 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`68226823 - `max_completion_tokens: optional number`68246825 The maximum number of tokens in the generated output.68266827 - `reasoning_effort: optional ReasoningEffort or null`68286829 Constrains effort on reasoning for reasoning models. Currently supported6830 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.6831 Reducing reasoning effort can result in faster responses and fewer tokens6832 used on reasoning in a response. Not all reasoning models support every6833 value. See the6834 [reasoning guide](/api/docs/guides/reasoning)6835 for model-specific support.68366837 - `"none"`68386839 - `"minimal"`68406841 - `"low"`68426843 - `"medium"`68446845 - `"high"`68466847 - `"xhigh"`68486849 - `"max"`68506851 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`68526853 An object specifying the format that the model must output.68546855 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables6856 Structured Outputs which ensures the model will match your supplied JSON6857 schema. Learn more in the [Structured Outputs6858 guide](/api/docs/guides/structured-outputs).68596860 Setting to `{ "type": "json_object" }` enables the older JSON mode, which6861 ensures the message the model generates is valid JSON. Using `json_schema`6862 is preferred for models that support it.68636864 - `ResponseFormatText object { type }`68656866 Default response format. Used to generate text responses.68676868 - `type: "text"`68696870 The type of response format being defined. Always `text`.68716872 - `"text"`68736874 - `ResponseFormatJSONSchema object { json_schema, type }`68756876 JSON Schema response format. Used to generate structured JSON responses.6877 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).68786879 - `json_schema: object { name, description, schema, strict }`68806881 Structured Outputs configuration options, including a JSON Schema.68826883 - `name: string`68846885 The name of the response format. Must be a-z, A-Z, 0-9, or contain6886 underscores and dashes, with a maximum length of 64.68876888 - `description: optional string`68896890 A description of what the response format is for, used by the model to6891 determine how to respond in the format.68926893 - `schema: optional map[unknown]`68946895 The schema for the response format, described as a JSON Schema object.6896 Learn how to build JSON schemas [here](https://json-schema.org/).68976898 - `strict: optional boolean or null`68996900 Whether to enable strict schema adherence when generating the output.6901 If set to true, the model will always follow the exact schema defined6902 in the `schema` field. Only a subset of JSON Schema is supported when6903 `strict` is `true`. To learn more, read the [Structured Outputs6904 guide](/api/docs/guides/structured-outputs).69056906 - `type: "json_schema"`69076908 The type of response format being defined. Always `json_schema`.69096910 - `"json_schema"`69116912 - `ResponseFormatJSONObject object { type }`69136914 JSON object response format. An older method of generating JSON responses.6915 Using `json_schema` is recommended for models that support it. Note that the6916 model will not generate JSON without a system or user message instructing it6917 to do so.69186919 - `type: "json_object"`69206921 The type of response format being defined. Always `json_object`.69226923 - `"json_object"`69246925 - `seed: optional number`69266927 A seed value to initialize the randomness, during sampling.69286929 - `temperature: optional number`69306931 A higher temperature increases randomness in the outputs.69326933 - `tools: optional array of ChatCompletionFunctionTool`69346935 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.69366937 - `function: FunctionDefinition`69386939 - `name: string`69406941 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.69426943 - `description: optional string`69446945 A description of what the function does, used by the model to choose when and how to call the function.69466947 - `parameters: optional FunctionParameters`69486949 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.69506951 Omitting `parameters` defines a function with an empty parameter list.69526953 - `strict: optional boolean or null`69546955 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).69566957 - `type: "function"`69586959 The type of the tool. Currently, only `function` is supported.69606961 - `"function"`69626963 - `top_p: optional number`69646965 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.69666967 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`69686969 A ResponsesRunDataSource object describing a model sampling configuration.69706971 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`69726973 Determines what populates the `item` namespace in this run's data source.69746975 - `EvalJSONLFileContentSource object { content, type }`69766977 - `content: array of object { item, sample }`69786979 The content of the jsonl file.69806981 - `item: map[unknown]`69826983 - `sample: optional map[unknown]`69846985 - `type: "file_content"`69866987 The type of jsonl source. Always `file_content`.69886989 - `"file_content"`69906991 - `EvalJSONLFileIDSource object { id, type }`69926993 - `id: string`69946995 The identifier of the file.69966997 - `type: "file_id"`69986999 The type of jsonl source. Always `file_id`.70007001 - `"file_id"`70027003 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`70047005 A EvalResponsesSource object describing a run data source configuration.70067007 - `type: "responses"`70087009 The type of run data source. Always `responses`.70107011 - `"responses"`70127013 - `created_after: optional number or null`70147015 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.70167017 - `created_before: optional number or null`70187019 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.70207021 - `instructions_search: optional string or null`70227023 Optional string to search the 'instructions' field. This is a query parameter used to select responses.70247025 - `metadata: optional unknown or null`70267027 Metadata filter for the responses. This is a query parameter used to select responses.70287029 - `model: optional string or null`70307031 The name of the model to find responses for. This is a query parameter used to select responses.70327033 - `reasoning_effort: optional ReasoningEffort or null`70347035 Constrains effort on reasoning for reasoning models. Currently supported7036 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.7037 Reducing reasoning effort can result in faster responses and fewer tokens7038 used on reasoning in a response. Not all reasoning models support every7039 value. See the7040 [reasoning guide](/api/docs/guides/reasoning)7041 for model-specific support.70427043 - `temperature: optional number or null`70447045 Sampling temperature. This is a query parameter used to select responses.70467047 - `tools: optional array of string or null`70487049 List of tool names. This is a query parameter used to select responses.70507051 - `top_p: optional number or null`70527053 Nucleus sampling parameter. This is a query parameter used to select responses.70547055 - `users: optional array of string or null`70567057 List of user identifiers. This is a query parameter used to select responses.70587059 - `type: "responses"`70607061 The type of run data source. Always `responses`.70627063 - `"responses"`70647065 - `input_messages: optional object { template, type } or object { item_reference, type }`70667067 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.70687069 - `InputMessagesTemplate object { template, type }`70707071 - `template: array of object { content, role } or object { content, role, type }`70727073 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.70747075 - `ChatMessage object { content, role }`70767077 - `content: string`70787079 The content of the message.70807081 - `role: string`70827083 The role of the message (e.g. "system", "assistant", "user").70847085 - `EvalMessageObject object { content, role, type }`70867087 A message input to the model with a role indicating instruction following7088 hierarchy. Instructions given with the `developer` or `system` role take7089 precedence over instructions given with the `user` role. Messages with the7090 `assistant` role are presumed to have been generated by the model in previous7091 interactions.70927093 - `content: string or ResponseInputText or object { text, type } or 3 more`70947095 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.70967097 - `TextInput = string`70987099 A text input to the model.71007101 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`71027103 A text input to the model.71047105 - `OutputText object { text, type }`71067107 A text output from the model.71087109 - `text: string`71107111 The text output from the model.71127113 - `type: "output_text"`71147115 The type of the output text. Always `output_text`.71167117 - `"output_text"`71187119 - `InputImage object { image_url, type, detail }`71207121 An image input block used within EvalItem content arrays.71227123 - `image_url: string`71247125 The URL of the image input.71267127 - `type: "input_image"`71287129 The type of the image input. Always `input_image`.71307131 - `"input_image"`71327133 - `detail: optional string`71347135 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.71367137 - `ResponseInputAudio object { input_audio, type }`71387139 An audio input to the model.71407141 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`71427143 A list of inputs, each of which may be either an input text, output text, input7144 image, or input audio object.71457146 - `role: "user" or "assistant" or "system" or "developer"`71477148 The role of the message input. One of `user`, `assistant`, `system`, or7149 `developer`.71507151 - `"user"`71527153 - `"assistant"`71547155 - `"system"`71567157 - `"developer"`71587159 - `type: optional "message"`71607161 The type of the message input. Always `message`.71627163 - `"message"`71647165 - `type: "template"`71667167 The type of input messages. Always `template`.71687169 - `"template"`71707171 - `InputMessagesItemReference object { item_reference, type }`71727173 - `item_reference: string`71747175 A reference to a variable in the `item` namespace. Ie, "item.name"71767177 - `type: "item_reference"`71787179 The type of input messages. Always `item_reference`.71807181 - `"item_reference"`71827183 - `model: optional string`71847185 The name of the model to use for generating completions (e.g. "o3-mini").71867187 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`71887189 - `max_completion_tokens: optional number`71907191 The maximum number of tokens in the generated output.71927193 - `reasoning_effort: optional ReasoningEffort or null`71947195 Constrains effort on reasoning for reasoning models. Currently supported7196 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.7197 Reducing reasoning effort can result in faster responses and fewer tokens7198 used on reasoning in a response. Not all reasoning models support every7199 value. See the7200 [reasoning guide](/api/docs/guides/reasoning)7201 for model-specific support.72027203 - `seed: optional number`72047205 A seed value to initialize the randomness, during sampling.72067207 - `temperature: optional number`72087209 A higher temperature increases randomness in the outputs.72107211 - `text: optional object { format }`72127213 Configuration options for a text response from the model. Can be plain7214 text or structured JSON data. Learn more:72157216 - [Text inputs and outputs](/api/docs/guides/text)7217 - [Structured Outputs](/api/docs/guides/structured-outputs)72187219 - `format: optional ResponseFormatTextConfig`72207221 An object specifying the format that the model must output.72227223 Configuring `{ "type": "json_schema" }` enables Structured Outputs,7224 which ensures the model will match your supplied JSON schema. Learn more in the7225 [Structured Outputs guide](/api/docs/guides/structured-outputs).72267227 The default format is `{ "type": "text" }` with no additional options.72287229 **Not recommended for gpt-4o and newer models:**72307231 Setting to `{ "type": "json_object" }` enables the older JSON mode, which7232 ensures the message the model generates is valid JSON. Using `json_schema`7233 is preferred for models that support it.72347235 - `ResponseFormatText object { type }`72367237 Default response format. Used to generate text responses.72387239 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`72407241 JSON Schema response format. Used to generate structured JSON responses.7242 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).72437244 - `name: string`72457246 The name of the response format. Must be a-z, A-Z, 0-9, or contain7247 underscores and dashes, with a maximum length of 64.72487249 - `schema: map[unknown]`72507251 The schema for the response format, described as a JSON Schema object.7252 Learn how to build JSON schemas [here](https://json-schema.org/).72537254 - `type: "json_schema"`72557256 The type of response format being defined. Always `json_schema`.72577258 - `"json_schema"`72597260 - `description: optional string`72617262 A description of what the response format is for, used by the model to7263 determine how to respond in the format.72647265 - `strict: optional boolean or null`72667267 Whether to enable strict schema adherence when generating the output.7268 If set to true, the model will always follow the exact schema defined7269 in the `schema` field. Only a subset of JSON Schema is supported when7270 `strict` is `true`. To learn more, read the [Structured Outputs7271 guide](/api/docs/guides/structured-outputs).72727273 - `ResponseFormatJSONObject object { type }`72747275 JSON object response format. An older method of generating JSON responses.7276 Using `json_schema` is recommended for models that support it. Note that the7277 model will not generate JSON without a system or user message instructing it7278 to do so.72797280 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`72817282 An array of tools the model may call while generating a response. You7283 can specify which tool to use by setting the `tool_choice` parameter.72847285 The two categories of tools you can provide the model are:72867287 - **Built-in tools**: Tools that are provided by OpenAI that extend the7288 model's capabilities, like [web search](/api/docs/guides/tools-web-search)7289 or [file search](/api/docs/guides/tools-file-search). Learn more about7290 [built-in tools](/api/docs/guides/tools).7291 - **Function calls (custom tools)**: Functions that are defined by you,7292 enabling the model to call your own code. Learn more about7293 [function calling](/api/docs/guides/function-calling).72947295 - `Function object { name, parameters, strict, 6 more }`72967297 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).72987299 - `name: string`73007301 The name of the function to call.73027303 - `parameters: map[unknown] or null`73047305 A JSON schema object describing the parameters of the function.73067307 - `strict: boolean or null`73087309 Whether strict parameter validation is enforced for this function tool.73107311 - `type: "function"`73127313 The type of the function tool. Always `function`.73147315 - `"function"`73167317 - `allowed_callers: optional array of "direct" or "programmatic" or null`73187319 The tool invocation context(s).73207321 - `"direct"`73227323 - `"programmatic"`73247325 - `async: optional boolean`73267327 - `defer_loading: optional boolean`73287329 Whether this function is deferred and loaded via tool search.73307331 - `description: optional string or null`73327333 A description of the function. Used by the model to determine whether or not to call the function.73347335 - `output_schema: optional map[unknown] or null`73367337 A JSON schema object describing the JSON value encoded in string outputs for this function.73387339 - `FileSearch object { type, vector_store_ids, filters, 2 more }`73407341 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).73427343 - `type: "file_search"`73447345 The type of the file search tool. Always `file_search`.73467347 - `"file_search"`73487349 - `vector_store_ids: array of string`73507351 The IDs of the vector stores to search.73527353 - `filters: optional ComparisonFilter or CompoundFilter or null`73547355 A filter to apply.73567357 - `ComparisonFilter object { key, type, value }`73587359 A filter used to compare a specified attribute key to a given value using a defined comparison operation.73607361 - `key: string`73627363 The key to compare against the value.73647365 - `type: "eq" or "ne" or "gt" or 5 more`73667367 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.73687369 - `eq`: equals7370 - `ne`: not equal7371 - `gt`: greater than7372 - `gte`: greater than or equal7373 - `lt`: less than7374 - `lte`: less than or equal7375 - `in`: in7376 - `nin`: not in73777378 - `"eq"`73797380 - `"ne"`73817382 - `"gt"`73837384 - `"gte"`73857386 - `"lt"`73877388 - `"lte"`73897390 - `"in"`73917392 - `"nin"`73937394 - `value: string or number or boolean or array of string or number`73957396 The value to compare against the attribute key; supports string, number, or boolean types.73977398 - `string`73997400 - `number`74017402 - `boolean`74037404 - `array of string or number`74057406 - `string`74077408 - `number`74097410 - `CompoundFilter object { filters, type }`74117412 Combine multiple filters using `and` or `or`.74137414 - `filters: array of ComparisonFilter or unknown`74157416 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.74177418 - `ComparisonFilter object { key, type, value }`74197420 A filter used to compare a specified attribute key to a given value using a defined comparison operation.74217422 - `unknown`74237424 - `type: "and" or "or"`74257426 Type of operation: `and` or `or`.74277428 - `"and"`74297430 - `"or"`74317432 - `max_num_results: optional number`74337434 The maximum number of results to return. This number should be between 1 and 50 inclusive.74357436 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`74377438 Ranking options for search.74397440 - `hybrid_search: optional object { embedding_weight, text_weight }`74417442 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.74437444 - `embedding_weight: number`74457446 The weight of the embedding in the reciprocal ranking fusion.74477448 - `text_weight: number`74497450 The weight of the text in the reciprocal ranking fusion.74517452 - `ranker: optional "auto" or "default-2024-11-15"`74537454 The ranker to use for the file search.74557456 - `"auto"`74577458 - `"default-2024-11-15"`74597460 - `score_threshold: optional number`74617462 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.74637464 - `Computer object { type }`74657466 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).74677468 - `type: "computer"`74697470 The type of the computer tool. Always `computer`.74717472 - `"computer"`74737474 - `ComputerUsePreview object { display_height, display_width, environment, type }`74757476 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).74777478 - `display_height: number`74797480 The height of the computer display.74817482 - `display_width: number`74837484 The width of the computer display.74857486 - `environment: "windows" or "mac" or "linux" or 2 more`74877488 The type of computer environment to control.74897490 - `"windows"`74917492 - `"mac"`74937494 - `"linux"`74957496 - `"ubuntu"`74977498 - `"browser"`74997500 - `type: "computer_use_preview"`75017502 The type of the computer use tool. Always `computer_use_preview`.75037504 - `"computer_use_preview"`75057506 - `WebSearch object { type, external_web_access, filters, 2 more }`75077508 Search the Internet for sources related to the prompt. Learn more about the7509 [web search tool](/api/docs/guides/tools-web-search).75107511 - `type: "web_search" or "web_search_2025_08_26"`75127513 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.75147515 - `"web_search"`75167517 - `"web_search_2025_08_26"`75187519 - `external_web_access: optional boolean`75207521 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.75227523 - `filters: optional object { allowed_domains } or null`75247525 Filters for the search.75267527 - `allowed_domains: optional array of string or null`75287529 Allowed domains for the search. If not provided, all domains are allowed.7530 Subdomains of the provided domains are allowed as well.75317532 Example: `["pubmed.ncbi.nlm.nih.gov"]`75337534 - `search_context_size: optional "low" or "medium" or "high"`75357536 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.75377538 - `"low"`75397540 - `"medium"`75417542 - `"high"`75437544 - `user_location: optional object { city, country, region, 2 more } or null`75457546 The approximate location of the user.75477548 - `city: optional string or null`75497550 Free text input for the city of the user, e.g. `San Francisco`.75517552 - `country: optional string or null`75537554 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.75557556 - `region: optional string or null`75577558 Free text input for the region of the user, e.g. `California`.75597560 - `timezone: optional string or null`75617562 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.75637564 - `type: optional "approximate"`75657566 The type of location approximation. Always `approximate`.75677568 - `"approximate"`75697570 - `Mcp object { server_label, type, allowed_callers, 9 more }`75717572 Give the model access to additional tools via remote Model Context Protocol7573 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).75747575 - `server_label: string`75767577 A label for this MCP server, used to identify it in tool calls.75787579 - `type: "mcp"`75807581 The type of the MCP tool. Always `mcp`.75827583 - `"mcp"`75847585 - `allowed_callers: optional array of "direct" or "programmatic" or null`75867587 The tool invocation context(s).75887589 - `"direct"`75907591 - `"programmatic"`75927593 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`75947595 List of allowed tool names or a filter object.75967597 - `McpAllowedTools = array of string`75987599 A string array of allowed tool names76007601 - `McpToolFilter object { read_only, tool_names }`76027603 A filter object to specify which tools are allowed.76047605 - `read_only: optional boolean`76067607 Indicates whether or not a tool modifies data or is read-only. If an7608 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),7609 it will match this filter.76107611 - `tool_names: optional array of string`76127613 List of allowed tool names.76147615 - `authorization: optional string`76167617 An OAuth access token that can be used with a remote MCP server, either7618 with a custom MCP server URL or a service connector. Your application7619 must handle the OAuth authorization flow and provide the token here.76207621 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`76227623 Identifier for service connectors, like those available in ChatGPT. One of7624 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more7625 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).76267627 This field is deprecated for models released after September 1, 2026.7628 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to7629 connect through a Secure MCP Tunnel.76307631 Currently supported `connector_id` values are:76327633 - Dropbox: `connector_dropbox`7634 - Gmail: `connector_gmail`7635 - Google Calendar: `connector_googlecalendar`7636 - Google Drive: `connector_googledrive`7637 - Microsoft Teams: `connector_microsoftteams`7638 - Outlook Calendar: `connector_outlookcalendar`7639 - Outlook Email: `connector_outlookemail`7640 - SharePoint: `connector_sharepoint`76417642 - `"connector_dropbox"`76437644 - `"connector_gmail"`76457646 - `"connector_googlecalendar"`76477648 - `"connector_googledrive"`76497650 - `"connector_microsoftteams"`76517652 - `"connector_outlookcalendar"`76537654 - `"connector_outlookemail"`76557656 - `"connector_sharepoint"`76577658 - `defer_loading: optional boolean`76597660 Whether this MCP tool is deferred and discovered via tool search.76617662 - `headers: optional map[string] or null`76637664 Optional HTTP headers to send to the MCP server. Use for authentication7665 or other purposes.76667667 - `require_approval: optional object { always, never } or "always" or "never" or null`76687669 Specify which of the MCP server's tools require approval.76707671 - `McpToolApprovalFilter object { always, never }`76727673 Specify which of the MCP server's tools require approval. Can be7674 `always`, `never`, or a filter object associated with tools7675 that require approval.76767677 - `always: optional object { read_only, tool_names }`76787679 A filter object to specify which tools are allowed.76807681 - `read_only: optional boolean`76827683 Indicates whether or not a tool modifies data or is read-only. If an7684 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),7685 it will match this filter.76867687 - `tool_names: optional array of string`76887689 List of allowed tool names.76907691 - `never: optional object { read_only, tool_names }`76927693 A filter object to specify which tools are allowed.76947695 - `read_only: optional boolean`76967697 Indicates whether or not a tool modifies data or is read-only. If an7698 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),7699 it will match this filter.77007701 - `tool_names: optional array of string`77027703 List of allowed tool names.77047705 - `McpToolApprovalSetting = "always" or "never"`77067707 Specify a single approval policy for all tools. One of `always` or7708 `never`. When set to `always`, all tools will require approval. When7709 set to `never`, all tools will not require approval.77107711 - `"always"`77127713 - `"never"`77147715 - `server_description: optional string`77167717 Optional description of the MCP server, used to provide more context.77187719 - `server_url: optional string`77207721 The URL for the MCP server. One of `server_url`, `connector_id`, or7722 `tunnel_id` must be provided.77237724 - `tunnel_id: optional string`77257726 The Secure MCP Tunnel ID to use instead of a direct server URL. One of7727 `server_url`, `connector_id`, or `tunnel_id` must be provided.77287729 - `CodeInterpreter object { container, type, allowed_callers }`77307731 A tool that runs Python code to help generate a response to a prompt.77327733 - `container: string or object { type, file_ids, memory_limit, network_policy }`77347735 The code interpreter container. Can be a container ID or an object that7736 specifies uploaded file IDs to make available to your code, along with an7737 optional `memory_limit` setting.77387739 - `string`77407741 The container ID.77427743 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`77447745 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.77467747 - `type: "auto"`77487749 Always `auto`.77507751 - `"auto"`77527753 - `file_ids: optional array of string`77547755 An optional list of uploaded files to make available to your code.77567757 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`77587759 The memory limit for the code interpreter container.77607761 - `"1g"`77627763 - `"4g"`77647765 - `"16g"`77667767 - `"64g"`77687769 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`77707771 Network access policy for the container.77727773 - `ContainerNetworkPolicyDisabled object { type }`77747775 - `type: "disabled"`77767777 Disable outbound network access. Always `disabled`.77787779 - `"disabled"`77807781 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`77827783 - `allowed_domains: array of string`77847785 A list of allowed domains when type is `allowlist`.77867787 - `type: "allowlist"`77887789 Allow outbound network access only to specified domains. Always `allowlist`.77907791 - `"allowlist"`77927793 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`77947795 Optional domain-scoped secrets for allowlisted domains.77967797 - `domain: string`77987799 The domain associated with the secret.78007801 - `name: string`78027803 The name of the secret to inject for the domain.78047805 - `value: string`78067807 The secret value to inject for the domain.78087809 - `type: "code_interpreter"`78107811 The type of the code interpreter tool. Always `code_interpreter`.78127813 - `"code_interpreter"`78147815 - `allowed_callers: optional array of "direct" or "programmatic" or null`78167817 The tool invocation context(s).78187819 - `"direct"`78207821 - `"programmatic"`78227823 - `ProgrammaticToolCalling object { type }`78247825 - `type: "programmatic_tool_calling"`78267827 The type of the tool. Always `programmatic_tool_calling`.78287829 - `"programmatic_tool_calling"`78307831 - `ImageGeneration object { type, action, background, 9 more }`78327833 A tool that generates images using the GPT image models.78347835 - `type: "image_generation"`78367837 The type of the image generation tool. Always `image_generation`.78387839 - `"image_generation"`78407841 - `action: optional "generate" or "edit" or "auto"`78427843 Whether to generate a new image or edit an existing image. Default: `auto`.78447845 - `"generate"`78467847 - `"edit"`78487849 - `"auto"`78507851 - `background: optional "transparent" or "opaque" or "auto"`78527853 Set the background of the generated image. One of `transparent`, `opaque`,7854 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including7855 their `2026-09-08` snapshots, support `opaque` and `transparent`7856 backgrounds. Transparent backgrounds are available for supported GPT Image7857 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in7858 preview. When using `transparent`, set the output format to `png` or `webp`.7859 Default: `auto`.78607861 - `"transparent"`78627863 - `"opaque"`78647865 - `"auto"`78667867 - `input_fidelity: optional "high" or "low" or null`78687869 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.78707871 - `"high"`78727873 - `"low"`78747875 - `input_image_mask: optional object { file_id, image_url }`78767877 Optional mask for inpainting. Contains `image_url`7878 (string, optional) and `file_id` (string, optional).78797880 - `file_id: optional string`78817882 File ID for the mask image.78837884 - `image_url: optional string`78857886 Base64-encoded mask image.78877888 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`78897890 The image generation model to use. One of `gpt-image-1`,7891 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,7892 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,7893 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,7894 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:7895 `gpt-image-1`.78967897 - `string`78987899 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`79007901 The image generation model to use. One of `gpt-image-1`,7902 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,7903 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,7904 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,7905 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:7906 `gpt-image-1`.79077908 - `"gpt-image-1"`79097910 - `"gpt-image-1-mini"`79117912 - `"gpt-image-1.5"`79137914 - `"gpt-image-2"`79157916 - `"gpt-image-2-2026-04-21"`79177918 - `"gpt-image-2.5-sunburst"`79197920 - `"gpt-image-2.5-sunburst-2026-09-08"`79217922 - `"gpt-image-2.5-flare"`79237924 - `"gpt-image-2.5-flare-2026-09-08"`79257926 - `moderation: optional "auto" or "low"`79277928 Moderation level for the generated image. Default: `auto`.79297930 - `"auto"`79317932 - `"low"`79337934 - `output_compression: optional number`79357936 Compression level for the output image. Default: 100.79377938 - `output_format: optional "png" or "webp" or "jpeg"`79397940 The output format of the generated image. One of `png`, `webp`, or7941 `jpeg`. Default: `png`.79427943 - `"png"`79447945 - `"webp"`79467947 - `"jpeg"`79487949 - `partial_images: optional number`79507951 Number of partial images to generate in streaming mode, from 0 (default value) to 3.79527953 - `quality: optional "low" or "medium" or "high" or 3 more`79547955 The quality of the generated image. The GPT image models support `low`,7956 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,7957 including their `2026-09-08` snapshots, also support `xhigh` and `max`.7958 Default: `auto`.79597960 - `"low"`79617962 - `"medium"`79637964 - `"high"`79657966 - `"xhigh"`79677968 - `"max"`79697970 - `"auto"`79717972 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`79737974 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.79757976 - `string`79777978 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`79797980 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.79817982 - `"1024x1024"`79837984 - `"1024x1536"`79857986 - `"1536x1024"`79877988 - `"auto"`79897990 - `LocalShell object { type }`79917992 A tool that allows the model to execute shell commands in a local environment.79937994 - `type: "local_shell"`79957996 The type of the local shell tool. Always `local_shell`.79977998 - `"local_shell"`79998000 - `Shell object { type, allowed_callers, environment }`80018002 A tool that allows the model to execute shell commands.80038004 - `type: "shell"`80058006 The type of the shell tool. Always `shell`.80078008 - `"shell"`80098010 - `allowed_callers: optional array of "direct" or "programmatic" or null`80118012 The tool invocation context(s).80138014 - `"direct"`80158016 - `"programmatic"`80178018 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`80198020 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`80218022 - `type: "container_auto"`80238024 Automatically creates a container for this request80258026 - `"container_auto"`80278028 - `file_ids: optional array of string`80298030 An optional list of uploaded files to make available to your code.80318032 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`80338034 The memory limit for the container.80358036 - `"1g"`80378038 - `"4g"`80398040 - `"16g"`80418042 - `"64g"`80438044 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`80458046 Network access policy for the container.80478048 - `ContainerNetworkPolicyDisabled object { type }`80498050 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`80518052 - `skills: optional array of SkillReference or InlineSkill`80538054 An optional list of skills referenced by id or inline data.80558056 - `SkillReference object { skill_id, type, version }`80578058 - `skill_id: string`80598060 The ID of the referenced skill.80618062 - `type: "skill_reference"`80638064 References a skill created with the /v1/skills endpoint.80658066 - `"skill_reference"`80678068 - `version: optional string`80698070 Optional skill version. Use a positive integer or 'latest'. Omit for default.80718072 - `InlineSkill object { description, name, source, type }`80738074 - `description: string`80758076 The description of the skill.80778078 - `name: string`80798080 The name of the skill.80818082 - `source: InlineSkillSource`80838084 Inline skill payload80858086 - `data: string`80878088 Base64-encoded skill zip bundle.80898090 - `media_type: "application/zip"`80918092 The media type of the inline skill payload. Must be `application/zip`.80938094 - `"application/zip"`80958096 - `type: "base64"`80978098 The type of the inline skill source. Must be `base64`.80998100 - `"base64"`81018102 - `type: "inline"`81038104 Defines an inline skill for this request.81058106 - `"inline"`81078108 - `LocalEnvironment object { type, skills }`81098110 - `type: "local"`81118112 Use a local computer environment.81138114 - `"local"`81158116 - `skills: optional array of LocalSkill`81178118 An optional list of skills.81198120 - `description: string`81218122 The description of the skill.81238124 - `name: string`81258126 The name of the skill.81278128 - `path: string`81298130 The path to the directory containing the skill.81318132 - `ContainerReference object { container_id, type }`81338134 - `container_id: string`81358136 The ID of the referenced container.81378138 - `type: "container_reference"`81398140 References a container created with the /v1/containers endpoint81418142 - `"container_reference"`81438144 - `Custom object { name, type, allowed_callers, 4 more }`81458146 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)81478148 - `name: string`81498150 The name of the custom tool, used to identify it in tool calls.81518152 - `type: "custom"`81538154 The type of the custom tool. Always `custom`.81558156 - `"custom"`81578158 - `allowed_callers: optional array of "direct" or "programmatic" or null`81598160 The tool invocation context(s).81618162 - `"direct"`81638164 - `"programmatic"`81658166 - `async: optional boolean`81678168 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.81698170 - `defer_loading: optional boolean`81718172 Whether this tool should be deferred and discovered via tool search.81738174 - `description: optional string`81758176 Optional description of the custom tool, used to provide more context.81778178 - `format: optional CustomToolInputFormat`81798180 The input format for the custom tool. Default is unconstrained text.81818182 - `Text object { type }`81838184 Unconstrained free-form text.81858186 - `type: "text"`81878188 Unconstrained text format. Always `text`.81898190 - `"text"`81918192 - `Grammar object { definition, syntax, type }`81938194 A grammar defined by the user.81958196 - `definition: string`81978198 The grammar definition.81998200 - `syntax: "lark" or "regex"`82018202 The syntax of the grammar definition. One of `lark` or `regex`.82038204 - `"lark"`82058206 - `"regex"`82078208 - `type: "grammar"`82098210 Grammar format. Always `grammar`.82118212 - `"grammar"`82138214 - `Namespace object { description, name, tools, type }`82158216 Groups function/custom tools under a shared namespace.82178218 - `description: string`82198220 A description of the namespace shown to the model.82218222 - `name: string`82238224 The namespace name used in tool calls (for example, `crm`).82258226 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`82278228 The function/custom tools available inside this namespace.82298230 - `Function object { name, type, allowed_callers, 6 more }`82318232 - `name: string`82338234 - `type: "function"`82358236 - `"function"`82378238 - `allowed_callers: optional array of "direct" or "programmatic" or null`82398240 The tool invocation context(s).82418242 - `"direct"`82438244 - `"programmatic"`82458246 - `async: optional boolean`82478248 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.82498250 - `defer_loading: optional boolean`82518252 Whether this function should be deferred and discovered via tool search.82538254 - `description: optional string or null`82558256 - `output_schema: optional map[unknown] or null`82578258 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.82598260 - `parameters: optional unknown or null`82618262 - `strict: optional boolean or null`82638264 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.82658266 - `Custom object { name, type, allowed_callers, 4 more }`82678268 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)82698270 - `name: string`82718272 The name of the custom tool, used to identify it in tool calls.82738274 - `type: "custom"`82758276 The type of the custom tool. Always `custom`.82778278 - `"custom"`82798280 - `allowed_callers: optional array of "direct" or "programmatic" or null`82818282 The tool invocation context(s).82838284 - `"direct"`82858286 - `"programmatic"`82878288 - `async: optional boolean`82898290 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.82918292 - `defer_loading: optional boolean`82938294 Whether this tool should be deferred and discovered via tool search.82958296 - `description: optional string`82978298 Optional description of the custom tool, used to provide more context.82998300 - `format: optional CustomToolInputFormat`83018302 The input format for the custom tool. Default is unconstrained text.83038304 - `type: "namespace"`83058306 The type of the tool. Always `namespace`.83078308 - `"namespace"`83098310 - `ToolSearch object { type, description, execution, parameters }`83118312 Hosted or BYOT tool search configuration for deferred tools.83138314 - `type: "tool_search"`83158316 The type of the tool. Always `tool_search`.83178318 - `"tool_search"`83198320 - `description: optional string or null`83218322 Description shown to the model for a client-executed tool search tool.83238324 - `execution: optional "server" or "client"`83258326 Whether tool search is executed by the server or by the client.83278328 - `"server"`83298330 - `"client"`83318332 - `parameters: optional unknown or null`83338334 Parameter schema for a client-executed tool search tool.83358336 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`83378338 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).83398340 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`83418342 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.83438344 - `"web_search_preview"`83458346 - `"web_search_preview_2025_03_11"`83478348 - `search_content_types: optional array of "text" or "image"`83498350 - `"text"`83518352 - `"image"`83538354 - `search_context_size: optional "low" or "medium" or "high"`83558356 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.83578358 - `"low"`83598360 - `"medium"`83618362 - `"high"`83638364 - `user_location: optional object { type, city, country, 2 more } or null`83658366 The user's location.83678368 - `type: "approximate"`83698370 The type of location approximation. Always `approximate`.83718372 - `"approximate"`83738374 - `city: optional string or null`83758376 Free text input for the city of the user, e.g. `San Francisco`.83778378 - `country: optional string or null`83798380 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.83818382 - `region: optional string or null`83838384 Free text input for the region of the user, e.g. `California`.83858386 - `timezone: optional string or null`83878388 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.83898390 - `ApplyPatch object { type, allowed_callers }`83918392 Allows the assistant to create, delete, or update files using unified diffs.83938394 - `type: "apply_patch"`83958396 The type of the tool. Always `apply_patch`.83978398 - `"apply_patch"`83998400 - `allowed_callers: optional array of "direct" or "programmatic" or null`84018402 The tool invocation context(s).84038404 - `"direct"`84058406 - `"programmatic"`84078408 - `top_p: optional number`84098410 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.84118412- `metadata: optional Metadata or null`84138414 Set of 16 key-value pairs that can be attached to an object. This can be8415 useful for storing additional information about the object in a structured8416 format, and querying for objects via API or the dashboard.84178418 Keys are strings with a maximum length of 64 characters. Values are strings8419 with a maximum length of 512 characters.84208421- `name: optional string`84228423 The name of the run.84248425### Returns84268427- `id: string`84288429 Unique identifier for the evaluation run.84308431- `created_at: number`84328433 Unix timestamp (in seconds) when the evaluation run was created.84348435- `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`84368437 Information about the run's data source.84388439 - `CreateEvalJSONLRunDataSource object { source, type }`84408441 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval84428443 - `source: object { content, type } or object { id, type }`84448445 Determines what populates the `item` namespace in the data source.84468447 - `EvalJSONLFileContentSource object { content, type }`84488449 - `content: array of object { item, sample }`84508451 The content of the jsonl file.84528453 - `item: map[unknown]`84548455 - `sample: optional map[unknown]`84568457 - `type: "file_content"`84588459 The type of jsonl source. Always `file_content`.84608461 - `"file_content"`84628463 - `EvalJSONLFileIDSource object { id, type }`84648465 - `id: string`84668467 The identifier of the file.84688469 - `type: "file_id"`84708471 The type of jsonl source. Always `file_id`.84728473 - `"file_id"`84748475 - `type: "jsonl"`84768477 The type of data source. Always `jsonl`.84788479 - `"jsonl"`84808481 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`84828483 A CompletionsRunDataSource object describing a model sampling configuration.84848485 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`84868487 Determines what populates the `item` namespace in this run's data source.84888489 - `EvalJSONLFileContentSource object { content, type }`84908491 - `content: array of object { item, sample }`84928493 The content of the jsonl file.84948495 - `item: map[unknown]`84968497 - `sample: optional map[unknown]`84988499 - `type: "file_content"`85008501 The type of jsonl source. Always `file_content`.85028503 - `"file_content"`85048505 - `EvalJSONLFileIDSource object { id, type }`85068507 - `id: string`85088509 The identifier of the file.85108511 - `type: "file_id"`85128513 The type of jsonl source. Always `file_id`.85148515 - `"file_id"`85168517 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`85188519 A StoredCompletionsRunDataSource configuration describing a set of filters85208521 - `type: "stored_completions"`85228523 The type of source. Always `stored_completions`.85248525 - `"stored_completions"`85268527 - `created_after: optional number or null`85288529 An optional Unix timestamp to filter items created after this time.85308531 - `created_before: optional number or null`85328533 An optional Unix timestamp to filter items created before this time.85348535 - `limit: optional number or null`85368537 An optional maximum number of items to return.85388539 - `metadata: optional Metadata or null`85408541 Set of 16 key-value pairs that can be attached to an object. This can be8542 useful for storing additional information about the object in a structured8543 format, and querying for objects via API or the dashboard.85448545 Keys are strings with a maximum length of 64 characters. Values are strings8546 with a maximum length of 512 characters.85478548 - `model: optional string or null`85498550 An optional model to filter by (e.g., 'gpt-6-astra').85518552 - `type: "completions"`85538554 The type of run data source. Always `completions`.85558556 - `"completions"`85578558 - `input_messages: optional object { template, type } or object { item_reference, type }`85598560 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.85618562 - `TemplateInputMessages object { template, type }`85638564 - `template: array of EasyInputMessage or object { content, role, type }`85658566 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.85678568 - `EasyInputMessage object { content, role, phase, type }`85698570 A message input to the model with a role indicating instruction following8571 hierarchy. Instructions given with the `developer` or `system` role take8572 precedence over instructions given with the `user` role. Messages with the8573 `assistant` role are presumed to have been generated by the model in previous8574 interactions.85758576 - `content: string or ResponseInputMessageContentList`85778578 Text, image, or audio input to the model, used to generate a response.8579 Can also contain previous assistant responses.85808581 - `TextInput = string`85828583 A text input to the model.85848585 - `ResponseInputMessageContentList = array of ResponseInputContent`85868587 A list of one or many input items to the model, containing different content8588 types.85898590 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`85918592 A text input to the model.85938594 - `text: string`85958596 The text input to the model.85978598 - `type: "input_text"`85998600 The type of the input item. Always `input_text`.86018602 - `"input_text"`86038604 - `prompt_cache_breakpoint: optional object { mode }`86058606 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.86078608 - `mode: "explicit"`86098610 The breakpoint mode. Always `explicit`.86118612 - `"explicit"`86138614 - `ResponseInputImage object { detail, type, file_id, 2 more }`86158616 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).86178618 - `detail: ImageDetail`86198620 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.86218622 - `"low"`86238624 - `"high"`86258626 - `"auto"`86278628 - `"original"`86298630 - `type: "input_image"`86318632 The type of the input item. Always `input_image`.86338634 - `"input_image"`86358636 - `file_id: optional string or null`86378638 The ID of the file to be sent to the model.86398640 - `image_url: optional string or null`86418642 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.86438644 - `prompt_cache_breakpoint: optional object { mode }`86458646 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.86478648 - `mode: "explicit"`86498650 The breakpoint mode. Always `explicit`.86518652 - `"explicit"`86538654 - `ResponseInputFile object { type, detail, file_data, 4 more }`86558656 A file input to the model.86578658 - `type: "input_file"`86598660 The type of the input item. Always `input_file`.86618662 - `"input_file"`86638664 - `detail: optional "auto" or "low" or "high"`86658666 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.86678668 - `"auto"`86698670 - `"low"`86718672 - `"high"`86738674 - `file_data: optional string`86758676 The content of the file to be sent to the model.86778678 - `file_id: optional string or null`86798680 The ID of the file to be sent to the model.86818682 - `file_url: optional string`86838684 The URL of the file to be sent to the model.86858686 - `filename: optional string`86878688 The name of the file to be sent to the model.86898690 - `prompt_cache_breakpoint: optional object { mode }`86918692 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.86938694 - `mode: "explicit"`86958696 The breakpoint mode. Always `explicit`.86978698 - `"explicit"`86998700 - `role: "user" or "assistant" or "system" or "developer"`87018702 The role of the message input. One of `user`, `assistant`, `system`, or8703 `developer`.87048705 - `"user"`87068707 - `"assistant"`87088709 - `"system"`87108711 - `"developer"`87128713 - `phase: optional "commentary" or "final_answer" or null`87148715 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).8716 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend8717 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.87188719 - `"commentary"`87208721 - `"final_answer"`87228723 - `type: optional "message"`87248725 The type of the message input. Always `message`.87268727 - `"message"`87288729 - `EvalMessageObject object { content, role, type }`87308731 A message input to the model with a role indicating instruction following8732 hierarchy. Instructions given with the `developer` or `system` role take8733 precedence over instructions given with the `user` role. Messages with the8734 `assistant` role are presumed to have been generated by the model in previous8735 interactions.87368737 - `content: string or ResponseInputText or object { text, type } or 3 more`87388739 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.87408741 - `TextInput = string`87428743 A text input to the model.87448745 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`87468747 A text input to the model.87488749 - `OutputText object { text, type }`87508751 A text output from the model.87528753 - `text: string`87548755 The text output from the model.87568757 - `type: "output_text"`87588759 The type of the output text. Always `output_text`.87608761 - `"output_text"`87628763 - `InputImage object { image_url, type, detail }`87648765 An image input block used within EvalItem content arrays.87668767 - `image_url: string`87688769 The URL of the image input.87708771 - `type: "input_image"`87728773 The type of the image input. Always `input_image`.87748775 - `"input_image"`87768777 - `detail: optional string`87788779 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.87808781 - `ResponseInputAudio object { input_audio, type }`87828783 An audio input to the model.87848785 - `input_audio: object { data, format }`87868787 - `data: string`87888789 Base64-encoded audio data.87908791 - `format: "mp3" or "wav"`87928793 The format of the audio data. Currently supported formats are `mp3` and8794 `wav`.87958796 - `"mp3"`87978798 - `"wav"`87998800 - `type: "input_audio"`88018802 The type of the input item. Always `input_audio`.88038804 - `"input_audio"`88058806 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`88078808 A list of inputs, each of which may be either an input text, output text, input8809 image, or input audio object.88108811 - `TextInput = string`88128813 A text input to the model.88148815 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`88168817 A text input to the model.88188819 - `OutputText object { text, type }`88208821 A text output from the model.88228823 - `text: string`88248825 The text output from the model.88268827 - `type: "output_text"`88288829 The type of the output text. Always `output_text`.88308831 - `"output_text"`88328833 - `InputImage object { image_url, type, detail }`88348835 An image input block used within EvalItem content arrays.88368837 - `image_url: string`88388839 The URL of the image input.88408841 - `type: "input_image"`88428843 The type of the image input. Always `input_image`.88448845 - `"input_image"`88468847 - `detail: optional string`88488849 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.88508851 - `ResponseInputAudio object { input_audio, type }`88528853 An audio input to the model.88548855 - `role: "user" or "assistant" or "system" or "developer"`88568857 The role of the message input. One of `user`, `assistant`, `system`, or8858 `developer`.88598860 - `"user"`88618862 - `"assistant"`88638864 - `"system"`88658866 - `"developer"`88678868 - `type: optional "message"`88698870 The type of the message input. Always `message`.88718872 - `"message"`88738874 - `type: "template"`88758876 The type of input messages. Always `template`.88778878 - `"template"`88798880 - `ItemReferenceInputMessages object { item_reference, type }`88818882 - `item_reference: string`88838884 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"88858886 - `type: "item_reference"`88878888 The type of input messages. Always `item_reference`.88898890 - `"item_reference"`88918892 - `model: optional string`88938894 The name of the model to use for generating completions (e.g. "o3-mini").88958896 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`88978898 - `max_completion_tokens: optional number`88998900 The maximum number of tokens in the generated output.89018902 - `reasoning_effort: optional ReasoningEffort or null`89038904 Constrains effort on reasoning for reasoning models. Currently supported8905 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.8906 Reducing reasoning effort can result in faster responses and fewer tokens8907 used on reasoning in a response. Not all reasoning models support every8908 value. See the8909 [reasoning guide](/api/docs/guides/reasoning)8910 for model-specific support.89118912 - `"none"`89138914 - `"minimal"`89158916 - `"low"`89178918 - `"medium"`89198920 - `"high"`89218922 - `"xhigh"`89238924 - `"max"`89258926 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`89278928 An object specifying the format that the model must output.89298930 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables8931 Structured Outputs which ensures the model will match your supplied JSON8932 schema. Learn more in the [Structured Outputs8933 guide](/api/docs/guides/structured-outputs).89348935 Setting to `{ "type": "json_object" }` enables the older JSON mode, which8936 ensures the message the model generates is valid JSON. Using `json_schema`8937 is preferred for models that support it.89388939 - `ResponseFormatText object { type }`89408941 Default response format. Used to generate text responses.89428943 - `type: "text"`89448945 The type of response format being defined. Always `text`.89468947 - `"text"`89488949 - `ResponseFormatJSONSchema object { json_schema, type }`89508951 JSON Schema response format. Used to generate structured JSON responses.8952 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).89538954 - `json_schema: object { name, description, schema, strict }`89558956 Structured Outputs configuration options, including a JSON Schema.89578958 - `name: string`89598960 The name of the response format. Must be a-z, A-Z, 0-9, or contain8961 underscores and dashes, with a maximum length of 64.89628963 - `description: optional string`89648965 A description of what the response format is for, used by the model to8966 determine how to respond in the format.89678968 - `schema: optional map[unknown]`89698970 The schema for the response format, described as a JSON Schema object.8971 Learn how to build JSON schemas [here](https://json-schema.org/).89728973 - `strict: optional boolean or null`89748975 Whether to enable strict schema adherence when generating the output.8976 If set to true, the model will always follow the exact schema defined8977 in the `schema` field. Only a subset of JSON Schema is supported when8978 `strict` is `true`. To learn more, read the [Structured Outputs8979 guide](/api/docs/guides/structured-outputs).89808981 - `type: "json_schema"`89828983 The type of response format being defined. Always `json_schema`.89848985 - `"json_schema"`89868987 - `ResponseFormatJSONObject object { type }`89888989 JSON object response format. An older method of generating JSON responses.8990 Using `json_schema` is recommended for models that support it. Note that the8991 model will not generate JSON without a system or user message instructing it8992 to do so.89938994 - `type: "json_object"`89958996 The type of response format being defined. Always `json_object`.89978998 - `"json_object"`89999000 - `seed: optional number`90019002 A seed value to initialize the randomness, during sampling.90039004 - `temperature: optional number`90059006 A higher temperature increases randomness in the outputs.90079008 - `tools: optional array of ChatCompletionFunctionTool`90099010 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.90119012 - `function: FunctionDefinition`90139014 - `name: string`90159016 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.90179018 - `description: optional string`90199020 A description of what the function does, used by the model to choose when and how to call the function.90219022 - `parameters: optional FunctionParameters`90239024 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.90259026 Omitting `parameters` defines a function with an empty parameter list.90279028 - `strict: optional boolean or null`90299030 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).90319032 - `type: "function"`90339034 The type of the tool. Currently, only `function` is supported.90359036 - `"function"`90379038 - `top_p: optional number`90399040 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.90419042 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`90439044 A ResponsesRunDataSource object describing a model sampling configuration.90459046 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`90479048 Determines what populates the `item` namespace in this run's data source.90499050 - `EvalJSONLFileContentSource object { content, type }`90519052 - `content: array of object { item, sample }`90539054 The content of the jsonl file.90559056 - `item: map[unknown]`90579058 - `sample: optional map[unknown]`90599060 - `type: "file_content"`90619062 The type of jsonl source. Always `file_content`.90639064 - `"file_content"`90659066 - `EvalJSONLFileIDSource object { id, type }`90679068 - `id: string`90699070 The identifier of the file.90719072 - `type: "file_id"`90739074 The type of jsonl source. Always `file_id`.90759076 - `"file_id"`90779078 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`90799080 A EvalResponsesSource object describing a run data source configuration.90819082 - `type: "responses"`90839084 The type of run data source. Always `responses`.90859086 - `"responses"`90879088 - `created_after: optional number or null`90899090 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.90919092 - `created_before: optional number or null`90939094 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.90959096 - `instructions_search: optional string or null`90979098 Optional string to search the 'instructions' field. This is a query parameter used to select responses.90999100 - `metadata: optional unknown or null`91019102 Metadata filter for the responses. This is a query parameter used to select responses.91039104 - `model: optional string or null`91059106 The name of the model to find responses for. This is a query parameter used to select responses.91079108 - `reasoning_effort: optional ReasoningEffort or null`91099110 Constrains effort on reasoning for reasoning models. Currently supported9111 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.9112 Reducing reasoning effort can result in faster responses and fewer tokens9113 used on reasoning in a response. Not all reasoning models support every9114 value. See the9115 [reasoning guide](/api/docs/guides/reasoning)9116 for model-specific support.91179118 - `temperature: optional number or null`91199120 Sampling temperature. This is a query parameter used to select responses.91219122 - `tools: optional array of string or null`91239124 List of tool names. This is a query parameter used to select responses.91259126 - `top_p: optional number or null`91279128 Nucleus sampling parameter. This is a query parameter used to select responses.91299130 - `users: optional array of string or null`91319132 List of user identifiers. This is a query parameter used to select responses.91339134 - `type: "responses"`91359136 The type of run data source. Always `responses`.91379138 - `"responses"`91399140 - `input_messages: optional object { template, type } or object { item_reference, type }`91419142 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.91439144 - `InputMessagesTemplate object { template, type }`91459146 - `template: array of object { content, role } or object { content, role, type }`91479148 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.91499150 - `ChatMessage object { content, role }`91519152 - `content: string`91539154 The content of the message.91559156 - `role: string`91579158 The role of the message (e.g. "system", "assistant", "user").91599160 - `EvalMessageObject object { content, role, type }`91619162 A message input to the model with a role indicating instruction following9163 hierarchy. Instructions given with the `developer` or `system` role take9164 precedence over instructions given with the `user` role. Messages with the9165 `assistant` role are presumed to have been generated by the model in previous9166 interactions.91679168 - `content: string or ResponseInputText or object { text, type } or 3 more`91699170 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.91719172 - `TextInput = string`91739174 A text input to the model.91759176 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`91779178 A text input to the model.91799180 - `OutputText object { text, type }`91819182 A text output from the model.91839184 - `text: string`91859186 The text output from the model.91879188 - `type: "output_text"`91899190 The type of the output text. Always `output_text`.91919192 - `"output_text"`91939194 - `InputImage object { image_url, type, detail }`91959196 An image input block used within EvalItem content arrays.91979198 - `image_url: string`91999200 The URL of the image input.92019202 - `type: "input_image"`92039204 The type of the image input. Always `input_image`.92059206 - `"input_image"`92079208 - `detail: optional string`92099210 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.92119212 - `ResponseInputAudio object { input_audio, type }`92139214 An audio input to the model.92159216 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`92179218 A list of inputs, each of which may be either an input text, output text, input9219 image, or input audio object.92209221 - `role: "user" or "assistant" or "system" or "developer"`92229223 The role of the message input. One of `user`, `assistant`, `system`, or9224 `developer`.92259226 - `"user"`92279228 - `"assistant"`92299230 - `"system"`92319232 - `"developer"`92339234 - `type: optional "message"`92359236 The type of the message input. Always `message`.92379238 - `"message"`92399240 - `type: "template"`92419242 The type of input messages. Always `template`.92439244 - `"template"`92459246 - `InputMessagesItemReference object { item_reference, type }`92479248 - `item_reference: string`92499250 A reference to a variable in the `item` namespace. Ie, "item.name"92519252 - `type: "item_reference"`92539254 The type of input messages. Always `item_reference`.92559256 - `"item_reference"`92579258 - `model: optional string`92599260 The name of the model to use for generating completions (e.g. "o3-mini").92619262 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`92639264 - `max_completion_tokens: optional number`92659266 The maximum number of tokens in the generated output.92679268 - `reasoning_effort: optional ReasoningEffort or null`92699270 Constrains effort on reasoning for reasoning models. Currently supported9271 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.9272 Reducing reasoning effort can result in faster responses and fewer tokens9273 used on reasoning in a response. Not all reasoning models support every9274 value. See the9275 [reasoning guide](/api/docs/guides/reasoning)9276 for model-specific support.92779278 - `seed: optional number`92799280 A seed value to initialize the randomness, during sampling.92819282 - `temperature: optional number`92839284 A higher temperature increases randomness in the outputs.92859286 - `text: optional object { format }`92879288 Configuration options for a text response from the model. Can be plain9289 text or structured JSON data. Learn more:92909291 - [Text inputs and outputs](/api/docs/guides/text)9292 - [Structured Outputs](/api/docs/guides/structured-outputs)92939294 - `format: optional ResponseFormatTextConfig`92959296 An object specifying the format that the model must output.92979298 Configuring `{ "type": "json_schema" }` enables Structured Outputs,9299 which ensures the model will match your supplied JSON schema. Learn more in the9300 [Structured Outputs guide](/api/docs/guides/structured-outputs).93019302 The default format is `{ "type": "text" }` with no additional options.93039304 **Not recommended for gpt-4o and newer models:**93059306 Setting to `{ "type": "json_object" }` enables the older JSON mode, which9307 ensures the message the model generates is valid JSON. Using `json_schema`9308 is preferred for models that support it.93099310 - `ResponseFormatText object { type }`93119312 Default response format. Used to generate text responses.93139314 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`93159316 JSON Schema response format. Used to generate structured JSON responses.9317 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).93189319 - `name: string`93209321 The name of the response format. Must be a-z, A-Z, 0-9, or contain9322 underscores and dashes, with a maximum length of 64.93239324 - `schema: map[unknown]`93259326 The schema for the response format, described as a JSON Schema object.9327 Learn how to build JSON schemas [here](https://json-schema.org/).93289329 - `type: "json_schema"`93309331 The type of response format being defined. Always `json_schema`.93329333 - `"json_schema"`93349335 - `description: optional string`93369337 A description of what the response format is for, used by the model to9338 determine how to respond in the format.93399340 - `strict: optional boolean or null`93419342 Whether to enable strict schema adherence when generating the output.9343 If set to true, the model will always follow the exact schema defined9344 in the `schema` field. Only a subset of JSON Schema is supported when9345 `strict` is `true`. To learn more, read the [Structured Outputs9346 guide](/api/docs/guides/structured-outputs).93479348 - `ResponseFormatJSONObject object { type }`93499350 JSON object response format. An older method of generating JSON responses.9351 Using `json_schema` is recommended for models that support it. Note that the9352 model will not generate JSON without a system or user message instructing it9353 to do so.93549355 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`93569357 An array of tools the model may call while generating a response. You9358 can specify which tool to use by setting the `tool_choice` parameter.93599360 The two categories of tools you can provide the model are:93619362 - **Built-in tools**: Tools that are provided by OpenAI that extend the9363 model's capabilities, like [web search](/api/docs/guides/tools-web-search)9364 or [file search](/api/docs/guides/tools-file-search). Learn more about9365 [built-in tools](/api/docs/guides/tools).9366 - **Function calls (custom tools)**: Functions that are defined by you,9367 enabling the model to call your own code. Learn more about9368 [function calling](/api/docs/guides/function-calling).93699370 - `Function object { name, parameters, strict, 6 more }`93719372 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).93739374 - `name: string`93759376 The name of the function to call.93779378 - `parameters: map[unknown] or null`93799380 A JSON schema object describing the parameters of the function.93819382 - `strict: boolean or null`93839384 Whether strict parameter validation is enforced for this function tool.93859386 - `type: "function"`93879388 The type of the function tool. Always `function`.93899390 - `"function"`93919392 - `allowed_callers: optional array of "direct" or "programmatic" or null`93939394 The tool invocation context(s).93959396 - `"direct"`93979398 - `"programmatic"`93999400 - `async: optional boolean`94019402 - `defer_loading: optional boolean`94039404 Whether this function is deferred and loaded via tool search.94059406 - `description: optional string or null`94079408 A description of the function. Used by the model to determine whether or not to call the function.94099410 - `output_schema: optional map[unknown] or null`94119412 A JSON schema object describing the JSON value encoded in string outputs for this function.94139414 - `FileSearch object { type, vector_store_ids, filters, 2 more }`94159416 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).94179418 - `type: "file_search"`94199420 The type of the file search tool. Always `file_search`.94219422 - `"file_search"`94239424 - `vector_store_ids: array of string`94259426 The IDs of the vector stores to search.94279428 - `filters: optional ComparisonFilter or CompoundFilter or null`94299430 A filter to apply.94319432 - `ComparisonFilter object { key, type, value }`94339434 A filter used to compare a specified attribute key to a given value using a defined comparison operation.94359436 - `key: string`94379438 The key to compare against the value.94399440 - `type: "eq" or "ne" or "gt" or 5 more`94419442 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.94439444 - `eq`: equals9445 - `ne`: not equal9446 - `gt`: greater than9447 - `gte`: greater than or equal9448 - `lt`: less than9449 - `lte`: less than or equal9450 - `in`: in9451 - `nin`: not in94529453 - `"eq"`94549455 - `"ne"`94569457 - `"gt"`94589459 - `"gte"`94609461 - `"lt"`94629463 - `"lte"`94649465 - `"in"`94669467 - `"nin"`94689469 - `value: string or number or boolean or array of string or number`94709471 The value to compare against the attribute key; supports string, number, or boolean types.94729473 - `string`94749475 - `number`94769477 - `boolean`94789479 - `array of string or number`94809481 - `string`94829483 - `number`94849485 - `CompoundFilter object { filters, type }`94869487 Combine multiple filters using `and` or `or`.94889489 - `filters: array of ComparisonFilter or unknown`94909491 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.94929493 - `ComparisonFilter object { key, type, value }`94949495 A filter used to compare a specified attribute key to a given value using a defined comparison operation.94969497 - `unknown`94989499 - `type: "and" or "or"`95009501 Type of operation: `and` or `or`.95029503 - `"and"`95049505 - `"or"`95069507 - `max_num_results: optional number`95089509 The maximum number of results to return. This number should be between 1 and 50 inclusive.95109511 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`95129513 Ranking options for search.95149515 - `hybrid_search: optional object { embedding_weight, text_weight }`95169517 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.95189519 - `embedding_weight: number`95209521 The weight of the embedding in the reciprocal ranking fusion.95229523 - `text_weight: number`95249525 The weight of the text in the reciprocal ranking fusion.95269527 - `ranker: optional "auto" or "default-2024-11-15"`95289529 The ranker to use for the file search.95309531 - `"auto"`95329533 - `"default-2024-11-15"`95349535 - `score_threshold: optional number`95369537 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.95389539 - `Computer object { type }`95409541 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).95429543 - `type: "computer"`95449545 The type of the computer tool. Always `computer`.95469547 - `"computer"`95489549 - `ComputerUsePreview object { display_height, display_width, environment, type }`95509551 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).95529553 - `display_height: number`95549555 The height of the computer display.95569557 - `display_width: number`95589559 The width of the computer display.95609561 - `environment: "windows" or "mac" or "linux" or 2 more`95629563 The type of computer environment to control.95649565 - `"windows"`95669567 - `"mac"`95689569 - `"linux"`95709571 - `"ubuntu"`95729573 - `"browser"`95749575 - `type: "computer_use_preview"`95769577 The type of the computer use tool. Always `computer_use_preview`.95789579 - `"computer_use_preview"`95809581 - `WebSearch object { type, external_web_access, filters, 2 more }`95829583 Search the Internet for sources related to the prompt. Learn more about the9584 [web search tool](/api/docs/guides/tools-web-search).95859586 - `type: "web_search" or "web_search_2025_08_26"`95879588 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.95899590 - `"web_search"`95919592 - `"web_search_2025_08_26"`95939594 - `external_web_access: optional boolean`95959596 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.95979598 - `filters: optional object { allowed_domains } or null`95999600 Filters for the search.96019602 - `allowed_domains: optional array of string or null`96039604 Allowed domains for the search. If not provided, all domains are allowed.9605 Subdomains of the provided domains are allowed as well.96069607 Example: `["pubmed.ncbi.nlm.nih.gov"]`96089609 - `search_context_size: optional "low" or "medium" or "high"`96109611 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.96129613 - `"low"`96149615 - `"medium"`96169617 - `"high"`96189619 - `user_location: optional object { city, country, region, 2 more } or null`96209621 The approximate location of the user.96229623 - `city: optional string or null`96249625 Free text input for the city of the user, e.g. `San Francisco`.96269627 - `country: optional string or null`96289629 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.96309631 - `region: optional string or null`96329633 Free text input for the region of the user, e.g. `California`.96349635 - `timezone: optional string or null`96369637 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.96389639 - `type: optional "approximate"`96409641 The type of location approximation. Always `approximate`.96429643 - `"approximate"`96449645 - `Mcp object { server_label, type, allowed_callers, 9 more }`96469647 Give the model access to additional tools via remote Model Context Protocol9648 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).96499650 - `server_label: string`96519652 A label for this MCP server, used to identify it in tool calls.96539654 - `type: "mcp"`96559656 The type of the MCP tool. Always `mcp`.96579658 - `"mcp"`96599660 - `allowed_callers: optional array of "direct" or "programmatic" or null`96619662 The tool invocation context(s).96639664 - `"direct"`96659666 - `"programmatic"`96679668 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`96699670 List of allowed tool names or a filter object.96719672 - `McpAllowedTools = array of string`96739674 A string array of allowed tool names96759676 - `McpToolFilter object { read_only, tool_names }`96779678 A filter object to specify which tools are allowed.96799680 - `read_only: optional boolean`96819682 Indicates whether or not a tool modifies data or is read-only. If an9683 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),9684 it will match this filter.96859686 - `tool_names: optional array of string`96879688 List of allowed tool names.96899690 - `authorization: optional string`96919692 An OAuth access token that can be used with a remote MCP server, either9693 with a custom MCP server URL or a service connector. Your application9694 must handle the OAuth authorization flow and provide the token here.96959696 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`96979698 Identifier for service connectors, like those available in ChatGPT. One of9699 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more9700 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).97019702 This field is deprecated for models released after September 1, 2026.9703 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to9704 connect through a Secure MCP Tunnel.97059706 Currently supported `connector_id` values are:97079708 - Dropbox: `connector_dropbox`9709 - Gmail: `connector_gmail`9710 - Google Calendar: `connector_googlecalendar`9711 - Google Drive: `connector_googledrive`9712 - Microsoft Teams: `connector_microsoftteams`9713 - Outlook Calendar: `connector_outlookcalendar`9714 - Outlook Email: `connector_outlookemail`9715 - SharePoint: `connector_sharepoint`97169717 - `"connector_dropbox"`97189719 - `"connector_gmail"`97209721 - `"connector_googlecalendar"`97229723 - `"connector_googledrive"`97249725 - `"connector_microsoftteams"`97269727 - `"connector_outlookcalendar"`97289729 - `"connector_outlookemail"`97309731 - `"connector_sharepoint"`97329733 - `defer_loading: optional boolean`97349735 Whether this MCP tool is deferred and discovered via tool search.97369737 - `headers: optional map[string] or null`97389739 Optional HTTP headers to send to the MCP server. Use for authentication9740 or other purposes.97419742 - `require_approval: optional object { always, never } or "always" or "never" or null`97439744 Specify which of the MCP server's tools require approval.97459746 - `McpToolApprovalFilter object { always, never }`97479748 Specify which of the MCP server's tools require approval. Can be9749 `always`, `never`, or a filter object associated with tools9750 that require approval.97519752 - `always: optional object { read_only, tool_names }`97539754 A filter object to specify which tools are allowed.97559756 - `read_only: optional boolean`97579758 Indicates whether or not a tool modifies data or is read-only. If an9759 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),9760 it will match this filter.97619762 - `tool_names: optional array of string`97639764 List of allowed tool names.97659766 - `never: optional object { read_only, tool_names }`97679768 A filter object to specify which tools are allowed.97699770 - `read_only: optional boolean`97719772 Indicates whether or not a tool modifies data or is read-only. If an9773 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),9774 it will match this filter.97759776 - `tool_names: optional array of string`97779778 List of allowed tool names.97799780 - `McpToolApprovalSetting = "always" or "never"`97819782 Specify a single approval policy for all tools. One of `always` or9783 `never`. When set to `always`, all tools will require approval. When9784 set to `never`, all tools will not require approval.97859786 - `"always"`97879788 - `"never"`97899790 - `server_description: optional string`97919792 Optional description of the MCP server, used to provide more context.97939794 - `server_url: optional string`97959796 The URL for the MCP server. One of `server_url`, `connector_id`, or9797 `tunnel_id` must be provided.97989799 - `tunnel_id: optional string`98009801 The Secure MCP Tunnel ID to use instead of a direct server URL. One of9802 `server_url`, `connector_id`, or `tunnel_id` must be provided.98039804 - `CodeInterpreter object { container, type, allowed_callers }`98059806 A tool that runs Python code to help generate a response to a prompt.98079808 - `container: string or object { type, file_ids, memory_limit, network_policy }`98099810 The code interpreter container. Can be a container ID or an object that9811 specifies uploaded file IDs to make available to your code, along with an9812 optional `memory_limit` setting.98139814 - `string`98159816 The container ID.98179818 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`98199820 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.98219822 - `type: "auto"`98239824 Always `auto`.98259826 - `"auto"`98279828 - `file_ids: optional array of string`98299830 An optional list of uploaded files to make available to your code.98319832 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`98339834 The memory limit for the code interpreter container.98359836 - `"1g"`98379838 - `"4g"`98399840 - `"16g"`98419842 - `"64g"`98439844 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`98459846 Network access policy for the container.98479848 - `ContainerNetworkPolicyDisabled object { type }`98499850 - `type: "disabled"`98519852 Disable outbound network access. Always `disabled`.98539854 - `"disabled"`98559856 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`98579858 - `allowed_domains: array of string`98599860 A list of allowed domains when type is `allowlist`.98619862 - `type: "allowlist"`98639864 Allow outbound network access only to specified domains. Always `allowlist`.98659866 - `"allowlist"`98679868 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`98699870 Optional domain-scoped secrets for allowlisted domains.98719872 - `domain: string`98739874 The domain associated with the secret.98759876 - `name: string`98779878 The name of the secret to inject for the domain.98799880 - `value: string`98819882 The secret value to inject for the domain.98839884 - `type: "code_interpreter"`98859886 The type of the code interpreter tool. Always `code_interpreter`.98879888 - `"code_interpreter"`98899890 - `allowed_callers: optional array of "direct" or "programmatic" or null`98919892 The tool invocation context(s).98939894 - `"direct"`98959896 - `"programmatic"`98979898 - `ProgrammaticToolCalling object { type }`98999900 - `type: "programmatic_tool_calling"`99019902 The type of the tool. Always `programmatic_tool_calling`.99039904 - `"programmatic_tool_calling"`99059906 - `ImageGeneration object { type, action, background, 9 more }`99079908 A tool that generates images using the GPT image models.99099910 - `type: "image_generation"`99119912 The type of the image generation tool. Always `image_generation`.99139914 - `"image_generation"`99159916 - `action: optional "generate" or "edit" or "auto"`99179918 Whether to generate a new image or edit an existing image. Default: `auto`.99199920 - `"generate"`99219922 - `"edit"`99239924 - `"auto"`99259926 - `background: optional "transparent" or "opaque" or "auto"`99279928 Set the background of the generated image. One of `transparent`, `opaque`,9929 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including9930 their `2026-09-08` snapshots, support `opaque` and `transparent`9931 backgrounds. Transparent backgrounds are available for supported GPT Image9932 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in9933 preview. When using `transparent`, set the output format to `png` or `webp`.9934 Default: `auto`.99359936 - `"transparent"`99379938 - `"opaque"`99399940 - `"auto"`99419942 - `input_fidelity: optional "high" or "low" or null`99439944 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.99459946 - `"high"`99479948 - `"low"`99499950 - `input_image_mask: optional object { file_id, image_url }`99519952 Optional mask for inpainting. Contains `image_url`9953 (string, optional) and `file_id` (string, optional).99549955 - `file_id: optional string`99569957 File ID for the mask image.99589959 - `image_url: optional string`99609961 Base64-encoded mask image.99629963 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`99649965 The image generation model to use. One of `gpt-image-1`,9966 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,9967 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,9968 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,9969 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:9970 `gpt-image-1`.99719972 - `string`99739974 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`99759976 The image generation model to use. One of `gpt-image-1`,9977 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,9978 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,9979 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,9980 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:9981 `gpt-image-1`.99829983 - `"gpt-image-1"`99849985 - `"gpt-image-1-mini"`99869987 - `"gpt-image-1.5"`99889989 - `"gpt-image-2"`99909991 - `"gpt-image-2-2026-04-21"`99929993 - `"gpt-image-2.5-sunburst"`99949995 - `"gpt-image-2.5-sunburst-2026-09-08"`99969997 - `"gpt-image-2.5-flare"`99989999 - `"gpt-image-2.5-flare-2026-09-08"`1000010001 - `moderation: optional "auto" or "low"`1000210003 Moderation level for the generated image. Default: `auto`.1000410005 - `"auto"`1000610007 - `"low"`1000810009 - `output_compression: optional number`1001010011 Compression level for the output image. Default: 100.1001210013 - `output_format: optional "png" or "webp" or "jpeg"`1001410015 The output format of the generated image. One of `png`, `webp`, or10016 `jpeg`. Default: `png`.1001710018 - `"png"`1001910020 - `"webp"`1002110022 - `"jpeg"`1002310024 - `partial_images: optional number`1002510026 Number of partial images to generate in streaming mode, from 0 (default value) to 3.1002710028 - `quality: optional "low" or "medium" or "high" or 3 more`1002910030 The quality of the generated image. The GPT image models support `low`,10031 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,10032 including their `2026-09-08` snapshots, also support `xhigh` and `max`.10033 Default: `auto`.1003410035 - `"low"`1003610037 - `"medium"`1003810039 - `"high"`1004010041 - `"xhigh"`1004210043 - `"max"`1004410045 - `"auto"`1004610047 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`1004810049 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.1005010051 - `string`1005210053 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`1005410055 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.1005610057 - `"1024x1024"`1005810059 - `"1024x1536"`1006010061 - `"1536x1024"`1006210063 - `"auto"`1006410065 - `LocalShell object { type }`1006610067 A tool that allows the model to execute shell commands in a local environment.1006810069 - `type: "local_shell"`1007010071 The type of the local shell tool. Always `local_shell`.1007210073 - `"local_shell"`1007410075 - `Shell object { type, allowed_callers, environment }`1007610077 A tool that allows the model to execute shell commands.1007810079 - `type: "shell"`1008010081 The type of the shell tool. Always `shell`.1008210083 - `"shell"`1008410085 - `allowed_callers: optional array of "direct" or "programmatic" or null`1008610087 The tool invocation context(s).1008810089 - `"direct"`1009010091 - `"programmatic"`1009210093 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`1009410095 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`1009610097 - `type: "container_auto"`1009810099 Automatically creates a container for this request1010010101 - `"container_auto"`1010210103 - `file_ids: optional array of string`1010410105 An optional list of uploaded files to make available to your code.1010610107 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`1010810109 The memory limit for the container.1011010111 - `"1g"`1011210113 - `"4g"`1011410115 - `"16g"`1011610117 - `"64g"`1011810119 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`1012010121 Network access policy for the container.1012210123 - `ContainerNetworkPolicyDisabled object { type }`1012410125 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`1012610127 - `skills: optional array of SkillReference or InlineSkill`1012810129 An optional list of skills referenced by id or inline data.1013010131 - `SkillReference object { skill_id, type, version }`1013210133 - `skill_id: string`1013410135 The ID of the referenced skill.1013610137 - `type: "skill_reference"`1013810139 References a skill created with the /v1/skills endpoint.1014010141 - `"skill_reference"`1014210143 - `version: optional string`1014410145 Optional skill version. Use a positive integer or 'latest'. Omit for default.1014610147 - `InlineSkill object { description, name, source, type }`1014810149 - `description: string`1015010151 The description of the skill.1015210153 - `name: string`1015410155 The name of the skill.1015610157 - `source: InlineSkillSource`1015810159 Inline skill payload1016010161 - `data: string`1016210163 Base64-encoded skill zip bundle.1016410165 - `media_type: "application/zip"`1016610167 The media type of the inline skill payload. Must be `application/zip`.1016810169 - `"application/zip"`1017010171 - `type: "base64"`1017210173 The type of the inline skill source. Must be `base64`.1017410175 - `"base64"`1017610177 - `type: "inline"`1017810179 Defines an inline skill for this request.1018010181 - `"inline"`1018210183 - `LocalEnvironment object { type, skills }`1018410185 - `type: "local"`1018610187 Use a local computer environment.1018810189 - `"local"`1019010191 - `skills: optional array of LocalSkill`1019210193 An optional list of skills.1019410195 - `description: string`1019610197 The description of the skill.1019810199 - `name: string`1020010201 The name of the skill.1020210203 - `path: string`1020410205 The path to the directory containing the skill.1020610207 - `ContainerReference object { container_id, type }`1020810209 - `container_id: string`1021010211 The ID of the referenced container.1021210213 - `type: "container_reference"`1021410215 References a container created with the /v1/containers endpoint1021610217 - `"container_reference"`1021810219 - `Custom object { name, type, allowed_callers, 4 more }`1022010221 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)1022210223 - `name: string`1022410225 The name of the custom tool, used to identify it in tool calls.1022610227 - `type: "custom"`1022810229 The type of the custom tool. Always `custom`.1023010231 - `"custom"`1023210233 - `allowed_callers: optional array of "direct" or "programmatic" or null`1023410235 The tool invocation context(s).1023610237 - `"direct"`1023810239 - `"programmatic"`1024010241 - `async: optional boolean`1024210243 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1024410245 - `defer_loading: optional boolean`1024610247 Whether this tool should be deferred and discovered via tool search.1024810249 - `description: optional string`1025010251 Optional description of the custom tool, used to provide more context.1025210253 - `format: optional CustomToolInputFormat`1025410255 The input format for the custom tool. Default is unconstrained text.1025610257 - `Text object { type }`1025810259 Unconstrained free-form text.1026010261 - `type: "text"`1026210263 Unconstrained text format. Always `text`.1026410265 - `"text"`1026610267 - `Grammar object { definition, syntax, type }`1026810269 A grammar defined by the user.1027010271 - `definition: string`1027210273 The grammar definition.1027410275 - `syntax: "lark" or "regex"`1027610277 The syntax of the grammar definition. One of `lark` or `regex`.1027810279 - `"lark"`1028010281 - `"regex"`1028210283 - `type: "grammar"`1028410285 Grammar format. Always `grammar`.1028610287 - `"grammar"`1028810289 - `Namespace object { description, name, tools, type }`1029010291 Groups function/custom tools under a shared namespace.1029210293 - `description: string`1029410295 A description of the namespace shown to the model.1029610297 - `name: string`1029810299 The namespace name used in tool calls (for example, `crm`).1030010301 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`1030210303 The function/custom tools available inside this namespace.1030410305 - `Function object { name, type, allowed_callers, 6 more }`1030610307 - `name: string`1030810309 - `type: "function"`1031010311 - `"function"`1031210313 - `allowed_callers: optional array of "direct" or "programmatic" or null`1031410315 The tool invocation context(s).1031610317 - `"direct"`1031810319 - `"programmatic"`1032010321 - `async: optional boolean`1032210323 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1032410325 - `defer_loading: optional boolean`1032610327 Whether this function should be deferred and discovered via tool search.1032810329 - `description: optional string or null`1033010331 - `output_schema: optional map[unknown] or null`1033210333 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.1033410335 - `parameters: optional unknown or null`1033610337 - `strict: optional boolean or null`1033810339 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.1034010341 - `Custom object { name, type, allowed_callers, 4 more }`1034210343 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)1034410345 - `name: string`1034610347 The name of the custom tool, used to identify it in tool calls.1034810349 - `type: "custom"`1035010351 The type of the custom tool. Always `custom`.1035210353 - `"custom"`1035410355 - `allowed_callers: optional array of "direct" or "programmatic" or null`1035610357 The tool invocation context(s).1035810359 - `"direct"`1036010361 - `"programmatic"`1036210363 - `async: optional boolean`1036410365 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1036610367 - `defer_loading: optional boolean`1036810369 Whether this tool should be deferred and discovered via tool search.1037010371 - `description: optional string`1037210373 Optional description of the custom tool, used to provide more context.1037410375 - `format: optional CustomToolInputFormat`1037610377 The input format for the custom tool. Default is unconstrained text.1037810379 - `type: "namespace"`1038010381 The type of the tool. Always `namespace`.1038210383 - `"namespace"`1038410385 - `ToolSearch object { type, description, execution, parameters }`1038610387 Hosted or BYOT tool search configuration for deferred tools.1038810389 - `type: "tool_search"`1039010391 The type of the tool. Always `tool_search`.1039210393 - `"tool_search"`1039410395 - `description: optional string or null`1039610397 Description shown to the model for a client-executed tool search tool.1039810399 - `execution: optional "server" or "client"`1040010401 Whether tool search is executed by the server or by the client.1040210403 - `"server"`1040410405 - `"client"`1040610407 - `parameters: optional unknown or null`1040810409 Parameter schema for a client-executed tool search tool.1041010411 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`1041210413 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).1041410415 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`1041610417 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.1041810419 - `"web_search_preview"`1042010421 - `"web_search_preview_2025_03_11"`1042210423 - `search_content_types: optional array of "text" or "image"`1042410425 - `"text"`1042610427 - `"image"`1042810429 - `search_context_size: optional "low" or "medium" or "high"`1043010431 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.1043210433 - `"low"`1043410435 - `"medium"`1043610437 - `"high"`1043810439 - `user_location: optional object { type, city, country, 2 more } or null`1044010441 The user's location.1044210443 - `type: "approximate"`1044410445 The type of location approximation. Always `approximate`.1044610447 - `"approximate"`1044810449 - `city: optional string or null`1045010451 Free text input for the city of the user, e.g. `San Francisco`.1045210453 - `country: optional string or null`1045410455 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.1045610457 - `region: optional string or null`1045810459 Free text input for the region of the user, e.g. `California`.1046010461 - `timezone: optional string or null`1046210463 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.1046410465 - `ApplyPatch object { type, allowed_callers }`1046610467 Allows the assistant to create, delete, or update files using unified diffs.1046810469 - `type: "apply_patch"`1047010471 The type of the tool. Always `apply_patch`.1047210473 - `"apply_patch"`1047410475 - `allowed_callers: optional array of "direct" or "programmatic" or null`1047610477 The tool invocation context(s).1047810479 - `"direct"`1048010481 - `"programmatic"`1048210483 - `top_p: optional number`1048410485 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1048610487- `error: EvalAPIError`1048810489 An object representing an error response from the Eval API.1049010491 - `code: string`1049210493 The error code.1049410495 - `message: string`1049610497 The error message.1049810499- `eval_id: string`1050010501 The identifier of the associated evaluation.1050210503- `metadata: Metadata or null`1050410505 Set of 16 key-value pairs that can be attached to an object. This can be10506 useful for storing additional information about the object in a structured10507 format, and querying for objects via API or the dashboard.1050810509 Keys are strings with a maximum length of 64 characters. Values are strings10510 with a maximum length of 512 characters.1051110512- `model: string`1051310514 The model that is evaluated, if applicable.1051510516- `name: string`1051710518 The name of the evaluation run.1051910520- `object: "eval.run"`1052110522 The type of the object. Always "eval.run".1052310524 - `"eval.run"`1052510526- `per_model_usage: array of object { cached_tokens, completion_tokens, invocation_count, 3 more }`1052710528 Usage statistics for each model during the evaluation run.1052910530 - `cached_tokens: number`1053110532 The number of tokens retrieved from cache.1053310534 - `completion_tokens: number`1053510536 The number of completion tokens generated.1053710538 - `invocation_count: number`1053910540 The number of invocations.1054110542 - `model_name: string`1054310544 The name of the model.1054510546 - `prompt_tokens: number`1054710548 The number of prompt tokens used.1054910550 - `total_tokens: number`1055110552 The total number of tokens used.1055310554- `per_testing_criteria_results: array of object { failed, passed, testing_criteria }`1055510556 Results per testing criteria applied during the evaluation run.1055710558 - `failed: number`1055910560 Number of tests failed for this criteria.1056110562 - `passed: number`1056310564 Number of tests passed for this criteria.1056510566 - `testing_criteria: string`1056710568 A description of the testing criteria.1056910570- `report_url: string`1057110572 The URL to the rendered evaluation run report on the UI dashboard.1057310574- `result_counts: object { errored, failed, passed, total }`1057510576 Counters summarizing the outcomes of the evaluation run.1057710578 - `errored: number`1057910580 Number of output items that resulted in an error.1058110582 - `failed: number`1058310584 Number of output items that failed to pass the evaluation.1058510586 - `passed: number`1058710588 Number of output items that passed the evaluation.1058910590 - `total: number`1059110592 Total number of executed output items.1059310594- `status: string`1059510596 The status of the evaluation run.1059710598### Example1059910600```http10601curl https://api.openai.com/v1/evals/$EVAL_ID/runs \10602 -H 'Content-Type: application/json' \10603 -H "Authorization: Bearer $OPENAI_API_KEY" \10604 -d '{10605 "data_source": {10606 "source": {10607 "content": [10608 {10609 "item": {10610 "foo": "bar"10611 }10612 }10613 ],10614 "type": "file_content"10615 },10616 "type": "jsonl"10617 }10618 }'10619```1062010621#### Response1062210623```json10624{10625 "id": "id",10626 "created_at": 0,10627 "data_source": {10628 "source": {10629 "content": [10630 {10631 "item": {10632 "foo": "bar"10633 },10634 "sample": {10635 "foo": "bar"10636 }10637 }10638 ],10639 "type": "file_content"10640 },10641 "type": "jsonl"10642 },10643 "error": {10644 "code": "code",10645 "message": "message"10646 },10647 "eval_id": "eval_id",10648 "metadata": {10649 "foo": "string"10650 },10651 "model": "model",10652 "name": "name",10653 "object": "eval.run",10654 "per_model_usage": [10655 {10656 "cached_tokens": 0,10657 "completion_tokens": 0,10658 "invocation_count": 0,10659 "model_name": "model_name",10660 "prompt_tokens": 0,10661 "total_tokens": 010662 }10663 ],10664 "per_testing_criteria_results": [10665 {10666 "failed": 0,10667 "passed": 0,10668 "testing_criteria": "testing_criteria"10669 }10670 ],10671 "report_url": "https://example.com",10672 "result_counts": {10673 "errored": 0,10674 "failed": 0,10675 "passed": 0,10676 "total": 010677 },10678 "status": "status"10679}10680```1068110682### Example1068310684```http10685curl https://api.openai.com/v1/evals/eval_67e579652b548190aaa83ada4b125f47/runs \10686 -X POST \10687 -H "Authorization: Bearer $OPENAI_API_KEY" \10688 -H "Content-Type: application/json" \10689 -d '{"name":"gpt-6-astra","data_source":{"type":"completions","input_messages":{"type":"template","template":[{"role":"developer","content":"Categorize a given news headline into one of the following topics: Technology, Markets, World, Business, or Sports.\n\n# Steps\n\n1. Analyze the content of the news headline to understand its primary focus.\n2. Extract the subject matter, identifying any key indicators or keywords.\n3. Use the identified indicators to determine the most suitable category out of the five options: Technology, Markets, World, Business, or Sports.\n4. Ensure only one category is selected per headline.\n\n# Output Format\n\nRespond with the chosen category as a single word. For instance: \"Technology\", \"Markets\", \"World\", \"Business\", or \"Sports\".\n\n# Examples\n\n**Input**: \"Apple Unveils New iPhone Model, Featuring Advanced AI Features\" \n**Output**: \"Technology\"\n\n**Input**: \"Global Stocks Mixed as Investors Await Central Bank Decisions\" \n**Output**: \"Markets\"\n\n**Input**: \"War in Ukraine: Latest Updates on Negotiation Status\" \n**Output**: \"World\"\n\n**Input**: \"Microsoft in Talks to Acquire Gaming Company for $2 Billion\" \n**Output**: \"Business\"\n\n**Input**: \"Manchester United Secures Win in Premier League Football Match\" \n**Output**: \"Sports\" \n\n# Notes\n\n- If the headline appears to fit into more than one category, choose the most dominant theme.\n- Keywords or phrases such as \"stocks\", \"company acquisition\", \"match\", or technological brands can be good indicators for classification.\n"} , {"role":"user","content":"{{item.input}}"}]} ,"sampling_params":{"max_completions_tokens":2048},"model":"gpt-6-astra","source":{"type":"file_content","content":[{"item":{"input":"Tech Company Launches Advanced Artificial Intelligence Platform","ground_truth":"Technology"}}]}}}'10690```1069110692#### Response1069310694```json10695{10696 "object": "eval.run",10697 "id": "evalrun_67e57965b480819094274e3a32235e4c",10698 "eval_id": "eval_67e579652b548190aaa83ada4b125f47",10699 "report_url": "https://platform.openai.com/evaluations/eval_67e579652b548190aaa83ada4b125f47&run_id=evalrun_67e57965b480819094274e3a32235e4c",10700 "status": "queued",10701 "model": "gpt-6-astra",10702 "name": "gpt-6-astra",10703 "created_at": 1743092069,10704 "result_counts": {10705 "total": 0,10706 "errored": 0,10707 "failed": 0,10708 "passed": 010709 },10710 "per_model_usage": null,10711 "per_testing_criteria_results": null,10712 "data_source": {10713 "type": "completions",10714 "source": {10715 "type": "file_content",10716 "content": [10717 {10718 "item": {10719 "input": "Tech Company Launches Advanced Artificial Intelligence Platform",10720 "ground_truth": "Technology"10721 }10722 }10723 ]10724 },10725 "input_messages": {10726 "type": "template",10727 "template": [10728 {10729 "type": "message",10730 "role": "developer",10731 "content": {10732 "type": "input_text",10733 "text": "Categorize a given news headline into one of the following topics: Technology, Markets, World, Business, or Sports.\n\n# Steps\n\n1. Analyze the content of the news headline to understand its primary focus.\n2. Extract the subject matter, identifying any key indicators or keywords.\n3. Use the identified indicators to determine the most suitable category out of the five options: Technology, Markets, World, Business, or Sports.\n4. Ensure only one category is selected per headline.\n\n# Output Format\n\nRespond with the chosen category as a single word. For instance: \"Technology\", \"Markets\", \"World\", \"Business\", or \"Sports\".\n\n# Examples\n\n**Input**: \"Apple Unveils New iPhone Model, Featuring Advanced AI Features\" \n**Output**: \"Technology\"\n\n**Input**: \"Global Stocks Mixed as Investors Await Central Bank Decisions\" \n**Output**: \"Markets\"\n\n**Input**: \"War in Ukraine: Latest Updates on Negotiation Status\" \n**Output**: \"World\"\n\n**Input**: \"Microsoft in Talks to Acquire Gaming Company for $2 Billion\" \n**Output**: \"Business\"\n\n**Input**: \"Manchester United Secures Win in Premier League Football Match\" \n**Output**: \"Sports\" \n\n# Notes\n\n- If the headline appears to fit into more than one category, choose the most dominant theme.\n- Keywords or phrases such as \"stocks\", \"company acquisition\", \"match\", or technological brands can be good indicators for classification.\n"10734 }10735 },10736 {10737 "type": "message",10738 "role": "user",10739 "content": {10740 "type": "input_text",10741 "text": "{{item.input}}"10742 }10743 }10744 ]10745 },10746 "model": "gpt-6-astra",10747 "sampling_params": {10748 "max_completions_tokens": 204810749 }10750 },10751 "error": null,10752 "metadata": {}10753}10754```1075510756## Delete eval run1075710758**delete** `/evals/{eval_id}/runs/{run_id}`1075910760Delete an eval run.1076110762### Path Parameters1076310764- `eval_id: string`1076510766- `run_id: string`1076710768### Returns1076910770- `deleted: optional boolean`1077110772- `object: optional string`1077310774- `run_id: optional string`1077510776### Example1077710778```http10779curl https://api.openai.com/v1/evals/$EVAL_ID/runs/$RUN_ID \10780 -X DELETE \10781 -H "Authorization: Bearer $OPENAI_API_KEY"10782```1078310784#### Response1078510786```json10787{10788 "deleted": true,10789 "object": "eval.run.deleted",10790 "run_id": "evalrun_677469f564d48190807532a852da3afb"10791}10792```1079310794### Example1079510796```http10797curl https://api.openai.com/v1/evals/eval_123abc/runs/evalrun_abc456 \10798 -X DELETE \10799 -H "Authorization: Bearer $OPENAI_API_KEY" \10800 -H "Content-Type: application/json"10801```1080210803#### Response1080410805```json10806{10807 "object": "eval.run.deleted",10808 "deleted": true,10809 "run_id": "evalrun_abc456"10810}10811```1081210813## Get eval runs1081410815**get** `/evals/{eval_id}/runs`1081610817Get a list of runs for an evaluation.1081810819### Path Parameters1082010821- `eval_id: string`1082210823### Query Parameters1082410825- `after: optional string`1082610827 Identifier for the last run from the previous pagination request.1082810829- `limit: optional number`1083010831 Number of runs to retrieve.1083210833- `order: optional "asc" or "desc"`1083410835 Sort order for runs by timestamp. Use `asc` for ascending order or `desc` for descending order. Defaults to `asc`.1083610837 - `"asc"`1083810839 - `"desc"`1084010841- `status: optional "queued" or "in_progress" or "completed" or 2 more`1084210843 Filter runs by status. One of `queued` | `in_progress` | `failed` | `completed` | `canceled`.1084410845 - `"queued"`1084610847 - `"in_progress"`1084810849 - `"completed"`1085010851 - `"canceled"`1085210853 - `"failed"`1085410855### Returns1085610857- `data: array of object { id, created_at, data_source, 11 more }`1085810859 An array of eval run objects.1086010861 - `id: string`1086210863 Unique identifier for the evaluation run.1086410865 - `created_at: number`1086610867 Unix timestamp (in seconds) when the evaluation run was created.1086810869 - `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`1087010871 Information about the run's data source.1087210873 - `CreateEvalJSONLRunDataSource object { source, type }`1087410875 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval1087610877 - `source: object { content, type } or object { id, type }`1087810879 Determines what populates the `item` namespace in the data source.1088010881 - `EvalJSONLFileContentSource object { content, type }`1088210883 - `content: array of object { item, sample }`1088410885 The content of the jsonl file.1088610887 - `item: map[unknown]`1088810889 - `sample: optional map[unknown]`1089010891 - `type: "file_content"`1089210893 The type of jsonl source. Always `file_content`.1089410895 - `"file_content"`1089610897 - `EvalJSONLFileIDSource object { id, type }`1089810899 - `id: string`1090010901 The identifier of the file.1090210903 - `type: "file_id"`1090410905 The type of jsonl source. Always `file_id`.1090610907 - `"file_id"`1090810909 - `type: "jsonl"`1091010911 The type of data source. Always `jsonl`.1091210913 - `"jsonl"`1091410915 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`1091610917 A CompletionsRunDataSource object describing a model sampling configuration.1091810919 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`1092010921 Determines what populates the `item` namespace in this run's data source.1092210923 - `EvalJSONLFileContentSource object { content, type }`1092410925 - `content: array of object { item, sample }`1092610927 The content of the jsonl file.1092810929 - `item: map[unknown]`1093010931 - `sample: optional map[unknown]`1093210933 - `type: "file_content"`1093410935 The type of jsonl source. Always `file_content`.1093610937 - `"file_content"`1093810939 - `EvalJSONLFileIDSource object { id, type }`1094010941 - `id: string`1094210943 The identifier of the file.1094410945 - `type: "file_id"`1094610947 The type of jsonl source. Always `file_id`.1094810949 - `"file_id"`1095010951 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`1095210953 A StoredCompletionsRunDataSource configuration describing a set of filters1095410955 - `type: "stored_completions"`1095610957 The type of source. Always `stored_completions`.1095810959 - `"stored_completions"`1096010961 - `created_after: optional number or null`1096210963 An optional Unix timestamp to filter items created after this time.1096410965 - `created_before: optional number or null`1096610967 An optional Unix timestamp to filter items created before this time.1096810969 - `limit: optional number or null`1097010971 An optional maximum number of items to return.1097210973 - `metadata: optional Metadata or null`1097410975 Set of 16 key-value pairs that can be attached to an object. This can be10976 useful for storing additional information about the object in a structured10977 format, and querying for objects via API or the dashboard.1097810979 Keys are strings with a maximum length of 64 characters. Values are strings10980 with a maximum length of 512 characters.1098110982 - `model: optional string or null`1098310984 An optional model to filter by (e.g., 'gpt-6-astra').1098510986 - `type: "completions"`1098710988 The type of run data source. Always `completions`.1098910990 - `"completions"`1099110992 - `input_messages: optional object { template, type } or object { item_reference, type }`1099310994 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1099510996 - `TemplateInputMessages object { template, type }`1099710998 - `template: array of EasyInputMessage or object { content, role, type }`1099911000 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1100111002 - `EasyInputMessage object { content, role, phase, type }`1100311004 A message input to the model with a role indicating instruction following11005 hierarchy. Instructions given with the `developer` or `system` role take11006 precedence over instructions given with the `user` role. Messages with the11007 `assistant` role are presumed to have been generated by the model in previous11008 interactions.1100911010 - `content: string or ResponseInputMessageContentList`1101111012 Text, image, or audio input to the model, used to generate a response.11013 Can also contain previous assistant responses.1101411015 - `TextInput = string`1101611017 A text input to the model.1101811019 - `ResponseInputMessageContentList = array of ResponseInputContent`1102011021 A list of one or many input items to the model, containing different content11022 types.1102311024 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1102511026 A text input to the model.1102711028 - `text: string`1102911030 The text input to the model.1103111032 - `type: "input_text"`1103311034 The type of the input item. Always `input_text`.1103511036 - `"input_text"`1103711038 - `prompt_cache_breakpoint: optional object { mode }`1103911040 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1104111042 - `mode: "explicit"`1104311044 The breakpoint mode. Always `explicit`.1104511046 - `"explicit"`1104711048 - `ResponseInputImage object { detail, type, file_id, 2 more }`1104911050 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).1105111052 - `detail: ImageDetail`1105311054 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.1105511056 - `"low"`1105711058 - `"high"`1105911060 - `"auto"`1106111062 - `"original"`1106311064 - `type: "input_image"`1106511066 The type of the input item. Always `input_image`.1106711068 - `"input_image"`1106911070 - `file_id: optional string or null`1107111072 The ID of the file to be sent to the model.1107311074 - `image_url: optional string or null`1107511076 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.1107711078 - `prompt_cache_breakpoint: optional object { mode }`1107911080 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1108111082 - `mode: "explicit"`1108311084 The breakpoint mode. Always `explicit`.1108511086 - `"explicit"`1108711088 - `ResponseInputFile object { type, detail, file_data, 4 more }`1108911090 A file input to the model.1109111092 - `type: "input_file"`1109311094 The type of the input item. Always `input_file`.1109511096 - `"input_file"`1109711098 - `detail: optional "auto" or "low" or "high"`1109911100 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.1110111102 - `"auto"`1110311104 - `"low"`1110511106 - `"high"`1110711108 - `file_data: optional string`1110911110 The content of the file to be sent to the model.1111111112 - `file_id: optional string or null`1111311114 The ID of the file to be sent to the model.1111511116 - `file_url: optional string`1111711118 The URL of the file to be sent to the model.1111911120 - `filename: optional string`1112111122 The name of the file to be sent to the model.1112311124 - `prompt_cache_breakpoint: optional object { mode }`1112511126 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1112711128 - `mode: "explicit"`1112911130 The breakpoint mode. Always `explicit`.1113111132 - `"explicit"`1113311134 - `role: "user" or "assistant" or "system" or "developer"`1113511136 The role of the message input. One of `user`, `assistant`, `system`, or11137 `developer`.1113811139 - `"user"`1114011141 - `"assistant"`1114211143 - `"system"`1114411145 - `"developer"`1114611147 - `phase: optional "commentary" or "final_answer" or null`1114811149 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).11150 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend11151 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.1115211153 - `"commentary"`1115411155 - `"final_answer"`1115611157 - `type: optional "message"`1115811159 The type of the message input. Always `message`.1116011161 - `"message"`1116211163 - `EvalMessageObject object { content, role, type }`1116411165 A message input to the model with a role indicating instruction following11166 hierarchy. Instructions given with the `developer` or `system` role take11167 precedence over instructions given with the `user` role. Messages with the11168 `assistant` role are presumed to have been generated by the model in previous11169 interactions.1117011171 - `content: string or ResponseInputText or object { text, type } or 3 more`1117211173 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1117411175 - `TextInput = string`1117611177 A text input to the model.1117811179 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1118011181 A text input to the model.1118211183 - `OutputText object { text, type }`1118411185 A text output from the model.1118611187 - `text: string`1118811189 The text output from the model.1119011191 - `type: "output_text"`1119211193 The type of the output text. Always `output_text`.1119411195 - `"output_text"`1119611197 - `InputImage object { image_url, type, detail }`1119811199 An image input block used within EvalItem content arrays.1120011201 - `image_url: string`1120211203 The URL of the image input.1120411205 - `type: "input_image"`1120611207 The type of the image input. Always `input_image`.1120811209 - `"input_image"`1121011211 - `detail: optional string`1121211213 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1121411215 - `ResponseInputAudio object { input_audio, type }`1121611217 An audio input to the model.1121811219 - `input_audio: object { data, format }`1122011221 - `data: string`1122211223 Base64-encoded audio data.1122411225 - `format: "mp3" or "wav"`1122611227 The format of the audio data. Currently supported formats are `mp3` and11228 `wav`.1122911230 - `"mp3"`1123111232 - `"wav"`1123311234 - `type: "input_audio"`1123511236 The type of the input item. Always `input_audio`.1123711238 - `"input_audio"`1123911240 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1124111242 A list of inputs, each of which may be either an input text, output text, input11243 image, or input audio object.1124411245 - `TextInput = string`1124611247 A text input to the model.1124811249 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1125011251 A text input to the model.1125211253 - `OutputText object { text, type }`1125411255 A text output from the model.1125611257 - `text: string`1125811259 The text output from the model.1126011261 - `type: "output_text"`1126211263 The type of the output text. Always `output_text`.1126411265 - `"output_text"`1126611267 - `InputImage object { image_url, type, detail }`1126811269 An image input block used within EvalItem content arrays.1127011271 - `image_url: string`1127211273 The URL of the image input.1127411275 - `type: "input_image"`1127611277 The type of the image input. Always `input_image`.1127811279 - `"input_image"`1128011281 - `detail: optional string`1128211283 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1128411285 - `ResponseInputAudio object { input_audio, type }`1128611287 An audio input to the model.1128811289 - `role: "user" or "assistant" or "system" or "developer"`1129011291 The role of the message input. One of `user`, `assistant`, `system`, or11292 `developer`.1129311294 - `"user"`1129511296 - `"assistant"`1129711298 - `"system"`1129911300 - `"developer"`1130111302 - `type: optional "message"`1130311304 The type of the message input. Always `message`.1130511306 - `"message"`1130711308 - `type: "template"`1130911310 The type of input messages. Always `template`.1131111312 - `"template"`1131311314 - `ItemReferenceInputMessages object { item_reference, type }`1131511316 - `item_reference: string`1131711318 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"1131911320 - `type: "item_reference"`1132111322 The type of input messages. Always `item_reference`.1132311324 - `"item_reference"`1132511326 - `model: optional string`1132711328 The name of the model to use for generating completions (e.g. "o3-mini").1132911330 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`1133111332 - `max_completion_tokens: optional number`1133311334 The maximum number of tokens in the generated output.1133511336 - `reasoning_effort: optional ReasoningEffort or null`1133711338 Constrains effort on reasoning for reasoning models. Currently supported11339 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.11340 Reducing reasoning effort can result in faster responses and fewer tokens11341 used on reasoning in a response. Not all reasoning models support every11342 value. See the11343 [reasoning guide](/api/docs/guides/reasoning)11344 for model-specific support.1134511346 - `"none"`1134711348 - `"minimal"`1134911350 - `"low"`1135111352 - `"medium"`1135311354 - `"high"`1135511356 - `"xhigh"`1135711358 - `"max"`1135911360 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`1136111362 An object specifying the format that the model must output.1136311364 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables11365 Structured Outputs which ensures the model will match your supplied JSON11366 schema. Learn more in the [Structured Outputs11367 guide](/api/docs/guides/structured-outputs).1136811369 Setting to `{ "type": "json_object" }` enables the older JSON mode, which11370 ensures the message the model generates is valid JSON. Using `json_schema`11371 is preferred for models that support it.1137211373 - `ResponseFormatText object { type }`1137411375 Default response format. Used to generate text responses.1137611377 - `type: "text"`1137811379 The type of response format being defined. Always `text`.1138011381 - `"text"`1138211383 - `ResponseFormatJSONSchema object { json_schema, type }`1138411385 JSON Schema response format. Used to generate structured JSON responses.11386 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1138711388 - `json_schema: object { name, description, schema, strict }`1138911390 Structured Outputs configuration options, including a JSON Schema.1139111392 - `name: string`1139311394 The name of the response format. Must be a-z, A-Z, 0-9, or contain11395 underscores and dashes, with a maximum length of 64.1139611397 - `description: optional string`1139811399 A description of what the response format is for, used by the model to11400 determine how to respond in the format.1140111402 - `schema: optional map[unknown]`1140311404 The schema for the response format, described as a JSON Schema object.11405 Learn how to build JSON schemas [here](https://json-schema.org/).1140611407 - `strict: optional boolean or null`1140811409 Whether to enable strict schema adherence when generating the output.11410 If set to true, the model will always follow the exact schema defined11411 in the `schema` field. Only a subset of JSON Schema is supported when11412 `strict` is `true`. To learn more, read the [Structured Outputs11413 guide](/api/docs/guides/structured-outputs).1141411415 - `type: "json_schema"`1141611417 The type of response format being defined. Always `json_schema`.1141811419 - `"json_schema"`1142011421 - `ResponseFormatJSONObject object { type }`1142211423 JSON object response format. An older method of generating JSON responses.11424 Using `json_schema` is recommended for models that support it. Note that the11425 model will not generate JSON without a system or user message instructing it11426 to do so.1142711428 - `type: "json_object"`1142911430 The type of response format being defined. Always `json_object`.1143111432 - `"json_object"`1143311434 - `seed: optional number`1143511436 A seed value to initialize the randomness, during sampling.1143711438 - `temperature: optional number`1143911440 A higher temperature increases randomness in the outputs.1144111442 - `tools: optional array of ChatCompletionFunctionTool`1144311444 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.1144511446 - `function: FunctionDefinition`1144711448 - `name: string`1144911450 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.1145111452 - `description: optional string`1145311454 A description of what the function does, used by the model to choose when and how to call the function.1145511456 - `parameters: optional FunctionParameters`1145711458 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.1145911460 Omitting `parameters` defines a function with an empty parameter list.1146111462 - `strict: optional boolean or null`1146311464 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).1146511466 - `type: "function"`1146711468 The type of the tool. Currently, only `function` is supported.1146911470 - `"function"`1147111472 - `top_p: optional number`1147311474 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1147511476 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`1147711478 A ResponsesRunDataSource object describing a model sampling configuration.1147911480 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`1148111482 Determines what populates the `item` namespace in this run's data source.1148311484 - `EvalJSONLFileContentSource object { content, type }`1148511486 - `content: array of object { item, sample }`1148711488 The content of the jsonl file.1148911490 - `item: map[unknown]`1149111492 - `sample: optional map[unknown]`1149311494 - `type: "file_content"`1149511496 The type of jsonl source. Always `file_content`.1149711498 - `"file_content"`1149911500 - `EvalJSONLFileIDSource object { id, type }`1150111502 - `id: string`1150311504 The identifier of the file.1150511506 - `type: "file_id"`1150711508 The type of jsonl source. Always `file_id`.1150911510 - `"file_id"`1151111512 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`1151311514 A EvalResponsesSource object describing a run data source configuration.1151511516 - `type: "responses"`1151711518 The type of run data source. Always `responses`.1151911520 - `"responses"`1152111522 - `created_after: optional number or null`1152311524 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.1152511526 - `created_before: optional number or null`1152711528 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.1152911530 - `instructions_search: optional string or null`1153111532 Optional string to search the 'instructions' field. This is a query parameter used to select responses.1153311534 - `metadata: optional unknown or null`1153511536 Metadata filter for the responses. This is a query parameter used to select responses.1153711538 - `model: optional string or null`1153911540 The name of the model to find responses for. This is a query parameter used to select responses.1154111542 - `reasoning_effort: optional ReasoningEffort or null`1154311544 Constrains effort on reasoning for reasoning models. Currently supported11545 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.11546 Reducing reasoning effort can result in faster responses and fewer tokens11547 used on reasoning in a response. Not all reasoning models support every11548 value. See the11549 [reasoning guide](/api/docs/guides/reasoning)11550 for model-specific support.1155111552 - `temperature: optional number or null`1155311554 Sampling temperature. This is a query parameter used to select responses.1155511556 - `tools: optional array of string or null`1155711558 List of tool names. This is a query parameter used to select responses.1155911560 - `top_p: optional number or null`1156111562 Nucleus sampling parameter. This is a query parameter used to select responses.1156311564 - `users: optional array of string or null`1156511566 List of user identifiers. This is a query parameter used to select responses.1156711568 - `type: "responses"`1156911570 The type of run data source. Always `responses`.1157111572 - `"responses"`1157311574 - `input_messages: optional object { template, type } or object { item_reference, type }`1157511576 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1157711578 - `InputMessagesTemplate object { template, type }`1157911580 - `template: array of object { content, role } or object { content, role, type }`1158111582 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1158311584 - `ChatMessage object { content, role }`1158511586 - `content: string`1158711588 The content of the message.1158911590 - `role: string`1159111592 The role of the message (e.g. "system", "assistant", "user").1159311594 - `EvalMessageObject object { content, role, type }`1159511596 A message input to the model with a role indicating instruction following11597 hierarchy. Instructions given with the `developer` or `system` role take11598 precedence over instructions given with the `user` role. Messages with the11599 `assistant` role are presumed to have been generated by the model in previous11600 interactions.1160111602 - `content: string or ResponseInputText or object { text, type } or 3 more`1160311604 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1160511606 - `TextInput = string`1160711608 A text input to the model.1160911610 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1161111612 A text input to the model.1161311614 - `OutputText object { text, type }`1161511616 A text output from the model.1161711618 - `text: string`1161911620 The text output from the model.1162111622 - `type: "output_text"`1162311624 The type of the output text. Always `output_text`.1162511626 - `"output_text"`1162711628 - `InputImage object { image_url, type, detail }`1162911630 An image input block used within EvalItem content arrays.1163111632 - `image_url: string`1163311634 The URL of the image input.1163511636 - `type: "input_image"`1163711638 The type of the image input. Always `input_image`.1163911640 - `"input_image"`1164111642 - `detail: optional string`1164311644 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1164511646 - `ResponseInputAudio object { input_audio, type }`1164711648 An audio input to the model.1164911650 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1165111652 A list of inputs, each of which may be either an input text, output text, input11653 image, or input audio object.1165411655 - `role: "user" or "assistant" or "system" or "developer"`1165611657 The role of the message input. One of `user`, `assistant`, `system`, or11658 `developer`.1165911660 - `"user"`1166111662 - `"assistant"`1166311664 - `"system"`1166511666 - `"developer"`1166711668 - `type: optional "message"`1166911670 The type of the message input. Always `message`.1167111672 - `"message"`1167311674 - `type: "template"`1167511676 The type of input messages. Always `template`.1167711678 - `"template"`1167911680 - `InputMessagesItemReference object { item_reference, type }`1168111682 - `item_reference: string`1168311684 A reference to a variable in the `item` namespace. Ie, "item.name"1168511686 - `type: "item_reference"`1168711688 The type of input messages. Always `item_reference`.1168911690 - `"item_reference"`1169111692 - `model: optional string`1169311694 The name of the model to use for generating completions (e.g. "o3-mini").1169511696 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`1169711698 - `max_completion_tokens: optional number`1169911700 The maximum number of tokens in the generated output.1170111702 - `reasoning_effort: optional ReasoningEffort or null`1170311704 Constrains effort on reasoning for reasoning models. Currently supported11705 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.11706 Reducing reasoning effort can result in faster responses and fewer tokens11707 used on reasoning in a response. Not all reasoning models support every11708 value. See the11709 [reasoning guide](/api/docs/guides/reasoning)11710 for model-specific support.1171111712 - `seed: optional number`1171311714 A seed value to initialize the randomness, during sampling.1171511716 - `temperature: optional number`1171711718 A higher temperature increases randomness in the outputs.1171911720 - `text: optional object { format }`1172111722 Configuration options for a text response from the model. Can be plain11723 text or structured JSON data. Learn more:1172411725 - [Text inputs and outputs](/api/docs/guides/text)11726 - [Structured Outputs](/api/docs/guides/structured-outputs)1172711728 - `format: optional ResponseFormatTextConfig`1172911730 An object specifying the format that the model must output.1173111732 Configuring `{ "type": "json_schema" }` enables Structured Outputs,11733 which ensures the model will match your supplied JSON schema. Learn more in the11734 [Structured Outputs guide](/api/docs/guides/structured-outputs).1173511736 The default format is `{ "type": "text" }` with no additional options.1173711738 **Not recommended for gpt-4o and newer models:**1173911740 Setting to `{ "type": "json_object" }` enables the older JSON mode, which11741 ensures the message the model generates is valid JSON. Using `json_schema`11742 is preferred for models that support it.1174311744 - `ResponseFormatText object { type }`1174511746 Default response format. Used to generate text responses.1174711748 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`1174911750 JSON Schema response format. Used to generate structured JSON responses.11751 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1175211753 - `name: string`1175411755 The name of the response format. Must be a-z, A-Z, 0-9, or contain11756 underscores and dashes, with a maximum length of 64.1175711758 - `schema: map[unknown]`1175911760 The schema for the response format, described as a JSON Schema object.11761 Learn how to build JSON schemas [here](https://json-schema.org/).1176211763 - `type: "json_schema"`1176411765 The type of response format being defined. Always `json_schema`.1176611767 - `"json_schema"`1176811769 - `description: optional string`1177011771 A description of what the response format is for, used by the model to11772 determine how to respond in the format.1177311774 - `strict: optional boolean or null`1177511776 Whether to enable strict schema adherence when generating the output.11777 If set to true, the model will always follow the exact schema defined11778 in the `schema` field. Only a subset of JSON Schema is supported when11779 `strict` is `true`. To learn more, read the [Structured Outputs11780 guide](/api/docs/guides/structured-outputs).1178111782 - `ResponseFormatJSONObject object { type }`1178311784 JSON object response format. An older method of generating JSON responses.11785 Using `json_schema` is recommended for models that support it. Note that the11786 model will not generate JSON without a system or user message instructing it11787 to do so.1178811789 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`1179011791 An array of tools the model may call while generating a response. You11792 can specify which tool to use by setting the `tool_choice` parameter.1179311794 The two categories of tools you can provide the model are:1179511796 - **Built-in tools**: Tools that are provided by OpenAI that extend the11797 model's capabilities, like [web search](/api/docs/guides/tools-web-search)11798 or [file search](/api/docs/guides/tools-file-search). Learn more about11799 [built-in tools](/api/docs/guides/tools).11800 - **Function calls (custom tools)**: Functions that are defined by you,11801 enabling the model to call your own code. Learn more about11802 [function calling](/api/docs/guides/function-calling).1180311804 - `Function object { name, parameters, strict, 6 more }`1180511806 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).1180711808 - `name: string`1180911810 The name of the function to call.1181111812 - `parameters: map[unknown] or null`1181311814 A JSON schema object describing the parameters of the function.1181511816 - `strict: boolean or null`1181711818 Whether strict parameter validation is enforced for this function tool.1181911820 - `type: "function"`1182111822 The type of the function tool. Always `function`.1182311824 - `"function"`1182511826 - `allowed_callers: optional array of "direct" or "programmatic" or null`1182711828 The tool invocation context(s).1182911830 - `"direct"`1183111832 - `"programmatic"`1183311834 - `async: optional boolean`1183511836 - `defer_loading: optional boolean`1183711838 Whether this function is deferred and loaded via tool search.1183911840 - `description: optional string or null`1184111842 A description of the function. Used by the model to determine whether or not to call the function.1184311844 - `output_schema: optional map[unknown] or null`1184511846 A JSON schema object describing the JSON value encoded in string outputs for this function.1184711848 - `FileSearch object { type, vector_store_ids, filters, 2 more }`1184911850 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).1185111852 - `type: "file_search"`1185311854 The type of the file search tool. Always `file_search`.1185511856 - `"file_search"`1185711858 - `vector_store_ids: array of string`1185911860 The IDs of the vector stores to search.1186111862 - `filters: optional ComparisonFilter or CompoundFilter or null`1186311864 A filter to apply.1186511866 - `ComparisonFilter object { key, type, value }`1186711868 A filter used to compare a specified attribute key to a given value using a defined comparison operation.1186911870 - `key: string`1187111872 The key to compare against the value.1187311874 - `type: "eq" or "ne" or "gt" or 5 more`1187511876 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.1187711878 - `eq`: equals11879 - `ne`: not equal11880 - `gt`: greater than11881 - `gte`: greater than or equal11882 - `lt`: less than11883 - `lte`: less than or equal11884 - `in`: in11885 - `nin`: not in1188611887 - `"eq"`1188811889 - `"ne"`1189011891 - `"gt"`1189211893 - `"gte"`1189411895 - `"lt"`1189611897 - `"lte"`1189811899 - `"in"`1190011901 - `"nin"`1190211903 - `value: string or number or boolean or array of string or number`1190411905 The value to compare against the attribute key; supports string, number, or boolean types.1190611907 - `string`1190811909 - `number`1191011911 - `boolean`1191211913 - `array of string or number`1191411915 - `string`1191611917 - `number`1191811919 - `CompoundFilter object { filters, type }`1192011921 Combine multiple filters using `and` or `or`.1192211923 - `filters: array of ComparisonFilter or unknown`1192411925 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.1192611927 - `ComparisonFilter object { key, type, value }`1192811929 A filter used to compare a specified attribute key to a given value using a defined comparison operation.1193011931 - `unknown`1193211933 - `type: "and" or "or"`1193411935 Type of operation: `and` or `or`.1193611937 - `"and"`1193811939 - `"or"`1194011941 - `max_num_results: optional number`1194211943 The maximum number of results to return. This number should be between 1 and 50 inclusive.1194411945 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`1194611947 Ranking options for search.1194811949 - `hybrid_search: optional object { embedding_weight, text_weight }`1195011951 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.1195211953 - `embedding_weight: number`1195411955 The weight of the embedding in the reciprocal ranking fusion.1195611957 - `text_weight: number`1195811959 The weight of the text in the reciprocal ranking fusion.1196011961 - `ranker: optional "auto" or "default-2024-11-15"`1196211963 The ranker to use for the file search.1196411965 - `"auto"`1196611967 - `"default-2024-11-15"`1196811969 - `score_threshold: optional number`1197011971 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.1197211973 - `Computer object { type }`1197411975 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).1197611977 - `type: "computer"`1197811979 The type of the computer tool. Always `computer`.1198011981 - `"computer"`1198211983 - `ComputerUsePreview object { display_height, display_width, environment, type }`1198411985 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).1198611987 - `display_height: number`1198811989 The height of the computer display.1199011991 - `display_width: number`1199211993 The width of the computer display.1199411995 - `environment: "windows" or "mac" or "linux" or 2 more`1199611997 The type of computer environment to control.1199811999 - `"windows"`1200012001 - `"mac"`1200212003 - `"linux"`1200412005 - `"ubuntu"`1200612007 - `"browser"`1200812009 - `type: "computer_use_preview"`1201012011 The type of the computer use tool. Always `computer_use_preview`.1201212013 - `"computer_use_preview"`1201412015 - `WebSearch object { type, external_web_access, filters, 2 more }`1201612017 Search the Internet for sources related to the prompt. Learn more about the12018 [web search tool](/api/docs/guides/tools-web-search).1201912020 - `type: "web_search" or "web_search_2025_08_26"`1202112022 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.1202312024 - `"web_search"`1202512026 - `"web_search_2025_08_26"`1202712028 - `external_web_access: optional boolean`1202912030 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.1203112032 - `filters: optional object { allowed_domains } or null`1203312034 Filters for the search.1203512036 - `allowed_domains: optional array of string or null`1203712038 Allowed domains for the search. If not provided, all domains are allowed.12039 Subdomains of the provided domains are allowed as well.1204012041 Example: `["pubmed.ncbi.nlm.nih.gov"]`1204212043 - `search_context_size: optional "low" or "medium" or "high"`1204412045 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.1204612047 - `"low"`1204812049 - `"medium"`1205012051 - `"high"`1205212053 - `user_location: optional object { city, country, region, 2 more } or null`1205412055 The approximate location of the user.1205612057 - `city: optional string or null`1205812059 Free text input for the city of the user, e.g. `San Francisco`.1206012061 - `country: optional string or null`1206212063 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.1206412065 - `region: optional string or null`1206612067 Free text input for the region of the user, e.g. `California`.1206812069 - `timezone: optional string or null`1207012071 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.1207212073 - `type: optional "approximate"`1207412075 The type of location approximation. Always `approximate`.1207612077 - `"approximate"`1207812079 - `Mcp object { server_label, type, allowed_callers, 9 more }`1208012081 Give the model access to additional tools via remote Model Context Protocol12082 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).1208312084 - `server_label: string`1208512086 A label for this MCP server, used to identify it in tool calls.1208712088 - `type: "mcp"`1208912090 The type of the MCP tool. Always `mcp`.1209112092 - `"mcp"`1209312094 - `allowed_callers: optional array of "direct" or "programmatic" or null`1209512096 The tool invocation context(s).1209712098 - `"direct"`1209912100 - `"programmatic"`1210112102 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`1210312104 List of allowed tool names or a filter object.1210512106 - `McpAllowedTools = array of string`1210712108 A string array of allowed tool names1210912110 - `McpToolFilter object { read_only, tool_names }`1211112112 A filter object to specify which tools are allowed.1211312114 - `read_only: optional boolean`1211512116 Indicates whether or not a tool modifies data or is read-only. If an12117 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),12118 it will match this filter.1211912120 - `tool_names: optional array of string`1212112122 List of allowed tool names.1212312124 - `authorization: optional string`1212512126 An OAuth access token that can be used with a remote MCP server, either12127 with a custom MCP server URL or a service connector. Your application12128 must handle the OAuth authorization flow and provide the token here.1212912130 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`1213112132 Identifier for service connectors, like those available in ChatGPT. One of12133 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more12134 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).1213512136 This field is deprecated for models released after September 1, 2026.12137 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to12138 connect through a Secure MCP Tunnel.1213912140 Currently supported `connector_id` values are:1214112142 - Dropbox: `connector_dropbox`12143 - Gmail: `connector_gmail`12144 - Google Calendar: `connector_googlecalendar`12145 - Google Drive: `connector_googledrive`12146 - Microsoft Teams: `connector_microsoftteams`12147 - Outlook Calendar: `connector_outlookcalendar`12148 - Outlook Email: `connector_outlookemail`12149 - SharePoint: `connector_sharepoint`1215012151 - `"connector_dropbox"`1215212153 - `"connector_gmail"`1215412155 - `"connector_googlecalendar"`1215612157 - `"connector_googledrive"`1215812159 - `"connector_microsoftteams"`1216012161 - `"connector_outlookcalendar"`1216212163 - `"connector_outlookemail"`1216412165 - `"connector_sharepoint"`1216612167 - `defer_loading: optional boolean`1216812169 Whether this MCP tool is deferred and discovered via tool search.1217012171 - `headers: optional map[string] or null`1217212173 Optional HTTP headers to send to the MCP server. Use for authentication12174 or other purposes.1217512176 - `require_approval: optional object { always, never } or "always" or "never" or null`1217712178 Specify which of the MCP server's tools require approval.1217912180 - `McpToolApprovalFilter object { always, never }`1218112182 Specify which of the MCP server's tools require approval. Can be12183 `always`, `never`, or a filter object associated with tools12184 that require approval.1218512186 - `always: optional object { read_only, tool_names }`1218712188 A filter object to specify which tools are allowed.1218912190 - `read_only: optional boolean`1219112192 Indicates whether or not a tool modifies data or is read-only. If an12193 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),12194 it will match this filter.1219512196 - `tool_names: optional array of string`1219712198 List of allowed tool names.1219912200 - `never: optional object { read_only, tool_names }`1220112202 A filter object to specify which tools are allowed.1220312204 - `read_only: optional boolean`1220512206 Indicates whether or not a tool modifies data or is read-only. If an12207 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),12208 it will match this filter.1220912210 - `tool_names: optional array of string`1221112212 List of allowed tool names.1221312214 - `McpToolApprovalSetting = "always" or "never"`1221512216 Specify a single approval policy for all tools. One of `always` or12217 `never`. When set to `always`, all tools will require approval. When12218 set to `never`, all tools will not require approval.1221912220 - `"always"`1222112222 - `"never"`1222312224 - `server_description: optional string`1222512226 Optional description of the MCP server, used to provide more context.1222712228 - `server_url: optional string`1222912230 The URL for the MCP server. One of `server_url`, `connector_id`, or12231 `tunnel_id` must be provided.1223212233 - `tunnel_id: optional string`1223412235 The Secure MCP Tunnel ID to use instead of a direct server URL. One of12236 `server_url`, `connector_id`, or `tunnel_id` must be provided.1223712238 - `CodeInterpreter object { container, type, allowed_callers }`1223912240 A tool that runs Python code to help generate a response to a prompt.1224112242 - `container: string or object { type, file_ids, memory_limit, network_policy }`1224312244 The code interpreter container. Can be a container ID or an object that12245 specifies uploaded file IDs to make available to your code, along with an12246 optional `memory_limit` setting.1224712248 - `string`1224912250 The container ID.1225112252 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`1225312254 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.1225512256 - `type: "auto"`1225712258 Always `auto`.1225912260 - `"auto"`1226112262 - `file_ids: optional array of string`1226312264 An optional list of uploaded files to make available to your code.1226512266 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`1226712268 The memory limit for the code interpreter container.1226912270 - `"1g"`1227112272 - `"4g"`1227312274 - `"16g"`1227512276 - `"64g"`1227712278 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`1227912280 Network access policy for the container.1228112282 - `ContainerNetworkPolicyDisabled object { type }`1228312284 - `type: "disabled"`1228512286 Disable outbound network access. Always `disabled`.1228712288 - `"disabled"`1228912290 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`1229112292 - `allowed_domains: array of string`1229312294 A list of allowed domains when type is `allowlist`.1229512296 - `type: "allowlist"`1229712298 Allow outbound network access only to specified domains. Always `allowlist`.1229912300 - `"allowlist"`1230112302 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`1230312304 Optional domain-scoped secrets for allowlisted domains.1230512306 - `domain: string`1230712308 The domain associated with the secret.1230912310 - `name: string`1231112312 The name of the secret to inject for the domain.1231312314 - `value: string`1231512316 The secret value to inject for the domain.1231712318 - `type: "code_interpreter"`1231912320 The type of the code interpreter tool. Always `code_interpreter`.1232112322 - `"code_interpreter"`1232312324 - `allowed_callers: optional array of "direct" or "programmatic" or null`1232512326 The tool invocation context(s).1232712328 - `"direct"`1232912330 - `"programmatic"`1233112332 - `ProgrammaticToolCalling object { type }`1233312334 - `type: "programmatic_tool_calling"`1233512336 The type of the tool. Always `programmatic_tool_calling`.1233712338 - `"programmatic_tool_calling"`1233912340 - `ImageGeneration object { type, action, background, 9 more }`1234112342 A tool that generates images using the GPT image models.1234312344 - `type: "image_generation"`1234512346 The type of the image generation tool. Always `image_generation`.1234712348 - `"image_generation"`1234912350 - `action: optional "generate" or "edit" or "auto"`1235112352 Whether to generate a new image or edit an existing image. Default: `auto`.1235312354 - `"generate"`1235512356 - `"edit"`1235712358 - `"auto"`1235912360 - `background: optional "transparent" or "opaque" or "auto"`1236112362 Set the background of the generated image. One of `transparent`, `opaque`,12363 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including12364 their `2026-09-08` snapshots, support `opaque` and `transparent`12365 backgrounds. Transparent backgrounds are available for supported GPT Image12366 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in12367 preview. When using `transparent`, set the output format to `png` or `webp`.12368 Default: `auto`.1236912370 - `"transparent"`1237112372 - `"opaque"`1237312374 - `"auto"`1237512376 - `input_fidelity: optional "high" or "low" or null`1237712378 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.1237912380 - `"high"`1238112382 - `"low"`1238312384 - `input_image_mask: optional object { file_id, image_url }`1238512386 Optional mask for inpainting. Contains `image_url`12387 (string, optional) and `file_id` (string, optional).1238812389 - `file_id: optional string`1239012391 File ID for the mask image.1239212393 - `image_url: optional string`1239412395 Base64-encoded mask image.1239612397 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`1239812399 The image generation model to use. One of `gpt-image-1`,12400 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,12401 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,12402 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,12403 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:12404 `gpt-image-1`.1240512406 - `string`1240712408 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`1240912410 The image generation model to use. One of `gpt-image-1`,12411 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,12412 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,12413 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,12414 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:12415 `gpt-image-1`.1241612417 - `"gpt-image-1"`1241812419 - `"gpt-image-1-mini"`1242012421 - `"gpt-image-1.5"`1242212423 - `"gpt-image-2"`1242412425 - `"gpt-image-2-2026-04-21"`1242612427 - `"gpt-image-2.5-sunburst"`1242812429 - `"gpt-image-2.5-sunburst-2026-09-08"`1243012431 - `"gpt-image-2.5-flare"`1243212433 - `"gpt-image-2.5-flare-2026-09-08"`1243412435 - `moderation: optional "auto" or "low"`1243612437 Moderation level for the generated image. Default: `auto`.1243812439 - `"auto"`1244012441 - `"low"`1244212443 - `output_compression: optional number`1244412445 Compression level for the output image. Default: 100.1244612447 - `output_format: optional "png" or "webp" or "jpeg"`1244812449 The output format of the generated image. One of `png`, `webp`, or12450 `jpeg`. Default: `png`.1245112452 - `"png"`1245312454 - `"webp"`1245512456 - `"jpeg"`1245712458 - `partial_images: optional number`1245912460 Number of partial images to generate in streaming mode, from 0 (default value) to 3.1246112462 - `quality: optional "low" or "medium" or "high" or 3 more`1246312464 The quality of the generated image. The GPT image models support `low`,12465 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,12466 including their `2026-09-08` snapshots, also support `xhigh` and `max`.12467 Default: `auto`.1246812469 - `"low"`1247012471 - `"medium"`1247212473 - `"high"`1247412475 - `"xhigh"`1247612477 - `"max"`1247812479 - `"auto"`1248012481 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`1248212483 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.1248412485 - `string`1248612487 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`1248812489 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.1249012491 - `"1024x1024"`1249212493 - `"1024x1536"`1249412495 - `"1536x1024"`1249612497 - `"auto"`1249812499 - `LocalShell object { type }`1250012501 A tool that allows the model to execute shell commands in a local environment.1250212503 - `type: "local_shell"`1250412505 The type of the local shell tool. Always `local_shell`.1250612507 - `"local_shell"`1250812509 - `Shell object { type, allowed_callers, environment }`1251012511 A tool that allows the model to execute shell commands.1251212513 - `type: "shell"`1251412515 The type of the shell tool. Always `shell`.1251612517 - `"shell"`1251812519 - `allowed_callers: optional array of "direct" or "programmatic" or null`1252012521 The tool invocation context(s).1252212523 - `"direct"`1252412525 - `"programmatic"`1252612527 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`1252812529 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`1253012531 - `type: "container_auto"`1253212533 Automatically creates a container for this request1253412535 - `"container_auto"`1253612537 - `file_ids: optional array of string`1253812539 An optional list of uploaded files to make available to your code.1254012541 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`1254212543 The memory limit for the container.1254412545 - `"1g"`1254612547 - `"4g"`1254812549 - `"16g"`1255012551 - `"64g"`1255212553 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`1255412555 Network access policy for the container.1255612557 - `ContainerNetworkPolicyDisabled object { type }`1255812559 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`1256012561 - `skills: optional array of SkillReference or InlineSkill`1256212563 An optional list of skills referenced by id or inline data.1256412565 - `SkillReference object { skill_id, type, version }`1256612567 - `skill_id: string`1256812569 The ID of the referenced skill.1257012571 - `type: "skill_reference"`1257212573 References a skill created with the /v1/skills endpoint.1257412575 - `"skill_reference"`1257612577 - `version: optional string`1257812579 Optional skill version. Use a positive integer or 'latest'. Omit for default.1258012581 - `InlineSkill object { description, name, source, type }`1258212583 - `description: string`1258412585 The description of the skill.1258612587 - `name: string`1258812589 The name of the skill.1259012591 - `source: InlineSkillSource`1259212593 Inline skill payload1259412595 - `data: string`1259612597 Base64-encoded skill zip bundle.1259812599 - `media_type: "application/zip"`1260012601 The media type of the inline skill payload. Must be `application/zip`.1260212603 - `"application/zip"`1260412605 - `type: "base64"`1260612607 The type of the inline skill source. Must be `base64`.1260812609 - `"base64"`1261012611 - `type: "inline"`1261212613 Defines an inline skill for this request.1261412615 - `"inline"`1261612617 - `LocalEnvironment object { type, skills }`1261812619 - `type: "local"`1262012621 Use a local computer environment.1262212623 - `"local"`1262412625 - `skills: optional array of LocalSkill`1262612627 An optional list of skills.1262812629 - `description: string`1263012631 The description of the skill.1263212633 - `name: string`1263412635 The name of the skill.1263612637 - `path: string`1263812639 The path to the directory containing the skill.1264012641 - `ContainerReference object { container_id, type }`1264212643 - `container_id: string`1264412645 The ID of the referenced container.1264612647 - `type: "container_reference"`1264812649 References a container created with the /v1/containers endpoint1265012651 - `"container_reference"`1265212653 - `Custom object { name, type, allowed_callers, 4 more }`1265412655 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)1265612657 - `name: string`1265812659 The name of the custom tool, used to identify it in tool calls.1266012661 - `type: "custom"`1266212663 The type of the custom tool. Always `custom`.1266412665 - `"custom"`1266612667 - `allowed_callers: optional array of "direct" or "programmatic" or null`1266812669 The tool invocation context(s).1267012671 - `"direct"`1267212673 - `"programmatic"`1267412675 - `async: optional boolean`1267612677 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1267812679 - `defer_loading: optional boolean`1268012681 Whether this tool should be deferred and discovered via tool search.1268212683 - `description: optional string`1268412685 Optional description of the custom tool, used to provide more context.1268612687 - `format: optional CustomToolInputFormat`1268812689 The input format for the custom tool. Default is unconstrained text.1269012691 - `Text object { type }`1269212693 Unconstrained free-form text.1269412695 - `type: "text"`1269612697 Unconstrained text format. Always `text`.1269812699 - `"text"`1270012701 - `Grammar object { definition, syntax, type }`1270212703 A grammar defined by the user.1270412705 - `definition: string`1270612707 The grammar definition.1270812709 - `syntax: "lark" or "regex"`1271012711 The syntax of the grammar definition. One of `lark` or `regex`.1271212713 - `"lark"`1271412715 - `"regex"`1271612717 - `type: "grammar"`1271812719 Grammar format. Always `grammar`.1272012721 - `"grammar"`1272212723 - `Namespace object { description, name, tools, type }`1272412725 Groups function/custom tools under a shared namespace.1272612727 - `description: string`1272812729 A description of the namespace shown to the model.1273012731 - `name: string`1273212733 The namespace name used in tool calls (for example, `crm`).1273412735 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`1273612737 The function/custom tools available inside this namespace.1273812739 - `Function object { name, type, allowed_callers, 6 more }`1274012741 - `name: string`1274212743 - `type: "function"`1274412745 - `"function"`1274612747 - `allowed_callers: optional array of "direct" or "programmatic" or null`1274812749 The tool invocation context(s).1275012751 - `"direct"`1275212753 - `"programmatic"`1275412755 - `async: optional boolean`1275612757 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1275812759 - `defer_loading: optional boolean`1276012761 Whether this function should be deferred and discovered via tool search.1276212763 - `description: optional string or null`1276412765 - `output_schema: optional map[unknown] or null`1276612767 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.1276812769 - `parameters: optional unknown or null`1277012771 - `strict: optional boolean or null`1277212773 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.1277412775 - `Custom object { name, type, allowed_callers, 4 more }`1277612777 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)1277812779 - `name: string`1278012781 The name of the custom tool, used to identify it in tool calls.1278212783 - `type: "custom"`1278412785 The type of the custom tool. Always `custom`.1278612787 - `"custom"`1278812789 - `allowed_callers: optional array of "direct" or "programmatic" or null`1279012791 The tool invocation context(s).1279212793 - `"direct"`1279412795 - `"programmatic"`1279612797 - `async: optional boolean`1279812799 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1280012801 - `defer_loading: optional boolean`1280212803 Whether this tool should be deferred and discovered via tool search.1280412805 - `description: optional string`1280612807 Optional description of the custom tool, used to provide more context.1280812809 - `format: optional CustomToolInputFormat`1281012811 The input format for the custom tool. Default is unconstrained text.1281212813 - `type: "namespace"`1281412815 The type of the tool. Always `namespace`.1281612817 - `"namespace"`1281812819 - `ToolSearch object { type, description, execution, parameters }`1282012821 Hosted or BYOT tool search configuration for deferred tools.1282212823 - `type: "tool_search"`1282412825 The type of the tool. Always `tool_search`.1282612827 - `"tool_search"`1282812829 - `description: optional string or null`1283012831 Description shown to the model for a client-executed tool search tool.1283212833 - `execution: optional "server" or "client"`1283412835 Whether tool search is executed by the server or by the client.1283612837 - `"server"`1283812839 - `"client"`1284012841 - `parameters: optional unknown or null`1284212843 Parameter schema for a client-executed tool search tool.1284412845 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`1284612847 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).1284812849 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`1285012851 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.1285212853 - `"web_search_preview"`1285412855 - `"web_search_preview_2025_03_11"`1285612857 - `search_content_types: optional array of "text" or "image"`1285812859 - `"text"`1286012861 - `"image"`1286212863 - `search_context_size: optional "low" or "medium" or "high"`1286412865 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.1286612867 - `"low"`1286812869 - `"medium"`1287012871 - `"high"`1287212873 - `user_location: optional object { type, city, country, 2 more } or null`1287412875 The user's location.1287612877 - `type: "approximate"`1287812879 The type of location approximation. Always `approximate`.1288012881 - `"approximate"`1288212883 - `city: optional string or null`1288412885 Free text input for the city of the user, e.g. `San Francisco`.1288612887 - `country: optional string or null`1288812889 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.1289012891 - `region: optional string or null`1289212893 Free text input for the region of the user, e.g. `California`.1289412895 - `timezone: optional string or null`1289612897 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.1289812899 - `ApplyPatch object { type, allowed_callers }`1290012901 Allows the assistant to create, delete, or update files using unified diffs.1290212903 - `type: "apply_patch"`1290412905 The type of the tool. Always `apply_patch`.1290612907 - `"apply_patch"`1290812909 - `allowed_callers: optional array of "direct" or "programmatic" or null`1291012911 The tool invocation context(s).1291212913 - `"direct"`1291412915 - `"programmatic"`1291612917 - `top_p: optional number`1291812919 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1292012921 - `error: EvalAPIError`1292212923 An object representing an error response from the Eval API.1292412925 - `code: string`1292612927 The error code.1292812929 - `message: string`1293012931 The error message.1293212933 - `eval_id: string`1293412935 The identifier of the associated evaluation.1293612937 - `metadata: Metadata or null`1293812939 Set of 16 key-value pairs that can be attached to an object. This can be12940 useful for storing additional information about the object in a structured12941 format, and querying for objects via API or the dashboard.1294212943 Keys are strings with a maximum length of 64 characters. Values are strings12944 with a maximum length of 512 characters.1294512946 - `model: string`1294712948 The model that is evaluated, if applicable.1294912950 - `name: string`1295112952 The name of the evaluation run.1295312954 - `object: "eval.run"`1295512956 The type of the object. Always "eval.run".1295712958 - `"eval.run"`1295912960 - `per_model_usage: array of object { cached_tokens, completion_tokens, invocation_count, 3 more }`1296112962 Usage statistics for each model during the evaluation run.1296312964 - `cached_tokens: number`1296512966 The number of tokens retrieved from cache.1296712968 - `completion_tokens: number`1296912970 The number of completion tokens generated.1297112972 - `invocation_count: number`1297312974 The number of invocations.1297512976 - `model_name: string`1297712978 The name of the model.1297912980 - `prompt_tokens: number`1298112982 The number of prompt tokens used.1298312984 - `total_tokens: number`1298512986 The total number of tokens used.1298712988 - `per_testing_criteria_results: array of object { failed, passed, testing_criteria }`1298912990 Results per testing criteria applied during the evaluation run.1299112992 - `failed: number`1299312994 Number of tests failed for this criteria.1299512996 - `passed: number`1299712998 Number of tests passed for this criteria.1299913000 - `testing_criteria: string`1300113002 A description of the testing criteria.1300313004 - `report_url: string`1300513006 The URL to the rendered evaluation run report on the UI dashboard.1300713008 - `result_counts: object { errored, failed, passed, total }`1300913010 Counters summarizing the outcomes of the evaluation run.1301113012 - `errored: number`1301313014 Number of output items that resulted in an error.1301513016 - `failed: number`1301713018 Number of output items that failed to pass the evaluation.1301913020 - `passed: number`1302113022 Number of output items that passed the evaluation.1302313024 - `total: number`1302513026 Total number of executed output items.1302713028 - `status: string`1302913030 The status of the evaluation run.1303113032- `first_id: string`1303313034 The identifier of the first eval run in the data array.1303513036- `has_more: boolean`1303713038 Indicates whether there are more evals available.1303913040- `last_id: string`1304113042 The identifier of the last eval run in the data array.1304313044- `object: "list"`1304513046 The type of this object. It is always set to "list".1304713048 - `"list"`1304913050### Example1305113052```http13053curl https://api.openai.com/v1/evals/$EVAL_ID/runs \13054 -H "Authorization: Bearer $OPENAI_API_KEY"13055```1305613057#### Response1305813059```json13060{13061 "data": [13062 {13063 "id": "id",13064 "created_at": 0,13065 "data_source": {13066 "source": {13067 "content": [13068 {13069 "item": {13070 "foo": "bar"13071 },13072 "sample": {13073 "foo": "bar"13074 }13075 }13076 ],13077 "type": "file_content"13078 },13079 "type": "jsonl"13080 },13081 "error": {13082 "code": "code",13083 "message": "message"13084 },13085 "eval_id": "eval_id",13086 "metadata": {13087 "foo": "string"13088 },13089 "model": "model",13090 "name": "name",13091 "object": "eval.run",13092 "per_model_usage": [13093 {13094 "cached_tokens": 0,13095 "completion_tokens": 0,13096 "invocation_count": 0,13097 "model_name": "model_name",13098 "prompt_tokens": 0,13099 "total_tokens": 013100 }13101 ],13102 "per_testing_criteria_results": [13103 {13104 "failed": 0,13105 "passed": 0,13106 "testing_criteria": "testing_criteria"13107 }13108 ],13109 "report_url": "https://example.com",13110 "result_counts": {13111 "errored": 0,13112 "failed": 0,13113 "passed": 0,13114 "total": 013115 },13116 "status": "status"13117 }13118 ],13119 "first_id": "first_id",13120 "has_more": true,13121 "last_id": "last_id",13122 "object": "list"13123}13124```1312513126### Example1312713128```http13129curl https://api.openai.com/v1/evals/egroup_67abd54d9b0081909a86353f6fb9317a/runs \13130 -H "Authorization: Bearer $OPENAI_API_KEY" \13131 -H "Content-Type: application/json"13132```1313313134#### Response1313513136```json13137{13138 "object": "list",13139 "data": [13140 {13141 "object": "eval.run",13142 "id": "evalrun_67e0c7d31560819090d60c0780591042",13143 "eval_id": "eval_67e0c726d560819083f19a957c4c640b",13144 "report_url": "https://platform.openai.com/evaluations/eval_67e0c726d560819083f19a957c4c640b",13145 "status": "completed",13146 "model": "o3-mini",13147 "name": "bulk_with_negative_examples_o3-mini",13148 "created_at": 1742784467,13149 "result_counts": {13150 "total": 1,13151 "errored": 0,13152 "failed": 0,13153 "passed": 113154 },13155 "per_model_usage": [13156 {13157 "model_name": "o3-mini",13158 "invocation_count": 1,13159 "prompt_tokens": 563,13160 "completion_tokens": 874,13161 "total_tokens": 1437,13162 "cached_tokens": 013163 }13164 ],13165 "per_testing_criteria_results": [13166 {13167 "testing_criteria": "Push Notification Summary Grader-1808cd0b-eeec-4e0b-a519-337e79f4f5d1",13168 "passed": 1,13169 "failed": 013170 }13171 ],13172 "data_source": {13173 "type": "completions",13174 "source": {13175 "type": "file_content",13176 "content": [13177 {13178 "item": {13179 "notifications": "\n- New message from Sarah: \"Can you call me later?\"\n- Your package has been delivered!\n- Flash sale: 20% off electronics for the next 2 hours!\n"13180 }13181 }13182 ]13183 },13184 "input_messages": {13185 "type": "template",13186 "template": [13187 {13188 "type": "message",13189 "role": "developer",13190 "content": {13191 "type": "input_text",13192 "text": "\n\n\n\nYou are a helpful assistant that takes in an array of push notifications and returns a collapsed summary of them.\nThe push notification will be provided as follows:\n<push_notifications>\n...notificationlist...\n</push_notifications>\n\nYou should return just the summary and nothing else.\n\n\nYou should return a summary that is concise and snappy.\n\n\nHere is an example of a good summary:\n<push_notifications>\n- Traffic alert: Accident reported on Main Street.- Package out for delivery: Expected by 5 PM.- New friend suggestion: Connect with Emma.\n</push_notifications>\n<summary>\nTraffic alert, package expected by 5pm, suggestion for new friend (Emily).\n</summary>\n\n\nHere is an example of a bad summary:\n<push_notifications>\n- Traffic alert: Accident reported on Main Street.- Package out for delivery: Expected by 5 PM.- New friend suggestion: Connect with Emma.\n</push_notifications>\n<summary>\nTraffic alert reported on main street. You have a package that will arrive by 5pm, Emily is a new friend suggested for you.\n</summary>\n"13193 }13194 },13195 {13196 "type": "message",13197 "role": "user",13198 "content": {13199 "type": "input_text",13200 "text": "<push_notifications>{{item.notifications}}</push_notifications>"13201 }13202 }13203 ]13204 },13205 "model": "o3-mini",13206 "sampling_params": null13207 },13208 "error": null,13209 "metadata": {}13210 }13211 ],13212 "first_id": "evalrun_67e0c7d31560819090d60c0780591042",13213 "last_id": "evalrun_67e0c7d31560819090d60c0780591042",13214 "has_more": true13215}13216```1321713218## Get an eval run1321913220**get** `/evals/{eval_id}/runs/{run_id}`1322113222Get an evaluation run by ID.1322313224### Path Parameters1322513226- `eval_id: string`1322713228- `run_id: string`1322913230### Returns1323113232- `id: string`1323313234 Unique identifier for the evaluation run.1323513236- `created_at: number`1323713238 Unix timestamp (in seconds) when the evaluation run was created.1323913240- `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`1324113242 Information about the run's data source.1324313244 - `CreateEvalJSONLRunDataSource object { source, type }`1324513246 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval1324713248 - `source: object { content, type } or object { id, type }`1324913250 Determines what populates the `item` namespace in the data source.1325113252 - `EvalJSONLFileContentSource object { content, type }`1325313254 - `content: array of object { item, sample }`1325513256 The content of the jsonl file.1325713258 - `item: map[unknown]`1325913260 - `sample: optional map[unknown]`1326113262 - `type: "file_content"`1326313264 The type of jsonl source. Always `file_content`.1326513266 - `"file_content"`1326713268 - `EvalJSONLFileIDSource object { id, type }`1326913270 - `id: string`1327113272 The identifier of the file.1327313274 - `type: "file_id"`1327513276 The type of jsonl source. Always `file_id`.1327713278 - `"file_id"`1327913280 - `type: "jsonl"`1328113282 The type of data source. Always `jsonl`.1328313284 - `"jsonl"`1328513286 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`1328713288 A CompletionsRunDataSource object describing a model sampling configuration.1328913290 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`1329113292 Determines what populates the `item` namespace in this run's data source.1329313294 - `EvalJSONLFileContentSource object { content, type }`1329513296 - `content: array of object { item, sample }`1329713298 The content of the jsonl file.1329913300 - `item: map[unknown]`1330113302 - `sample: optional map[unknown]`1330313304 - `type: "file_content"`1330513306 The type of jsonl source. Always `file_content`.1330713308 - `"file_content"`1330913310 - `EvalJSONLFileIDSource object { id, type }`1331113312 - `id: string`1331313314 The identifier of the file.1331513316 - `type: "file_id"`1331713318 The type of jsonl source. Always `file_id`.1331913320 - `"file_id"`1332113322 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`1332313324 A StoredCompletionsRunDataSource configuration describing a set of filters1332513326 - `type: "stored_completions"`1332713328 The type of source. Always `stored_completions`.1332913330 - `"stored_completions"`1333113332 - `created_after: optional number or null`1333313334 An optional Unix timestamp to filter items created after this time.1333513336 - `created_before: optional number or null`1333713338 An optional Unix timestamp to filter items created before this time.1333913340 - `limit: optional number or null`1334113342 An optional maximum number of items to return.1334313344 - `metadata: optional Metadata or null`1334513346 Set of 16 key-value pairs that can be attached to an object. This can be13347 useful for storing additional information about the object in a structured13348 format, and querying for objects via API or the dashboard.1334913350 Keys are strings with a maximum length of 64 characters. Values are strings13351 with a maximum length of 512 characters.1335213353 - `model: optional string or null`1335413355 An optional model to filter by (e.g., 'gpt-6-astra').1335613357 - `type: "completions"`1335813359 The type of run data source. Always `completions`.1336013361 - `"completions"`1336213363 - `input_messages: optional object { template, type } or object { item_reference, type }`1336413365 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1336613367 - `TemplateInputMessages object { template, type }`1336813369 - `template: array of EasyInputMessage or object { content, role, type }`1337013371 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1337213373 - `EasyInputMessage object { content, role, phase, type }`1337413375 A message input to the model with a role indicating instruction following13376 hierarchy. Instructions given with the `developer` or `system` role take13377 precedence over instructions given with the `user` role. Messages with the13378 `assistant` role are presumed to have been generated by the model in previous13379 interactions.1338013381 - `content: string or ResponseInputMessageContentList`1338213383 Text, image, or audio input to the model, used to generate a response.13384 Can also contain previous assistant responses.1338513386 - `TextInput = string`1338713388 A text input to the model.1338913390 - `ResponseInputMessageContentList = array of ResponseInputContent`1339113392 A list of one or many input items to the model, containing different content13393 types.1339413395 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1339613397 A text input to the model.1339813399 - `text: string`1340013401 The text input to the model.1340213403 - `type: "input_text"`1340413405 The type of the input item. Always `input_text`.1340613407 - `"input_text"`1340813409 - `prompt_cache_breakpoint: optional object { mode }`1341013411 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1341213413 - `mode: "explicit"`1341413415 The breakpoint mode. Always `explicit`.1341613417 - `"explicit"`1341813419 - `ResponseInputImage object { detail, type, file_id, 2 more }`1342013421 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).1342213423 - `detail: ImageDetail`1342413425 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.1342613427 - `"low"`1342813429 - `"high"`1343013431 - `"auto"`1343213433 - `"original"`1343413435 - `type: "input_image"`1343613437 The type of the input item. Always `input_image`.1343813439 - `"input_image"`1344013441 - `file_id: optional string or null`1344213443 The ID of the file to be sent to the model.1344413445 - `image_url: optional string or null`1344613447 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.1344813449 - `prompt_cache_breakpoint: optional object { mode }`1345013451 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1345213453 - `mode: "explicit"`1345413455 The breakpoint mode. Always `explicit`.1345613457 - `"explicit"`1345813459 - `ResponseInputFile object { type, detail, file_data, 4 more }`1346013461 A file input to the model.1346213463 - `type: "input_file"`1346413465 The type of the input item. Always `input_file`.1346613467 - `"input_file"`1346813469 - `detail: optional "auto" or "low" or "high"`1347013471 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.1347213473 - `"auto"`1347413475 - `"low"`1347613477 - `"high"`1347813479 - `file_data: optional string`1348013481 The content of the file to be sent to the model.1348213483 - `file_id: optional string or null`1348413485 The ID of the file to be sent to the model.1348613487 - `file_url: optional string`1348813489 The URL of the file to be sent to the model.1349013491 - `filename: optional string`1349213493 The name of the file to be sent to the model.1349413495 - `prompt_cache_breakpoint: optional object { mode }`1349613497 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1349813499 - `mode: "explicit"`1350013501 The breakpoint mode. Always `explicit`.1350213503 - `"explicit"`1350413505 - `role: "user" or "assistant" or "system" or "developer"`1350613507 The role of the message input. One of `user`, `assistant`, `system`, or13508 `developer`.1350913510 - `"user"`1351113512 - `"assistant"`1351313514 - `"system"`1351513516 - `"developer"`1351713518 - `phase: optional "commentary" or "final_answer" or null`1351913520 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).13521 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend13522 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.1352313524 - `"commentary"`1352513526 - `"final_answer"`1352713528 - `type: optional "message"`1352913530 The type of the message input. Always `message`.1353113532 - `"message"`1353313534 - `EvalMessageObject object { content, role, type }`1353513536 A message input to the model with a role indicating instruction following13537 hierarchy. Instructions given with the `developer` or `system` role take13538 precedence over instructions given with the `user` role. Messages with the13539 `assistant` role are presumed to have been generated by the model in previous13540 interactions.1354113542 - `content: string or ResponseInputText or object { text, type } or 3 more`1354313544 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1354513546 - `TextInput = string`1354713548 A text input to the model.1354913550 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1355113552 A text input to the model.1355313554 - `OutputText object { text, type }`1355513556 A text output from the model.1355713558 - `text: string`1355913560 The text output from the model.1356113562 - `type: "output_text"`1356313564 The type of the output text. Always `output_text`.1356513566 - `"output_text"`1356713568 - `InputImage object { image_url, type, detail }`1356913570 An image input block used within EvalItem content arrays.1357113572 - `image_url: string`1357313574 The URL of the image input.1357513576 - `type: "input_image"`1357713578 The type of the image input. Always `input_image`.1357913580 - `"input_image"`1358113582 - `detail: optional string`1358313584 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1358513586 - `ResponseInputAudio object { input_audio, type }`1358713588 An audio input to the model.1358913590 - `input_audio: object { data, format }`1359113592 - `data: string`1359313594 Base64-encoded audio data.1359513596 - `format: "mp3" or "wav"`1359713598 The format of the audio data. Currently supported formats are `mp3` and13599 `wav`.1360013601 - `"mp3"`1360213603 - `"wav"`1360413605 - `type: "input_audio"`1360613607 The type of the input item. Always `input_audio`.1360813609 - `"input_audio"`1361013611 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1361213613 A list of inputs, each of which may be either an input text, output text, input13614 image, or input audio object.1361513616 - `TextInput = string`1361713618 A text input to the model.1361913620 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1362113622 A text input to the model.1362313624 - `OutputText object { text, type }`1362513626 A text output from the model.1362713628 - `text: string`1362913630 The text output from the model.1363113632 - `type: "output_text"`1363313634 The type of the output text. Always `output_text`.1363513636 - `"output_text"`1363713638 - `InputImage object { image_url, type, detail }`1363913640 An image input block used within EvalItem content arrays.1364113642 - `image_url: string`1364313644 The URL of the image input.1364513646 - `type: "input_image"`1364713648 The type of the image input. Always `input_image`.1364913650 - `"input_image"`1365113652 - `detail: optional string`1365313654 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1365513656 - `ResponseInputAudio object { input_audio, type }`1365713658 An audio input to the model.1365913660 - `role: "user" or "assistant" or "system" or "developer"`1366113662 The role of the message input. One of `user`, `assistant`, `system`, or13663 `developer`.1366413665 - `"user"`1366613667 - `"assistant"`1366813669 - `"system"`1367013671 - `"developer"`1367213673 - `type: optional "message"`1367413675 The type of the message input. Always `message`.1367613677 - `"message"`1367813679 - `type: "template"`1368013681 The type of input messages. Always `template`.1368213683 - `"template"`1368413685 - `ItemReferenceInputMessages object { item_reference, type }`1368613687 - `item_reference: string`1368813689 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"1369013691 - `type: "item_reference"`1369213693 The type of input messages. Always `item_reference`.1369413695 - `"item_reference"`1369613697 - `model: optional string`1369813699 The name of the model to use for generating completions (e.g. "o3-mini").1370013701 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`1370213703 - `max_completion_tokens: optional number`1370413705 The maximum number of tokens in the generated output.1370613707 - `reasoning_effort: optional ReasoningEffort or null`1370813709 Constrains effort on reasoning for reasoning models. Currently supported13710 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.13711 Reducing reasoning effort can result in faster responses and fewer tokens13712 used on reasoning in a response. Not all reasoning models support every13713 value. See the13714 [reasoning guide](/api/docs/guides/reasoning)13715 for model-specific support.1371613717 - `"none"`1371813719 - `"minimal"`1372013721 - `"low"`1372213723 - `"medium"`1372413725 - `"high"`1372613727 - `"xhigh"`1372813729 - `"max"`1373013731 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`1373213733 An object specifying the format that the model must output.1373413735 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables13736 Structured Outputs which ensures the model will match your supplied JSON13737 schema. Learn more in the [Structured Outputs13738 guide](/api/docs/guides/structured-outputs).1373913740 Setting to `{ "type": "json_object" }` enables the older JSON mode, which13741 ensures the message the model generates is valid JSON. Using `json_schema`13742 is preferred for models that support it.1374313744 - `ResponseFormatText object { type }`1374513746 Default response format. Used to generate text responses.1374713748 - `type: "text"`1374913750 The type of response format being defined. Always `text`.1375113752 - `"text"`1375313754 - `ResponseFormatJSONSchema object { json_schema, type }`1375513756 JSON Schema response format. Used to generate structured JSON responses.13757 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1375813759 - `json_schema: object { name, description, schema, strict }`1376013761 Structured Outputs configuration options, including a JSON Schema.1376213763 - `name: string`1376413765 The name of the response format. Must be a-z, A-Z, 0-9, or contain13766 underscores and dashes, with a maximum length of 64.1376713768 - `description: optional string`1376913770 A description of what the response format is for, used by the model to13771 determine how to respond in the format.1377213773 - `schema: optional map[unknown]`1377413775 The schema for the response format, described as a JSON Schema object.13776 Learn how to build JSON schemas [here](https://json-schema.org/).1377713778 - `strict: optional boolean or null`1377913780 Whether to enable strict schema adherence when generating the output.13781 If set to true, the model will always follow the exact schema defined13782 in the `schema` field. Only a subset of JSON Schema is supported when13783 `strict` is `true`. To learn more, read the [Structured Outputs13784 guide](/api/docs/guides/structured-outputs).1378513786 - `type: "json_schema"`1378713788 The type of response format being defined. Always `json_schema`.1378913790 - `"json_schema"`1379113792 - `ResponseFormatJSONObject object { type }`1379313794 JSON object response format. An older method of generating JSON responses.13795 Using `json_schema` is recommended for models that support it. Note that the13796 model will not generate JSON without a system or user message instructing it13797 to do so.1379813799 - `type: "json_object"`1380013801 The type of response format being defined. Always `json_object`.1380213803 - `"json_object"`1380413805 - `seed: optional number`1380613807 A seed value to initialize the randomness, during sampling.1380813809 - `temperature: optional number`1381013811 A higher temperature increases randomness in the outputs.1381213813 - `tools: optional array of ChatCompletionFunctionTool`1381413815 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.1381613817 - `function: FunctionDefinition`1381813819 - `name: string`1382013821 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.1382213823 - `description: optional string`1382413825 A description of what the function does, used by the model to choose when and how to call the function.1382613827 - `parameters: optional FunctionParameters`1382813829 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.1383013831 Omitting `parameters` defines a function with an empty parameter list.1383213833 - `strict: optional boolean or null`1383413835 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).1383613837 - `type: "function"`1383813839 The type of the tool. Currently, only `function` is supported.1384013841 - `"function"`1384213843 - `top_p: optional number`1384413845 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1384613847 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`1384813849 A ResponsesRunDataSource object describing a model sampling configuration.1385013851 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`1385213853 Determines what populates the `item` namespace in this run's data source.1385413855 - `EvalJSONLFileContentSource object { content, type }`1385613857 - `content: array of object { item, sample }`1385813859 The content of the jsonl file.1386013861 - `item: map[unknown]`1386213863 - `sample: optional map[unknown]`1386413865 - `type: "file_content"`1386613867 The type of jsonl source. Always `file_content`.1386813869 - `"file_content"`1387013871 - `EvalJSONLFileIDSource object { id, type }`1387213873 - `id: string`1387413875 The identifier of the file.1387613877 - `type: "file_id"`1387813879 The type of jsonl source. Always `file_id`.1388013881 - `"file_id"`1388213883 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`1388413885 A EvalResponsesSource object describing a run data source configuration.1388613887 - `type: "responses"`1388813889 The type of run data source. Always `responses`.1389013891 - `"responses"`1389213893 - `created_after: optional number or null`1389413895 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.1389613897 - `created_before: optional number or null`1389813899 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.1390013901 - `instructions_search: optional string or null`1390213903 Optional string to search the 'instructions' field. This is a query parameter used to select responses.1390413905 - `metadata: optional unknown or null`1390613907 Metadata filter for the responses. This is a query parameter used to select responses.1390813909 - `model: optional string or null`1391013911 The name of the model to find responses for. This is a query parameter used to select responses.1391213913 - `reasoning_effort: optional ReasoningEffort or null`1391413915 Constrains effort on reasoning for reasoning models. Currently supported13916 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.13917 Reducing reasoning effort can result in faster responses and fewer tokens13918 used on reasoning in a response. Not all reasoning models support every13919 value. See the13920 [reasoning guide](/api/docs/guides/reasoning)13921 for model-specific support.1392213923 - `temperature: optional number or null`1392413925 Sampling temperature. This is a query parameter used to select responses.1392613927 - `tools: optional array of string or null`1392813929 List of tool names. This is a query parameter used to select responses.1393013931 - `top_p: optional number or null`1393213933 Nucleus sampling parameter. This is a query parameter used to select responses.1393413935 - `users: optional array of string or null`1393613937 List of user identifiers. This is a query parameter used to select responses.1393813939 - `type: "responses"`1394013941 The type of run data source. Always `responses`.1394213943 - `"responses"`1394413945 - `input_messages: optional object { template, type } or object { item_reference, type }`1394613947 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1394813949 - `InputMessagesTemplate object { template, type }`1395013951 - `template: array of object { content, role } or object { content, role, type }`1395213953 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1395413955 - `ChatMessage object { content, role }`1395613957 - `content: string`1395813959 The content of the message.1396013961 - `role: string`1396213963 The role of the message (e.g. "system", "assistant", "user").1396413965 - `EvalMessageObject object { content, role, type }`1396613967 A message input to the model with a role indicating instruction following13968 hierarchy. Instructions given with the `developer` or `system` role take13969 precedence over instructions given with the `user` role. Messages with the13970 `assistant` role are presumed to have been generated by the model in previous13971 interactions.1397213973 - `content: string or ResponseInputText or object { text, type } or 3 more`1397413975 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1397613977 - `TextInput = string`1397813979 A text input to the model.1398013981 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1398213983 A text input to the model.1398413985 - `OutputText object { text, type }`1398613987 A text output from the model.1398813989 - `text: string`1399013991 The text output from the model.1399213993 - `type: "output_text"`1399413995 The type of the output text. Always `output_text`.1399613997 - `"output_text"`1399813999 - `InputImage object { image_url, type, detail }`1400014001 An image input block used within EvalItem content arrays.1400214003 - `image_url: string`1400414005 The URL of the image input.1400614007 - `type: "input_image"`1400814009 The type of the image input. Always `input_image`.1401014011 - `"input_image"`1401214013 - `detail: optional string`1401414015 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1401614017 - `ResponseInputAudio object { input_audio, type }`1401814019 An audio input to the model.1402014021 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1402214023 A list of inputs, each of which may be either an input text, output text, input14024 image, or input audio object.1402514026 - `role: "user" or "assistant" or "system" or "developer"`1402714028 The role of the message input. One of `user`, `assistant`, `system`, or14029 `developer`.1403014031 - `"user"`1403214033 - `"assistant"`1403414035 - `"system"`1403614037 - `"developer"`1403814039 - `type: optional "message"`1404014041 The type of the message input. Always `message`.1404214043 - `"message"`1404414045 - `type: "template"`1404614047 The type of input messages. Always `template`.1404814049 - `"template"`1405014051 - `InputMessagesItemReference object { item_reference, type }`1405214053 - `item_reference: string`1405414055 A reference to a variable in the `item` namespace. Ie, "item.name"1405614057 - `type: "item_reference"`1405814059 The type of input messages. Always `item_reference`.1406014061 - `"item_reference"`1406214063 - `model: optional string`1406414065 The name of the model to use for generating completions (e.g. "o3-mini").1406614067 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`1406814069 - `max_completion_tokens: optional number`1407014071 The maximum number of tokens in the generated output.1407214073 - `reasoning_effort: optional ReasoningEffort or null`1407414075 Constrains effort on reasoning for reasoning models. Currently supported14076 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.14077 Reducing reasoning effort can result in faster responses and fewer tokens14078 used on reasoning in a response. Not all reasoning models support every14079 value. See the14080 [reasoning guide](/api/docs/guides/reasoning)14081 for model-specific support.1408214083 - `seed: optional number`1408414085 A seed value to initialize the randomness, during sampling.1408614087 - `temperature: optional number`1408814089 A higher temperature increases randomness in the outputs.1409014091 - `text: optional object { format }`1409214093 Configuration options for a text response from the model. Can be plain14094 text or structured JSON data. Learn more:1409514096 - [Text inputs and outputs](/api/docs/guides/text)14097 - [Structured Outputs](/api/docs/guides/structured-outputs)1409814099 - `format: optional ResponseFormatTextConfig`1410014101 An object specifying the format that the model must output.1410214103 Configuring `{ "type": "json_schema" }` enables Structured Outputs,14104 which ensures the model will match your supplied JSON schema. Learn more in the14105 [Structured Outputs guide](/api/docs/guides/structured-outputs).1410614107 The default format is `{ "type": "text" }` with no additional options.1410814109 **Not recommended for gpt-4o and newer models:**1411014111 Setting to `{ "type": "json_object" }` enables the older JSON mode, which14112 ensures the message the model generates is valid JSON. Using `json_schema`14113 is preferred for models that support it.1411414115 - `ResponseFormatText object { type }`1411614117 Default response format. Used to generate text responses.1411814119 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`1412014121 JSON Schema response format. Used to generate structured JSON responses.14122 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1412314124 - `name: string`1412514126 The name of the response format. Must be a-z, A-Z, 0-9, or contain14127 underscores and dashes, with a maximum length of 64.1412814129 - `schema: map[unknown]`1413014131 The schema for the response format, described as a JSON Schema object.14132 Learn how to build JSON schemas [here](https://json-schema.org/).1413314134 - `type: "json_schema"`1413514136 The type of response format being defined. Always `json_schema`.1413714138 - `"json_schema"`1413914140 - `description: optional string`1414114142 A description of what the response format is for, used by the model to14143 determine how to respond in the format.1414414145 - `strict: optional boolean or null`1414614147 Whether to enable strict schema adherence when generating the output.14148 If set to true, the model will always follow the exact schema defined14149 in the `schema` field. Only a subset of JSON Schema is supported when14150 `strict` is `true`. To learn more, read the [Structured Outputs14151 guide](/api/docs/guides/structured-outputs).1415214153 - `ResponseFormatJSONObject object { type }`1415414155 JSON object response format. An older method of generating JSON responses.14156 Using `json_schema` is recommended for models that support it. Note that the14157 model will not generate JSON without a system or user message instructing it14158 to do so.1415914160 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`1416114162 An array of tools the model may call while generating a response. You14163 can specify which tool to use by setting the `tool_choice` parameter.1416414165 The two categories of tools you can provide the model are:1416614167 - **Built-in tools**: Tools that are provided by OpenAI that extend the14168 model's capabilities, like [web search](/api/docs/guides/tools-web-search)14169 or [file search](/api/docs/guides/tools-file-search). Learn more about14170 [built-in tools](/api/docs/guides/tools).14171 - **Function calls (custom tools)**: Functions that are defined by you,14172 enabling the model to call your own code. Learn more about14173 [function calling](/api/docs/guides/function-calling).1417414175 - `Function object { name, parameters, strict, 6 more }`1417614177 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).1417814179 - `name: string`1418014181 The name of the function to call.1418214183 - `parameters: map[unknown] or null`1418414185 A JSON schema object describing the parameters of the function.1418614187 - `strict: boolean or null`1418814189 Whether strict parameter validation is enforced for this function tool.1419014191 - `type: "function"`1419214193 The type of the function tool. Always `function`.1419414195 - `"function"`1419614197 - `allowed_callers: optional array of "direct" or "programmatic" or null`1419814199 The tool invocation context(s).1420014201 - `"direct"`1420214203 - `"programmatic"`1420414205 - `async: optional boolean`1420614207 - `defer_loading: optional boolean`1420814209 Whether this function is deferred and loaded via tool search.1421014211 - `description: optional string or null`1421214213 A description of the function. Used by the model to determine whether or not to call the function.1421414215 - `output_schema: optional map[unknown] or null`1421614217 A JSON schema object describing the JSON value encoded in string outputs for this function.1421814219 - `FileSearch object { type, vector_store_ids, filters, 2 more }`1422014221 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).1422214223 - `type: "file_search"`1422414225 The type of the file search tool. Always `file_search`.1422614227 - `"file_search"`1422814229 - `vector_store_ids: array of string`1423014231 The IDs of the vector stores to search.1423214233 - `filters: optional ComparisonFilter or CompoundFilter or null`1423414235 A filter to apply.1423614237 - `ComparisonFilter object { key, type, value }`1423814239 A filter used to compare a specified attribute key to a given value using a defined comparison operation.1424014241 - `key: string`1424214243 The key to compare against the value.1424414245 - `type: "eq" or "ne" or "gt" or 5 more`1424614247 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.1424814249 - `eq`: equals14250 - `ne`: not equal14251 - `gt`: greater than14252 - `gte`: greater than or equal14253 - `lt`: less than14254 - `lte`: less than or equal14255 - `in`: in14256 - `nin`: not in1425714258 - `"eq"`1425914260 - `"ne"`1426114262 - `"gt"`1426314264 - `"gte"`1426514266 - `"lt"`1426714268 - `"lte"`1426914270 - `"in"`1427114272 - `"nin"`1427314274 - `value: string or number or boolean or array of string or number`1427514276 The value to compare against the attribute key; supports string, number, or boolean types.1427714278 - `string`1427914280 - `number`1428114282 - `boolean`1428314284 - `array of string or number`1428514286 - `string`1428714288 - `number`1428914290 - `CompoundFilter object { filters, type }`1429114292 Combine multiple filters using `and` or `or`.1429314294 - `filters: array of ComparisonFilter or unknown`1429514296 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.1429714298 - `ComparisonFilter object { key, type, value }`1429914300 A filter used to compare a specified attribute key to a given value using a defined comparison operation.1430114302 - `unknown`1430314304 - `type: "and" or "or"`1430514306 Type of operation: `and` or `or`.1430714308 - `"and"`1430914310 - `"or"`1431114312 - `max_num_results: optional number`1431314314 The maximum number of results to return. This number should be between 1 and 50 inclusive.1431514316 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`1431714318 Ranking options for search.1431914320 - `hybrid_search: optional object { embedding_weight, text_weight }`1432114322 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.1432314324 - `embedding_weight: number`1432514326 The weight of the embedding in the reciprocal ranking fusion.1432714328 - `text_weight: number`1432914330 The weight of the text in the reciprocal ranking fusion.1433114332 - `ranker: optional "auto" or "default-2024-11-15"`1433314334 The ranker to use for the file search.1433514336 - `"auto"`1433714338 - `"default-2024-11-15"`1433914340 - `score_threshold: optional number`1434114342 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.1434314344 - `Computer object { type }`1434514346 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).1434714348 - `type: "computer"`1434914350 The type of the computer tool. Always `computer`.1435114352 - `"computer"`1435314354 - `ComputerUsePreview object { display_height, display_width, environment, type }`1435514356 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).1435714358 - `display_height: number`1435914360 The height of the computer display.1436114362 - `display_width: number`1436314364 The width of the computer display.1436514366 - `environment: "windows" or "mac" or "linux" or 2 more`1436714368 The type of computer environment to control.1436914370 - `"windows"`1437114372 - `"mac"`1437314374 - `"linux"`1437514376 - `"ubuntu"`1437714378 - `"browser"`1437914380 - `type: "computer_use_preview"`1438114382 The type of the computer use tool. Always `computer_use_preview`.1438314384 - `"computer_use_preview"`1438514386 - `WebSearch object { type, external_web_access, filters, 2 more }`1438714388 Search the Internet for sources related to the prompt. Learn more about the14389 [web search tool](/api/docs/guides/tools-web-search).1439014391 - `type: "web_search" or "web_search_2025_08_26"`1439214393 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.1439414395 - `"web_search"`1439614397 - `"web_search_2025_08_26"`1439814399 - `external_web_access: optional boolean`1440014401 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.1440214403 - `filters: optional object { allowed_domains } or null`1440414405 Filters for the search.1440614407 - `allowed_domains: optional array of string or null`1440814409 Allowed domains for the search. If not provided, all domains are allowed.14410 Subdomains of the provided domains are allowed as well.1441114412 Example: `["pubmed.ncbi.nlm.nih.gov"]`1441314414 - `search_context_size: optional "low" or "medium" or "high"`1441514416 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.1441714418 - `"low"`1441914420 - `"medium"`1442114422 - `"high"`1442314424 - `user_location: optional object { city, country, region, 2 more } or null`1442514426 The approximate location of the user.1442714428 - `city: optional string or null`1442914430 Free text input for the city of the user, e.g. `San Francisco`.1443114432 - `country: optional string or null`1443314434 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.1443514436 - `region: optional string or null`1443714438 Free text input for the region of the user, e.g. `California`.1443914440 - `timezone: optional string or null`1444114442 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.1444314444 - `type: optional "approximate"`1444514446 The type of location approximation. Always `approximate`.1444714448 - `"approximate"`1444914450 - `Mcp object { server_label, type, allowed_callers, 9 more }`1445114452 Give the model access to additional tools via remote Model Context Protocol14453 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).1445414455 - `server_label: string`1445614457 A label for this MCP server, used to identify it in tool calls.1445814459 - `type: "mcp"`1446014461 The type of the MCP tool. Always `mcp`.1446214463 - `"mcp"`1446414465 - `allowed_callers: optional array of "direct" or "programmatic" or null`1446614467 The tool invocation context(s).1446814469 - `"direct"`1447014471 - `"programmatic"`1447214473 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`1447414475 List of allowed tool names or a filter object.1447614477 - `McpAllowedTools = array of string`1447814479 A string array of allowed tool names1448014481 - `McpToolFilter object { read_only, tool_names }`1448214483 A filter object to specify which tools are allowed.1448414485 - `read_only: optional boolean`1448614487 Indicates whether or not a tool modifies data or is read-only. If an14488 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),14489 it will match this filter.1449014491 - `tool_names: optional array of string`1449214493 List of allowed tool names.1449414495 - `authorization: optional string`1449614497 An OAuth access token that can be used with a remote MCP server, either14498 with a custom MCP server URL or a service connector. Your application14499 must handle the OAuth authorization flow and provide the token here.1450014501 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`1450214503 Identifier for service connectors, like those available in ChatGPT. One of14504 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more14505 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).1450614507 This field is deprecated for models released after September 1, 2026.14508 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to14509 connect through a Secure MCP Tunnel.1451014511 Currently supported `connector_id` values are:1451214513 - Dropbox: `connector_dropbox`14514 - Gmail: `connector_gmail`14515 - Google Calendar: `connector_googlecalendar`14516 - Google Drive: `connector_googledrive`14517 - Microsoft Teams: `connector_microsoftteams`14518 - Outlook Calendar: `connector_outlookcalendar`14519 - Outlook Email: `connector_outlookemail`14520 - SharePoint: `connector_sharepoint`1452114522 - `"connector_dropbox"`1452314524 - `"connector_gmail"`1452514526 - `"connector_googlecalendar"`1452714528 - `"connector_googledrive"`1452914530 - `"connector_microsoftteams"`1453114532 - `"connector_outlookcalendar"`1453314534 - `"connector_outlookemail"`1453514536 - `"connector_sharepoint"`1453714538 - `defer_loading: optional boolean`1453914540 Whether this MCP tool is deferred and discovered via tool search.1454114542 - `headers: optional map[string] or null`1454314544 Optional HTTP headers to send to the MCP server. Use for authentication14545 or other purposes.1454614547 - `require_approval: optional object { always, never } or "always" or "never" or null`1454814549 Specify which of the MCP server's tools require approval.1455014551 - `McpToolApprovalFilter object { always, never }`1455214553 Specify which of the MCP server's tools require approval. Can be14554 `always`, `never`, or a filter object associated with tools14555 that require approval.1455614557 - `always: optional object { read_only, tool_names }`1455814559 A filter object to specify which tools are allowed.1456014561 - `read_only: optional boolean`1456214563 Indicates whether or not a tool modifies data or is read-only. If an14564 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),14565 it will match this filter.1456614567 - `tool_names: optional array of string`1456814569 List of allowed tool names.1457014571 - `never: optional object { read_only, tool_names }`1457214573 A filter object to specify which tools are allowed.1457414575 - `read_only: optional boolean`1457614577 Indicates whether or not a tool modifies data or is read-only. If an14578 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),14579 it will match this filter.1458014581 - `tool_names: optional array of string`1458214583 List of allowed tool names.1458414585 - `McpToolApprovalSetting = "always" or "never"`1458614587 Specify a single approval policy for all tools. One of `always` or14588 `never`. When set to `always`, all tools will require approval. When14589 set to `never`, all tools will not require approval.1459014591 - `"always"`1459214593 - `"never"`1459414595 - `server_description: optional string`1459614597 Optional description of the MCP server, used to provide more context.1459814599 - `server_url: optional string`1460014601 The URL for the MCP server. One of `server_url`, `connector_id`, or14602 `tunnel_id` must be provided.1460314604 - `tunnel_id: optional string`1460514606 The Secure MCP Tunnel ID to use instead of a direct server URL. One of14607 `server_url`, `connector_id`, or `tunnel_id` must be provided.1460814609 - `CodeInterpreter object { container, type, allowed_callers }`1461014611 A tool that runs Python code to help generate a response to a prompt.1461214613 - `container: string or object { type, file_ids, memory_limit, network_policy }`1461414615 The code interpreter container. Can be a container ID or an object that14616 specifies uploaded file IDs to make available to your code, along with an14617 optional `memory_limit` setting.1461814619 - `string`1462014621 The container ID.1462214623 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`1462414625 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.1462614627 - `type: "auto"`1462814629 Always `auto`.1463014631 - `"auto"`1463214633 - `file_ids: optional array of string`1463414635 An optional list of uploaded files to make available to your code.1463614637 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`1463814639 The memory limit for the code interpreter container.1464014641 - `"1g"`1464214643 - `"4g"`1464414645 - `"16g"`1464614647 - `"64g"`1464814649 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`1465014651 Network access policy for the container.1465214653 - `ContainerNetworkPolicyDisabled object { type }`1465414655 - `type: "disabled"`1465614657 Disable outbound network access. Always `disabled`.1465814659 - `"disabled"`1466014661 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`1466214663 - `allowed_domains: array of string`1466414665 A list of allowed domains when type is `allowlist`.1466614667 - `type: "allowlist"`1466814669 Allow outbound network access only to specified domains. Always `allowlist`.1467014671 - `"allowlist"`1467214673 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`1467414675 Optional domain-scoped secrets for allowlisted domains.1467614677 - `domain: string`1467814679 The domain associated with the secret.1468014681 - `name: string`1468214683 The name of the secret to inject for the domain.1468414685 - `value: string`1468614687 The secret value to inject for the domain.1468814689 - `type: "code_interpreter"`1469014691 The type of the code interpreter tool. Always `code_interpreter`.1469214693 - `"code_interpreter"`1469414695 - `allowed_callers: optional array of "direct" or "programmatic" or null`1469614697 The tool invocation context(s).1469814699 - `"direct"`1470014701 - `"programmatic"`1470214703 - `ProgrammaticToolCalling object { type }`1470414705 - `type: "programmatic_tool_calling"`1470614707 The type of the tool. Always `programmatic_tool_calling`.1470814709 - `"programmatic_tool_calling"`1471014711 - `ImageGeneration object { type, action, background, 9 more }`1471214713 A tool that generates images using the GPT image models.1471414715 - `type: "image_generation"`1471614717 The type of the image generation tool. Always `image_generation`.1471814719 - `"image_generation"`1472014721 - `action: optional "generate" or "edit" or "auto"`1472214723 Whether to generate a new image or edit an existing image. Default: `auto`.1472414725 - `"generate"`1472614727 - `"edit"`1472814729 - `"auto"`1473014731 - `background: optional "transparent" or "opaque" or "auto"`1473214733 Set the background of the generated image. One of `transparent`, `opaque`,14734 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including14735 their `2026-09-08` snapshots, support `opaque` and `transparent`14736 backgrounds. Transparent backgrounds are available for supported GPT Image14737 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in14738 preview. When using `transparent`, set the output format to `png` or `webp`.14739 Default: `auto`.1474014741 - `"transparent"`1474214743 - `"opaque"`1474414745 - `"auto"`1474614747 - `input_fidelity: optional "high" or "low" or null`1474814749 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.1475014751 - `"high"`1475214753 - `"low"`1475414755 - `input_image_mask: optional object { file_id, image_url }`1475614757 Optional mask for inpainting. Contains `image_url`14758 (string, optional) and `file_id` (string, optional).1475914760 - `file_id: optional string`1476114762 File ID for the mask image.1476314764 - `image_url: optional string`1476514766 Base64-encoded mask image.1476714768 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`1476914770 The image generation model to use. One of `gpt-image-1`,14771 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,14772 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,14773 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,14774 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:14775 `gpt-image-1`.1477614777 - `string`1477814779 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`1478014781 The image generation model to use. One of `gpt-image-1`,14782 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,14783 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,14784 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,14785 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:14786 `gpt-image-1`.1478714788 - `"gpt-image-1"`1478914790 - `"gpt-image-1-mini"`1479114792 - `"gpt-image-1.5"`1479314794 - `"gpt-image-2"`1479514796 - `"gpt-image-2-2026-04-21"`1479714798 - `"gpt-image-2.5-sunburst"`1479914800 - `"gpt-image-2.5-sunburst-2026-09-08"`1480114802 - `"gpt-image-2.5-flare"`1480314804 - `"gpt-image-2.5-flare-2026-09-08"`1480514806 - `moderation: optional "auto" or "low"`1480714808 Moderation level for the generated image. Default: `auto`.1480914810 - `"auto"`1481114812 - `"low"`1481314814 - `output_compression: optional number`1481514816 Compression level for the output image. Default: 100.1481714818 - `output_format: optional "png" or "webp" or "jpeg"`1481914820 The output format of the generated image. One of `png`, `webp`, or14821 `jpeg`. Default: `png`.1482214823 - `"png"`1482414825 - `"webp"`1482614827 - `"jpeg"`1482814829 - `partial_images: optional number`1483014831 Number of partial images to generate in streaming mode, from 0 (default value) to 3.1483214833 - `quality: optional "low" or "medium" or "high" or 3 more`1483414835 The quality of the generated image. The GPT image models support `low`,14836 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,14837 including their `2026-09-08` snapshots, also support `xhigh` and `max`.14838 Default: `auto`.1483914840 - `"low"`1484114842 - `"medium"`1484314844 - `"high"`1484514846 - `"xhigh"`1484714848 - `"max"`1484914850 - `"auto"`1485114852 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`1485314854 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.1485514856 - `string`1485714858 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`1485914860 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.1486114862 - `"1024x1024"`1486314864 - `"1024x1536"`1486514866 - `"1536x1024"`1486714868 - `"auto"`1486914870 - `LocalShell object { type }`1487114872 A tool that allows the model to execute shell commands in a local environment.1487314874 - `type: "local_shell"`1487514876 The type of the local shell tool. Always `local_shell`.1487714878 - `"local_shell"`1487914880 - `Shell object { type, allowed_callers, environment }`1488114882 A tool that allows the model to execute shell commands.1488314884 - `type: "shell"`1488514886 The type of the shell tool. Always `shell`.1488714888 - `"shell"`1488914890 - `allowed_callers: optional array of "direct" or "programmatic" or null`1489114892 The tool invocation context(s).1489314894 - `"direct"`1489514896 - `"programmatic"`1489714898 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`1489914900 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`1490114902 - `type: "container_auto"`1490314904 Automatically creates a container for this request1490514906 - `"container_auto"`1490714908 - `file_ids: optional array of string`1490914910 An optional list of uploaded files to make available to your code.1491114912 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`1491314914 The memory limit for the container.1491514916 - `"1g"`1491714918 - `"4g"`1491914920 - `"16g"`1492114922 - `"64g"`1492314924 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`1492514926 Network access policy for the container.1492714928 - `ContainerNetworkPolicyDisabled object { type }`1492914930 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`1493114932 - `skills: optional array of SkillReference or InlineSkill`1493314934 An optional list of skills referenced by id or inline data.1493514936 - `SkillReference object { skill_id, type, version }`1493714938 - `skill_id: string`1493914940 The ID of the referenced skill.1494114942 - `type: "skill_reference"`1494314944 References a skill created with the /v1/skills endpoint.1494514946 - `"skill_reference"`1494714948 - `version: optional string`1494914950 Optional skill version. Use a positive integer or 'latest'. Omit for default.1495114952 - `InlineSkill object { description, name, source, type }`1495314954 - `description: string`1495514956 The description of the skill.1495714958 - `name: string`1495914960 The name of the skill.1496114962 - `source: InlineSkillSource`1496314964 Inline skill payload1496514966 - `data: string`1496714968 Base64-encoded skill zip bundle.1496914970 - `media_type: "application/zip"`1497114972 The media type of the inline skill payload. Must be `application/zip`.1497314974 - `"application/zip"`1497514976 - `type: "base64"`1497714978 The type of the inline skill source. Must be `base64`.1497914980 - `"base64"`1498114982 - `type: "inline"`1498314984 Defines an inline skill for this request.1498514986 - `"inline"`1498714988 - `LocalEnvironment object { type, skills }`1498914990 - `type: "local"`1499114992 Use a local computer environment.1499314994 - `"local"`1499514996 - `skills: optional array of LocalSkill`1499714998 An optional list of skills.1499915000 - `description: string`1500115002 The description of the skill.1500315004 - `name: string`1500515006 The name of the skill.1500715008 - `path: string`1500915010 The path to the directory containing the skill.1501115012 - `ContainerReference object { container_id, type }`1501315014 - `container_id: string`1501515016 The ID of the referenced container.1501715018 - `type: "container_reference"`1501915020 References a container created with the /v1/containers endpoint1502115022 - `"container_reference"`1502315024 - `Custom object { name, type, allowed_callers, 4 more }`1502515026 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)1502715028 - `name: string`1502915030 The name of the custom tool, used to identify it in tool calls.1503115032 - `type: "custom"`1503315034 The type of the custom tool. Always `custom`.1503515036 - `"custom"`1503715038 - `allowed_callers: optional array of "direct" or "programmatic" or null`1503915040 The tool invocation context(s).1504115042 - `"direct"`1504315044 - `"programmatic"`1504515046 - `async: optional boolean`1504715048 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1504915050 - `defer_loading: optional boolean`1505115052 Whether this tool should be deferred and discovered via tool search.1505315054 - `description: optional string`1505515056 Optional description of the custom tool, used to provide more context.1505715058 - `format: optional CustomToolInputFormat`1505915060 The input format for the custom tool. Default is unconstrained text.1506115062 - `Text object { type }`1506315064 Unconstrained free-form text.1506515066 - `type: "text"`1506715068 Unconstrained text format. Always `text`.1506915070 - `"text"`1507115072 - `Grammar object { definition, syntax, type }`1507315074 A grammar defined by the user.1507515076 - `definition: string`1507715078 The grammar definition.1507915080 - `syntax: "lark" or "regex"`1508115082 The syntax of the grammar definition. One of `lark` or `regex`.1508315084 - `"lark"`1508515086 - `"regex"`1508715088 - `type: "grammar"`1508915090 Grammar format. Always `grammar`.1509115092 - `"grammar"`1509315094 - `Namespace object { description, name, tools, type }`1509515096 Groups function/custom tools under a shared namespace.1509715098 - `description: string`1509915100 A description of the namespace shown to the model.1510115102 - `name: string`1510315104 The namespace name used in tool calls (for example, `crm`).1510515106 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`1510715108 The function/custom tools available inside this namespace.1510915110 - `Function object { name, type, allowed_callers, 6 more }`1511115112 - `name: string`1511315114 - `type: "function"`1511515116 - `"function"`1511715118 - `allowed_callers: optional array of "direct" or "programmatic" or null`1511915120 The tool invocation context(s).1512115122 - `"direct"`1512315124 - `"programmatic"`1512515126 - `async: optional boolean`1512715128 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1512915130 - `defer_loading: optional boolean`1513115132 Whether this function should be deferred and discovered via tool search.1513315134 - `description: optional string or null`1513515136 - `output_schema: optional map[unknown] or null`1513715138 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.1513915140 - `parameters: optional unknown or null`1514115142 - `strict: optional boolean or null`1514315144 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.1514515146 - `Custom object { name, type, allowed_callers, 4 more }`1514715148 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)1514915150 - `name: string`1515115152 The name of the custom tool, used to identify it in tool calls.1515315154 - `type: "custom"`1515515156 The type of the custom tool. Always `custom`.1515715158 - `"custom"`1515915160 - `allowed_callers: optional array of "direct" or "programmatic" or null`1516115162 The tool invocation context(s).1516315164 - `"direct"`1516515166 - `"programmatic"`1516715168 - `async: optional boolean`1516915170 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1517115172 - `defer_loading: optional boolean`1517315174 Whether this tool should be deferred and discovered via tool search.1517515176 - `description: optional string`1517715178 Optional description of the custom tool, used to provide more context.1517915180 - `format: optional CustomToolInputFormat`1518115182 The input format for the custom tool. Default is unconstrained text.1518315184 - `type: "namespace"`1518515186 The type of the tool. Always `namespace`.1518715188 - `"namespace"`1518915190 - `ToolSearch object { type, description, execution, parameters }`1519115192 Hosted or BYOT tool search configuration for deferred tools.1519315194 - `type: "tool_search"`1519515196 The type of the tool. Always `tool_search`.1519715198 - `"tool_search"`1519915200 - `description: optional string or null`1520115202 Description shown to the model for a client-executed tool search tool.1520315204 - `execution: optional "server" or "client"`1520515206 Whether tool search is executed by the server or by the client.1520715208 - `"server"`1520915210 - `"client"`1521115212 - `parameters: optional unknown or null`1521315214 Parameter schema for a client-executed tool search tool.1521515216 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`1521715218 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).1521915220 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`1522115222 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.1522315224 - `"web_search_preview"`1522515226 - `"web_search_preview_2025_03_11"`1522715228 - `search_content_types: optional array of "text" or "image"`1522915230 - `"text"`1523115232 - `"image"`1523315234 - `search_context_size: optional "low" or "medium" or "high"`1523515236 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.1523715238 - `"low"`1523915240 - `"medium"`1524115242 - `"high"`1524315244 - `user_location: optional object { type, city, country, 2 more } or null`1524515246 The user's location.1524715248 - `type: "approximate"`1524915250 The type of location approximation. Always `approximate`.1525115252 - `"approximate"`1525315254 - `city: optional string or null`1525515256 Free text input for the city of the user, e.g. `San Francisco`.1525715258 - `country: optional string or null`1525915260 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.1526115262 - `region: optional string or null`1526315264 Free text input for the region of the user, e.g. `California`.1526515266 - `timezone: optional string or null`1526715268 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.1526915270 - `ApplyPatch object { type, allowed_callers }`1527115272 Allows the assistant to create, delete, or update files using unified diffs.1527315274 - `type: "apply_patch"`1527515276 The type of the tool. Always `apply_patch`.1527715278 - `"apply_patch"`1527915280 - `allowed_callers: optional array of "direct" or "programmatic" or null`1528115282 The tool invocation context(s).1528315284 - `"direct"`1528515286 - `"programmatic"`1528715288 - `top_p: optional number`1528915290 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1529115292- `error: EvalAPIError`1529315294 An object representing an error response from the Eval API.1529515296 - `code: string`1529715298 The error code.1529915300 - `message: string`1530115302 The error message.1530315304- `eval_id: string`1530515306 The identifier of the associated evaluation.1530715308- `metadata: Metadata or null`1530915310 Set of 16 key-value pairs that can be attached to an object. This can be15311 useful for storing additional information about the object in a structured15312 format, and querying for objects via API or the dashboard.1531315314 Keys are strings with a maximum length of 64 characters. Values are strings15315 with a maximum length of 512 characters.1531615317- `model: string`1531815319 The model that is evaluated, if applicable.1532015321- `name: string`1532215323 The name of the evaluation run.1532415325- `object: "eval.run"`1532615327 The type of the object. Always "eval.run".1532815329 - `"eval.run"`1533015331- `per_model_usage: array of object { cached_tokens, completion_tokens, invocation_count, 3 more }`1533215333 Usage statistics for each model during the evaluation run.1533415335 - `cached_tokens: number`1533615337 The number of tokens retrieved from cache.1533815339 - `completion_tokens: number`1534015341 The number of completion tokens generated.1534215343 - `invocation_count: number`1534415345 The number of invocations.1534615347 - `model_name: string`1534815349 The name of the model.1535015351 - `prompt_tokens: number`1535215353 The number of prompt tokens used.1535415355 - `total_tokens: number`1535615357 The total number of tokens used.1535815359- `per_testing_criteria_results: array of object { failed, passed, testing_criteria }`1536015361 Results per testing criteria applied during the evaluation run.1536215363 - `failed: number`1536415365 Number of tests failed for this criteria.1536615367 - `passed: number`1536815369 Number of tests passed for this criteria.1537015371 - `testing_criteria: string`1537215373 A description of the testing criteria.1537415375- `report_url: string`1537615377 The URL to the rendered evaluation run report on the UI dashboard.1537815379- `result_counts: object { errored, failed, passed, total }`1538015381 Counters summarizing the outcomes of the evaluation run.1538215383 - `errored: number`1538415385 Number of output items that resulted in an error.1538615387 - `failed: number`1538815389 Number of output items that failed to pass the evaluation.1539015391 - `passed: number`1539215393 Number of output items that passed the evaluation.1539415395 - `total: number`1539615397 Total number of executed output items.1539815399- `status: string`1540015401 The status of the evaluation run.1540215403### Example1540415405```http15406curl https://api.openai.com/v1/evals/$EVAL_ID/runs/$RUN_ID \15407 -H "Authorization: Bearer $OPENAI_API_KEY"15408```1540915410#### Response1541115412```json15413{15414 "id": "id",15415 "created_at": 0,15416 "data_source": {15417 "source": {15418 "content": [15419 {15420 "item": {15421 "foo": "bar"15422 },15423 "sample": {15424 "foo": "bar"15425 }15426 }15427 ],15428 "type": "file_content"15429 },15430 "type": "jsonl"15431 },15432 "error": {15433 "code": "code",15434 "message": "message"15435 },15436 "eval_id": "eval_id",15437 "metadata": {15438 "foo": "string"15439 },15440 "model": "model",15441 "name": "name",15442 "object": "eval.run",15443 "per_model_usage": [15444 {15445 "cached_tokens": 0,15446 "completion_tokens": 0,15447 "invocation_count": 0,15448 "model_name": "model_name",15449 "prompt_tokens": 0,15450 "total_tokens": 015451 }15452 ],15453 "per_testing_criteria_results": [15454 {15455 "failed": 0,15456 "passed": 0,15457 "testing_criteria": "testing_criteria"15458 }15459 ],15460 "report_url": "https://example.com",15461 "result_counts": {15462 "errored": 0,15463 "failed": 0,15464 "passed": 0,15465 "total": 015466 },15467 "status": "status"15468}15469```1547015471### Example1547215473```http15474curl https://api.openai.com/v1/evals/eval_67abd54d9b0081909a86353f6fb9317a/runs/evalrun_67abd54d60ec8190832b46859da808f7 \15475 -H "Authorization: Bearer $OPENAI_API_KEY" \15476 -H "Content-Type: application/json"15477```1547815479#### Response1548015481```json15482{15483 "object": "eval.run",15484 "id": "evalrun_67abd54d60ec8190832b46859da808f7",15485 "eval_id": "eval_67abd54d9b0081909a86353f6fb9317a",15486 "report_url": "https://platform.openai.com/evaluations/eval_67abd54d9b0081909a86353f6fb9317a?run_id=evalrun_67abd54d60ec8190832b46859da808f7",15487 "status": "queued",15488 "model": "gpt-6-astra",15489 "name": "gpt-6-astra",15490 "created_at": 1743092069,15491 "result_counts": {15492 "total": 0,15493 "errored": 0,15494 "failed": 0,15495 "passed": 015496 },15497 "per_model_usage": null,15498 "per_testing_criteria_results": null,15499 "data_source": {15500 "type": "completions",15501 "source": {15502 "type": "file_content",15503 "content": [15504 {15505 "item": {15506 "input": "Tech Company Launches Advanced Artificial Intelligence Platform",15507 "ground_truth": "Technology"15508 }15509 },15510 {15511 "item": {15512 "input": "Central Bank Increases Interest Rates Amid Inflation Concerns",15513 "ground_truth": "Markets"15514 }15515 },15516 {15517 "item": {15518 "input": "International Summit Addresses Climate Change Strategies",15519 "ground_truth": "World"15520 }15521 },15522 {15523 "item": {15524 "input": "Major Retailer Reports Record-Breaking Holiday Sales",15525 "ground_truth": "Business"15526 }15527 },15528 {15529 "item": {15530 "input": "National Team Qualifies for World Championship Finals",15531 "ground_truth": "Sports"15532 }15533 },15534 {15535 "item": {15536 "input": "Stock Markets Rally After Positive Economic Data Released",15537 "ground_truth": "Markets"15538 }15539 },15540 {15541 "item": {15542 "input": "Global Manufacturer Announces Merger with Competitor",15543 "ground_truth": "Business"15544 }15545 },15546 {15547 "item": {15548 "input": "Breakthrough in Renewable Energy Technology Unveiled",15549 "ground_truth": "Technology"15550 }15551 },15552 {15553 "item": {15554 "input": "World Leaders Sign Historic Climate Agreement",15555 "ground_truth": "World"15556 }15557 },15558 {15559 "item": {15560 "input": "Professional Athlete Sets New Record in Championship Event",15561 "ground_truth": "Sports"15562 }15563 },15564 {15565 "item": {15566 "input": "Financial Institutions Adapt to New Regulatory Requirements",15567 "ground_truth": "Business"15568 }15569 },15570 {15571 "item": {15572 "input": "Tech Conference Showcases Advances in Artificial Intelligence",15573 "ground_truth": "Technology"15574 }15575 },15576 {15577 "item": {15578 "input": "Global Markets Respond to Oil Price Fluctuations",15579 "ground_truth": "Markets"15580 }15581 },15582 {15583 "item": {15584 "input": "International Cooperation Strengthened Through New Treaty",15585 "ground_truth": "World"15586 }15587 },15588 {15589 "item": {15590 "input": "Sports League Announces Revised Schedule for Upcoming Season",15591 "ground_truth": "Sports"15592 }15593 }15594 ]15595 },15596 "input_messages": {15597 "type": "template",15598 "template": [15599 {15600 "type": "message",15601 "role": "developer",15602 "content": {15603 "type": "input_text",15604 "text": "Categorize a given news headline into one of the following topics: Technology, Markets, World, Business, or Sports.\n\n# Steps\n\n1. Analyze the content of the news headline to understand its primary focus.\n2. Extract the subject matter, identifying any key indicators or keywords.\n3. Use the identified indicators to determine the most suitable category out of the five options: Technology, Markets, World, Business, or Sports.\n4. Ensure only one category is selected per headline.\n\n# Output Format\n\nRespond with the chosen category as a single word. For instance: \"Technology\", \"Markets\", \"World\", \"Business\", or \"Sports\".\n\n# Examples\n\n**Input**: \"Apple Unveils New iPhone Model, Featuring Advanced AI Features\" \n**Output**: \"Technology\"\n\n**Input**: \"Global Stocks Mixed as Investors Await Central Bank Decisions\" \n**Output**: \"Markets\"\n\n**Input**: \"War in Ukraine: Latest Updates on Negotiation Status\" \n**Output**: \"World\"\n\n**Input**: \"Microsoft in Talks to Acquire Gaming Company for $2 Billion\" \n**Output**: \"Business\"\n\n**Input**: \"Manchester United Secures Win in Premier League Football Match\" \n**Output**: \"Sports\" \n\n# Notes\n\n- If the headline appears to fit into more than one category, choose the most dominant theme.\n- Keywords or phrases such as \"stocks\", \"company acquisition\", \"match\", or technological brands can be good indicators for classification.\n"15605 }15606 },15607 {15608 "type": "message",15609 "role": "user",15610 "content": {15611 "type": "input_text",15612 "text": "{{item.input}}"15613 }15614 }15615 ]15616 },15617 "model": "gpt-6-astra",15618 "sampling_params": {15619 "max_completions_tokens": 204815620 }15621 },15622 "error": null,15623 "metadata": {}15624}15625```1562615627## Domain Types1562815629### Create Eval Completions Run Data Source1563015631- `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`1563215633 A CompletionsRunDataSource object describing a model sampling configuration.1563415635 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`1563615637 Determines what populates the `item` namespace in this run's data source.1563815639 - `EvalJSONLFileContentSource object { content, type }`1564015641 - `content: array of object { item, sample }`1564215643 The content of the jsonl file.1564415645 - `item: map[unknown]`1564615647 - `sample: optional map[unknown]`1564815649 - `type: "file_content"`1565015651 The type of jsonl source. Always `file_content`.1565215653 - `"file_content"`1565415655 - `EvalJSONLFileIDSource object { id, type }`1565615657 - `id: string`1565815659 The identifier of the file.1566015661 - `type: "file_id"`1566215663 The type of jsonl source. Always `file_id`.1566415665 - `"file_id"`1566615667 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`1566815669 A StoredCompletionsRunDataSource configuration describing a set of filters1567015671 - `type: "stored_completions"`1567215673 The type of source. Always `stored_completions`.1567415675 - `"stored_completions"`1567615677 - `created_after: optional number or null`1567815679 An optional Unix timestamp to filter items created after this time.1568015681 - `created_before: optional number or null`1568215683 An optional Unix timestamp to filter items created before this time.1568415685 - `limit: optional number or null`1568615687 An optional maximum number of items to return.1568815689 - `metadata: optional Metadata or null`1569015691 Set of 16 key-value pairs that can be attached to an object. This can be15692 useful for storing additional information about the object in a structured15693 format, and querying for objects via API or the dashboard.1569415695 Keys are strings with a maximum length of 64 characters. Values are strings15696 with a maximum length of 512 characters.1569715698 - `model: optional string or null`1569915700 An optional model to filter by (e.g., 'gpt-6-astra').1570115702 - `type: "completions"`1570315704 The type of run data source. Always `completions`.1570515706 - `"completions"`1570715708 - `input_messages: optional object { template, type } or object { item_reference, type }`1570915710 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1571115712 - `TemplateInputMessages object { template, type }`1571315714 - `template: array of EasyInputMessage or object { content, role, type }`1571515716 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1571715718 - `EasyInputMessage object { content, role, phase, type }`1571915720 A message input to the model with a role indicating instruction following15721 hierarchy. Instructions given with the `developer` or `system` role take15722 precedence over instructions given with the `user` role. Messages with the15723 `assistant` role are presumed to have been generated by the model in previous15724 interactions.1572515726 - `content: string or ResponseInputMessageContentList`1572715728 Text, image, or audio input to the model, used to generate a response.15729 Can also contain previous assistant responses.1573015731 - `TextInput = string`1573215733 A text input to the model.1573415735 - `ResponseInputMessageContentList = array of ResponseInputContent`1573615737 A list of one or many input items to the model, containing different content15738 types.1573915740 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1574115742 A text input to the model.1574315744 - `text: string`1574515746 The text input to the model.1574715748 - `type: "input_text"`1574915750 The type of the input item. Always `input_text`.1575115752 - `"input_text"`1575315754 - `prompt_cache_breakpoint: optional object { mode }`1575515756 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1575715758 - `mode: "explicit"`1575915760 The breakpoint mode. Always `explicit`.1576115762 - `"explicit"`1576315764 - `ResponseInputImage object { detail, type, file_id, 2 more }`1576515766 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).1576715768 - `detail: ImageDetail`1576915770 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.1577115772 - `"low"`1577315774 - `"high"`1577515776 - `"auto"`1577715778 - `"original"`1577915780 - `type: "input_image"`1578115782 The type of the input item. Always `input_image`.1578315784 - `"input_image"`1578515786 - `file_id: optional string or null`1578715788 The ID of the file to be sent to the model.1578915790 - `image_url: optional string or null`1579115792 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.1579315794 - `prompt_cache_breakpoint: optional object { mode }`1579515796 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1579715798 - `mode: "explicit"`1579915800 The breakpoint mode. Always `explicit`.1580115802 - `"explicit"`1580315804 - `ResponseInputFile object { type, detail, file_data, 4 more }`1580515806 A file input to the model.1580715808 - `type: "input_file"`1580915810 The type of the input item. Always `input_file`.1581115812 - `"input_file"`1581315814 - `detail: optional "auto" or "low" or "high"`1581515816 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.1581715818 - `"auto"`1581915820 - `"low"`1582115822 - `"high"`1582315824 - `file_data: optional string`1582515826 The content of the file to be sent to the model.1582715828 - `file_id: optional string or null`1582915830 The ID of the file to be sent to the model.1583115832 - `file_url: optional string`1583315834 The URL of the file to be sent to the model.1583515836 - `filename: optional string`1583715838 The name of the file to be sent to the model.1583915840 - `prompt_cache_breakpoint: optional object { mode }`1584115842 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1584315844 - `mode: "explicit"`1584515846 The breakpoint mode. Always `explicit`.1584715848 - `"explicit"`1584915850 - `role: "user" or "assistant" or "system" or "developer"`1585115852 The role of the message input. One of `user`, `assistant`, `system`, or15853 `developer`.1585415855 - `"user"`1585615857 - `"assistant"`1585815859 - `"system"`1586015861 - `"developer"`1586215863 - `phase: optional "commentary" or "final_answer" or null`1586415865 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).15866 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend15867 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.1586815869 - `"commentary"`1587015871 - `"final_answer"`1587215873 - `type: optional "message"`1587415875 The type of the message input. Always `message`.1587615877 - `"message"`1587815879 - `EvalMessageObject object { content, role, type }`1588015881 A message input to the model with a role indicating instruction following15882 hierarchy. Instructions given with the `developer` or `system` role take15883 precedence over instructions given with the `user` role. Messages with the15884 `assistant` role are presumed to have been generated by the model in previous15885 interactions.1588615887 - `content: string or ResponseInputText or object { text, type } or 3 more`1588815889 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1589015891 - `TextInput = string`1589215893 A text input to the model.1589415895 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1589615897 A text input to the model.1589815899 - `OutputText object { text, type }`1590015901 A text output from the model.1590215903 - `text: string`1590415905 The text output from the model.1590615907 - `type: "output_text"`1590815909 The type of the output text. Always `output_text`.1591015911 - `"output_text"`1591215913 - `InputImage object { image_url, type, detail }`1591415915 An image input block used within EvalItem content arrays.1591615917 - `image_url: string`1591815919 The URL of the image input.1592015921 - `type: "input_image"`1592215923 The type of the image input. Always `input_image`.1592415925 - `"input_image"`1592615927 - `detail: optional string`1592815929 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1593015931 - `ResponseInputAudio object { input_audio, type }`1593215933 An audio input to the model.1593415935 - `input_audio: object { data, format }`1593615937 - `data: string`1593815939 Base64-encoded audio data.1594015941 - `format: "mp3" or "wav"`1594215943 The format of the audio data. Currently supported formats are `mp3` and15944 `wav`.1594515946 - `"mp3"`1594715948 - `"wav"`1594915950 - `type: "input_audio"`1595115952 The type of the input item. Always `input_audio`.1595315954 - `"input_audio"`1595515956 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1595715958 A list of inputs, each of which may be either an input text, output text, input15959 image, or input audio object.1596015961 - `TextInput = string`1596215963 A text input to the model.1596415965 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1596615967 A text input to the model.1596815969 - `OutputText object { text, type }`1597015971 A text output from the model.1597215973 - `text: string`1597415975 The text output from the model.1597615977 - `type: "output_text"`1597815979 The type of the output text. Always `output_text`.1598015981 - `"output_text"`1598215983 - `InputImage object { image_url, type, detail }`1598415985 An image input block used within EvalItem content arrays.1598615987 - `image_url: string`1598815989 The URL of the image input.1599015991 - `type: "input_image"`1599215993 The type of the image input. Always `input_image`.1599415995 - `"input_image"`1599615997 - `detail: optional string`1599815999 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1600016001 - `ResponseInputAudio object { input_audio, type }`1600216003 An audio input to the model.1600416005 - `role: "user" or "assistant" or "system" or "developer"`1600616007 The role of the message input. One of `user`, `assistant`, `system`, or16008 `developer`.1600916010 - `"user"`1601116012 - `"assistant"`1601316014 - `"system"`1601516016 - `"developer"`1601716018 - `type: optional "message"`1601916020 The type of the message input. Always `message`.1602116022 - `"message"`1602316024 - `type: "template"`1602516026 The type of input messages. Always `template`.1602716028 - `"template"`1602916030 - `ItemReferenceInputMessages object { item_reference, type }`1603116032 - `item_reference: string`1603316034 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"1603516036 - `type: "item_reference"`1603716038 The type of input messages. Always `item_reference`.1603916040 - `"item_reference"`1604116042 - `model: optional string`1604316044 The name of the model to use for generating completions (e.g. "o3-mini").1604516046 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`1604716048 - `max_completion_tokens: optional number`1604916050 The maximum number of tokens in the generated output.1605116052 - `reasoning_effort: optional ReasoningEffort or null`1605316054 Constrains effort on reasoning for reasoning models. Currently supported16055 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.16056 Reducing reasoning effort can result in faster responses and fewer tokens16057 used on reasoning in a response. Not all reasoning models support every16058 value. See the16059 [reasoning guide](/api/docs/guides/reasoning)16060 for model-specific support.1606116062 - `"none"`1606316064 - `"minimal"`1606516066 - `"low"`1606716068 - `"medium"`1606916070 - `"high"`1607116072 - `"xhigh"`1607316074 - `"max"`1607516076 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`1607716078 An object specifying the format that the model must output.1607916080 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables16081 Structured Outputs which ensures the model will match your supplied JSON16082 schema. Learn more in the [Structured Outputs16083 guide](/api/docs/guides/structured-outputs).1608416085 Setting to `{ "type": "json_object" }` enables the older JSON mode, which16086 ensures the message the model generates is valid JSON. Using `json_schema`16087 is preferred for models that support it.1608816089 - `ResponseFormatText object { type }`1609016091 Default response format. Used to generate text responses.1609216093 - `type: "text"`1609416095 The type of response format being defined. Always `text`.1609616097 - `"text"`1609816099 - `ResponseFormatJSONSchema object { json_schema, type }`1610016101 JSON Schema response format. Used to generate structured JSON responses.16102 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1610316104 - `json_schema: object { name, description, schema, strict }`1610516106 Structured Outputs configuration options, including a JSON Schema.1610716108 - `name: string`1610916110 The name of the response format. Must be a-z, A-Z, 0-9, or contain16111 underscores and dashes, with a maximum length of 64.1611216113 - `description: optional string`1611416115 A description of what the response format is for, used by the model to16116 determine how to respond in the format.1611716118 - `schema: optional map[unknown]`1611916120 The schema for the response format, described as a JSON Schema object.16121 Learn how to build JSON schemas [here](https://json-schema.org/).1612216123 - `strict: optional boolean or null`1612416125 Whether to enable strict schema adherence when generating the output.16126 If set to true, the model will always follow the exact schema defined16127 in the `schema` field. Only a subset of JSON Schema is supported when16128 `strict` is `true`. To learn more, read the [Structured Outputs16129 guide](/api/docs/guides/structured-outputs).1613016131 - `type: "json_schema"`1613216133 The type of response format being defined. Always `json_schema`.1613416135 - `"json_schema"`1613616137 - `ResponseFormatJSONObject object { type }`1613816139 JSON object response format. An older method of generating JSON responses.16140 Using `json_schema` is recommended for models that support it. Note that the16141 model will not generate JSON without a system or user message instructing it16142 to do so.1614316144 - `type: "json_object"`1614516146 The type of response format being defined. Always `json_object`.1614716148 - `"json_object"`1614916150 - `seed: optional number`1615116152 A seed value to initialize the randomness, during sampling.1615316154 - `temperature: optional number`1615516156 A higher temperature increases randomness in the outputs.1615716158 - `tools: optional array of ChatCompletionFunctionTool`1615916160 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.1616116162 - `function: FunctionDefinition`1616316164 - `name: string`1616516166 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.1616716168 - `description: optional string`1616916170 A description of what the function does, used by the model to choose when and how to call the function.1617116172 - `parameters: optional FunctionParameters`1617316174 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.1617516176 Omitting `parameters` defines a function with an empty parameter list.1617716178 - `strict: optional boolean or null`1617916180 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).1618116182 - `type: "function"`1618316184 The type of the tool. Currently, only `function` is supported.1618516186 - `"function"`1618716188 - `top_p: optional number`1618916190 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1619116192### Create Eval JSONL Run Data Source1619316194- `CreateEvalJSONLRunDataSource object { source, type }`1619516196 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval1619716198 - `source: object { content, type } or object { id, type }`1619916200 Determines what populates the `item` namespace in the data source.1620116202 - `EvalJSONLFileContentSource object { content, type }`1620316204 - `content: array of object { item, sample }`1620516206 The content of the jsonl file.1620716208 - `item: map[unknown]`1620916210 - `sample: optional map[unknown]`1621116212 - `type: "file_content"`1621316214 The type of jsonl source. Always `file_content`.1621516216 - `"file_content"`1621716218 - `EvalJSONLFileIDSource object { id, type }`1621916220 - `id: string`1622116222 The identifier of the file.1622316224 - `type: "file_id"`1622516226 The type of jsonl source. Always `file_id`.1622716228 - `"file_id"`1622916230 - `type: "jsonl"`1623116232 The type of data source. Always `jsonl`.1623316234 - `"jsonl"`1623516236### Eval API Error1623716238- `EvalAPIError object { code, message }`1623916240 An object representing an error response from the Eval API.1624116242 - `code: string`1624316244 The error code.1624516246 - `message: string`1624716248 The error message.1624916250### Run Cancel Response1625116252- `RunCancelResponse object { id, created_at, data_source, 11 more }`1625316254 A schema representing an evaluation run.1625516256 - `id: string`1625716258 Unique identifier for the evaluation run.1625916260 - `created_at: number`1626116262 Unix timestamp (in seconds) when the evaluation run was created.1626316264 - `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`1626516266 Information about the run's data source.1626716268 - `CreateEvalJSONLRunDataSource object { source, type }`1626916270 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval1627116272 - `source: object { content, type } or object { id, type }`1627316274 Determines what populates the `item` namespace in the data source.1627516276 - `EvalJSONLFileContentSource object { content, type }`1627716278 - `content: array of object { item, sample }`1627916280 The content of the jsonl file.1628116282 - `item: map[unknown]`1628316284 - `sample: optional map[unknown]`1628516286 - `type: "file_content"`1628716288 The type of jsonl source. Always `file_content`.1628916290 - `"file_content"`1629116292 - `EvalJSONLFileIDSource object { id, type }`1629316294 - `id: string`1629516296 The identifier of the file.1629716298 - `type: "file_id"`1629916300 The type of jsonl source. Always `file_id`.1630116302 - `"file_id"`1630316304 - `type: "jsonl"`1630516306 The type of data source. Always `jsonl`.1630716308 - `"jsonl"`1630916310 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`1631116312 A CompletionsRunDataSource object describing a model sampling configuration.1631316314 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`1631516316 Determines what populates the `item` namespace in this run's data source.1631716318 - `EvalJSONLFileContentSource object { content, type }`1631916320 - `content: array of object { item, sample }`1632116322 The content of the jsonl file.1632316324 - `item: map[unknown]`1632516326 - `sample: optional map[unknown]`1632716328 - `type: "file_content"`1632916330 The type of jsonl source. Always `file_content`.1633116332 - `"file_content"`1633316334 - `EvalJSONLFileIDSource object { id, type }`1633516336 - `id: string`1633716338 The identifier of the file.1633916340 - `type: "file_id"`1634116342 The type of jsonl source. Always `file_id`.1634316344 - `"file_id"`1634516346 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`1634716348 A StoredCompletionsRunDataSource configuration describing a set of filters1634916350 - `type: "stored_completions"`1635116352 The type of source. Always `stored_completions`.1635316354 - `"stored_completions"`1635516356 - `created_after: optional number or null`1635716358 An optional Unix timestamp to filter items created after this time.1635916360 - `created_before: optional number or null`1636116362 An optional Unix timestamp to filter items created before this time.1636316364 - `limit: optional number or null`1636516366 An optional maximum number of items to return.1636716368 - `metadata: optional Metadata or null`1636916370 Set of 16 key-value pairs that can be attached to an object. This can be16371 useful for storing additional information about the object in a structured16372 format, and querying for objects via API or the dashboard.1637316374 Keys are strings with a maximum length of 64 characters. Values are strings16375 with a maximum length of 512 characters.1637616377 - `model: optional string or null`1637816379 An optional model to filter by (e.g., 'gpt-6-astra').1638016381 - `type: "completions"`1638216383 The type of run data source. Always `completions`.1638416385 - `"completions"`1638616387 - `input_messages: optional object { template, type } or object { item_reference, type }`1638816389 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1639016391 - `TemplateInputMessages object { template, type }`1639216393 - `template: array of EasyInputMessage or object { content, role, type }`1639416395 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1639616397 - `EasyInputMessage object { content, role, phase, type }`1639816399 A message input to the model with a role indicating instruction following16400 hierarchy. Instructions given with the `developer` or `system` role take16401 precedence over instructions given with the `user` role. Messages with the16402 `assistant` role are presumed to have been generated by the model in previous16403 interactions.1640416405 - `content: string or ResponseInputMessageContentList`1640616407 Text, image, or audio input to the model, used to generate a response.16408 Can also contain previous assistant responses.1640916410 - `TextInput = string`1641116412 A text input to the model.1641316414 - `ResponseInputMessageContentList = array of ResponseInputContent`1641516416 A list of one or many input items to the model, containing different content16417 types.1641816419 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1642016421 A text input to the model.1642216423 - `text: string`1642416425 The text input to the model.1642616427 - `type: "input_text"`1642816429 The type of the input item. Always `input_text`.1643016431 - `"input_text"`1643216433 - `prompt_cache_breakpoint: optional object { mode }`1643416435 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1643616437 - `mode: "explicit"`1643816439 The breakpoint mode. Always `explicit`.1644016441 - `"explicit"`1644216443 - `ResponseInputImage object { detail, type, file_id, 2 more }`1644416445 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).1644616447 - `detail: ImageDetail`1644816449 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.1645016451 - `"low"`1645216453 - `"high"`1645416455 - `"auto"`1645616457 - `"original"`1645816459 - `type: "input_image"`1646016461 The type of the input item. Always `input_image`.1646216463 - `"input_image"`1646416465 - `file_id: optional string or null`1646616467 The ID of the file to be sent to the model.1646816469 - `image_url: optional string or null`1647016471 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.1647216473 - `prompt_cache_breakpoint: optional object { mode }`1647416475 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1647616477 - `mode: "explicit"`1647816479 The breakpoint mode. Always `explicit`.1648016481 - `"explicit"`1648216483 - `ResponseInputFile object { type, detail, file_data, 4 more }`1648416485 A file input to the model.1648616487 - `type: "input_file"`1648816489 The type of the input item. Always `input_file`.1649016491 - `"input_file"`1649216493 - `detail: optional "auto" or "low" or "high"`1649416495 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.1649616497 - `"auto"`1649816499 - `"low"`1650016501 - `"high"`1650216503 - `file_data: optional string`1650416505 The content of the file to be sent to the model.1650616507 - `file_id: optional string or null`1650816509 The ID of the file to be sent to the model.1651016511 - `file_url: optional string`1651216513 The URL of the file to be sent to the model.1651416515 - `filename: optional string`1651616517 The name of the file to be sent to the model.1651816519 - `prompt_cache_breakpoint: optional object { mode }`1652016521 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1652216523 - `mode: "explicit"`1652416525 The breakpoint mode. Always `explicit`.1652616527 - `"explicit"`1652816529 - `role: "user" or "assistant" or "system" or "developer"`1653016531 The role of the message input. One of `user`, `assistant`, `system`, or16532 `developer`.1653316534 - `"user"`1653516536 - `"assistant"`1653716538 - `"system"`1653916540 - `"developer"`1654116542 - `phase: optional "commentary" or "final_answer" or null`1654316544 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).16545 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend16546 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.1654716548 - `"commentary"`1654916550 - `"final_answer"`1655116552 - `type: optional "message"`1655316554 The type of the message input. Always `message`.1655516556 - `"message"`1655716558 - `EvalMessageObject object { content, role, type }`1655916560 A message input to the model with a role indicating instruction following16561 hierarchy. Instructions given with the `developer` or `system` role take16562 precedence over instructions given with the `user` role. Messages with the16563 `assistant` role are presumed to have been generated by the model in previous16564 interactions.1656516566 - `content: string or ResponseInputText or object { text, type } or 3 more`1656716568 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1656916570 - `TextInput = string`1657116572 A text input to the model.1657316574 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1657516576 A text input to the model.1657716578 - `OutputText object { text, type }`1657916580 A text output from the model.1658116582 - `text: string`1658316584 The text output from the model.1658516586 - `type: "output_text"`1658716588 The type of the output text. Always `output_text`.1658916590 - `"output_text"`1659116592 - `InputImage object { image_url, type, detail }`1659316594 An image input block used within EvalItem content arrays.1659516596 - `image_url: string`1659716598 The URL of the image input.1659916600 - `type: "input_image"`1660116602 The type of the image input. Always `input_image`.1660316604 - `"input_image"`1660516606 - `detail: optional string`1660716608 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1660916610 - `ResponseInputAudio object { input_audio, type }`1661116612 An audio input to the model.1661316614 - `input_audio: object { data, format }`1661516616 - `data: string`1661716618 Base64-encoded audio data.1661916620 - `format: "mp3" or "wav"`1662116622 The format of the audio data. Currently supported formats are `mp3` and16623 `wav`.1662416625 - `"mp3"`1662616627 - `"wav"`1662816629 - `type: "input_audio"`1663016631 The type of the input item. Always `input_audio`.1663216633 - `"input_audio"`1663416635 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1663616637 A list of inputs, each of which may be either an input text, output text, input16638 image, or input audio object.1663916640 - `TextInput = string`1664116642 A text input to the model.1664316644 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1664516646 A text input to the model.1664716648 - `OutputText object { text, type }`1664916650 A text output from the model.1665116652 - `text: string`1665316654 The text output from the model.1665516656 - `type: "output_text"`1665716658 The type of the output text. Always `output_text`.1665916660 - `"output_text"`1666116662 - `InputImage object { image_url, type, detail }`1666316664 An image input block used within EvalItem content arrays.1666516666 - `image_url: string`1666716668 The URL of the image input.1666916670 - `type: "input_image"`1667116672 The type of the image input. Always `input_image`.1667316674 - `"input_image"`1667516676 - `detail: optional string`1667716678 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1667916680 - `ResponseInputAudio object { input_audio, type }`1668116682 An audio input to the model.1668316684 - `role: "user" or "assistant" or "system" or "developer"`1668516686 The role of the message input. One of `user`, `assistant`, `system`, or16687 `developer`.1668816689 - `"user"`1669016691 - `"assistant"`1669216693 - `"system"`1669416695 - `"developer"`1669616697 - `type: optional "message"`1669816699 The type of the message input. Always `message`.1670016701 - `"message"`1670216703 - `type: "template"`1670416705 The type of input messages. Always `template`.1670616707 - `"template"`1670816709 - `ItemReferenceInputMessages object { item_reference, type }`1671016711 - `item_reference: string`1671216713 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"1671416715 - `type: "item_reference"`1671616717 The type of input messages. Always `item_reference`.1671816719 - `"item_reference"`1672016721 - `model: optional string`1672216723 The name of the model to use for generating completions (e.g. "o3-mini").1672416725 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`1672616727 - `max_completion_tokens: optional number`1672816729 The maximum number of tokens in the generated output.1673016731 - `reasoning_effort: optional ReasoningEffort or null`1673216733 Constrains effort on reasoning for reasoning models. Currently supported16734 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.16735 Reducing reasoning effort can result in faster responses and fewer tokens16736 used on reasoning in a response. Not all reasoning models support every16737 value. See the16738 [reasoning guide](/api/docs/guides/reasoning)16739 for model-specific support.1674016741 - `"none"`1674216743 - `"minimal"`1674416745 - `"low"`1674616747 - `"medium"`1674816749 - `"high"`1675016751 - `"xhigh"`1675216753 - `"max"`1675416755 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`1675616757 An object specifying the format that the model must output.1675816759 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables16760 Structured Outputs which ensures the model will match your supplied JSON16761 schema. Learn more in the [Structured Outputs16762 guide](/api/docs/guides/structured-outputs).1676316764 Setting to `{ "type": "json_object" }` enables the older JSON mode, which16765 ensures the message the model generates is valid JSON. Using `json_schema`16766 is preferred for models that support it.1676716768 - `ResponseFormatText object { type }`1676916770 Default response format. Used to generate text responses.1677116772 - `type: "text"`1677316774 The type of response format being defined. Always `text`.1677516776 - `"text"`1677716778 - `ResponseFormatJSONSchema object { json_schema, type }`1677916780 JSON Schema response format. Used to generate structured JSON responses.16781 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1678216783 - `json_schema: object { name, description, schema, strict }`1678416785 Structured Outputs configuration options, including a JSON Schema.1678616787 - `name: string`1678816789 The name of the response format. Must be a-z, A-Z, 0-9, or contain16790 underscores and dashes, with a maximum length of 64.1679116792 - `description: optional string`1679316794 A description of what the response format is for, used by the model to16795 determine how to respond in the format.1679616797 - `schema: optional map[unknown]`1679816799 The schema for the response format, described as a JSON Schema object.16800 Learn how to build JSON schemas [here](https://json-schema.org/).1680116802 - `strict: optional boolean or null`1680316804 Whether to enable strict schema adherence when generating the output.16805 If set to true, the model will always follow the exact schema defined16806 in the `schema` field. Only a subset of JSON Schema is supported when16807 `strict` is `true`. To learn more, read the [Structured Outputs16808 guide](/api/docs/guides/structured-outputs).1680916810 - `type: "json_schema"`1681116812 The type of response format being defined. Always `json_schema`.1681316814 - `"json_schema"`1681516816 - `ResponseFormatJSONObject object { type }`1681716818 JSON object response format. An older method of generating JSON responses.16819 Using `json_schema` is recommended for models that support it. Note that the16820 model will not generate JSON without a system or user message instructing it16821 to do so.1682216823 - `type: "json_object"`1682416825 The type of response format being defined. Always `json_object`.1682616827 - `"json_object"`1682816829 - `seed: optional number`1683016831 A seed value to initialize the randomness, during sampling.1683216833 - `temperature: optional number`1683416835 A higher temperature increases randomness in the outputs.1683616837 - `tools: optional array of ChatCompletionFunctionTool`1683816839 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.1684016841 - `function: FunctionDefinition`1684216843 - `name: string`1684416845 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.1684616847 - `description: optional string`1684816849 A description of what the function does, used by the model to choose when and how to call the function.1685016851 - `parameters: optional FunctionParameters`1685216853 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.1685416855 Omitting `parameters` defines a function with an empty parameter list.1685616857 - `strict: optional boolean or null`1685816859 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).1686016861 - `type: "function"`1686216863 The type of the tool. Currently, only `function` is supported.1686416865 - `"function"`1686616867 - `top_p: optional number`1686816869 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1687016871 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`1687216873 A ResponsesRunDataSource object describing a model sampling configuration.1687416875 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`1687616877 Determines what populates the `item` namespace in this run's data source.1687816879 - `EvalJSONLFileContentSource object { content, type }`1688016881 - `content: array of object { item, sample }`1688216883 The content of the jsonl file.1688416885 - `item: map[unknown]`1688616887 - `sample: optional map[unknown]`1688816889 - `type: "file_content"`1689016891 The type of jsonl source. Always `file_content`.1689216893 - `"file_content"`1689416895 - `EvalJSONLFileIDSource object { id, type }`1689616897 - `id: string`1689816899 The identifier of the file.1690016901 - `type: "file_id"`1690216903 The type of jsonl source. Always `file_id`.1690416905 - `"file_id"`1690616907 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`1690816909 A EvalResponsesSource object describing a run data source configuration.1691016911 - `type: "responses"`1691216913 The type of run data source. Always `responses`.1691416915 - `"responses"`1691616917 - `created_after: optional number or null`1691816919 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.1692016921 - `created_before: optional number or null`1692216923 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.1692416925 - `instructions_search: optional string or null`1692616927 Optional string to search the 'instructions' field. This is a query parameter used to select responses.1692816929 - `metadata: optional unknown or null`1693016931 Metadata filter for the responses. This is a query parameter used to select responses.1693216933 - `model: optional string or null`1693416935 The name of the model to find responses for. This is a query parameter used to select responses.1693616937 - `reasoning_effort: optional ReasoningEffort or null`1693816939 Constrains effort on reasoning for reasoning models. Currently supported16940 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.16941 Reducing reasoning effort can result in faster responses and fewer tokens16942 used on reasoning in a response. Not all reasoning models support every16943 value. See the16944 [reasoning guide](/api/docs/guides/reasoning)16945 for model-specific support.1694616947 - `temperature: optional number or null`1694816949 Sampling temperature. This is a query parameter used to select responses.1695016951 - `tools: optional array of string or null`1695216953 List of tool names. This is a query parameter used to select responses.1695416955 - `top_p: optional number or null`1695616957 Nucleus sampling parameter. This is a query parameter used to select responses.1695816959 - `users: optional array of string or null`1696016961 List of user identifiers. This is a query parameter used to select responses.1696216963 - `type: "responses"`1696416965 The type of run data source. Always `responses`.1696616967 - `"responses"`1696816969 - `input_messages: optional object { template, type } or object { item_reference, type }`1697016971 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1697216973 - `InputMessagesTemplate object { template, type }`1697416975 - `template: array of object { content, role } or object { content, role, type }`1697616977 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1697816979 - `ChatMessage object { content, role }`1698016981 - `content: string`1698216983 The content of the message.1698416985 - `role: string`1698616987 The role of the message (e.g. "system", "assistant", "user").1698816989 - `EvalMessageObject object { content, role, type }`1699016991 A message input to the model with a role indicating instruction following16992 hierarchy. Instructions given with the `developer` or `system` role take16993 precedence over instructions given with the `user` role. Messages with the16994 `assistant` role are presumed to have been generated by the model in previous16995 interactions.1699616997 - `content: string or ResponseInputText or object { text, type } or 3 more`1699816999 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1700017001 - `TextInput = string`1700217003 A text input to the model.1700417005 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1700617007 A text input to the model.1700817009 - `OutputText object { text, type }`1701017011 A text output from the model.1701217013 - `text: string`1701417015 The text output from the model.1701617017 - `type: "output_text"`1701817019 The type of the output text. Always `output_text`.1702017021 - `"output_text"`1702217023 - `InputImage object { image_url, type, detail }`1702417025 An image input block used within EvalItem content arrays.1702617027 - `image_url: string`1702817029 The URL of the image input.1703017031 - `type: "input_image"`1703217033 The type of the image input. Always `input_image`.1703417035 - `"input_image"`1703617037 - `detail: optional string`1703817039 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1704017041 - `ResponseInputAudio object { input_audio, type }`1704217043 An audio input to the model.1704417045 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1704617047 A list of inputs, each of which may be either an input text, output text, input17048 image, or input audio object.1704917050 - `role: "user" or "assistant" or "system" or "developer"`1705117052 The role of the message input. One of `user`, `assistant`, `system`, or17053 `developer`.1705417055 - `"user"`1705617057 - `"assistant"`1705817059 - `"system"`1706017061 - `"developer"`1706217063 - `type: optional "message"`1706417065 The type of the message input. Always `message`.1706617067 - `"message"`1706817069 - `type: "template"`1707017071 The type of input messages. Always `template`.1707217073 - `"template"`1707417075 - `InputMessagesItemReference object { item_reference, type }`1707617077 - `item_reference: string`1707817079 A reference to a variable in the `item` namespace. Ie, "item.name"1708017081 - `type: "item_reference"`1708217083 The type of input messages. Always `item_reference`.1708417085 - `"item_reference"`1708617087 - `model: optional string`1708817089 The name of the model to use for generating completions (e.g. "o3-mini").1709017091 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`1709217093 - `max_completion_tokens: optional number`1709417095 The maximum number of tokens in the generated output.1709617097 - `reasoning_effort: optional ReasoningEffort or null`1709817099 Constrains effort on reasoning for reasoning models. Currently supported17100 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.17101 Reducing reasoning effort can result in faster responses and fewer tokens17102 used on reasoning in a response. Not all reasoning models support every17103 value. See the17104 [reasoning guide](/api/docs/guides/reasoning)17105 for model-specific support.1710617107 - `seed: optional number`1710817109 A seed value to initialize the randomness, during sampling.1711017111 - `temperature: optional number`1711217113 A higher temperature increases randomness in the outputs.1711417115 - `text: optional object { format }`1711617117 Configuration options for a text response from the model. Can be plain17118 text or structured JSON data. Learn more:1711917120 - [Text inputs and outputs](/api/docs/guides/text)17121 - [Structured Outputs](/api/docs/guides/structured-outputs)1712217123 - `format: optional ResponseFormatTextConfig`1712417125 An object specifying the format that the model must output.1712617127 Configuring `{ "type": "json_schema" }` enables Structured Outputs,17128 which ensures the model will match your supplied JSON schema. Learn more in the17129 [Structured Outputs guide](/api/docs/guides/structured-outputs).1713017131 The default format is `{ "type": "text" }` with no additional options.1713217133 **Not recommended for gpt-4o and newer models:**1713417135 Setting to `{ "type": "json_object" }` enables the older JSON mode, which17136 ensures the message the model generates is valid JSON. Using `json_schema`17137 is preferred for models that support it.1713817139 - `ResponseFormatText object { type }`1714017141 Default response format. Used to generate text responses.1714217143 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`1714417145 JSON Schema response format. Used to generate structured JSON responses.17146 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1714717148 - `name: string`1714917150 The name of the response format. Must be a-z, A-Z, 0-9, or contain17151 underscores and dashes, with a maximum length of 64.1715217153 - `schema: map[unknown]`1715417155 The schema for the response format, described as a JSON Schema object.17156 Learn how to build JSON schemas [here](https://json-schema.org/).1715717158 - `type: "json_schema"`1715917160 The type of response format being defined. Always `json_schema`.1716117162 - `"json_schema"`1716317164 - `description: optional string`1716517166 A description of what the response format is for, used by the model to17167 determine how to respond in the format.1716817169 - `strict: optional boolean or null`1717017171 Whether to enable strict schema adherence when generating the output.17172 If set to true, the model will always follow the exact schema defined17173 in the `schema` field. Only a subset of JSON Schema is supported when17174 `strict` is `true`. To learn more, read the [Structured Outputs17175 guide](/api/docs/guides/structured-outputs).1717617177 - `ResponseFormatJSONObject object { type }`1717817179 JSON object response format. An older method of generating JSON responses.17180 Using `json_schema` is recommended for models that support it. Note that the17181 model will not generate JSON without a system or user message instructing it17182 to do so.1718317184 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`1718517186 An array of tools the model may call while generating a response. You17187 can specify which tool to use by setting the `tool_choice` parameter.1718817189 The two categories of tools you can provide the model are:1719017191 - **Built-in tools**: Tools that are provided by OpenAI that extend the17192 model's capabilities, like [web search](/api/docs/guides/tools-web-search)17193 or [file search](/api/docs/guides/tools-file-search). Learn more about17194 [built-in tools](/api/docs/guides/tools).17195 - **Function calls (custom tools)**: Functions that are defined by you,17196 enabling the model to call your own code. Learn more about17197 [function calling](/api/docs/guides/function-calling).1719817199 - `Function object { name, parameters, strict, 6 more }`1720017201 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).1720217203 - `name: string`1720417205 The name of the function to call.1720617207 - `parameters: map[unknown] or null`1720817209 A JSON schema object describing the parameters of the function.1721017211 - `strict: boolean or null`1721217213 Whether strict parameter validation is enforced for this function tool.1721417215 - `type: "function"`1721617217 The type of the function tool. Always `function`.1721817219 - `"function"`1722017221 - `allowed_callers: optional array of "direct" or "programmatic" or null`1722217223 The tool invocation context(s).1722417225 - `"direct"`1722617227 - `"programmatic"`1722817229 - `async: optional boolean`1723017231 - `defer_loading: optional boolean`1723217233 Whether this function is deferred and loaded via tool search.1723417235 - `description: optional string or null`1723617237 A description of the function. Used by the model to determine whether or not to call the function.1723817239 - `output_schema: optional map[unknown] or null`1724017241 A JSON schema object describing the JSON value encoded in string outputs for this function.1724217243 - `FileSearch object { type, vector_store_ids, filters, 2 more }`1724417245 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).1724617247 - `type: "file_search"`1724817249 The type of the file search tool. Always `file_search`.1725017251 - `"file_search"`1725217253 - `vector_store_ids: array of string`1725417255 The IDs of the vector stores to search.1725617257 - `filters: optional ComparisonFilter or CompoundFilter or null`1725817259 A filter to apply.1726017261 - `ComparisonFilter object { key, type, value }`1726217263 A filter used to compare a specified attribute key to a given value using a defined comparison operation.1726417265 - `key: string`1726617267 The key to compare against the value.1726817269 - `type: "eq" or "ne" or "gt" or 5 more`1727017271 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.1727217273 - `eq`: equals17274 - `ne`: not equal17275 - `gt`: greater than17276 - `gte`: greater than or equal17277 - `lt`: less than17278 - `lte`: less than or equal17279 - `in`: in17280 - `nin`: not in1728117282 - `"eq"`1728317284 - `"ne"`1728517286 - `"gt"`1728717288 - `"gte"`1728917290 - `"lt"`1729117292 - `"lte"`1729317294 - `"in"`1729517296 - `"nin"`1729717298 - `value: string or number or boolean or array of string or number`1729917300 The value to compare against the attribute key; supports string, number, or boolean types.1730117302 - `string`1730317304 - `number`1730517306 - `boolean`1730717308 - `array of string or number`1730917310 - `string`1731117312 - `number`1731317314 - `CompoundFilter object { filters, type }`1731517316 Combine multiple filters using `and` or `or`.1731717318 - `filters: array of ComparisonFilter or unknown`1731917320 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.1732117322 - `ComparisonFilter object { key, type, value }`1732317324 A filter used to compare a specified attribute key to a given value using a defined comparison operation.1732517326 - `unknown`1732717328 - `type: "and" or "or"`1732917330 Type of operation: `and` or `or`.1733117332 - `"and"`1733317334 - `"or"`1733517336 - `max_num_results: optional number`1733717338 The maximum number of results to return. This number should be between 1 and 50 inclusive.1733917340 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`1734117342 Ranking options for search.1734317344 - `hybrid_search: optional object { embedding_weight, text_weight }`1734517346 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.1734717348 - `embedding_weight: number`1734917350 The weight of the embedding in the reciprocal ranking fusion.1735117352 - `text_weight: number`1735317354 The weight of the text in the reciprocal ranking fusion.1735517356 - `ranker: optional "auto" or "default-2024-11-15"`1735717358 The ranker to use for the file search.1735917360 - `"auto"`1736117362 - `"default-2024-11-15"`1736317364 - `score_threshold: optional number`1736517366 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.1736717368 - `Computer object { type }`1736917370 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).1737117372 - `type: "computer"`1737317374 The type of the computer tool. Always `computer`.1737517376 - `"computer"`1737717378 - `ComputerUsePreview object { display_height, display_width, environment, type }`1737917380 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).1738117382 - `display_height: number`1738317384 The height of the computer display.1738517386 - `display_width: number`1738717388 The width of the computer display.1738917390 - `environment: "windows" or "mac" or "linux" or 2 more`1739117392 The type of computer environment to control.1739317394 - `"windows"`1739517396 - `"mac"`1739717398 - `"linux"`1739917400 - `"ubuntu"`1740117402 - `"browser"`1740317404 - `type: "computer_use_preview"`1740517406 The type of the computer use tool. Always `computer_use_preview`.1740717408 - `"computer_use_preview"`1740917410 - `WebSearch object { type, external_web_access, filters, 2 more }`1741117412 Search the Internet for sources related to the prompt. Learn more about the17413 [web search tool](/api/docs/guides/tools-web-search).1741417415 - `type: "web_search" or "web_search_2025_08_26"`1741617417 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.1741817419 - `"web_search"`1742017421 - `"web_search_2025_08_26"`1742217423 - `external_web_access: optional boolean`1742417425 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.1742617427 - `filters: optional object { allowed_domains } or null`1742817429 Filters for the search.1743017431 - `allowed_domains: optional array of string or null`1743217433 Allowed domains for the search. If not provided, all domains are allowed.17434 Subdomains of the provided domains are allowed as well.1743517436 Example: `["pubmed.ncbi.nlm.nih.gov"]`1743717438 - `search_context_size: optional "low" or "medium" or "high"`1743917440 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.1744117442 - `"low"`1744317444 - `"medium"`1744517446 - `"high"`1744717448 - `user_location: optional object { city, country, region, 2 more } or null`1744917450 The approximate location of the user.1745117452 - `city: optional string or null`1745317454 Free text input for the city of the user, e.g. `San Francisco`.1745517456 - `country: optional string or null`1745717458 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.1745917460 - `region: optional string or null`1746117462 Free text input for the region of the user, e.g. `California`.1746317464 - `timezone: optional string or null`1746517466 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.1746717468 - `type: optional "approximate"`1746917470 The type of location approximation. Always `approximate`.1747117472 - `"approximate"`1747317474 - `Mcp object { server_label, type, allowed_callers, 9 more }`1747517476 Give the model access to additional tools via remote Model Context Protocol17477 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).1747817479 - `server_label: string`1748017481 A label for this MCP server, used to identify it in tool calls.1748217483 - `type: "mcp"`1748417485 The type of the MCP tool. Always `mcp`.1748617487 - `"mcp"`1748817489 - `allowed_callers: optional array of "direct" or "programmatic" or null`1749017491 The tool invocation context(s).1749217493 - `"direct"`1749417495 - `"programmatic"`1749617497 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`1749817499 List of allowed tool names or a filter object.1750017501 - `McpAllowedTools = array of string`1750217503 A string array of allowed tool names1750417505 - `McpToolFilter object { read_only, tool_names }`1750617507 A filter object to specify which tools are allowed.1750817509 - `read_only: optional boolean`1751017511 Indicates whether or not a tool modifies data or is read-only. If an17512 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),17513 it will match this filter.1751417515 - `tool_names: optional array of string`1751617517 List of allowed tool names.1751817519 - `authorization: optional string`1752017521 An OAuth access token that can be used with a remote MCP server, either17522 with a custom MCP server URL or a service connector. Your application17523 must handle the OAuth authorization flow and provide the token here.1752417525 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`1752617527 Identifier for service connectors, like those available in ChatGPT. One of17528 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more17529 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).1753017531 This field is deprecated for models released after September 1, 2026.17532 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to17533 connect through a Secure MCP Tunnel.1753417535 Currently supported `connector_id` values are:1753617537 - Dropbox: `connector_dropbox`17538 - Gmail: `connector_gmail`17539 - Google Calendar: `connector_googlecalendar`17540 - Google Drive: `connector_googledrive`17541 - Microsoft Teams: `connector_microsoftteams`17542 - Outlook Calendar: `connector_outlookcalendar`17543 - Outlook Email: `connector_outlookemail`17544 - SharePoint: `connector_sharepoint`1754517546 - `"connector_dropbox"`1754717548 - `"connector_gmail"`1754917550 - `"connector_googlecalendar"`1755117552 - `"connector_googledrive"`1755317554 - `"connector_microsoftteams"`1755517556 - `"connector_outlookcalendar"`1755717558 - `"connector_outlookemail"`1755917560 - `"connector_sharepoint"`1756117562 - `defer_loading: optional boolean`1756317564 Whether this MCP tool is deferred and discovered via tool search.1756517566 - `headers: optional map[string] or null`1756717568 Optional HTTP headers to send to the MCP server. Use for authentication17569 or other purposes.1757017571 - `require_approval: optional object { always, never } or "always" or "never" or null`1757217573 Specify which of the MCP server's tools require approval.1757417575 - `McpToolApprovalFilter object { always, never }`1757617577 Specify which of the MCP server's tools require approval. Can be17578 `always`, `never`, or a filter object associated with tools17579 that require approval.1758017581 - `always: optional object { read_only, tool_names }`1758217583 A filter object to specify which tools are allowed.1758417585 - `read_only: optional boolean`1758617587 Indicates whether or not a tool modifies data or is read-only. If an17588 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),17589 it will match this filter.1759017591 - `tool_names: optional array of string`1759217593 List of allowed tool names.1759417595 - `never: optional object { read_only, tool_names }`1759617597 A filter object to specify which tools are allowed.1759817599 - `read_only: optional boolean`1760017601 Indicates whether or not a tool modifies data or is read-only. If an17602 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),17603 it will match this filter.1760417605 - `tool_names: optional array of string`1760617607 List of allowed tool names.1760817609 - `McpToolApprovalSetting = "always" or "never"`1761017611 Specify a single approval policy for all tools. One of `always` or17612 `never`. When set to `always`, all tools will require approval. When17613 set to `never`, all tools will not require approval.1761417615 - `"always"`1761617617 - `"never"`1761817619 - `server_description: optional string`1762017621 Optional description of the MCP server, used to provide more context.1762217623 - `server_url: optional string`1762417625 The URL for the MCP server. One of `server_url`, `connector_id`, or17626 `tunnel_id` must be provided.1762717628 - `tunnel_id: optional string`1762917630 The Secure MCP Tunnel ID to use instead of a direct server URL. One of17631 `server_url`, `connector_id`, or `tunnel_id` must be provided.1763217633 - `CodeInterpreter object { container, type, allowed_callers }`1763417635 A tool that runs Python code to help generate a response to a prompt.1763617637 - `container: string or object { type, file_ids, memory_limit, network_policy }`1763817639 The code interpreter container. Can be a container ID or an object that17640 specifies uploaded file IDs to make available to your code, along with an17641 optional `memory_limit` setting.1764217643 - `string`1764417645 The container ID.1764617647 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`1764817649 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.1765017651 - `type: "auto"`1765217653 Always `auto`.1765417655 - `"auto"`1765617657 - `file_ids: optional array of string`1765817659 An optional list of uploaded files to make available to your code.1766017661 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`1766217663 The memory limit for the code interpreter container.1766417665 - `"1g"`1766617667 - `"4g"`1766817669 - `"16g"`1767017671 - `"64g"`1767217673 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`1767417675 Network access policy for the container.1767617677 - `ContainerNetworkPolicyDisabled object { type }`1767817679 - `type: "disabled"`1768017681 Disable outbound network access. Always `disabled`.1768217683 - `"disabled"`1768417685 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`1768617687 - `allowed_domains: array of string`1768817689 A list of allowed domains when type is `allowlist`.1769017691 - `type: "allowlist"`1769217693 Allow outbound network access only to specified domains. Always `allowlist`.1769417695 - `"allowlist"`1769617697 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`1769817699 Optional domain-scoped secrets for allowlisted domains.1770017701 - `domain: string`1770217703 The domain associated with the secret.1770417705 - `name: string`1770617707 The name of the secret to inject for the domain.1770817709 - `value: string`1771017711 The secret value to inject for the domain.1771217713 - `type: "code_interpreter"`1771417715 The type of the code interpreter tool. Always `code_interpreter`.1771617717 - `"code_interpreter"`1771817719 - `allowed_callers: optional array of "direct" or "programmatic" or null`1772017721 The tool invocation context(s).1772217723 - `"direct"`1772417725 - `"programmatic"`1772617727 - `ProgrammaticToolCalling object { type }`1772817729 - `type: "programmatic_tool_calling"`1773017731 The type of the tool. Always `programmatic_tool_calling`.1773217733 - `"programmatic_tool_calling"`1773417735 - `ImageGeneration object { type, action, background, 9 more }`1773617737 A tool that generates images using the GPT image models.1773817739 - `type: "image_generation"`1774017741 The type of the image generation tool. Always `image_generation`.1774217743 - `"image_generation"`1774417745 - `action: optional "generate" or "edit" or "auto"`1774617747 Whether to generate a new image or edit an existing image. Default: `auto`.1774817749 - `"generate"`1775017751 - `"edit"`1775217753 - `"auto"`1775417755 - `background: optional "transparent" or "opaque" or "auto"`1775617757 Set the background of the generated image. One of `transparent`, `opaque`,17758 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including17759 their `2026-09-08` snapshots, support `opaque` and `transparent`17760 backgrounds. Transparent backgrounds are available for supported GPT Image17761 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in17762 preview. When using `transparent`, set the output format to `png` or `webp`.17763 Default: `auto`.1776417765 - `"transparent"`1776617767 - `"opaque"`1776817769 - `"auto"`1777017771 - `input_fidelity: optional "high" or "low" or null`1777217773 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.1777417775 - `"high"`1777617777 - `"low"`1777817779 - `input_image_mask: optional object { file_id, image_url }`1778017781 Optional mask for inpainting. Contains `image_url`17782 (string, optional) and `file_id` (string, optional).1778317784 - `file_id: optional string`1778517786 File ID for the mask image.1778717788 - `image_url: optional string`1778917790 Base64-encoded mask image.1779117792 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`1779317794 The image generation model to use. One of `gpt-image-1`,17795 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,17796 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,17797 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,17798 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:17799 `gpt-image-1`.1780017801 - `string`1780217803 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`1780417805 The image generation model to use. One of `gpt-image-1`,17806 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,17807 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,17808 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,17809 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:17810 `gpt-image-1`.1781117812 - `"gpt-image-1"`1781317814 - `"gpt-image-1-mini"`1781517816 - `"gpt-image-1.5"`1781717818 - `"gpt-image-2"`1781917820 - `"gpt-image-2-2026-04-21"`1782117822 - `"gpt-image-2.5-sunburst"`1782317824 - `"gpt-image-2.5-sunburst-2026-09-08"`1782517826 - `"gpt-image-2.5-flare"`1782717828 - `"gpt-image-2.5-flare-2026-09-08"`1782917830 - `moderation: optional "auto" or "low"`1783117832 Moderation level for the generated image. Default: `auto`.1783317834 - `"auto"`1783517836 - `"low"`1783717838 - `output_compression: optional number`1783917840 Compression level for the output image. Default: 100.1784117842 - `output_format: optional "png" or "webp" or "jpeg"`1784317844 The output format of the generated image. One of `png`, `webp`, or17845 `jpeg`. Default: `png`.1784617847 - `"png"`1784817849 - `"webp"`1785017851 - `"jpeg"`1785217853 - `partial_images: optional number`1785417855 Number of partial images to generate in streaming mode, from 0 (default value) to 3.1785617857 - `quality: optional "low" or "medium" or "high" or 3 more`1785817859 The quality of the generated image. The GPT image models support `low`,17860 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,17861 including their `2026-09-08` snapshots, also support `xhigh` and `max`.17862 Default: `auto`.1786317864 - `"low"`1786517866 - `"medium"`1786717868 - `"high"`1786917870 - `"xhigh"`1787117872 - `"max"`1787317874 - `"auto"`1787517876 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`1787717878 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.1787917880 - `string`1788117882 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`1788317884 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.1788517886 - `"1024x1024"`1788717888 - `"1024x1536"`1788917890 - `"1536x1024"`1789117892 - `"auto"`1789317894 - `LocalShell object { type }`1789517896 A tool that allows the model to execute shell commands in a local environment.1789717898 - `type: "local_shell"`1789917900 The type of the local shell tool. Always `local_shell`.1790117902 - `"local_shell"`1790317904 - `Shell object { type, allowed_callers, environment }`1790517906 A tool that allows the model to execute shell commands.1790717908 - `type: "shell"`1790917910 The type of the shell tool. Always `shell`.1791117912 - `"shell"`1791317914 - `allowed_callers: optional array of "direct" or "programmatic" or null`1791517916 The tool invocation context(s).1791717918 - `"direct"`1791917920 - `"programmatic"`1792117922 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`1792317924 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`1792517926 - `type: "container_auto"`1792717928 Automatically creates a container for this request1792917930 - `"container_auto"`1793117932 - `file_ids: optional array of string`1793317934 An optional list of uploaded files to make available to your code.1793517936 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`1793717938 The memory limit for the container.1793917940 - `"1g"`1794117942 - `"4g"`1794317944 - `"16g"`1794517946 - `"64g"`1794717948 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`1794917950 Network access policy for the container.1795117952 - `ContainerNetworkPolicyDisabled object { type }`1795317954 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`1795517956 - `skills: optional array of SkillReference or InlineSkill`1795717958 An optional list of skills referenced by id or inline data.1795917960 - `SkillReference object { skill_id, type, version }`1796117962 - `skill_id: string`1796317964 The ID of the referenced skill.1796517966 - `type: "skill_reference"`1796717968 References a skill created with the /v1/skills endpoint.1796917970 - `"skill_reference"`1797117972 - `version: optional string`1797317974 Optional skill version. Use a positive integer or 'latest'. Omit for default.1797517976 - `InlineSkill object { description, name, source, type }`1797717978 - `description: string`1797917980 The description of the skill.1798117982 - `name: string`1798317984 The name of the skill.1798517986 - `source: InlineSkillSource`1798717988 Inline skill payload1798917990 - `data: string`1799117992 Base64-encoded skill zip bundle.1799317994 - `media_type: "application/zip"`1799517996 The media type of the inline skill payload. Must be `application/zip`.1799717998 - `"application/zip"`1799918000 - `type: "base64"`1800118002 The type of the inline skill source. Must be `base64`.1800318004 - `"base64"`1800518006 - `type: "inline"`1800718008 Defines an inline skill for this request.1800918010 - `"inline"`1801118012 - `LocalEnvironment object { type, skills }`1801318014 - `type: "local"`1801518016 Use a local computer environment.1801718018 - `"local"`1801918020 - `skills: optional array of LocalSkill`1802118022 An optional list of skills.1802318024 - `description: string`1802518026 The description of the skill.1802718028 - `name: string`1802918030 The name of the skill.1803118032 - `path: string`1803318034 The path to the directory containing the skill.1803518036 - `ContainerReference object { container_id, type }`1803718038 - `container_id: string`1803918040 The ID of the referenced container.1804118042 - `type: "container_reference"`1804318044 References a container created with the /v1/containers endpoint1804518046 - `"container_reference"`1804718048 - `Custom object { name, type, allowed_callers, 4 more }`1804918050 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)1805118052 - `name: string`1805318054 The name of the custom tool, used to identify it in tool calls.1805518056 - `type: "custom"`1805718058 The type of the custom tool. Always `custom`.1805918060 - `"custom"`1806118062 - `allowed_callers: optional array of "direct" or "programmatic" or null`1806318064 The tool invocation context(s).1806518066 - `"direct"`1806718068 - `"programmatic"`1806918070 - `async: optional boolean`1807118072 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1807318074 - `defer_loading: optional boolean`1807518076 Whether this tool should be deferred and discovered via tool search.1807718078 - `description: optional string`1807918080 Optional description of the custom tool, used to provide more context.1808118082 - `format: optional CustomToolInputFormat`1808318084 The input format for the custom tool. Default is unconstrained text.1808518086 - `Text object { type }`1808718088 Unconstrained free-form text.1808918090 - `type: "text"`1809118092 Unconstrained text format. Always `text`.1809318094 - `"text"`1809518096 - `Grammar object { definition, syntax, type }`1809718098 A grammar defined by the user.1809918100 - `definition: string`1810118102 The grammar definition.1810318104 - `syntax: "lark" or "regex"`1810518106 The syntax of the grammar definition. One of `lark` or `regex`.1810718108 - `"lark"`1810918110 - `"regex"`1811118112 - `type: "grammar"`1811318114 Grammar format. Always `grammar`.1811518116 - `"grammar"`1811718118 - `Namespace object { description, name, tools, type }`1811918120 Groups function/custom tools under a shared namespace.1812118122 - `description: string`1812318124 A description of the namespace shown to the model.1812518126 - `name: string`1812718128 The namespace name used in tool calls (for example, `crm`).1812918130 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`1813118132 The function/custom tools available inside this namespace.1813318134 - `Function object { name, type, allowed_callers, 6 more }`1813518136 - `name: string`1813718138 - `type: "function"`1813918140 - `"function"`1814118142 - `allowed_callers: optional array of "direct" or "programmatic" or null`1814318144 The tool invocation context(s).1814518146 - `"direct"`1814718148 - `"programmatic"`1814918150 - `async: optional boolean`1815118152 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1815318154 - `defer_loading: optional boolean`1815518156 Whether this function should be deferred and discovered via tool search.1815718158 - `description: optional string or null`1815918160 - `output_schema: optional map[unknown] or null`1816118162 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.1816318164 - `parameters: optional unknown or null`1816518166 - `strict: optional boolean or null`1816718168 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.1816918170 - `Custom object { name, type, allowed_callers, 4 more }`1817118172 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)1817318174 - `name: string`1817518176 The name of the custom tool, used to identify it in tool calls.1817718178 - `type: "custom"`1817918180 The type of the custom tool. Always `custom`.1818118182 - `"custom"`1818318184 - `allowed_callers: optional array of "direct" or "programmatic" or null`1818518186 The tool invocation context(s).1818718188 - `"direct"`1818918190 - `"programmatic"`1819118192 - `async: optional boolean`1819318194 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.1819518196 - `defer_loading: optional boolean`1819718198 Whether this tool should be deferred and discovered via tool search.1819918200 - `description: optional string`1820118202 Optional description of the custom tool, used to provide more context.1820318204 - `format: optional CustomToolInputFormat`1820518206 The input format for the custom tool. Default is unconstrained text.1820718208 - `type: "namespace"`1820918210 The type of the tool. Always `namespace`.1821118212 - `"namespace"`1821318214 - `ToolSearch object { type, description, execution, parameters }`1821518216 Hosted or BYOT tool search configuration for deferred tools.1821718218 - `type: "tool_search"`1821918220 The type of the tool. Always `tool_search`.1822118222 - `"tool_search"`1822318224 - `description: optional string or null`1822518226 Description shown to the model for a client-executed tool search tool.1822718228 - `execution: optional "server" or "client"`1822918230 Whether tool search is executed by the server or by the client.1823118232 - `"server"`1823318234 - `"client"`1823518236 - `parameters: optional unknown or null`1823718238 Parameter schema for a client-executed tool search tool.1823918240 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`1824118242 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).1824318244 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`1824518246 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.1824718248 - `"web_search_preview"`1824918250 - `"web_search_preview_2025_03_11"`1825118252 - `search_content_types: optional array of "text" or "image"`1825318254 - `"text"`1825518256 - `"image"`1825718258 - `search_context_size: optional "low" or "medium" or "high"`1825918260 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.1826118262 - `"low"`1826318264 - `"medium"`1826518266 - `"high"`1826718268 - `user_location: optional object { type, city, country, 2 more } or null`1826918270 The user's location.1827118272 - `type: "approximate"`1827318274 The type of location approximation. Always `approximate`.1827518276 - `"approximate"`1827718278 - `city: optional string or null`1827918280 Free text input for the city of the user, e.g. `San Francisco`.1828118282 - `country: optional string or null`1828318284 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.1828518286 - `region: optional string or null`1828718288 Free text input for the region of the user, e.g. `California`.1828918290 - `timezone: optional string or null`1829118292 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.1829318294 - `ApplyPatch object { type, allowed_callers }`1829518296 Allows the assistant to create, delete, or update files using unified diffs.1829718298 - `type: "apply_patch"`1829918300 The type of the tool. Always `apply_patch`.1830118302 - `"apply_patch"`1830318304 - `allowed_callers: optional array of "direct" or "programmatic" or null`1830518306 The tool invocation context(s).1830718308 - `"direct"`1830918310 - `"programmatic"`1831118312 - `top_p: optional number`1831318314 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1831518316 - `error: EvalAPIError`1831718318 An object representing an error response from the Eval API.1831918320 - `code: string`1832118322 The error code.1832318324 - `message: string`1832518326 The error message.1832718328 - `eval_id: string`1832918330 The identifier of the associated evaluation.1833118332 - `metadata: Metadata or null`1833318334 Set of 16 key-value pairs that can be attached to an object. This can be18335 useful for storing additional information about the object in a structured18336 format, and querying for objects via API or the dashboard.1833718338 Keys are strings with a maximum length of 64 characters. Values are strings18339 with a maximum length of 512 characters.1834018341 - `model: string`1834218343 The model that is evaluated, if applicable.1834418345 - `name: string`1834618347 The name of the evaluation run.1834818349 - `object: "eval.run"`1835018351 The type of the object. Always "eval.run".1835218353 - `"eval.run"`1835418355 - `per_model_usage: array of object { cached_tokens, completion_tokens, invocation_count, 3 more }`1835618357 Usage statistics for each model during the evaluation run.1835818359 - `cached_tokens: number`1836018361 The number of tokens retrieved from cache.1836218363 - `completion_tokens: number`1836418365 The number of completion tokens generated.1836618367 - `invocation_count: number`1836818369 The number of invocations.1837018371 - `model_name: string`1837218373 The name of the model.1837418375 - `prompt_tokens: number`1837618377 The number of prompt tokens used.1837818379 - `total_tokens: number`1838018381 The total number of tokens used.1838218383 - `per_testing_criteria_results: array of object { failed, passed, testing_criteria }`1838418385 Results per testing criteria applied during the evaluation run.1838618387 - `failed: number`1838818389 Number of tests failed for this criteria.1839018391 - `passed: number`1839218393 Number of tests passed for this criteria.1839418395 - `testing_criteria: string`1839618397 A description of the testing criteria.1839818399 - `report_url: string`1840018401 The URL to the rendered evaluation run report on the UI dashboard.1840218403 - `result_counts: object { errored, failed, passed, total }`1840418405 Counters summarizing the outcomes of the evaluation run.1840618407 - `errored: number`1840818409 Number of output items that resulted in an error.1841018411 - `failed: number`1841218413 Number of output items that failed to pass the evaluation.1841418415 - `passed: number`1841618417 Number of output items that passed the evaluation.1841818419 - `total: number`1842018421 Total number of executed output items.1842218423 - `status: string`1842418425 The status of the evaluation run.1842618427### Run Create Response1842818429- `RunCreateResponse object { id, created_at, data_source, 11 more }`1843018431 A schema representing an evaluation run.1843218433 - `id: string`1843418435 Unique identifier for the evaluation run.1843618437 - `created_at: number`1843818439 Unix timestamp (in seconds) when the evaluation run was created.1844018441 - `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`1844218443 Information about the run's data source.1844418445 - `CreateEvalJSONLRunDataSource object { source, type }`1844618447 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval1844818449 - `source: object { content, type } or object { id, type }`1845018451 Determines what populates the `item` namespace in the data source.1845218453 - `EvalJSONLFileContentSource object { content, type }`1845418455 - `content: array of object { item, sample }`1845618457 The content of the jsonl file.1845818459 - `item: map[unknown]`1846018461 - `sample: optional map[unknown]`1846218463 - `type: "file_content"`1846418465 The type of jsonl source. Always `file_content`.1846618467 - `"file_content"`1846818469 - `EvalJSONLFileIDSource object { id, type }`1847018471 - `id: string`1847218473 The identifier of the file.1847418475 - `type: "file_id"`1847618477 The type of jsonl source. Always `file_id`.1847818479 - `"file_id"`1848018481 - `type: "jsonl"`1848218483 The type of data source. Always `jsonl`.1848418485 - `"jsonl"`1848618487 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`1848818489 A CompletionsRunDataSource object describing a model sampling configuration.1849018491 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`1849218493 Determines what populates the `item` namespace in this run's data source.1849418495 - `EvalJSONLFileContentSource object { content, type }`1849618497 - `content: array of object { item, sample }`1849818499 The content of the jsonl file.1850018501 - `item: map[unknown]`1850218503 - `sample: optional map[unknown]`1850418505 - `type: "file_content"`1850618507 The type of jsonl source. Always `file_content`.1850818509 - `"file_content"`1851018511 - `EvalJSONLFileIDSource object { id, type }`1851218513 - `id: string`1851418515 The identifier of the file.1851618517 - `type: "file_id"`1851818519 The type of jsonl source. Always `file_id`.1852018521 - `"file_id"`1852218523 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`1852418525 A StoredCompletionsRunDataSource configuration describing a set of filters1852618527 - `type: "stored_completions"`1852818529 The type of source. Always `stored_completions`.1853018531 - `"stored_completions"`1853218533 - `created_after: optional number or null`1853418535 An optional Unix timestamp to filter items created after this time.1853618537 - `created_before: optional number or null`1853818539 An optional Unix timestamp to filter items created before this time.1854018541 - `limit: optional number or null`1854218543 An optional maximum number of items to return.1854418545 - `metadata: optional Metadata or null`1854618547 Set of 16 key-value pairs that can be attached to an object. This can be18548 useful for storing additional information about the object in a structured18549 format, and querying for objects via API or the dashboard.1855018551 Keys are strings with a maximum length of 64 characters. Values are strings18552 with a maximum length of 512 characters.1855318554 - `model: optional string or null`1855518556 An optional model to filter by (e.g., 'gpt-6-astra').1855718558 - `type: "completions"`1855918560 The type of run data source. Always `completions`.1856118562 - `"completions"`1856318564 - `input_messages: optional object { template, type } or object { item_reference, type }`1856518566 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1856718568 - `TemplateInputMessages object { template, type }`1856918570 - `template: array of EasyInputMessage or object { content, role, type }`1857118572 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1857318574 - `EasyInputMessage object { content, role, phase, type }`1857518576 A message input to the model with a role indicating instruction following18577 hierarchy. Instructions given with the `developer` or `system` role take18578 precedence over instructions given with the `user` role. Messages with the18579 `assistant` role are presumed to have been generated by the model in previous18580 interactions.1858118582 - `content: string or ResponseInputMessageContentList`1858318584 Text, image, or audio input to the model, used to generate a response.18585 Can also contain previous assistant responses.1858618587 - `TextInput = string`1858818589 A text input to the model.1859018591 - `ResponseInputMessageContentList = array of ResponseInputContent`1859218593 A list of one or many input items to the model, containing different content18594 types.1859518596 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1859718598 A text input to the model.1859918600 - `text: string`1860118602 The text input to the model.1860318604 - `type: "input_text"`1860518606 The type of the input item. Always `input_text`.1860718608 - `"input_text"`1860918610 - `prompt_cache_breakpoint: optional object { mode }`1861118612 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1861318614 - `mode: "explicit"`1861518616 The breakpoint mode. Always `explicit`.1861718618 - `"explicit"`1861918620 - `ResponseInputImage object { detail, type, file_id, 2 more }`1862118622 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).1862318624 - `detail: ImageDetail`1862518626 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.1862718628 - `"low"`1862918630 - `"high"`1863118632 - `"auto"`1863318634 - `"original"`1863518636 - `type: "input_image"`1863718638 The type of the input item. Always `input_image`.1863918640 - `"input_image"`1864118642 - `file_id: optional string or null`1864318644 The ID of the file to be sent to the model.1864518646 - `image_url: optional string or null`1864718648 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.1864918650 - `prompt_cache_breakpoint: optional object { mode }`1865118652 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1865318654 - `mode: "explicit"`1865518656 The breakpoint mode. Always `explicit`.1865718658 - `"explicit"`1865918660 - `ResponseInputFile object { type, detail, file_data, 4 more }`1866118662 A file input to the model.1866318664 - `type: "input_file"`1866518666 The type of the input item. Always `input_file`.1866718668 - `"input_file"`1866918670 - `detail: optional "auto" or "low" or "high"`1867118672 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.1867318674 - `"auto"`1867518676 - `"low"`1867718678 - `"high"`1867918680 - `file_data: optional string`1868118682 The content of the file to be sent to the model.1868318684 - `file_id: optional string or null`1868518686 The ID of the file to be sent to the model.1868718688 - `file_url: optional string`1868918690 The URL of the file to be sent to the model.1869118692 - `filename: optional string`1869318694 The name of the file to be sent to the model.1869518696 - `prompt_cache_breakpoint: optional object { mode }`1869718698 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.1869918700 - `mode: "explicit"`1870118702 The breakpoint mode. Always `explicit`.1870318704 - `"explicit"`1870518706 - `role: "user" or "assistant" or "system" or "developer"`1870718708 The role of the message input. One of `user`, `assistant`, `system`, or18709 `developer`.1871018711 - `"user"`1871218713 - `"assistant"`1871418715 - `"system"`1871618717 - `"developer"`1871818719 - `phase: optional "commentary" or "final_answer" or null`1872018721 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).18722 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend18723 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.1872418725 - `"commentary"`1872618727 - `"final_answer"`1872818729 - `type: optional "message"`1873018731 The type of the message input. Always `message`.1873218733 - `"message"`1873418735 - `EvalMessageObject object { content, role, type }`1873618737 A message input to the model with a role indicating instruction following18738 hierarchy. Instructions given with the `developer` or `system` role take18739 precedence over instructions given with the `user` role. Messages with the18740 `assistant` role are presumed to have been generated by the model in previous18741 interactions.1874218743 - `content: string or ResponseInputText or object { text, type } or 3 more`1874418745 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1874618747 - `TextInput = string`1874818749 A text input to the model.1875018751 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1875218753 A text input to the model.1875418755 - `OutputText object { text, type }`1875618757 A text output from the model.1875818759 - `text: string`1876018761 The text output from the model.1876218763 - `type: "output_text"`1876418765 The type of the output text. Always `output_text`.1876618767 - `"output_text"`1876818769 - `InputImage object { image_url, type, detail }`1877018771 An image input block used within EvalItem content arrays.1877218773 - `image_url: string`1877418775 The URL of the image input.1877618777 - `type: "input_image"`1877818779 The type of the image input. Always `input_image`.1878018781 - `"input_image"`1878218783 - `detail: optional string`1878418785 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1878618787 - `ResponseInputAudio object { input_audio, type }`1878818789 An audio input to the model.1879018791 - `input_audio: object { data, format }`1879218793 - `data: string`1879418795 Base64-encoded audio data.1879618797 - `format: "mp3" or "wav"`1879818799 The format of the audio data. Currently supported formats are `mp3` and18800 `wav`.1880118802 - `"mp3"`1880318804 - `"wav"`1880518806 - `type: "input_audio"`1880718808 The type of the input item. Always `input_audio`.1880918810 - `"input_audio"`1881118812 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1881318814 A list of inputs, each of which may be either an input text, output text, input18815 image, or input audio object.1881618817 - `TextInput = string`1881818819 A text input to the model.1882018821 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1882218823 A text input to the model.1882418825 - `OutputText object { text, type }`1882618827 A text output from the model.1882818829 - `text: string`1883018831 The text output from the model.1883218833 - `type: "output_text"`1883418835 The type of the output text. Always `output_text`.1883618837 - `"output_text"`1883818839 - `InputImage object { image_url, type, detail }`1884018841 An image input block used within EvalItem content arrays.1884218843 - `image_url: string`1884418845 The URL of the image input.1884618847 - `type: "input_image"`1884818849 The type of the image input. Always `input_image`.1885018851 - `"input_image"`1885218853 - `detail: optional string`1885418855 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1885618857 - `ResponseInputAudio object { input_audio, type }`1885818859 An audio input to the model.1886018861 - `role: "user" or "assistant" or "system" or "developer"`1886218863 The role of the message input. One of `user`, `assistant`, `system`, or18864 `developer`.1886518866 - `"user"`1886718868 - `"assistant"`1886918870 - `"system"`1887118872 - `"developer"`1887318874 - `type: optional "message"`1887518876 The type of the message input. Always `message`.1887718878 - `"message"`1887918880 - `type: "template"`1888118882 The type of input messages. Always `template`.1888318884 - `"template"`1888518886 - `ItemReferenceInputMessages object { item_reference, type }`1888718888 - `item_reference: string`1888918890 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"1889118892 - `type: "item_reference"`1889318894 The type of input messages. Always `item_reference`.1889518896 - `"item_reference"`1889718898 - `model: optional string`1889918900 The name of the model to use for generating completions (e.g. "o3-mini").1890118902 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`1890318904 - `max_completion_tokens: optional number`1890518906 The maximum number of tokens in the generated output.1890718908 - `reasoning_effort: optional ReasoningEffort or null`1890918910 Constrains effort on reasoning for reasoning models. Currently supported18911 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.18912 Reducing reasoning effort can result in faster responses and fewer tokens18913 used on reasoning in a response. Not all reasoning models support every18914 value. See the18915 [reasoning guide](/api/docs/guides/reasoning)18916 for model-specific support.1891718918 - `"none"`1891918920 - `"minimal"`1892118922 - `"low"`1892318924 - `"medium"`1892518926 - `"high"`1892718928 - `"xhigh"`1892918930 - `"max"`1893118932 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`1893318934 An object specifying the format that the model must output.1893518936 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables18937 Structured Outputs which ensures the model will match your supplied JSON18938 schema. Learn more in the [Structured Outputs18939 guide](/api/docs/guides/structured-outputs).1894018941 Setting to `{ "type": "json_object" }` enables the older JSON mode, which18942 ensures the message the model generates is valid JSON. Using `json_schema`18943 is preferred for models that support it.1894418945 - `ResponseFormatText object { type }`1894618947 Default response format. Used to generate text responses.1894818949 - `type: "text"`1895018951 The type of response format being defined. Always `text`.1895218953 - `"text"`1895418955 - `ResponseFormatJSONSchema object { json_schema, type }`1895618957 JSON Schema response format. Used to generate structured JSON responses.18958 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1895918960 - `json_schema: object { name, description, schema, strict }`1896118962 Structured Outputs configuration options, including a JSON Schema.1896318964 - `name: string`1896518966 The name of the response format. Must be a-z, A-Z, 0-9, or contain18967 underscores and dashes, with a maximum length of 64.1896818969 - `description: optional string`1897018971 A description of what the response format is for, used by the model to18972 determine how to respond in the format.1897318974 - `schema: optional map[unknown]`1897518976 The schema for the response format, described as a JSON Schema object.18977 Learn how to build JSON schemas [here](https://json-schema.org/).1897818979 - `strict: optional boolean or null`1898018981 Whether to enable strict schema adherence when generating the output.18982 If set to true, the model will always follow the exact schema defined18983 in the `schema` field. Only a subset of JSON Schema is supported when18984 `strict` is `true`. To learn more, read the [Structured Outputs18985 guide](/api/docs/guides/structured-outputs).1898618987 - `type: "json_schema"`1898818989 The type of response format being defined. Always `json_schema`.1899018991 - `"json_schema"`1899218993 - `ResponseFormatJSONObject object { type }`1899418995 JSON object response format. An older method of generating JSON responses.18996 Using `json_schema` is recommended for models that support it. Note that the18997 model will not generate JSON without a system or user message instructing it18998 to do so.1899919000 - `type: "json_object"`1900119002 The type of response format being defined. Always `json_object`.1900319004 - `"json_object"`1900519006 - `seed: optional number`1900719008 A seed value to initialize the randomness, during sampling.1900919010 - `temperature: optional number`1901119012 A higher temperature increases randomness in the outputs.1901319014 - `tools: optional array of ChatCompletionFunctionTool`1901519016 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.1901719018 - `function: FunctionDefinition`1901919020 - `name: string`1902119022 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.1902319024 - `description: optional string`1902519026 A description of what the function does, used by the model to choose when and how to call the function.1902719028 - `parameters: optional FunctionParameters`1902919030 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.1903119032 Omitting `parameters` defines a function with an empty parameter list.1903319034 - `strict: optional boolean or null`1903519036 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).1903719038 - `type: "function"`1903919040 The type of the tool. Currently, only `function` is supported.1904119042 - `"function"`1904319044 - `top_p: optional number`1904519046 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.1904719048 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`1904919050 A ResponsesRunDataSource object describing a model sampling configuration.1905119052 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`1905319054 Determines what populates the `item` namespace in this run's data source.1905519056 - `EvalJSONLFileContentSource object { content, type }`1905719058 - `content: array of object { item, sample }`1905919060 The content of the jsonl file.1906119062 - `item: map[unknown]`1906319064 - `sample: optional map[unknown]`1906519066 - `type: "file_content"`1906719068 The type of jsonl source. Always `file_content`.1906919070 - `"file_content"`1907119072 - `EvalJSONLFileIDSource object { id, type }`1907319074 - `id: string`1907519076 The identifier of the file.1907719078 - `type: "file_id"`1907919080 The type of jsonl source. Always `file_id`.1908119082 - `"file_id"`1908319084 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`1908519086 A EvalResponsesSource object describing a run data source configuration.1908719088 - `type: "responses"`1908919090 The type of run data source. Always `responses`.1909119092 - `"responses"`1909319094 - `created_after: optional number or null`1909519096 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.1909719098 - `created_before: optional number or null`1909919100 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.1910119102 - `instructions_search: optional string or null`1910319104 Optional string to search the 'instructions' field. This is a query parameter used to select responses.1910519106 - `metadata: optional unknown or null`1910719108 Metadata filter for the responses. This is a query parameter used to select responses.1910919110 - `model: optional string or null`1911119112 The name of the model to find responses for. This is a query parameter used to select responses.1911319114 - `reasoning_effort: optional ReasoningEffort or null`1911519116 Constrains effort on reasoning for reasoning models. Currently supported19117 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.19118 Reducing reasoning effort can result in faster responses and fewer tokens19119 used on reasoning in a response. Not all reasoning models support every19120 value. See the19121 [reasoning guide](/api/docs/guides/reasoning)19122 for model-specific support.1912319124 - `temperature: optional number or null`1912519126 Sampling temperature. This is a query parameter used to select responses.1912719128 - `tools: optional array of string or null`1912919130 List of tool names. This is a query parameter used to select responses.1913119132 - `top_p: optional number or null`1913319134 Nucleus sampling parameter. This is a query parameter used to select responses.1913519136 - `users: optional array of string or null`1913719138 List of user identifiers. This is a query parameter used to select responses.1913919140 - `type: "responses"`1914119142 The type of run data source. Always `responses`.1914319144 - `"responses"`1914519146 - `input_messages: optional object { template, type } or object { item_reference, type }`1914719148 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.1914919150 - `InputMessagesTemplate object { template, type }`1915119152 - `template: array of object { content, role } or object { content, role, type }`1915319154 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.1915519156 - `ChatMessage object { content, role }`1915719158 - `content: string`1915919160 The content of the message.1916119162 - `role: string`1916319164 The role of the message (e.g. "system", "assistant", "user").1916519166 - `EvalMessageObject object { content, role, type }`1916719168 A message input to the model with a role indicating instruction following19169 hierarchy. Instructions given with the `developer` or `system` role take19170 precedence over instructions given with the `user` role. Messages with the19171 `assistant` role are presumed to have been generated by the model in previous19172 interactions.1917319174 - `content: string or ResponseInputText or object { text, type } or 3 more`1917519176 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.1917719178 - `TextInput = string`1917919180 A text input to the model.1918119182 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`1918319184 A text input to the model.1918519186 - `OutputText object { text, type }`1918719188 A text output from the model.1918919190 - `text: string`1919119192 The text output from the model.1919319194 - `type: "output_text"`1919519196 The type of the output text. Always `output_text`.1919719198 - `"output_text"`1919919200 - `InputImage object { image_url, type, detail }`1920119202 An image input block used within EvalItem content arrays.1920319204 - `image_url: string`1920519206 The URL of the image input.1920719208 - `type: "input_image"`1920919210 The type of the image input. Always `input_image`.1921119212 - `"input_image"`1921319214 - `detail: optional string`1921519216 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.1921719218 - `ResponseInputAudio object { input_audio, type }`1921919220 An audio input to the model.1922119222 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`1922319224 A list of inputs, each of which may be either an input text, output text, input19225 image, or input audio object.1922619227 - `role: "user" or "assistant" or "system" or "developer"`1922819229 The role of the message input. One of `user`, `assistant`, `system`, or19230 `developer`.1923119232 - `"user"`1923319234 - `"assistant"`1923519236 - `"system"`1923719238 - `"developer"`1923919240 - `type: optional "message"`1924119242 The type of the message input. Always `message`.1924319244 - `"message"`1924519246 - `type: "template"`1924719248 The type of input messages. Always `template`.1924919250 - `"template"`1925119252 - `InputMessagesItemReference object { item_reference, type }`1925319254 - `item_reference: string`1925519256 A reference to a variable in the `item` namespace. Ie, "item.name"1925719258 - `type: "item_reference"`1925919260 The type of input messages. Always `item_reference`.1926119262 - `"item_reference"`1926319264 - `model: optional string`1926519266 The name of the model to use for generating completions (e.g. "o3-mini").1926719268 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`1926919270 - `max_completion_tokens: optional number`1927119272 The maximum number of tokens in the generated output.1927319274 - `reasoning_effort: optional ReasoningEffort or null`1927519276 Constrains effort on reasoning for reasoning models. Currently supported19277 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.19278 Reducing reasoning effort can result in faster responses and fewer tokens19279 used on reasoning in a response. Not all reasoning models support every19280 value. See the19281 [reasoning guide](/api/docs/guides/reasoning)19282 for model-specific support.1928319284 - `seed: optional number`1928519286 A seed value to initialize the randomness, during sampling.1928719288 - `temperature: optional number`1928919290 A higher temperature increases randomness in the outputs.1929119292 - `text: optional object { format }`1929319294 Configuration options for a text response from the model. Can be plain19295 text or structured JSON data. Learn more:1929619297 - [Text inputs and outputs](/api/docs/guides/text)19298 - [Structured Outputs](/api/docs/guides/structured-outputs)1929919300 - `format: optional ResponseFormatTextConfig`1930119302 An object specifying the format that the model must output.1930319304 Configuring `{ "type": "json_schema" }` enables Structured Outputs,19305 which ensures the model will match your supplied JSON schema. Learn more in the19306 [Structured Outputs guide](/api/docs/guides/structured-outputs).1930719308 The default format is `{ "type": "text" }` with no additional options.1930919310 **Not recommended for gpt-4o and newer models:**1931119312 Setting to `{ "type": "json_object" }` enables the older JSON mode, which19313 ensures the message the model generates is valid JSON. Using `json_schema`19314 is preferred for models that support it.1931519316 - `ResponseFormatText object { type }`1931719318 Default response format. Used to generate text responses.1931919320 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`1932119322 JSON Schema response format. Used to generate structured JSON responses.19323 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).1932419325 - `name: string`1932619327 The name of the response format. Must be a-z, A-Z, 0-9, or contain19328 underscores and dashes, with a maximum length of 64.1932919330 - `schema: map[unknown]`1933119332 The schema for the response format, described as a JSON Schema object.19333 Learn how to build JSON schemas [here](https://json-schema.org/).1933419335 - `type: "json_schema"`1933619337 The type of response format being defined. Always `json_schema`.1933819339 - `"json_schema"`1934019341 - `description: optional string`1934219343 A description of what the response format is for, used by the model to19344 determine how to respond in the format.1934519346 - `strict: optional boolean or null`1934719348 Whether to enable strict schema adherence when generating the output.19349 If set to true, the model will always follow the exact schema defined19350 in the `schema` field. Only a subset of JSON Schema is supported when19351 `strict` is `true`. To learn more, read the [Structured Outputs19352 guide](/api/docs/guides/structured-outputs).1935319354 - `ResponseFormatJSONObject object { type }`1935519356 JSON object response format. An older method of generating JSON responses.19357 Using `json_schema` is recommended for models that support it. Note that the19358 model will not generate JSON without a system or user message instructing it19359 to do so.1936019361 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`1936219363 An array of tools the model may call while generating a response. You19364 can specify which tool to use by setting the `tool_choice` parameter.1936519366 The two categories of tools you can provide the model are:1936719368 - **Built-in tools**: Tools that are provided by OpenAI that extend the19369 model's capabilities, like [web search](/api/docs/guides/tools-web-search)19370 or [file search](/api/docs/guides/tools-file-search). Learn more about19371 [built-in tools](/api/docs/guides/tools).19372 - **Function calls (custom tools)**: Functions that are defined by you,19373 enabling the model to call your own code. Learn more about19374 [function calling](/api/docs/guides/function-calling).1937519376 - `Function object { name, parameters, strict, 6 more }`1937719378 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).1937919380 - `name: string`1938119382 The name of the function to call.1938319384 - `parameters: map[unknown] or null`1938519386 A JSON schema object describing the parameters of the function.1938719388 - `strict: boolean or null`1938919390 Whether strict parameter validation is enforced for this function tool.1939119392 - `type: "function"`1939319394 The type of the function tool. Always `function`.1939519396 - `"function"`1939719398 - `allowed_callers: optional array of "direct" or "programmatic" or null`1939919400 The tool invocation context(s).1940119402 - `"direct"`1940319404 - `"programmatic"`1940519406 - `async: optional boolean`1940719408 - `defer_loading: optional boolean`1940919410 Whether this function is deferred and loaded via tool search.1941119412 - `description: optional string or null`1941319414 A description of the function. Used by the model to determine whether or not to call the function.1941519416 - `output_schema: optional map[unknown] or null`1941719418 A JSON schema object describing the JSON value encoded in string outputs for this function.1941919420 - `FileSearch object { type, vector_store_ids, filters, 2 more }`1942119422 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).1942319424 - `type: "file_search"`1942519426 The type of the file search tool. Always `file_search`.1942719428 - `"file_search"`1942919430 - `vector_store_ids: array of string`1943119432 The IDs of the vector stores to search.1943319434 - `filters: optional ComparisonFilter or CompoundFilter or null`1943519436 A filter to apply.1943719438 - `ComparisonFilter object { key, type, value }`1943919440 A filter used to compare a specified attribute key to a given value using a defined comparison operation.1944119442 - `key: string`1944319444 The key to compare against the value.1944519446 - `type: "eq" or "ne" or "gt" or 5 more`1944719448 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.1944919450 - `eq`: equals19451 - `ne`: not equal19452 - `gt`: greater than19453 - `gte`: greater than or equal19454 - `lt`: less than19455 - `lte`: less than or equal19456 - `in`: in19457 - `nin`: not in1945819459 - `"eq"`1946019461 - `"ne"`1946219463 - `"gt"`1946419465 - `"gte"`1946619467 - `"lt"`1946819469 - `"lte"`1947019471 - `"in"`1947219473 - `"nin"`1947419475 - `value: string or number or boolean or array of string or number`1947619477 The value to compare against the attribute key; supports string, number, or boolean types.1947819479 - `string`1948019481 - `number`1948219483 - `boolean`1948419485 - `array of string or number`1948619487 - `string`1948819489 - `number`1949019491 - `CompoundFilter object { filters, type }`1949219493 Combine multiple filters using `and` or `or`.1949419495 - `filters: array of ComparisonFilter or unknown`1949619497 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.1949819499 - `ComparisonFilter object { key, type, value }`1950019501 A filter used to compare a specified attribute key to a given value using a defined comparison operation.1950219503 - `unknown`1950419505 - `type: "and" or "or"`1950619507 Type of operation: `and` or `or`.1950819509 - `"and"`1951019511 - `"or"`1951219513 - `max_num_results: optional number`1951419515 The maximum number of results to return. This number should be between 1 and 50 inclusive.1951619517 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`1951819519 Ranking options for search.1952019521 - `hybrid_search: optional object { embedding_weight, text_weight }`1952219523 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.1952419525 - `embedding_weight: number`1952619527 The weight of the embedding in the reciprocal ranking fusion.1952819529 - `text_weight: number`1953019531 The weight of the text in the reciprocal ranking fusion.1953219533 - `ranker: optional "auto" or "default-2024-11-15"`1953419535 The ranker to use for the file search.1953619537 - `"auto"`1953819539 - `"default-2024-11-15"`1954019541 - `score_threshold: optional number`1954219543 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.1954419545 - `Computer object { type }`1954619547 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).1954819549 - `type: "computer"`1955019551 The type of the computer tool. Always `computer`.1955219553 - `"computer"`1955419555 - `ComputerUsePreview object { display_height, display_width, environment, type }`1955619557 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).1955819559 - `display_height: number`1956019561 The height of the computer display.1956219563 - `display_width: number`1956419565 The width of the computer display.1956619567 - `environment: "windows" or "mac" or "linux" or 2 more`1956819569 The type of computer environment to control.1957019571 - `"windows"`1957219573 - `"mac"`1957419575 - `"linux"`1957619577 - `"ubuntu"`1957819579 - `"browser"`1958019581 - `type: "computer_use_preview"`1958219583 The type of the computer use tool. Always `computer_use_preview`.1958419585 - `"computer_use_preview"`1958619587 - `WebSearch object { type, external_web_access, filters, 2 more }`1958819589 Search the Internet for sources related to the prompt. Learn more about the19590 [web search tool](/api/docs/guides/tools-web-search).1959119592 - `type: "web_search" or "web_search_2025_08_26"`1959319594 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.1959519596 - `"web_search"`1959719598 - `"web_search_2025_08_26"`1959919600 - `external_web_access: optional boolean`1960119602 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.1960319604 - `filters: optional object { allowed_domains } or null`1960519606 Filters for the search.1960719608 - `allowed_domains: optional array of string or null`1960919610 Allowed domains for the search. If not provided, all domains are allowed.19611 Subdomains of the provided domains are allowed as well.1961219613 Example: `["pubmed.ncbi.nlm.nih.gov"]`1961419615 - `search_context_size: optional "low" or "medium" or "high"`1961619617 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.1961819619 - `"low"`1962019621 - `"medium"`1962219623 - `"high"`1962419625 - `user_location: optional object { city, country, region, 2 more } or null`1962619627 The approximate location of the user.1962819629 - `city: optional string or null`1963019631 Free text input for the city of the user, e.g. `San Francisco`.1963219633 - `country: optional string or null`1963419635 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.1963619637 - `region: optional string or null`1963819639 Free text input for the region of the user, e.g. `California`.1964019641 - `timezone: optional string or null`1964219643 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.1964419645 - `type: optional "approximate"`1964619647 The type of location approximation. Always `approximate`.1964819649 - `"approximate"`1965019651 - `Mcp object { server_label, type, allowed_callers, 9 more }`1965219653 Give the model access to additional tools via remote Model Context Protocol19654 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).1965519656 - `server_label: string`1965719658 A label for this MCP server, used to identify it in tool calls.1965919660 - `type: "mcp"`1966119662 The type of the MCP tool. Always `mcp`.1966319664 - `"mcp"`1966519666 - `allowed_callers: optional array of "direct" or "programmatic" or null`1966719668 The tool invocation context(s).1966919670 - `"direct"`1967119672 - `"programmatic"`1967319674 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`1967519676 List of allowed tool names or a filter object.1967719678 - `McpAllowedTools = array of string`1967919680 A string array of allowed tool names1968119682 - `McpToolFilter object { read_only, tool_names }`1968319684 A filter object to specify which tools are allowed.1968519686 - `read_only: optional boolean`1968719688 Indicates whether or not a tool modifies data or is read-only. If an19689 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),19690 it will match this filter.1969119692 - `tool_names: optional array of string`1969319694 List of allowed tool names.1969519696 - `authorization: optional string`1969719698 An OAuth access token that can be used with a remote MCP server, either19699 with a custom MCP server URL or a service connector. Your application19700 must handle the OAuth authorization flow and provide the token here.1970119702 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`1970319704 Identifier for service connectors, like those available in ChatGPT. One of19705 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more19706 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).1970719708 This field is deprecated for models released after September 1, 2026.19709 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to19710 connect through a Secure MCP Tunnel.1971119712 Currently supported `connector_id` values are:1971319714 - Dropbox: `connector_dropbox`19715 - Gmail: `connector_gmail`19716 - Google Calendar: `connector_googlecalendar`19717 - Google Drive: `connector_googledrive`19718 - Microsoft Teams: `connector_microsoftteams`19719 - Outlook Calendar: `connector_outlookcalendar`19720 - Outlook Email: `connector_outlookemail`19721 - SharePoint: `connector_sharepoint`1972219723 - `"connector_dropbox"`1972419725 - `"connector_gmail"`1972619727 - `"connector_googlecalendar"`1972819729 - `"connector_googledrive"`1973019731 - `"connector_microsoftteams"`1973219733 - `"connector_outlookcalendar"`1973419735 - `"connector_outlookemail"`1973619737 - `"connector_sharepoint"`1973819739 - `defer_loading: optional boolean`1974019741 Whether this MCP tool is deferred and discovered via tool search.1974219743 - `headers: optional map[string] or null`1974419745 Optional HTTP headers to send to the MCP server. Use for authentication19746 or other purposes.1974719748 - `require_approval: optional object { always, never } or "always" or "never" or null`1974919750 Specify which of the MCP server's tools require approval.1975119752 - `McpToolApprovalFilter object { always, never }`1975319754 Specify which of the MCP server's tools require approval. Can be19755 `always`, `never`, or a filter object associated with tools19756 that require approval.1975719758 - `always: optional object { read_only, tool_names }`1975919760 A filter object to specify which tools are allowed.1976119762 - `read_only: optional boolean`1976319764 Indicates whether or not a tool modifies data or is read-only. If an19765 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),19766 it will match this filter.1976719768 - `tool_names: optional array of string`1976919770 List of allowed tool names.1977119772 - `never: optional object { read_only, tool_names }`1977319774 A filter object to specify which tools are allowed.1977519776 - `read_only: optional boolean`1977719778 Indicates whether or not a tool modifies data or is read-only. If an19779 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),19780 it will match this filter.1978119782 - `tool_names: optional array of string`1978319784 List of allowed tool names.1978519786 - `McpToolApprovalSetting = "always" or "never"`1978719788 Specify a single approval policy for all tools. One of `always` or19789 `never`. When set to `always`, all tools will require approval. When19790 set to `never`, all tools will not require approval.1979119792 - `"always"`1979319794 - `"never"`1979519796 - `server_description: optional string`1979719798 Optional description of the MCP server, used to provide more context.1979919800 - `server_url: optional string`1980119802 The URL for the MCP server. One of `server_url`, `connector_id`, or19803 `tunnel_id` must be provided.1980419805 - `tunnel_id: optional string`1980619807 The Secure MCP Tunnel ID to use instead of a direct server URL. One of19808 `server_url`, `connector_id`, or `tunnel_id` must be provided.1980919810 - `CodeInterpreter object { container, type, allowed_callers }`1981119812 A tool that runs Python code to help generate a response to a prompt.1981319814 - `container: string or object { type, file_ids, memory_limit, network_policy }`1981519816 The code interpreter container. Can be a container ID or an object that19817 specifies uploaded file IDs to make available to your code, along with an19818 optional `memory_limit` setting.1981919820 - `string`1982119822 The container ID.1982319824 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`1982519826 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.1982719828 - `type: "auto"`1982919830 Always `auto`.1983119832 - `"auto"`1983319834 - `file_ids: optional array of string`1983519836 An optional list of uploaded files to make available to your code.1983719838 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`1983919840 The memory limit for the code interpreter container.1984119842 - `"1g"`1984319844 - `"4g"`1984519846 - `"16g"`1984719848 - `"64g"`1984919850 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`1985119852 Network access policy for the container.1985319854 - `ContainerNetworkPolicyDisabled object { type }`1985519856 - `type: "disabled"`1985719858 Disable outbound network access. Always `disabled`.1985919860 - `"disabled"`1986119862 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`1986319864 - `allowed_domains: array of string`1986519866 A list of allowed domains when type is `allowlist`.1986719868 - `type: "allowlist"`1986919870 Allow outbound network access only to specified domains. Always `allowlist`.1987119872 - `"allowlist"`1987319874 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`1987519876 Optional domain-scoped secrets for allowlisted domains.1987719878 - `domain: string`1987919880 The domain associated with the secret.1988119882 - `name: string`1988319884 The name of the secret to inject for the domain.1988519886 - `value: string`1988719888 The secret value to inject for the domain.1988919890 - `type: "code_interpreter"`1989119892 The type of the code interpreter tool. Always `code_interpreter`.1989319894 - `"code_interpreter"`1989519896 - `allowed_callers: optional array of "direct" or "programmatic" or null`1989719898 The tool invocation context(s).1989919900 - `"direct"`1990119902 - `"programmatic"`1990319904 - `ProgrammaticToolCalling object { type }`1990519906 - `type: "programmatic_tool_calling"`1990719908 The type of the tool. Always `programmatic_tool_calling`.1990919910 - `"programmatic_tool_calling"`1991119912 - `ImageGeneration object { type, action, background, 9 more }`1991319914 A tool that generates images using the GPT image models.1991519916 - `type: "image_generation"`1991719918 The type of the image generation tool. Always `image_generation`.1991919920 - `"image_generation"`1992119922 - `action: optional "generate" or "edit" or "auto"`1992319924 Whether to generate a new image or edit an existing image. Default: `auto`.1992519926 - `"generate"`1992719928 - `"edit"`1992919930 - `"auto"`1993119932 - `background: optional "transparent" or "opaque" or "auto"`1993319934 Set the background of the generated image. One of `transparent`, `opaque`,19935 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including19936 their `2026-09-08` snapshots, support `opaque` and `transparent`19937 backgrounds. Transparent backgrounds are available for supported GPT Image19938 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in19939 preview. When using `transparent`, set the output format to `png` or `webp`.19940 Default: `auto`.1994119942 - `"transparent"`1994319944 - `"opaque"`1994519946 - `"auto"`1994719948 - `input_fidelity: optional "high" or "low" or null`1994919950 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.1995119952 - `"high"`1995319954 - `"low"`1995519956 - `input_image_mask: optional object { file_id, image_url }`1995719958 Optional mask for inpainting. Contains `image_url`19959 (string, optional) and `file_id` (string, optional).1996019961 - `file_id: optional string`1996219963 File ID for the mask image.1996419965 - `image_url: optional string`1996619967 Base64-encoded mask image.1996819969 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`1997019971 The image generation model to use. One of `gpt-image-1`,19972 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,19973 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,19974 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,19975 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:19976 `gpt-image-1`.1997719978 - `string`1997919980 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`1998119982 The image generation model to use. One of `gpt-image-1`,19983 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,19984 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,19985 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,19986 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:19987 `gpt-image-1`.1998819989 - `"gpt-image-1"`1999019991 - `"gpt-image-1-mini"`1999219993 - `"gpt-image-1.5"`1999419995 - `"gpt-image-2"`1999619997 - `"gpt-image-2-2026-04-21"`1999819999 - `"gpt-image-2.5-sunburst"`2000020001 - `"gpt-image-2.5-sunburst-2026-09-08"`2000220003 - `"gpt-image-2.5-flare"`2000420005 - `"gpt-image-2.5-flare-2026-09-08"`2000620007 - `moderation: optional "auto" or "low"`2000820009 Moderation level for the generated image. Default: `auto`.2001020011 - `"auto"`2001220013 - `"low"`2001420015 - `output_compression: optional number`2001620017 Compression level for the output image. Default: 100.2001820019 - `output_format: optional "png" or "webp" or "jpeg"`2002020021 The output format of the generated image. One of `png`, `webp`, or20022 `jpeg`. Default: `png`.2002320024 - `"png"`2002520026 - `"webp"`2002720028 - `"jpeg"`2002920030 - `partial_images: optional number`2003120032 Number of partial images to generate in streaming mode, from 0 (default value) to 3.2003320034 - `quality: optional "low" or "medium" or "high" or 3 more`2003520036 The quality of the generated image. The GPT image models support `low`,20037 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,20038 including their `2026-09-08` snapshots, also support `xhigh` and `max`.20039 Default: `auto`.2004020041 - `"low"`2004220043 - `"medium"`2004420045 - `"high"`2004620047 - `"xhigh"`2004820049 - `"max"`2005020051 - `"auto"`2005220053 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`2005420055 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.2005620057 - `string`2005820059 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`2006020061 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.2006220063 - `"1024x1024"`2006420065 - `"1024x1536"`2006620067 - `"1536x1024"`2006820069 - `"auto"`2007020071 - `LocalShell object { type }`2007220073 A tool that allows the model to execute shell commands in a local environment.2007420075 - `type: "local_shell"`2007620077 The type of the local shell tool. Always `local_shell`.2007820079 - `"local_shell"`2008020081 - `Shell object { type, allowed_callers, environment }`2008220083 A tool that allows the model to execute shell commands.2008420085 - `type: "shell"`2008620087 The type of the shell tool. Always `shell`.2008820089 - `"shell"`2009020091 - `allowed_callers: optional array of "direct" or "programmatic" or null`2009220093 The tool invocation context(s).2009420095 - `"direct"`2009620097 - `"programmatic"`2009820099 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`2010020101 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`2010220103 - `type: "container_auto"`2010420105 Automatically creates a container for this request2010620107 - `"container_auto"`2010820109 - `file_ids: optional array of string`2011020111 An optional list of uploaded files to make available to your code.2011220113 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`2011420115 The memory limit for the container.2011620117 - `"1g"`2011820119 - `"4g"`2012020121 - `"16g"`2012220123 - `"64g"`2012420125 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`2012620127 Network access policy for the container.2012820129 - `ContainerNetworkPolicyDisabled object { type }`2013020131 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`2013220133 - `skills: optional array of SkillReference or InlineSkill`2013420135 An optional list of skills referenced by id or inline data.2013620137 - `SkillReference object { skill_id, type, version }`2013820139 - `skill_id: string`2014020141 The ID of the referenced skill.2014220143 - `type: "skill_reference"`2014420145 References a skill created with the /v1/skills endpoint.2014620147 - `"skill_reference"`2014820149 - `version: optional string`2015020151 Optional skill version. Use a positive integer or 'latest'. Omit for default.2015220153 - `InlineSkill object { description, name, source, type }`2015420155 - `description: string`2015620157 The description of the skill.2015820159 - `name: string`2016020161 The name of the skill.2016220163 - `source: InlineSkillSource`2016420165 Inline skill payload2016620167 - `data: string`2016820169 Base64-encoded skill zip bundle.2017020171 - `media_type: "application/zip"`2017220173 The media type of the inline skill payload. Must be `application/zip`.2017420175 - `"application/zip"`2017620177 - `type: "base64"`2017820179 The type of the inline skill source. Must be `base64`.2018020181 - `"base64"`2018220183 - `type: "inline"`2018420185 Defines an inline skill for this request.2018620187 - `"inline"`2018820189 - `LocalEnvironment object { type, skills }`2019020191 - `type: "local"`2019220193 Use a local computer environment.2019420195 - `"local"`2019620197 - `skills: optional array of LocalSkill`2019820199 An optional list of skills.2020020201 - `description: string`2020220203 The description of the skill.2020420205 - `name: string`2020620207 The name of the skill.2020820209 - `path: string`2021020211 The path to the directory containing the skill.2021220213 - `ContainerReference object { container_id, type }`2021420215 - `container_id: string`2021620217 The ID of the referenced container.2021820219 - `type: "container_reference"`2022020221 References a container created with the /v1/containers endpoint2022220223 - `"container_reference"`2022420225 - `Custom object { name, type, allowed_callers, 4 more }`2022620227 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)2022820229 - `name: string`2023020231 The name of the custom tool, used to identify it in tool calls.2023220233 - `type: "custom"`2023420235 The type of the custom tool. Always `custom`.2023620237 - `"custom"`2023820239 - `allowed_callers: optional array of "direct" or "programmatic" or null`2024020241 The tool invocation context(s).2024220243 - `"direct"`2024420245 - `"programmatic"`2024620247 - `async: optional boolean`2024820249 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2025020251 - `defer_loading: optional boolean`2025220253 Whether this tool should be deferred and discovered via tool search.2025420255 - `description: optional string`2025620257 Optional description of the custom tool, used to provide more context.2025820259 - `format: optional CustomToolInputFormat`2026020261 The input format for the custom tool. Default is unconstrained text.2026220263 - `Text object { type }`2026420265 Unconstrained free-form text.2026620267 - `type: "text"`2026820269 Unconstrained text format. Always `text`.2027020271 - `"text"`2027220273 - `Grammar object { definition, syntax, type }`2027420275 A grammar defined by the user.2027620277 - `definition: string`2027820279 The grammar definition.2028020281 - `syntax: "lark" or "regex"`2028220283 The syntax of the grammar definition. One of `lark` or `regex`.2028420285 - `"lark"`2028620287 - `"regex"`2028820289 - `type: "grammar"`2029020291 Grammar format. Always `grammar`.2029220293 - `"grammar"`2029420295 - `Namespace object { description, name, tools, type }`2029620297 Groups function/custom tools under a shared namespace.2029820299 - `description: string`2030020301 A description of the namespace shown to the model.2030220303 - `name: string`2030420305 The namespace name used in tool calls (for example, `crm`).2030620307 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`2030820309 The function/custom tools available inside this namespace.2031020311 - `Function object { name, type, allowed_callers, 6 more }`2031220313 - `name: string`2031420315 - `type: "function"`2031620317 - `"function"`2031820319 - `allowed_callers: optional array of "direct" or "programmatic" or null`2032020321 The tool invocation context(s).2032220323 - `"direct"`2032420325 - `"programmatic"`2032620327 - `async: optional boolean`2032820329 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2033020331 - `defer_loading: optional boolean`2033220333 Whether this function should be deferred and discovered via tool search.2033420335 - `description: optional string or null`2033620337 - `output_schema: optional map[unknown] or null`2033820339 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.2034020341 - `parameters: optional unknown or null`2034220343 - `strict: optional boolean or null`2034420345 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.2034620347 - `Custom object { name, type, allowed_callers, 4 more }`2034820349 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)2035020351 - `name: string`2035220353 The name of the custom tool, used to identify it in tool calls.2035420355 - `type: "custom"`2035620357 The type of the custom tool. Always `custom`.2035820359 - `"custom"`2036020361 - `allowed_callers: optional array of "direct" or "programmatic" or null`2036220363 The tool invocation context(s).2036420365 - `"direct"`2036620367 - `"programmatic"`2036820369 - `async: optional boolean`2037020371 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2037220373 - `defer_loading: optional boolean`2037420375 Whether this tool should be deferred and discovered via tool search.2037620377 - `description: optional string`2037820379 Optional description of the custom tool, used to provide more context.2038020381 - `format: optional CustomToolInputFormat`2038220383 The input format for the custom tool. Default is unconstrained text.2038420385 - `type: "namespace"`2038620387 The type of the tool. Always `namespace`.2038820389 - `"namespace"`2039020391 - `ToolSearch object { type, description, execution, parameters }`2039220393 Hosted or BYOT tool search configuration for deferred tools.2039420395 - `type: "tool_search"`2039620397 The type of the tool. Always `tool_search`.2039820399 - `"tool_search"`2040020401 - `description: optional string or null`2040220403 Description shown to the model for a client-executed tool search tool.2040420405 - `execution: optional "server" or "client"`2040620407 Whether tool search is executed by the server or by the client.2040820409 - `"server"`2041020411 - `"client"`2041220413 - `parameters: optional unknown or null`2041420415 Parameter schema for a client-executed tool search tool.2041620417 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`2041820419 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).2042020421 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`2042220423 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.2042420425 - `"web_search_preview"`2042620427 - `"web_search_preview_2025_03_11"`2042820429 - `search_content_types: optional array of "text" or "image"`2043020431 - `"text"`2043220433 - `"image"`2043420435 - `search_context_size: optional "low" or "medium" or "high"`2043620437 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.2043820439 - `"low"`2044020441 - `"medium"`2044220443 - `"high"`2044420445 - `user_location: optional object { type, city, country, 2 more } or null`2044620447 The user's location.2044820449 - `type: "approximate"`2045020451 The type of location approximation. Always `approximate`.2045220453 - `"approximate"`2045420455 - `city: optional string or null`2045620457 Free text input for the city of the user, e.g. `San Francisco`.2045820459 - `country: optional string or null`2046020461 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.2046220463 - `region: optional string or null`2046420465 Free text input for the region of the user, e.g. `California`.2046620467 - `timezone: optional string or null`2046820469 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.2047020471 - `ApplyPatch object { type, allowed_callers }`2047220473 Allows the assistant to create, delete, or update files using unified diffs.2047420475 - `type: "apply_patch"`2047620477 The type of the tool. Always `apply_patch`.2047820479 - `"apply_patch"`2048020481 - `allowed_callers: optional array of "direct" or "programmatic" or null`2048220483 The tool invocation context(s).2048420485 - `"direct"`2048620487 - `"programmatic"`2048820489 - `top_p: optional number`2049020491 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.2049220493 - `error: EvalAPIError`2049420495 An object representing an error response from the Eval API.2049620497 - `code: string`2049820499 The error code.2050020501 - `message: string`2050220503 The error message.2050420505 - `eval_id: string`2050620507 The identifier of the associated evaluation.2050820509 - `metadata: Metadata or null`2051020511 Set of 16 key-value pairs that can be attached to an object. This can be20512 useful for storing additional information about the object in a structured20513 format, and querying for objects via API or the dashboard.2051420515 Keys are strings with a maximum length of 64 characters. Values are strings20516 with a maximum length of 512 characters.2051720518 - `model: string`2051920520 The model that is evaluated, if applicable.2052120522 - `name: string`2052320524 The name of the evaluation run.2052520526 - `object: "eval.run"`2052720528 The type of the object. Always "eval.run".2052920530 - `"eval.run"`2053120532 - `per_model_usage: array of object { cached_tokens, completion_tokens, invocation_count, 3 more }`2053320534 Usage statistics for each model during the evaluation run.2053520536 - `cached_tokens: number`2053720538 The number of tokens retrieved from cache.2053920540 - `completion_tokens: number`2054120542 The number of completion tokens generated.2054320544 - `invocation_count: number`2054520546 The number of invocations.2054720548 - `model_name: string`2054920550 The name of the model.2055120552 - `prompt_tokens: number`2055320554 The number of prompt tokens used.2055520556 - `total_tokens: number`2055720558 The total number of tokens used.2055920560 - `per_testing_criteria_results: array of object { failed, passed, testing_criteria }`2056120562 Results per testing criteria applied during the evaluation run.2056320564 - `failed: number`2056520566 Number of tests failed for this criteria.2056720568 - `passed: number`2056920570 Number of tests passed for this criteria.2057120572 - `testing_criteria: string`2057320574 A description of the testing criteria.2057520576 - `report_url: string`2057720578 The URL to the rendered evaluation run report on the UI dashboard.2057920580 - `result_counts: object { errored, failed, passed, total }`2058120582 Counters summarizing the outcomes of the evaluation run.2058320584 - `errored: number`2058520586 Number of output items that resulted in an error.2058720588 - `failed: number`2058920590 Number of output items that failed to pass the evaluation.2059120592 - `passed: number`2059320594 Number of output items that passed the evaluation.2059520596 - `total: number`2059720598 Total number of executed output items.2059920600 - `status: string`2060120602 The status of the evaluation run.2060320604### Run Delete Response2060520606- `RunDeleteResponse object { deleted, object, run_id }`2060720608 - `deleted: optional boolean`2060920610 - `object: optional string`2061120612 - `run_id: optional string`2061320614### Run List Response2061520616- `RunListResponse object { id, created_at, data_source, 11 more }`2061720618 A schema representing an evaluation run.2061920620 - `id: string`2062120622 Unique identifier for the evaluation run.2062320624 - `created_at: number`2062520626 Unix timestamp (in seconds) when the evaluation run was created.2062720628 - `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`2062920630 Information about the run's data source.2063120632 - `CreateEvalJSONLRunDataSource object { source, type }`2063320634 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval2063520636 - `source: object { content, type } or object { id, type }`2063720638 Determines what populates the `item` namespace in the data source.2063920640 - `EvalJSONLFileContentSource object { content, type }`2064120642 - `content: array of object { item, sample }`2064320644 The content of the jsonl file.2064520646 - `item: map[unknown]`2064720648 - `sample: optional map[unknown]`2064920650 - `type: "file_content"`2065120652 The type of jsonl source. Always `file_content`.2065320654 - `"file_content"`2065520656 - `EvalJSONLFileIDSource object { id, type }`2065720658 - `id: string`2065920660 The identifier of the file.2066120662 - `type: "file_id"`2066320664 The type of jsonl source. Always `file_id`.2066520666 - `"file_id"`2066720668 - `type: "jsonl"`2066920670 The type of data source. Always `jsonl`.2067120672 - `"jsonl"`2067320674 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`2067520676 A CompletionsRunDataSource object describing a model sampling configuration.2067720678 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`2067920680 Determines what populates the `item` namespace in this run's data source.2068120682 - `EvalJSONLFileContentSource object { content, type }`2068320684 - `content: array of object { item, sample }`2068520686 The content of the jsonl file.2068720688 - `item: map[unknown]`2068920690 - `sample: optional map[unknown]`2069120692 - `type: "file_content"`2069320694 The type of jsonl source. Always `file_content`.2069520696 - `"file_content"`2069720698 - `EvalJSONLFileIDSource object { id, type }`2069920700 - `id: string`2070120702 The identifier of the file.2070320704 - `type: "file_id"`2070520706 The type of jsonl source. Always `file_id`.2070720708 - `"file_id"`2070920710 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`2071120712 A StoredCompletionsRunDataSource configuration describing a set of filters2071320714 - `type: "stored_completions"`2071520716 The type of source. Always `stored_completions`.2071720718 - `"stored_completions"`2071920720 - `created_after: optional number or null`2072120722 An optional Unix timestamp to filter items created after this time.2072320724 - `created_before: optional number or null`2072520726 An optional Unix timestamp to filter items created before this time.2072720728 - `limit: optional number or null`2072920730 An optional maximum number of items to return.2073120732 - `metadata: optional Metadata or null`2073320734 Set of 16 key-value pairs that can be attached to an object. This can be20735 useful for storing additional information about the object in a structured20736 format, and querying for objects via API or the dashboard.2073720738 Keys are strings with a maximum length of 64 characters. Values are strings20739 with a maximum length of 512 characters.2074020741 - `model: optional string or null`2074220743 An optional model to filter by (e.g., 'gpt-6-astra').2074420745 - `type: "completions"`2074620747 The type of run data source. Always `completions`.2074820749 - `"completions"`2075020751 - `input_messages: optional object { template, type } or object { item_reference, type }`2075220753 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.2075420755 - `TemplateInputMessages object { template, type }`2075620757 - `template: array of EasyInputMessage or object { content, role, type }`2075820759 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.2076020761 - `EasyInputMessage object { content, role, phase, type }`2076220763 A message input to the model with a role indicating instruction following20764 hierarchy. Instructions given with the `developer` or `system` role take20765 precedence over instructions given with the `user` role. Messages with the20766 `assistant` role are presumed to have been generated by the model in previous20767 interactions.2076820769 - `content: string or ResponseInputMessageContentList`2077020771 Text, image, or audio input to the model, used to generate a response.20772 Can also contain previous assistant responses.2077320774 - `TextInput = string`2077520776 A text input to the model.2077720778 - `ResponseInputMessageContentList = array of ResponseInputContent`2077920780 A list of one or many input items to the model, containing different content20781 types.2078220783 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`2078420785 A text input to the model.2078620787 - `text: string`2078820789 The text input to the model.2079020791 - `type: "input_text"`2079220793 The type of the input item. Always `input_text`.2079420795 - `"input_text"`2079620797 - `prompt_cache_breakpoint: optional object { mode }`2079820799 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.2080020801 - `mode: "explicit"`2080220803 The breakpoint mode. Always `explicit`.2080420805 - `"explicit"`2080620807 - `ResponseInputImage object { detail, type, file_id, 2 more }`2080820809 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).2081020811 - `detail: ImageDetail`2081220813 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.2081420815 - `"low"`2081620817 - `"high"`2081820819 - `"auto"`2082020821 - `"original"`2082220823 - `type: "input_image"`2082420825 The type of the input item. Always `input_image`.2082620827 - `"input_image"`2082820829 - `file_id: optional string or null`2083020831 The ID of the file to be sent to the model.2083220833 - `image_url: optional string or null`2083420835 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.2083620837 - `prompt_cache_breakpoint: optional object { mode }`2083820839 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.2084020841 - `mode: "explicit"`2084220843 The breakpoint mode. Always `explicit`.2084420845 - `"explicit"`2084620847 - `ResponseInputFile object { type, detail, file_data, 4 more }`2084820849 A file input to the model.2085020851 - `type: "input_file"`2085220853 The type of the input item. Always `input_file`.2085420855 - `"input_file"`2085620857 - `detail: optional "auto" or "low" or "high"`2085820859 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.2086020861 - `"auto"`2086220863 - `"low"`2086420865 - `"high"`2086620867 - `file_data: optional string`2086820869 The content of the file to be sent to the model.2087020871 - `file_id: optional string or null`2087220873 The ID of the file to be sent to the model.2087420875 - `file_url: optional string`2087620877 The URL of the file to be sent to the model.2087820879 - `filename: optional string`2088020881 The name of the file to be sent to the model.2088220883 - `prompt_cache_breakpoint: optional object { mode }`2088420885 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.2088620887 - `mode: "explicit"`2088820889 The breakpoint mode. Always `explicit`.2089020891 - `"explicit"`2089220893 - `role: "user" or "assistant" or "system" or "developer"`2089420895 The role of the message input. One of `user`, `assistant`, `system`, or20896 `developer`.2089720898 - `"user"`2089920900 - `"assistant"`2090120902 - `"system"`2090320904 - `"developer"`2090520906 - `phase: optional "commentary" or "final_answer" or null`2090720908 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).20909 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend20910 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.2091120912 - `"commentary"`2091320914 - `"final_answer"`2091520916 - `type: optional "message"`2091720918 The type of the message input. Always `message`.2091920920 - `"message"`2092120922 - `EvalMessageObject object { content, role, type }`2092320924 A message input to the model with a role indicating instruction following20925 hierarchy. Instructions given with the `developer` or `system` role take20926 precedence over instructions given with the `user` role. Messages with the20927 `assistant` role are presumed to have been generated by the model in previous20928 interactions.2092920930 - `content: string or ResponseInputText or object { text, type } or 3 more`2093120932 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.2093320934 - `TextInput = string`2093520936 A text input to the model.2093720938 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`2093920940 A text input to the model.2094120942 - `OutputText object { text, type }`2094320944 A text output from the model.2094520946 - `text: string`2094720948 The text output from the model.2094920950 - `type: "output_text"`2095120952 The type of the output text. Always `output_text`.2095320954 - `"output_text"`2095520956 - `InputImage object { image_url, type, detail }`2095720958 An image input block used within EvalItem content arrays.2095920960 - `image_url: string`2096120962 The URL of the image input.2096320964 - `type: "input_image"`2096520966 The type of the image input. Always `input_image`.2096720968 - `"input_image"`2096920970 - `detail: optional string`2097120972 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.2097320974 - `ResponseInputAudio object { input_audio, type }`2097520976 An audio input to the model.2097720978 - `input_audio: object { data, format }`2097920980 - `data: string`2098120982 Base64-encoded audio data.2098320984 - `format: "mp3" or "wav"`2098520986 The format of the audio data. Currently supported formats are `mp3` and20987 `wav`.2098820989 - `"mp3"`2099020991 - `"wav"`2099220993 - `type: "input_audio"`2099420995 The type of the input item. Always `input_audio`.2099620997 - `"input_audio"`2099820999 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`2100021001 A list of inputs, each of which may be either an input text, output text, input21002 image, or input audio object.2100321004 - `TextInput = string`2100521006 A text input to the model.2100721008 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`2100921010 A text input to the model.2101121012 - `OutputText object { text, type }`2101321014 A text output from the model.2101521016 - `text: string`2101721018 The text output from the model.2101921020 - `type: "output_text"`2102121022 The type of the output text. Always `output_text`.2102321024 - `"output_text"`2102521026 - `InputImage object { image_url, type, detail }`2102721028 An image input block used within EvalItem content arrays.2102921030 - `image_url: string`2103121032 The URL of the image input.2103321034 - `type: "input_image"`2103521036 The type of the image input. Always `input_image`.2103721038 - `"input_image"`2103921040 - `detail: optional string`2104121042 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.2104321044 - `ResponseInputAudio object { input_audio, type }`2104521046 An audio input to the model.2104721048 - `role: "user" or "assistant" or "system" or "developer"`2104921050 The role of the message input. One of `user`, `assistant`, `system`, or21051 `developer`.2105221053 - `"user"`2105421055 - `"assistant"`2105621057 - `"system"`2105821059 - `"developer"`2106021061 - `type: optional "message"`2106221063 The type of the message input. Always `message`.2106421065 - `"message"`2106621067 - `type: "template"`2106821069 The type of input messages. Always `template`.2107021071 - `"template"`2107221073 - `ItemReferenceInputMessages object { item_reference, type }`2107421075 - `item_reference: string`2107621077 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"2107821079 - `type: "item_reference"`2108021081 The type of input messages. Always `item_reference`.2108221083 - `"item_reference"`2108421085 - `model: optional string`2108621087 The name of the model to use for generating completions (e.g. "o3-mini").2108821089 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`2109021091 - `max_completion_tokens: optional number`2109221093 The maximum number of tokens in the generated output.2109421095 - `reasoning_effort: optional ReasoningEffort or null`2109621097 Constrains effort on reasoning for reasoning models. Currently supported21098 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.21099 Reducing reasoning effort can result in faster responses and fewer tokens21100 used on reasoning in a response. Not all reasoning models support every21101 value. See the21102 [reasoning guide](/api/docs/guides/reasoning)21103 for model-specific support.2110421105 - `"none"`2110621107 - `"minimal"`2110821109 - `"low"`2111021111 - `"medium"`2111221113 - `"high"`2111421115 - `"xhigh"`2111621117 - `"max"`2111821119 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`2112021121 An object specifying the format that the model must output.2112221123 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables21124 Structured Outputs which ensures the model will match your supplied JSON21125 schema. Learn more in the [Structured Outputs21126 guide](/api/docs/guides/structured-outputs).2112721128 Setting to `{ "type": "json_object" }` enables the older JSON mode, which21129 ensures the message the model generates is valid JSON. Using `json_schema`21130 is preferred for models that support it.2113121132 - `ResponseFormatText object { type }`2113321134 Default response format. Used to generate text responses.2113521136 - `type: "text"`2113721138 The type of response format being defined. Always `text`.2113921140 - `"text"`2114121142 - `ResponseFormatJSONSchema object { json_schema, type }`2114321144 JSON Schema response format. Used to generate structured JSON responses.21145 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).2114621147 - `json_schema: object { name, description, schema, strict }`2114821149 Structured Outputs configuration options, including a JSON Schema.2115021151 - `name: string`2115221153 The name of the response format. Must be a-z, A-Z, 0-9, or contain21154 underscores and dashes, with a maximum length of 64.2115521156 - `description: optional string`2115721158 A description of what the response format is for, used by the model to21159 determine how to respond in the format.2116021161 - `schema: optional map[unknown]`2116221163 The schema for the response format, described as a JSON Schema object.21164 Learn how to build JSON schemas [here](https://json-schema.org/).2116521166 - `strict: optional boolean or null`2116721168 Whether to enable strict schema adherence when generating the output.21169 If set to true, the model will always follow the exact schema defined21170 in the `schema` field. Only a subset of JSON Schema is supported when21171 `strict` is `true`. To learn more, read the [Structured Outputs21172 guide](/api/docs/guides/structured-outputs).2117321174 - `type: "json_schema"`2117521176 The type of response format being defined. Always `json_schema`.2117721178 - `"json_schema"`2117921180 - `ResponseFormatJSONObject object { type }`2118121182 JSON object response format. An older method of generating JSON responses.21183 Using `json_schema` is recommended for models that support it. Note that the21184 model will not generate JSON without a system or user message instructing it21185 to do so.2118621187 - `type: "json_object"`2118821189 The type of response format being defined. Always `json_object`.2119021191 - `"json_object"`2119221193 - `seed: optional number`2119421195 A seed value to initialize the randomness, during sampling.2119621197 - `temperature: optional number`2119821199 A higher temperature increases randomness in the outputs.2120021201 - `tools: optional array of ChatCompletionFunctionTool`2120221203 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.2120421205 - `function: FunctionDefinition`2120621207 - `name: string`2120821209 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.2121021211 - `description: optional string`2121221213 A description of what the function does, used by the model to choose when and how to call the function.2121421215 - `parameters: optional FunctionParameters`2121621217 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.2121821219 Omitting `parameters` defines a function with an empty parameter list.2122021221 - `strict: optional boolean or null`2122221223 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).2122421225 - `type: "function"`2122621227 The type of the tool. Currently, only `function` is supported.2122821229 - `"function"`2123021231 - `top_p: optional number`2123221233 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.2123421235 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`2123621237 A ResponsesRunDataSource object describing a model sampling configuration.2123821239 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`2124021241 Determines what populates the `item` namespace in this run's data source.2124221243 - `EvalJSONLFileContentSource object { content, type }`2124421245 - `content: array of object { item, sample }`2124621247 The content of the jsonl file.2124821249 - `item: map[unknown]`2125021251 - `sample: optional map[unknown]`2125221253 - `type: "file_content"`2125421255 The type of jsonl source. Always `file_content`.2125621257 - `"file_content"`2125821259 - `EvalJSONLFileIDSource object { id, type }`2126021261 - `id: string`2126221263 The identifier of the file.2126421265 - `type: "file_id"`2126621267 The type of jsonl source. Always `file_id`.2126821269 - `"file_id"`2127021271 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`2127221273 A EvalResponsesSource object describing a run data source configuration.2127421275 - `type: "responses"`2127621277 The type of run data source. Always `responses`.2127821279 - `"responses"`2128021281 - `created_after: optional number or null`2128221283 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.2128421285 - `created_before: optional number or null`2128621287 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.2128821289 - `instructions_search: optional string or null`2129021291 Optional string to search the 'instructions' field. This is a query parameter used to select responses.2129221293 - `metadata: optional unknown or null`2129421295 Metadata filter for the responses. This is a query parameter used to select responses.2129621297 - `model: optional string or null`2129821299 The name of the model to find responses for. This is a query parameter used to select responses.2130021301 - `reasoning_effort: optional ReasoningEffort or null`2130221303 Constrains effort on reasoning for reasoning models. Currently supported21304 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.21305 Reducing reasoning effort can result in faster responses and fewer tokens21306 used on reasoning in a response. Not all reasoning models support every21307 value. See the21308 [reasoning guide](/api/docs/guides/reasoning)21309 for model-specific support.2131021311 - `temperature: optional number or null`2131221313 Sampling temperature. This is a query parameter used to select responses.2131421315 - `tools: optional array of string or null`2131621317 List of tool names. This is a query parameter used to select responses.2131821319 - `top_p: optional number or null`2132021321 Nucleus sampling parameter. This is a query parameter used to select responses.2132221323 - `users: optional array of string or null`2132421325 List of user identifiers. This is a query parameter used to select responses.2132621327 - `type: "responses"`2132821329 The type of run data source. Always `responses`.2133021331 - `"responses"`2133221333 - `input_messages: optional object { template, type } or object { item_reference, type }`2133421335 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.2133621337 - `InputMessagesTemplate object { template, type }`2133821339 - `template: array of object { content, role } or object { content, role, type }`2134021341 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.2134221343 - `ChatMessage object { content, role }`2134421345 - `content: string`2134621347 The content of the message.2134821349 - `role: string`2135021351 The role of the message (e.g. "system", "assistant", "user").2135221353 - `EvalMessageObject object { content, role, type }`2135421355 A message input to the model with a role indicating instruction following21356 hierarchy. Instructions given with the `developer` or `system` role take21357 precedence over instructions given with the `user` role. Messages with the21358 `assistant` role are presumed to have been generated by the model in previous21359 interactions.2136021361 - `content: string or ResponseInputText or object { text, type } or 3 more`2136221363 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.2136421365 - `TextInput = string`2136621367 A text input to the model.2136821369 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`2137021371 A text input to the model.2137221373 - `OutputText object { text, type }`2137421375 A text output from the model.2137621377 - `text: string`2137821379 The text output from the model.2138021381 - `type: "output_text"`2138221383 The type of the output text. Always `output_text`.2138421385 - `"output_text"`2138621387 - `InputImage object { image_url, type, detail }`2138821389 An image input block used within EvalItem content arrays.2139021391 - `image_url: string`2139221393 The URL of the image input.2139421395 - `type: "input_image"`2139621397 The type of the image input. Always `input_image`.2139821399 - `"input_image"`2140021401 - `detail: optional string`2140221403 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.2140421405 - `ResponseInputAudio object { input_audio, type }`2140621407 An audio input to the model.2140821409 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`2141021411 A list of inputs, each of which may be either an input text, output text, input21412 image, or input audio object.2141321414 - `role: "user" or "assistant" or "system" or "developer"`2141521416 The role of the message input. One of `user`, `assistant`, `system`, or21417 `developer`.2141821419 - `"user"`2142021421 - `"assistant"`2142221423 - `"system"`2142421425 - `"developer"`2142621427 - `type: optional "message"`2142821429 The type of the message input. Always `message`.2143021431 - `"message"`2143221433 - `type: "template"`2143421435 The type of input messages. Always `template`.2143621437 - `"template"`2143821439 - `InputMessagesItemReference object { item_reference, type }`2144021441 - `item_reference: string`2144221443 A reference to a variable in the `item` namespace. Ie, "item.name"2144421445 - `type: "item_reference"`2144621447 The type of input messages. Always `item_reference`.2144821449 - `"item_reference"`2145021451 - `model: optional string`2145221453 The name of the model to use for generating completions (e.g. "o3-mini").2145421455 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`2145621457 - `max_completion_tokens: optional number`2145821459 The maximum number of tokens in the generated output.2146021461 - `reasoning_effort: optional ReasoningEffort or null`2146221463 Constrains effort on reasoning for reasoning models. Currently supported21464 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.21465 Reducing reasoning effort can result in faster responses and fewer tokens21466 used on reasoning in a response. Not all reasoning models support every21467 value. See the21468 [reasoning guide](/api/docs/guides/reasoning)21469 for model-specific support.2147021471 - `seed: optional number`2147221473 A seed value to initialize the randomness, during sampling.2147421475 - `temperature: optional number`2147621477 A higher temperature increases randomness in the outputs.2147821479 - `text: optional object { format }`2148021481 Configuration options for a text response from the model. Can be plain21482 text or structured JSON data. Learn more:2148321484 - [Text inputs and outputs](/api/docs/guides/text)21485 - [Structured Outputs](/api/docs/guides/structured-outputs)2148621487 - `format: optional ResponseFormatTextConfig`2148821489 An object specifying the format that the model must output.2149021491 Configuring `{ "type": "json_schema" }` enables Structured Outputs,21492 which ensures the model will match your supplied JSON schema. Learn more in the21493 [Structured Outputs guide](/api/docs/guides/structured-outputs).2149421495 The default format is `{ "type": "text" }` with no additional options.2149621497 **Not recommended for gpt-4o and newer models:**2149821499 Setting to `{ "type": "json_object" }` enables the older JSON mode, which21500 ensures the message the model generates is valid JSON. Using `json_schema`21501 is preferred for models that support it.2150221503 - `ResponseFormatText object { type }`2150421505 Default response format. Used to generate text responses.2150621507 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`2150821509 JSON Schema response format. Used to generate structured JSON responses.21510 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).2151121512 - `name: string`2151321514 The name of the response format. Must be a-z, A-Z, 0-9, or contain21515 underscores and dashes, with a maximum length of 64.2151621517 - `schema: map[unknown]`2151821519 The schema for the response format, described as a JSON Schema object.21520 Learn how to build JSON schemas [here](https://json-schema.org/).2152121522 - `type: "json_schema"`2152321524 The type of response format being defined. Always `json_schema`.2152521526 - `"json_schema"`2152721528 - `description: optional string`2152921530 A description of what the response format is for, used by the model to21531 determine how to respond in the format.2153221533 - `strict: optional boolean or null`2153421535 Whether to enable strict schema adherence when generating the output.21536 If set to true, the model will always follow the exact schema defined21537 in the `schema` field. Only a subset of JSON Schema is supported when21538 `strict` is `true`. To learn more, read the [Structured Outputs21539 guide](/api/docs/guides/structured-outputs).2154021541 - `ResponseFormatJSONObject object { type }`2154221543 JSON object response format. An older method of generating JSON responses.21544 Using `json_schema` is recommended for models that support it. Note that the21545 model will not generate JSON without a system or user message instructing it21546 to do so.2154721548 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`2154921550 An array of tools the model may call while generating a response. You21551 can specify which tool to use by setting the `tool_choice` parameter.2155221553 The two categories of tools you can provide the model are:2155421555 - **Built-in tools**: Tools that are provided by OpenAI that extend the21556 model's capabilities, like [web search](/api/docs/guides/tools-web-search)21557 or [file search](/api/docs/guides/tools-file-search). Learn more about21558 [built-in tools](/api/docs/guides/tools).21559 - **Function calls (custom tools)**: Functions that are defined by you,21560 enabling the model to call your own code. Learn more about21561 [function calling](/api/docs/guides/function-calling).2156221563 - `Function object { name, parameters, strict, 6 more }`2156421565 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).2156621567 - `name: string`2156821569 The name of the function to call.2157021571 - `parameters: map[unknown] or null`2157221573 A JSON schema object describing the parameters of the function.2157421575 - `strict: boolean or null`2157621577 Whether strict parameter validation is enforced for this function tool.2157821579 - `type: "function"`2158021581 The type of the function tool. Always `function`.2158221583 - `"function"`2158421585 - `allowed_callers: optional array of "direct" or "programmatic" or null`2158621587 The tool invocation context(s).2158821589 - `"direct"`2159021591 - `"programmatic"`2159221593 - `async: optional boolean`2159421595 - `defer_loading: optional boolean`2159621597 Whether this function is deferred and loaded via tool search.2159821599 - `description: optional string or null`2160021601 A description of the function. Used by the model to determine whether or not to call the function.2160221603 - `output_schema: optional map[unknown] or null`2160421605 A JSON schema object describing the JSON value encoded in string outputs for this function.2160621607 - `FileSearch object { type, vector_store_ids, filters, 2 more }`2160821609 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).2161021611 - `type: "file_search"`2161221613 The type of the file search tool. Always `file_search`.2161421615 - `"file_search"`2161621617 - `vector_store_ids: array of string`2161821619 The IDs of the vector stores to search.2162021621 - `filters: optional ComparisonFilter or CompoundFilter or null`2162221623 A filter to apply.2162421625 - `ComparisonFilter object { key, type, value }`2162621627 A filter used to compare a specified attribute key to a given value using a defined comparison operation.2162821629 - `key: string`2163021631 The key to compare against the value.2163221633 - `type: "eq" or "ne" or "gt" or 5 more`2163421635 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.2163621637 - `eq`: equals21638 - `ne`: not equal21639 - `gt`: greater than21640 - `gte`: greater than or equal21641 - `lt`: less than21642 - `lte`: less than or equal21643 - `in`: in21644 - `nin`: not in2164521646 - `"eq"`2164721648 - `"ne"`2164921650 - `"gt"`2165121652 - `"gte"`2165321654 - `"lt"`2165521656 - `"lte"`2165721658 - `"in"`2165921660 - `"nin"`2166121662 - `value: string or number or boolean or array of string or number`2166321664 The value to compare against the attribute key; supports string, number, or boolean types.2166521666 - `string`2166721668 - `number`2166921670 - `boolean`2167121672 - `array of string or number`2167321674 - `string`2167521676 - `number`2167721678 - `CompoundFilter object { filters, type }`2167921680 Combine multiple filters using `and` or `or`.2168121682 - `filters: array of ComparisonFilter or unknown`2168321684 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.2168521686 - `ComparisonFilter object { key, type, value }`2168721688 A filter used to compare a specified attribute key to a given value using a defined comparison operation.2168921690 - `unknown`2169121692 - `type: "and" or "or"`2169321694 Type of operation: `and` or `or`.2169521696 - `"and"`2169721698 - `"or"`2169921700 - `max_num_results: optional number`2170121702 The maximum number of results to return. This number should be between 1 and 50 inclusive.2170321704 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`2170521706 Ranking options for search.2170721708 - `hybrid_search: optional object { embedding_weight, text_weight }`2170921710 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.2171121712 - `embedding_weight: number`2171321714 The weight of the embedding in the reciprocal ranking fusion.2171521716 - `text_weight: number`2171721718 The weight of the text in the reciprocal ranking fusion.2171921720 - `ranker: optional "auto" or "default-2024-11-15"`2172121722 The ranker to use for the file search.2172321724 - `"auto"`2172521726 - `"default-2024-11-15"`2172721728 - `score_threshold: optional number`2172921730 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.2173121732 - `Computer object { type }`2173321734 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).2173521736 - `type: "computer"`2173721738 The type of the computer tool. Always `computer`.2173921740 - `"computer"`2174121742 - `ComputerUsePreview object { display_height, display_width, environment, type }`2174321744 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).2174521746 - `display_height: number`2174721748 The height of the computer display.2174921750 - `display_width: number`2175121752 The width of the computer display.2175321754 - `environment: "windows" or "mac" or "linux" or 2 more`2175521756 The type of computer environment to control.2175721758 - `"windows"`2175921760 - `"mac"`2176121762 - `"linux"`2176321764 - `"ubuntu"`2176521766 - `"browser"`2176721768 - `type: "computer_use_preview"`2176921770 The type of the computer use tool. Always `computer_use_preview`.2177121772 - `"computer_use_preview"`2177321774 - `WebSearch object { type, external_web_access, filters, 2 more }`2177521776 Search the Internet for sources related to the prompt. Learn more about the21777 [web search tool](/api/docs/guides/tools-web-search).2177821779 - `type: "web_search" or "web_search_2025_08_26"`2178021781 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.2178221783 - `"web_search"`2178421785 - `"web_search_2025_08_26"`2178621787 - `external_web_access: optional boolean`2178821789 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.2179021791 - `filters: optional object { allowed_domains } or null`2179221793 Filters for the search.2179421795 - `allowed_domains: optional array of string or null`2179621797 Allowed domains for the search. If not provided, all domains are allowed.21798 Subdomains of the provided domains are allowed as well.2179921800 Example: `["pubmed.ncbi.nlm.nih.gov"]`2180121802 - `search_context_size: optional "low" or "medium" or "high"`2180321804 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.2180521806 - `"low"`2180721808 - `"medium"`2180921810 - `"high"`2181121812 - `user_location: optional object { city, country, region, 2 more } or null`2181321814 The approximate location of the user.2181521816 - `city: optional string or null`2181721818 Free text input for the city of the user, e.g. `San Francisco`.2181921820 - `country: optional string or null`2182121822 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.2182321824 - `region: optional string or null`2182521826 Free text input for the region of the user, e.g. `California`.2182721828 - `timezone: optional string or null`2182921830 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.2183121832 - `type: optional "approximate"`2183321834 The type of location approximation. Always `approximate`.2183521836 - `"approximate"`2183721838 - `Mcp object { server_label, type, allowed_callers, 9 more }`2183921840 Give the model access to additional tools via remote Model Context Protocol21841 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).2184221843 - `server_label: string`2184421845 A label for this MCP server, used to identify it in tool calls.2184621847 - `type: "mcp"`2184821849 The type of the MCP tool. Always `mcp`.2185021851 - `"mcp"`2185221853 - `allowed_callers: optional array of "direct" or "programmatic" or null`2185421855 The tool invocation context(s).2185621857 - `"direct"`2185821859 - `"programmatic"`2186021861 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`2186221863 List of allowed tool names or a filter object.2186421865 - `McpAllowedTools = array of string`2186621867 A string array of allowed tool names2186821869 - `McpToolFilter object { read_only, tool_names }`2187021871 A filter object to specify which tools are allowed.2187221873 - `read_only: optional boolean`2187421875 Indicates whether or not a tool modifies data or is read-only. If an21876 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),21877 it will match this filter.2187821879 - `tool_names: optional array of string`2188021881 List of allowed tool names.2188221883 - `authorization: optional string`2188421885 An OAuth access token that can be used with a remote MCP server, either21886 with a custom MCP server URL or a service connector. Your application21887 must handle the OAuth authorization flow and provide the token here.2188821889 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`2189021891 Identifier for service connectors, like those available in ChatGPT. One of21892 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more21893 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).2189421895 This field is deprecated for models released after September 1, 2026.21896 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to21897 connect through a Secure MCP Tunnel.2189821899 Currently supported `connector_id` values are:2190021901 - Dropbox: `connector_dropbox`21902 - Gmail: `connector_gmail`21903 - Google Calendar: `connector_googlecalendar`21904 - Google Drive: `connector_googledrive`21905 - Microsoft Teams: `connector_microsoftteams`21906 - Outlook Calendar: `connector_outlookcalendar`21907 - Outlook Email: `connector_outlookemail`21908 - SharePoint: `connector_sharepoint`2190921910 - `"connector_dropbox"`2191121912 - `"connector_gmail"`2191321914 - `"connector_googlecalendar"`2191521916 - `"connector_googledrive"`2191721918 - `"connector_microsoftteams"`2191921920 - `"connector_outlookcalendar"`2192121922 - `"connector_outlookemail"`2192321924 - `"connector_sharepoint"`2192521926 - `defer_loading: optional boolean`2192721928 Whether this MCP tool is deferred and discovered via tool search.2192921930 - `headers: optional map[string] or null`2193121932 Optional HTTP headers to send to the MCP server. Use for authentication21933 or other purposes.2193421935 - `require_approval: optional object { always, never } or "always" or "never" or null`2193621937 Specify which of the MCP server's tools require approval.2193821939 - `McpToolApprovalFilter object { always, never }`2194021941 Specify which of the MCP server's tools require approval. Can be21942 `always`, `never`, or a filter object associated with tools21943 that require approval.2194421945 - `always: optional object { read_only, tool_names }`2194621947 A filter object to specify which tools are allowed.2194821949 - `read_only: optional boolean`2195021951 Indicates whether or not a tool modifies data or is read-only. If an21952 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),21953 it will match this filter.2195421955 - `tool_names: optional array of string`2195621957 List of allowed tool names.2195821959 - `never: optional object { read_only, tool_names }`2196021961 A filter object to specify which tools are allowed.2196221963 - `read_only: optional boolean`2196421965 Indicates whether or not a tool modifies data or is read-only. If an21966 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),21967 it will match this filter.2196821969 - `tool_names: optional array of string`2197021971 List of allowed tool names.2197221973 - `McpToolApprovalSetting = "always" or "never"`2197421975 Specify a single approval policy for all tools. One of `always` or21976 `never`. When set to `always`, all tools will require approval. When21977 set to `never`, all tools will not require approval.2197821979 - `"always"`2198021981 - `"never"`2198221983 - `server_description: optional string`2198421985 Optional description of the MCP server, used to provide more context.2198621987 - `server_url: optional string`2198821989 The URL for the MCP server. One of `server_url`, `connector_id`, or21990 `tunnel_id` must be provided.2199121992 - `tunnel_id: optional string`2199321994 The Secure MCP Tunnel ID to use instead of a direct server URL. One of21995 `server_url`, `connector_id`, or `tunnel_id` must be provided.2199621997 - `CodeInterpreter object { container, type, allowed_callers }`2199821999 A tool that runs Python code to help generate a response to a prompt.2200022001 - `container: string or object { type, file_ids, memory_limit, network_policy }`2200222003 The code interpreter container. Can be a container ID or an object that22004 specifies uploaded file IDs to make available to your code, along with an22005 optional `memory_limit` setting.2200622007 - `string`2200822009 The container ID.2201022011 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`2201222013 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.2201422015 - `type: "auto"`2201622017 Always `auto`.2201822019 - `"auto"`2202022021 - `file_ids: optional array of string`2202222023 An optional list of uploaded files to make available to your code.2202422025 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`2202622027 The memory limit for the code interpreter container.2202822029 - `"1g"`2203022031 - `"4g"`2203222033 - `"16g"`2203422035 - `"64g"`2203622037 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`2203822039 Network access policy for the container.2204022041 - `ContainerNetworkPolicyDisabled object { type }`2204222043 - `type: "disabled"`2204422045 Disable outbound network access. Always `disabled`.2204622047 - `"disabled"`2204822049 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`2205022051 - `allowed_domains: array of string`2205222053 A list of allowed domains when type is `allowlist`.2205422055 - `type: "allowlist"`2205622057 Allow outbound network access only to specified domains. Always `allowlist`.2205822059 - `"allowlist"`2206022061 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`2206222063 Optional domain-scoped secrets for allowlisted domains.2206422065 - `domain: string`2206622067 The domain associated with the secret.2206822069 - `name: string`2207022071 The name of the secret to inject for the domain.2207222073 - `value: string`2207422075 The secret value to inject for the domain.2207622077 - `type: "code_interpreter"`2207822079 The type of the code interpreter tool. Always `code_interpreter`.2208022081 - `"code_interpreter"`2208222083 - `allowed_callers: optional array of "direct" or "programmatic" or null`2208422085 The tool invocation context(s).2208622087 - `"direct"`2208822089 - `"programmatic"`2209022091 - `ProgrammaticToolCalling object { type }`2209222093 - `type: "programmatic_tool_calling"`2209422095 The type of the tool. Always `programmatic_tool_calling`.2209622097 - `"programmatic_tool_calling"`2209822099 - `ImageGeneration object { type, action, background, 9 more }`2210022101 A tool that generates images using the GPT image models.2210222103 - `type: "image_generation"`2210422105 The type of the image generation tool. Always `image_generation`.2210622107 - `"image_generation"`2210822109 - `action: optional "generate" or "edit" or "auto"`2211022111 Whether to generate a new image or edit an existing image. Default: `auto`.2211222113 - `"generate"`2211422115 - `"edit"`2211622117 - `"auto"`2211822119 - `background: optional "transparent" or "opaque" or "auto"`2212022121 Set the background of the generated image. One of `transparent`, `opaque`,22122 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including22123 their `2026-09-08` snapshots, support `opaque` and `transparent`22124 backgrounds. Transparent backgrounds are available for supported GPT Image22125 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in22126 preview. When using `transparent`, set the output format to `png` or `webp`.22127 Default: `auto`.2212822129 - `"transparent"`2213022131 - `"opaque"`2213222133 - `"auto"`2213422135 - `input_fidelity: optional "high" or "low" or null`2213622137 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.2213822139 - `"high"`2214022141 - `"low"`2214222143 - `input_image_mask: optional object { file_id, image_url }`2214422145 Optional mask for inpainting. Contains `image_url`22146 (string, optional) and `file_id` (string, optional).2214722148 - `file_id: optional string`2214922150 File ID for the mask image.2215122152 - `image_url: optional string`2215322154 Base64-encoded mask image.2215522156 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`2215722158 The image generation model to use. One of `gpt-image-1`,22159 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,22160 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,22161 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,22162 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:22163 `gpt-image-1`.2216422165 - `string`2216622167 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`2216822169 The image generation model to use. One of `gpt-image-1`,22170 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,22171 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,22172 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,22173 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:22174 `gpt-image-1`.2217522176 - `"gpt-image-1"`2217722178 - `"gpt-image-1-mini"`2217922180 - `"gpt-image-1.5"`2218122182 - `"gpt-image-2"`2218322184 - `"gpt-image-2-2026-04-21"`2218522186 - `"gpt-image-2.5-sunburst"`2218722188 - `"gpt-image-2.5-sunburst-2026-09-08"`2218922190 - `"gpt-image-2.5-flare"`2219122192 - `"gpt-image-2.5-flare-2026-09-08"`2219322194 - `moderation: optional "auto" or "low"`2219522196 Moderation level for the generated image. Default: `auto`.2219722198 - `"auto"`2219922200 - `"low"`2220122202 - `output_compression: optional number`2220322204 Compression level for the output image. Default: 100.2220522206 - `output_format: optional "png" or "webp" or "jpeg"`2220722208 The output format of the generated image. One of `png`, `webp`, or22209 `jpeg`. Default: `png`.2221022211 - `"png"`2221222213 - `"webp"`2221422215 - `"jpeg"`2221622217 - `partial_images: optional number`2221822219 Number of partial images to generate in streaming mode, from 0 (default value) to 3.2222022221 - `quality: optional "low" or "medium" or "high" or 3 more`2222222223 The quality of the generated image. The GPT image models support `low`,22224 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,22225 including their `2026-09-08` snapshots, also support `xhigh` and `max`.22226 Default: `auto`.2222722228 - `"low"`2222922230 - `"medium"`2223122232 - `"high"`2223322234 - `"xhigh"`2223522236 - `"max"`2223722238 - `"auto"`2223922240 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`2224122242 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.2224322244 - `string`2224522246 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`2224722248 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.2224922250 - `"1024x1024"`2225122252 - `"1024x1536"`2225322254 - `"1536x1024"`2225522256 - `"auto"`2225722258 - `LocalShell object { type }`2225922260 A tool that allows the model to execute shell commands in a local environment.2226122262 - `type: "local_shell"`2226322264 The type of the local shell tool. Always `local_shell`.2226522266 - `"local_shell"`2226722268 - `Shell object { type, allowed_callers, environment }`2226922270 A tool that allows the model to execute shell commands.2227122272 - `type: "shell"`2227322274 The type of the shell tool. Always `shell`.2227522276 - `"shell"`2227722278 - `allowed_callers: optional array of "direct" or "programmatic" or null`2227922280 The tool invocation context(s).2228122282 - `"direct"`2228322284 - `"programmatic"`2228522286 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`2228722288 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`2228922290 - `type: "container_auto"`2229122292 Automatically creates a container for this request2229322294 - `"container_auto"`2229522296 - `file_ids: optional array of string`2229722298 An optional list of uploaded files to make available to your code.2229922300 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`2230122302 The memory limit for the container.2230322304 - `"1g"`2230522306 - `"4g"`2230722308 - `"16g"`2230922310 - `"64g"`2231122312 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`2231322314 Network access policy for the container.2231522316 - `ContainerNetworkPolicyDisabled object { type }`2231722318 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`2231922320 - `skills: optional array of SkillReference or InlineSkill`2232122322 An optional list of skills referenced by id or inline data.2232322324 - `SkillReference object { skill_id, type, version }`2232522326 - `skill_id: string`2232722328 The ID of the referenced skill.2232922330 - `type: "skill_reference"`2233122332 References a skill created with the /v1/skills endpoint.2233322334 - `"skill_reference"`2233522336 - `version: optional string`2233722338 Optional skill version. Use a positive integer or 'latest'. Omit for default.2233922340 - `InlineSkill object { description, name, source, type }`2234122342 - `description: string`2234322344 The description of the skill.2234522346 - `name: string`2234722348 The name of the skill.2234922350 - `source: InlineSkillSource`2235122352 Inline skill payload2235322354 - `data: string`2235522356 Base64-encoded skill zip bundle.2235722358 - `media_type: "application/zip"`2235922360 The media type of the inline skill payload. Must be `application/zip`.2236122362 - `"application/zip"`2236322364 - `type: "base64"`2236522366 The type of the inline skill source. Must be `base64`.2236722368 - `"base64"`2236922370 - `type: "inline"`2237122372 Defines an inline skill for this request.2237322374 - `"inline"`2237522376 - `LocalEnvironment object { type, skills }`2237722378 - `type: "local"`2237922380 Use a local computer environment.2238122382 - `"local"`2238322384 - `skills: optional array of LocalSkill`2238522386 An optional list of skills.2238722388 - `description: string`2238922390 The description of the skill.2239122392 - `name: string`2239322394 The name of the skill.2239522396 - `path: string`2239722398 The path to the directory containing the skill.2239922400 - `ContainerReference object { container_id, type }`2240122402 - `container_id: string`2240322404 The ID of the referenced container.2240522406 - `type: "container_reference"`2240722408 References a container created with the /v1/containers endpoint2240922410 - `"container_reference"`2241122412 - `Custom object { name, type, allowed_callers, 4 more }`2241322414 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)2241522416 - `name: string`2241722418 The name of the custom tool, used to identify it in tool calls.2241922420 - `type: "custom"`2242122422 The type of the custom tool. Always `custom`.2242322424 - `"custom"`2242522426 - `allowed_callers: optional array of "direct" or "programmatic" or null`2242722428 The tool invocation context(s).2242922430 - `"direct"`2243122432 - `"programmatic"`2243322434 - `async: optional boolean`2243522436 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2243722438 - `defer_loading: optional boolean`2243922440 Whether this tool should be deferred and discovered via tool search.2244122442 - `description: optional string`2244322444 Optional description of the custom tool, used to provide more context.2244522446 - `format: optional CustomToolInputFormat`2244722448 The input format for the custom tool. Default is unconstrained text.2244922450 - `Text object { type }`2245122452 Unconstrained free-form text.2245322454 - `type: "text"`2245522456 Unconstrained text format. Always `text`.2245722458 - `"text"`2245922460 - `Grammar object { definition, syntax, type }`2246122462 A grammar defined by the user.2246322464 - `definition: string`2246522466 The grammar definition.2246722468 - `syntax: "lark" or "regex"`2246922470 The syntax of the grammar definition. One of `lark` or `regex`.2247122472 - `"lark"`2247322474 - `"regex"`2247522476 - `type: "grammar"`2247722478 Grammar format. Always `grammar`.2247922480 - `"grammar"`2248122482 - `Namespace object { description, name, tools, type }`2248322484 Groups function/custom tools under a shared namespace.2248522486 - `description: string`2248722488 A description of the namespace shown to the model.2248922490 - `name: string`2249122492 The namespace name used in tool calls (for example, `crm`).2249322494 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`2249522496 The function/custom tools available inside this namespace.2249722498 - `Function object { name, type, allowed_callers, 6 more }`2249922500 - `name: string`2250122502 - `type: "function"`2250322504 - `"function"`2250522506 - `allowed_callers: optional array of "direct" or "programmatic" or null`2250722508 The tool invocation context(s).2250922510 - `"direct"`2251122512 - `"programmatic"`2251322514 - `async: optional boolean`2251522516 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2251722518 - `defer_loading: optional boolean`2251922520 Whether this function should be deferred and discovered via tool search.2252122522 - `description: optional string or null`2252322524 - `output_schema: optional map[unknown] or null`2252522526 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.2252722528 - `parameters: optional unknown or null`2252922530 - `strict: optional boolean or null`2253122532 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.2253322534 - `Custom object { name, type, allowed_callers, 4 more }`2253522536 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)2253722538 - `name: string`2253922540 The name of the custom tool, used to identify it in tool calls.2254122542 - `type: "custom"`2254322544 The type of the custom tool. Always `custom`.2254522546 - `"custom"`2254722548 - `allowed_callers: optional array of "direct" or "programmatic" or null`2254922550 The tool invocation context(s).2255122552 - `"direct"`2255322554 - `"programmatic"`2255522556 - `async: optional boolean`2255722558 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2255922560 - `defer_loading: optional boolean`2256122562 Whether this tool should be deferred and discovered via tool search.2256322564 - `description: optional string`2256522566 Optional description of the custom tool, used to provide more context.2256722568 - `format: optional CustomToolInputFormat`2256922570 The input format for the custom tool. Default is unconstrained text.2257122572 - `type: "namespace"`2257322574 The type of the tool. Always `namespace`.2257522576 - `"namespace"`2257722578 - `ToolSearch object { type, description, execution, parameters }`2257922580 Hosted or BYOT tool search configuration for deferred tools.2258122582 - `type: "tool_search"`2258322584 The type of the tool. Always `tool_search`.2258522586 - `"tool_search"`2258722588 - `description: optional string or null`2258922590 Description shown to the model for a client-executed tool search tool.2259122592 - `execution: optional "server" or "client"`2259322594 Whether tool search is executed by the server or by the client.2259522596 - `"server"`2259722598 - `"client"`2259922600 - `parameters: optional unknown or null`2260122602 Parameter schema for a client-executed tool search tool.2260322604 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`2260522606 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).2260722608 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`2260922610 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.2261122612 - `"web_search_preview"`2261322614 - `"web_search_preview_2025_03_11"`2261522616 - `search_content_types: optional array of "text" or "image"`2261722618 - `"text"`2261922620 - `"image"`2262122622 - `search_context_size: optional "low" or "medium" or "high"`2262322624 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.2262522626 - `"low"`2262722628 - `"medium"`2262922630 - `"high"`2263122632 - `user_location: optional object { type, city, country, 2 more } or null`2263322634 The user's location.2263522636 - `type: "approximate"`2263722638 The type of location approximation. Always `approximate`.2263922640 - `"approximate"`2264122642 - `city: optional string or null`2264322644 Free text input for the city of the user, e.g. `San Francisco`.2264522646 - `country: optional string or null`2264722648 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.2264922650 - `region: optional string or null`2265122652 Free text input for the region of the user, e.g. `California`.2265322654 - `timezone: optional string or null`2265522656 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.2265722658 - `ApplyPatch object { type, allowed_callers }`2265922660 Allows the assistant to create, delete, or update files using unified diffs.2266122662 - `type: "apply_patch"`2266322664 The type of the tool. Always `apply_patch`.2266522666 - `"apply_patch"`2266722668 - `allowed_callers: optional array of "direct" or "programmatic" or null`2266922670 The tool invocation context(s).2267122672 - `"direct"`2267322674 - `"programmatic"`2267522676 - `top_p: optional number`2267722678 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.2267922680 - `error: EvalAPIError`2268122682 An object representing an error response from the Eval API.2268322684 - `code: string`2268522686 The error code.2268722688 - `message: string`2268922690 The error message.2269122692 - `eval_id: string`2269322694 The identifier of the associated evaluation.2269522696 - `metadata: Metadata or null`2269722698 Set of 16 key-value pairs that can be attached to an object. This can be22699 useful for storing additional information about the object in a structured22700 format, and querying for objects via API or the dashboard.2270122702 Keys are strings with a maximum length of 64 characters. Values are strings22703 with a maximum length of 512 characters.2270422705 - `model: string`2270622707 The model that is evaluated, if applicable.2270822709 - `name: string`2271022711 The name of the evaluation run.2271222713 - `object: "eval.run"`2271422715 The type of the object. Always "eval.run".2271622717 - `"eval.run"`2271822719 - `per_model_usage: array of object { cached_tokens, completion_tokens, invocation_count, 3 more }`2272022721 Usage statistics for each model during the evaluation run.2272222723 - `cached_tokens: number`2272422725 The number of tokens retrieved from cache.2272622727 - `completion_tokens: number`2272822729 The number of completion tokens generated.2273022731 - `invocation_count: number`2273222733 The number of invocations.2273422735 - `model_name: string`2273622737 The name of the model.2273822739 - `prompt_tokens: number`2274022741 The number of prompt tokens used.2274222743 - `total_tokens: number`2274422745 The total number of tokens used.2274622747 - `per_testing_criteria_results: array of object { failed, passed, testing_criteria }`2274822749 Results per testing criteria applied during the evaluation run.2275022751 - `failed: number`2275222753 Number of tests failed for this criteria.2275422755 - `passed: number`2275622757 Number of tests passed for this criteria.2275822759 - `testing_criteria: string`2276022761 A description of the testing criteria.2276222763 - `report_url: string`2276422765 The URL to the rendered evaluation run report on the UI dashboard.2276622767 - `result_counts: object { errored, failed, passed, total }`2276822769 Counters summarizing the outcomes of the evaluation run.2277022771 - `errored: number`2277222773 Number of output items that resulted in an error.2277422775 - `failed: number`2277622777 Number of output items that failed to pass the evaluation.2277822779 - `passed: number`2278022781 Number of output items that passed the evaluation.2278222783 - `total: number`2278422785 Total number of executed output items.2278622787 - `status: string`2278822789 The status of the evaluation run.2279022791### Run Retrieve Response2279222793- `RunRetrieveResponse object { id, created_at, data_source, 11 more }`2279422795 A schema representing an evaluation run.2279622797 - `id: string`2279822799 Unique identifier for the evaluation run.2280022801 - `created_at: number`2280222803 Unix timestamp (in seconds) when the evaluation run was created.2280422805 - `data_source: CreateEvalJSONLRunDataSource or CreateEvalCompletionsRunDataSource or object { source, type, input_messages, 2 more }`2280622807 Information about the run's data source.2280822809 - `CreateEvalJSONLRunDataSource object { source, type }`2281022811 A JsonlRunDataSource object with that specifies a JSONL file that matches the eval2281222813 - `source: object { content, type } or object { id, type }`2281422815 Determines what populates the `item` namespace in the data source.2281622817 - `EvalJSONLFileContentSource object { content, type }`2281822819 - `content: array of object { item, sample }`2282022821 The content of the jsonl file.2282222823 - `item: map[unknown]`2282422825 - `sample: optional map[unknown]`2282622827 - `type: "file_content"`2282822829 The type of jsonl source. Always `file_content`.2283022831 - `"file_content"`2283222833 - `EvalJSONLFileIDSource object { id, type }`2283422835 - `id: string`2283622837 The identifier of the file.2283822839 - `type: "file_id"`2284022841 The type of jsonl source. Always `file_id`.2284222843 - `"file_id"`2284422845 - `type: "jsonl"`2284622847 The type of data source. Always `jsonl`.2284822849 - `"jsonl"`2285022851 - `CreateEvalCompletionsRunDataSource object { source, type, input_messages, 2 more }`2285222853 A CompletionsRunDataSource object describing a model sampling configuration.2285422855 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 3 more }`2285622857 Determines what populates the `item` namespace in this run's data source.2285822859 - `EvalJSONLFileContentSource object { content, type }`2286022861 - `content: array of object { item, sample }`2286222863 The content of the jsonl file.2286422865 - `item: map[unknown]`2286622867 - `sample: optional map[unknown]`2286822869 - `type: "file_content"`2287022871 The type of jsonl source. Always `file_content`.2287222873 - `"file_content"`2287422875 - `EvalJSONLFileIDSource object { id, type }`2287622877 - `id: string`2287822879 The identifier of the file.2288022881 - `type: "file_id"`2288222883 The type of jsonl source. Always `file_id`.2288422885 - `"file_id"`2288622887 - `StoredCompletionsRunDataSource object { type, created_after, created_before, 3 more }`2288822889 A StoredCompletionsRunDataSource configuration describing a set of filters2289022891 - `type: "stored_completions"`2289222893 The type of source. Always `stored_completions`.2289422895 - `"stored_completions"`2289622897 - `created_after: optional number or null`2289822899 An optional Unix timestamp to filter items created after this time.2290022901 - `created_before: optional number or null`2290222903 An optional Unix timestamp to filter items created before this time.2290422905 - `limit: optional number or null`2290622907 An optional maximum number of items to return.2290822909 - `metadata: optional Metadata or null`2291022911 Set of 16 key-value pairs that can be attached to an object. This can be22912 useful for storing additional information about the object in a structured22913 format, and querying for objects via API or the dashboard.2291422915 Keys are strings with a maximum length of 64 characters. Values are strings22916 with a maximum length of 512 characters.2291722918 - `model: optional string or null`2291922920 An optional model to filter by (e.g., 'gpt-6-astra').2292122922 - `type: "completions"`2292322924 The type of run data source. Always `completions`.2292522926 - `"completions"`2292722928 - `input_messages: optional object { template, type } or object { item_reference, type }`2292922930 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.2293122932 - `TemplateInputMessages object { template, type }`2293322934 - `template: array of EasyInputMessage or object { content, role, type }`2293522936 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.2293722938 - `EasyInputMessage object { content, role, phase, type }`2293922940 A message input to the model with a role indicating instruction following22941 hierarchy. Instructions given with the `developer` or `system` role take22942 precedence over instructions given with the `user` role. Messages with the22943 `assistant` role are presumed to have been generated by the model in previous22944 interactions.2294522946 - `content: string or ResponseInputMessageContentList`2294722948 Text, image, or audio input to the model, used to generate a response.22949 Can also contain previous assistant responses.2295022951 - `TextInput = string`2295222953 A text input to the model.2295422955 - `ResponseInputMessageContentList = array of ResponseInputContent`2295622957 A list of one or many input items to the model, containing different content22958 types.2295922960 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`2296122962 A text input to the model.2296322964 - `text: string`2296522966 The text input to the model.2296722968 - `type: "input_text"`2296922970 The type of the input item. Always `input_text`.2297122972 - `"input_text"`2297322974 - `prompt_cache_breakpoint: optional object { mode }`2297522976 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.2297722978 - `mode: "explicit"`2297922980 The breakpoint mode. Always `explicit`.2298122982 - `"explicit"`2298322984 - `ResponseInputImage object { detail, type, file_id, 2 more }`2298522986 An image input to the model. Learn about [image inputs](/api/docs/guides/images-vision).2298722988 - `detail: ImageDetail`2298922990 The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.2299122992 - `"low"`2299322994 - `"high"`2299522996 - `"auto"`2299722998 - `"original"`2299923000 - `type: "input_image"`2300123002 The type of the input item. Always `input_image`.2300323004 - `"input_image"`2300523006 - `file_id: optional string or null`2300723008 The ID of the file to be sent to the model.2300923010 - `image_url: optional string or null`2301123012 The URL of the image to be sent to the model. A fully qualified URL or base64 encoded image in a data URL.2301323014 - `prompt_cache_breakpoint: optional object { mode }`2301523016 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.2301723018 - `mode: "explicit"`2301923020 The breakpoint mode. Always `explicit`.2302123022 - `"explicit"`2302323024 - `ResponseInputFile object { type, detail, file_data, 4 more }`2302523026 A file input to the model.2302723028 - `type: "input_file"`2302923030 The type of the input item. Always `input_file`.2303123032 - `"input_file"`2303323034 - `detail: optional "auto" or "low" or "high"`2303523036 The detail level of the file to be sent to the model. Use `auto` to let the system select the detail level; for GPT-5.6 and later models, `auto` uses high-quality rendering, which may increase input token usage. Use `low` for lower-cost rendering, or `high` to render the file at higher quality. Defaults to `auto`.2303723038 - `"auto"`2303923040 - `"low"`2304123042 - `"high"`2304323044 - `file_data: optional string`2304523046 The content of the file to be sent to the model.2304723048 - `file_id: optional string or null`2304923050 The ID of the file to be sent to the model.2305123052 - `file_url: optional string`2305323054 The URL of the file to be sent to the model.2305523056 - `filename: optional string`2305723058 The name of the file to be sent to the model.2305923060 - `prompt_cache_breakpoint: optional object { mode }`2306123062 Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.2306323064 - `mode: "explicit"`2306523066 The breakpoint mode. Always `explicit`.2306723068 - `"explicit"`2306923070 - `role: "user" or "assistant" or "system" or "developer"`2307123072 The role of the message input. One of `user`, `assistant`, `system`, or23073 `developer`.2307423075 - `"user"`2307623077 - `"assistant"`2307823079 - `"system"`2308023081 - `"developer"`2308223083 - `phase: optional "commentary" or "final_answer" or null`2308423085 Labels an `assistant` message as intermediate commentary (`commentary`) or the final answer (`final_answer`).23086 For models like `gpt-5.3-codex` and beyond, when sending follow-up requests, preserve and resend23087 phase on all assistant messages — dropping it can degrade performance. Not used for user messages.2308823089 - `"commentary"`2309023091 - `"final_answer"`2309223093 - `type: optional "message"`2309423095 The type of the message input. Always `message`.2309623097 - `"message"`2309823099 - `EvalMessageObject object { content, role, type }`2310023101 A message input to the model with a role indicating instruction following23102 hierarchy. Instructions given with the `developer` or `system` role take23103 precedence over instructions given with the `user` role. Messages with the23104 `assistant` role are presumed to have been generated by the model in previous23105 interactions.2310623107 - `content: string or ResponseInputText or object { text, type } or 3 more`2310823109 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.2311023111 - `TextInput = string`2311223113 A text input to the model.2311423115 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`2311623117 A text input to the model.2311823119 - `OutputText object { text, type }`2312023121 A text output from the model.2312223123 - `text: string`2312423125 The text output from the model.2312623127 - `type: "output_text"`2312823129 The type of the output text. Always `output_text`.2313023131 - `"output_text"`2313223133 - `InputImage object { image_url, type, detail }`2313423135 An image input block used within EvalItem content arrays.2313623137 - `image_url: string`2313823139 The URL of the image input.2314023141 - `type: "input_image"`2314223143 The type of the image input. Always `input_image`.2314423145 - `"input_image"`2314623147 - `detail: optional string`2314823149 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.2315023151 - `ResponseInputAudio object { input_audio, type }`2315223153 An audio input to the model.2315423155 - `input_audio: object { data, format }`2315623157 - `data: string`2315823159 Base64-encoded audio data.2316023161 - `format: "mp3" or "wav"`2316223163 The format of the audio data. Currently supported formats are `mp3` and23164 `wav`.2316523166 - `"mp3"`2316723168 - `"wav"`2316923170 - `type: "input_audio"`2317123172 The type of the input item. Always `input_audio`.2317323174 - `"input_audio"`2317523176 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`2317723178 A list of inputs, each of which may be either an input text, output text, input23179 image, or input audio object.2318023181 - `TextInput = string`2318223183 A text input to the model.2318423185 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`2318623187 A text input to the model.2318823189 - `OutputText object { text, type }`2319023191 A text output from the model.2319223193 - `text: string`2319423195 The text output from the model.2319623197 - `type: "output_text"`2319823199 The type of the output text. Always `output_text`.2320023201 - `"output_text"`2320223203 - `InputImage object { image_url, type, detail }`2320423205 An image input block used within EvalItem content arrays.2320623207 - `image_url: string`2320823209 The URL of the image input.2321023211 - `type: "input_image"`2321223213 The type of the image input. Always `input_image`.2321423215 - `"input_image"`2321623217 - `detail: optional string`2321823219 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.2322023221 - `ResponseInputAudio object { input_audio, type }`2322223223 An audio input to the model.2322423225 - `role: "user" or "assistant" or "system" or "developer"`2322623227 The role of the message input. One of `user`, `assistant`, `system`, or23228 `developer`.2322923230 - `"user"`2323123232 - `"assistant"`2323323234 - `"system"`2323523236 - `"developer"`2323723238 - `type: optional "message"`2323923240 The type of the message input. Always `message`.2324123242 - `"message"`2324323244 - `type: "template"`2324523246 The type of input messages. Always `template`.2324723248 - `"template"`2324923250 - `ItemReferenceInputMessages object { item_reference, type }`2325123252 - `item_reference: string`2325323254 A reference to a variable in the `item` namespace. Ie, "item.input_trajectory"2325523256 - `type: "item_reference"`2325723258 The type of input messages. Always `item_reference`.2325923260 - `"item_reference"`2326123262 - `model: optional string`2326323264 The name of the model to use for generating completions (e.g. "o3-mini").2326523266 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, response_format, 4 more }`2326723268 - `max_completion_tokens: optional number`2326923270 The maximum number of tokens in the generated output.2327123272 - `reasoning_effort: optional ReasoningEffort or null`2327323274 Constrains effort on reasoning for reasoning models. Currently supported23275 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.23276 Reducing reasoning effort can result in faster responses and fewer tokens23277 used on reasoning in a response. Not all reasoning models support every23278 value. See the23279 [reasoning guide](/api/docs/guides/reasoning)23280 for model-specific support.2328123282 - `"none"`2328323284 - `"minimal"`2328523286 - `"low"`2328723288 - `"medium"`2328923290 - `"high"`2329123292 - `"xhigh"`2329323294 - `"max"`2329523296 - `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`2329723298 An object specifying the format that the model must output.2329923300 Setting to `{ "type": "json_schema", "json_schema": {...} }` enables23301 Structured Outputs which ensures the model will match your supplied JSON23302 schema. Learn more in the [Structured Outputs23303 guide](/api/docs/guides/structured-outputs).2330423305 Setting to `{ "type": "json_object" }` enables the older JSON mode, which23306 ensures the message the model generates is valid JSON. Using `json_schema`23307 is preferred for models that support it.2330823309 - `ResponseFormatText object { type }`2331023311 Default response format. Used to generate text responses.2331223313 - `type: "text"`2331423315 The type of response format being defined. Always `text`.2331623317 - `"text"`2331823319 - `ResponseFormatJSONSchema object { json_schema, type }`2332023321 JSON Schema response format. Used to generate structured JSON responses.23322 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).2332323324 - `json_schema: object { name, description, schema, strict }`2332523326 Structured Outputs configuration options, including a JSON Schema.2332723328 - `name: string`2332923330 The name of the response format. Must be a-z, A-Z, 0-9, or contain23331 underscores and dashes, with a maximum length of 64.2333223333 - `description: optional string`2333423335 A description of what the response format is for, used by the model to23336 determine how to respond in the format.2333723338 - `schema: optional map[unknown]`2333923340 The schema for the response format, described as a JSON Schema object.23341 Learn how to build JSON schemas [here](https://json-schema.org/).2334223343 - `strict: optional boolean or null`2334423345 Whether to enable strict schema adherence when generating the output.23346 If set to true, the model will always follow the exact schema defined23347 in the `schema` field. Only a subset of JSON Schema is supported when23348 `strict` is `true`. To learn more, read the [Structured Outputs23349 guide](/api/docs/guides/structured-outputs).2335023351 - `type: "json_schema"`2335223353 The type of response format being defined. Always `json_schema`.2335423355 - `"json_schema"`2335623357 - `ResponseFormatJSONObject object { type }`2335823359 JSON object response format. An older method of generating JSON responses.23360 Using `json_schema` is recommended for models that support it. Note that the23361 model will not generate JSON without a system or user message instructing it23362 to do so.2336323364 - `type: "json_object"`2336523366 The type of response format being defined. Always `json_object`.2336723368 - `"json_object"`2336923370 - `seed: optional number`2337123372 A seed value to initialize the randomness, during sampling.2337323374 - `temperature: optional number`2337523376 A higher temperature increases randomness in the outputs.2337723378 - `tools: optional array of ChatCompletionFunctionTool`2337923380 A list of tools the model may call. Currently, only functions are supported as a tool. Use this to provide a list of functions the model may generate JSON inputs for. A max of 128 functions are supported.2338123382 - `function: FunctionDefinition`2338323384 - `name: string`2338523386 The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.2338723388 - `description: optional string`2338923390 A description of what the function does, used by the model to choose when and how to call the function.2339123392 - `parameters: optional FunctionParameters`2339323394 The parameters the functions accepts, described as a JSON Schema object. See the [guide](/api/docs/guides/function-calling) for examples, and the [JSON Schema reference](https://json-schema.org/understanding-json-schema/) for documentation about the format.2339523396 Omitting `parameters` defines a function with an empty parameter list.2339723398 - `strict: optional boolean or null`2339923400 Whether to enable strict schema adherence when generating the function call. If set to true, the model will follow the exact schema defined in the `parameters` field. Only a subset of JSON Schema is supported when `strict` is `true`. Learn more about Structured Outputs in the [function calling guide](/api/docs/guides/function-calling).2340123402 - `type: "function"`2340323404 The type of the tool. Currently, only `function` is supported.2340523406 - `"function"`2340723408 - `top_p: optional number`2340923410 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.2341123412 - `ResponsesRunDataSource object { source, type, input_messages, 2 more }`2341323414 A ResponsesRunDataSource object describing a model sampling configuration.2341523416 - `source: object { content, type } or object { id, type } or object { type, created_after, created_before, 8 more }`2341723418 Determines what populates the `item` namespace in this run's data source.2341923420 - `EvalJSONLFileContentSource object { content, type }`2342123422 - `content: array of object { item, sample }`2342323424 The content of the jsonl file.2342523426 - `item: map[unknown]`2342723428 - `sample: optional map[unknown]`2342923430 - `type: "file_content"`2343123432 The type of jsonl source. Always `file_content`.2343323434 - `"file_content"`2343523436 - `EvalJSONLFileIDSource object { id, type }`2343723438 - `id: string`2343923440 The identifier of the file.2344123442 - `type: "file_id"`2344323444 The type of jsonl source. Always `file_id`.2344523446 - `"file_id"`2344723448 - `EvalResponsesSource object { type, created_after, created_before, 8 more }`2344923450 A EvalResponsesSource object describing a run data source configuration.2345123452 - `type: "responses"`2345323454 The type of run data source. Always `responses`.2345523456 - `"responses"`2345723458 - `created_after: optional number or null`2345923460 Only include items created after this timestamp (inclusive). This is a query parameter used to select responses.2346123462 - `created_before: optional number or null`2346323464 Only include items created before this timestamp (inclusive). This is a query parameter used to select responses.2346523466 - `instructions_search: optional string or null`2346723468 Optional string to search the 'instructions' field. This is a query parameter used to select responses.2346923470 - `metadata: optional unknown or null`2347123472 Metadata filter for the responses. This is a query parameter used to select responses.2347323474 - `model: optional string or null`2347523476 The name of the model to find responses for. This is a query parameter used to select responses.2347723478 - `reasoning_effort: optional ReasoningEffort or null`2347923480 Constrains effort on reasoning for reasoning models. Currently supported23481 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.23482 Reducing reasoning effort can result in faster responses and fewer tokens23483 used on reasoning in a response. Not all reasoning models support every23484 value. See the23485 [reasoning guide](/api/docs/guides/reasoning)23486 for model-specific support.2348723488 - `temperature: optional number or null`2348923490 Sampling temperature. This is a query parameter used to select responses.2349123492 - `tools: optional array of string or null`2349323494 List of tool names. This is a query parameter used to select responses.2349523496 - `top_p: optional number or null`2349723498 Nucleus sampling parameter. This is a query parameter used to select responses.2349923500 - `users: optional array of string or null`2350123502 List of user identifiers. This is a query parameter used to select responses.2350323504 - `type: "responses"`2350523506 The type of run data source. Always `responses`.2350723508 - `"responses"`2350923510 - `input_messages: optional object { template, type } or object { item_reference, type }`2351123512 Used when sampling from a model. Dictates the structure of the messages passed into the model. Can either be a reference to a prebuilt trajectory (ie, `item.input_trajectory`), or a template with variable references to the `item` namespace.2351323514 - `InputMessagesTemplate object { template, type }`2351523516 - `template: array of object { content, role } or object { content, role, type }`2351723518 A list of chat messages forming the prompt or context. May include variable references to the `item` namespace, ie {{item.name}}.2351923520 - `ChatMessage object { content, role }`2352123522 - `content: string`2352323524 The content of the message.2352523526 - `role: string`2352723528 The role of the message (e.g. "system", "assistant", "user").2352923530 - `EvalMessageObject object { content, role, type }`2353123532 A message input to the model with a role indicating instruction following23533 hierarchy. Instructions given with the `developer` or `system` role take23534 precedence over instructions given with the `user` role. Messages with the23535 `assistant` role are presumed to have been generated by the model in previous23536 interactions.2353723538 - `content: string or ResponseInputText or object { text, type } or 3 more`2353923540 Inputs to the model - can contain template strings. Supports text, output text, input images, and input audio, either as a single item or an array of items.2354123542 - `TextInput = string`2354323544 A text input to the model.2354523546 - `ResponseInputText object { text, type, prompt_cache_breakpoint }`2354723548 A text input to the model.2354923550 - `OutputText object { text, type }`2355123552 A text output from the model.2355323554 - `text: string`2355523556 The text output from the model.2355723558 - `type: "output_text"`2355923560 The type of the output text. Always `output_text`.2356123562 - `"output_text"`2356323564 - `InputImage object { image_url, type, detail }`2356523566 An image input block used within EvalItem content arrays.2356723568 - `image_url: string`2356923570 The URL of the image input.2357123572 - `type: "input_image"`2357323574 The type of the image input. Always `input_image`.2357523576 - `"input_image"`2357723578 - `detail: optional string`2357923580 The detail level of the image to be sent to the model. One of `high`, `low`, or `auto`. Defaults to `auto`.2358123582 - `ResponseInputAudio object { input_audio, type }`2358323584 An audio input to the model.2358523586 - `GraderInputs = array of string or ResponseInputText or object { text, type } or 2 more`2358723588 A list of inputs, each of which may be either an input text, output text, input23589 image, or input audio object.2359023591 - `role: "user" or "assistant" or "system" or "developer"`2359223593 The role of the message input. One of `user`, `assistant`, `system`, or23594 `developer`.2359523596 - `"user"`2359723598 - `"assistant"`2359923600 - `"system"`2360123602 - `"developer"`2360323604 - `type: optional "message"`2360523606 The type of the message input. Always `message`.2360723608 - `"message"`2360923610 - `type: "template"`2361123612 The type of input messages. Always `template`.2361323614 - `"template"`2361523616 - `InputMessagesItemReference object { item_reference, type }`2361723618 - `item_reference: string`2361923620 A reference to a variable in the `item` namespace. Ie, "item.name"2362123622 - `type: "item_reference"`2362323624 The type of input messages. Always `item_reference`.2362523626 - `"item_reference"`2362723628 - `model: optional string`2362923630 The name of the model to use for generating completions (e.g. "o3-mini").2363123632 - `sampling_params: optional object { max_completion_tokens, reasoning_effort, seed, 4 more }`2363323634 - `max_completion_tokens: optional number`2363523636 The maximum number of tokens in the generated output.2363723638 - `reasoning_effort: optional ReasoningEffort or null`2363923640 Constrains effort on reasoning for reasoning models. Currently supported23641 values are `none`, `minimal`, `low`, `medium`, `high`, `xhigh`, and `max`.23642 Reducing reasoning effort can result in faster responses and fewer tokens23643 used on reasoning in a response. Not all reasoning models support every23644 value. See the23645 [reasoning guide](/api/docs/guides/reasoning)23646 for model-specific support.2364723648 - `seed: optional number`2364923650 A seed value to initialize the randomness, during sampling.2365123652 - `temperature: optional number`2365323654 A higher temperature increases randomness in the outputs.2365523656 - `text: optional object { format }`2365723658 Configuration options for a text response from the model. Can be plain23659 text or structured JSON data. Learn more:2366023661 - [Text inputs and outputs](/api/docs/guides/text)23662 - [Structured Outputs](/api/docs/guides/structured-outputs)2366323664 - `format: optional ResponseFormatTextConfig`2366523666 An object specifying the format that the model must output.2366723668 Configuring `{ "type": "json_schema" }` enables Structured Outputs,23669 which ensures the model will match your supplied JSON schema. Learn more in the23670 [Structured Outputs guide](/api/docs/guides/structured-outputs).2367123672 The default format is `{ "type": "text" }` with no additional options.2367323674 **Not recommended for gpt-4o and newer models:**2367523676 Setting to `{ "type": "json_object" }` enables the older JSON mode, which23677 ensures the message the model generates is valid JSON. Using `json_schema`23678 is preferred for models that support it.2367923680 - `ResponseFormatText object { type }`2368123682 Default response format. Used to generate text responses.2368323684 - `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`2368523686 JSON Schema response format. Used to generate structured JSON responses.23687 Learn more about [Structured Outputs](/api/docs/guides/structured-outputs).2368823689 - `name: string`2369023691 The name of the response format. Must be a-z, A-Z, 0-9, or contain23692 underscores and dashes, with a maximum length of 64.2369323694 - `schema: map[unknown]`2369523696 The schema for the response format, described as a JSON Schema object.23697 Learn how to build JSON schemas [here](https://json-schema.org/).2369823699 - `type: "json_schema"`2370023701 The type of response format being defined. Always `json_schema`.2370223703 - `"json_schema"`2370423705 - `description: optional string`2370623707 A description of what the response format is for, used by the model to23708 determine how to respond in the format.2370923710 - `strict: optional boolean or null`2371123712 Whether to enable strict schema adherence when generating the output.23713 If set to true, the model will always follow the exact schema defined23714 in the `schema` field. Only a subset of JSON Schema is supported when23715 `strict` is `true`. To learn more, read the [Structured Outputs23716 guide](/api/docs/guides/structured-outputs).2371723718 - `ResponseFormatJSONObject object { type }`2371923720 JSON object response format. An older method of generating JSON responses.23721 Using `json_schema` is recommended for models that support it. Note that the23722 model will not generate JSON without a system or user message instructing it23723 to do so.2372423725 - `tools: optional array of object { name, parameters, strict, 6 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`2372623727 An array of tools the model may call while generating a response. You23728 can specify which tool to use by setting the `tool_choice` parameter.2372923730 The two categories of tools you can provide the model are:2373123732 - **Built-in tools**: Tools that are provided by OpenAI that extend the23733 model's capabilities, like [web search](/api/docs/guides/tools-web-search)23734 or [file search](/api/docs/guides/tools-file-search). Learn more about23735 [built-in tools](/api/docs/guides/tools).23736 - **Function calls (custom tools)**: Functions that are defined by you,23737 enabling the model to call your own code. Learn more about23738 [function calling](/api/docs/guides/function-calling).2373923740 - `Function object { name, parameters, strict, 6 more }`2374123742 Defines a function in your own code the model can choose to call. Learn more about [function calling](/api/docs/guides/function-calling).2374323744 - `name: string`2374523746 The name of the function to call.2374723748 - `parameters: map[unknown] or null`2374923750 A JSON schema object describing the parameters of the function.2375123752 - `strict: boolean or null`2375323754 Whether strict parameter validation is enforced for this function tool.2375523756 - `type: "function"`2375723758 The type of the function tool. Always `function`.2375923760 - `"function"`2376123762 - `allowed_callers: optional array of "direct" or "programmatic" or null`2376323764 The tool invocation context(s).2376523766 - `"direct"`2376723768 - `"programmatic"`2376923770 - `async: optional boolean`2377123772 - `defer_loading: optional boolean`2377323774 Whether this function is deferred and loaded via tool search.2377523776 - `description: optional string or null`2377723778 A description of the function. Used by the model to determine whether or not to call the function.2377923780 - `output_schema: optional map[unknown] or null`2378123782 A JSON schema object describing the JSON value encoded in string outputs for this function.2378323784 - `FileSearch object { type, vector_store_ids, filters, 2 more }`2378523786 A tool that searches for relevant content from uploaded files. Learn more about the [file search tool](/api/docs/guides/tools-file-search).2378723788 - `type: "file_search"`2378923790 The type of the file search tool. Always `file_search`.2379123792 - `"file_search"`2379323794 - `vector_store_ids: array of string`2379523796 The IDs of the vector stores to search.2379723798 - `filters: optional ComparisonFilter or CompoundFilter or null`2379923800 A filter to apply.2380123802 - `ComparisonFilter object { key, type, value }`2380323804 A filter used to compare a specified attribute key to a given value using a defined comparison operation.2380523806 - `key: string`2380723808 The key to compare against the value.2380923810 - `type: "eq" or "ne" or "gt" or 5 more`2381123812 Specifies the comparison operator: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.2381323814 - `eq`: equals23815 - `ne`: not equal23816 - `gt`: greater than23817 - `gte`: greater than or equal23818 - `lt`: less than23819 - `lte`: less than or equal23820 - `in`: in23821 - `nin`: not in2382223823 - `"eq"`2382423825 - `"ne"`2382623827 - `"gt"`2382823829 - `"gte"`2383023831 - `"lt"`2383223833 - `"lte"`2383423835 - `"in"`2383623837 - `"nin"`2383823839 - `value: string or number or boolean or array of string or number`2384023841 The value to compare against the attribute key; supports string, number, or boolean types.2384223843 - `string`2384423845 - `number`2384623847 - `boolean`2384823849 - `array of string or number`2385023851 - `string`2385223853 - `number`2385423855 - `CompoundFilter object { filters, type }`2385623857 Combine multiple filters using `and` or `or`.2385823859 - `filters: array of ComparisonFilter or unknown`2386023861 Array of filters to combine. Items can be `ComparisonFilter` or `CompoundFilter`.2386223863 - `ComparisonFilter object { key, type, value }`2386423865 A filter used to compare a specified attribute key to a given value using a defined comparison operation.2386623867 - `unknown`2386823869 - `type: "and" or "or"`2387023871 Type of operation: `and` or `or`.2387223873 - `"and"`2387423875 - `"or"`2387623877 - `max_num_results: optional number`2387823879 The maximum number of results to return. This number should be between 1 and 50 inclusive.2388023881 - `ranking_options: optional object { hybrid_search, ranker, score_threshold }`2388223883 Ranking options for search.2388423885 - `hybrid_search: optional object { embedding_weight, text_weight }`2388623887 Weights that control how reciprocal rank fusion balances semantic embedding matches versus sparse keyword matches when hybrid search is enabled.2388823889 - `embedding_weight: number`2389023891 The weight of the embedding in the reciprocal ranking fusion.2389223893 - `text_weight: number`2389423895 The weight of the text in the reciprocal ranking fusion.2389623897 - `ranker: optional "auto" or "default-2024-11-15"`2389823899 The ranker to use for the file search.2390023901 - `"auto"`2390223903 - `"default-2024-11-15"`2390423905 - `score_threshold: optional number`2390623907 The score threshold for the file search, a number between 0 and 1. Numbers closer to 1 will attempt to return only the most relevant results, but may return fewer results.2390823909 - `Computer object { type }`2391023911 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).2391223913 - `type: "computer"`2391423915 The type of the computer tool. Always `computer`.2391623917 - `"computer"`2391823919 - `ComputerUsePreview object { display_height, display_width, environment, type }`2392023921 A tool that controls a virtual computer. Learn more about the [computer tool](/api/docs/guides/tools-computer-use).2392223923 - `display_height: number`2392423925 The height of the computer display.2392623927 - `display_width: number`2392823929 The width of the computer display.2393023931 - `environment: "windows" or "mac" or "linux" or 2 more`2393223933 The type of computer environment to control.2393423935 - `"windows"`2393623937 - `"mac"`2393823939 - `"linux"`2394023941 - `"ubuntu"`2394223943 - `"browser"`2394423945 - `type: "computer_use_preview"`2394623947 The type of the computer use tool. Always `computer_use_preview`.2394823949 - `"computer_use_preview"`2395023951 - `WebSearch object { type, external_web_access, filters, 2 more }`2395223953 Search the Internet for sources related to the prompt. Learn more about the23954 [web search tool](/api/docs/guides/tools-web-search).2395523956 - `type: "web_search" or "web_search_2025_08_26"`2395723958 The type of the web search tool. One of `web_search` or `web_search_2025_08_26`.2395923960 - `"web_search"`2396123962 - `"web_search_2025_08_26"`2396323964 - `external_web_access: optional boolean`2396523966 Allow live internet access for web search. Defaults to true when omitted. When false, the web search tool runs in offline/cache-only mode and will not fetch new external content.2396723968 - `filters: optional object { allowed_domains } or null`2396923970 Filters for the search.2397123972 - `allowed_domains: optional array of string or null`2397323974 Allowed domains for the search. If not provided, all domains are allowed.23975 Subdomains of the provided domains are allowed as well.2397623977 Example: `["pubmed.ncbi.nlm.nih.gov"]`2397823979 - `search_context_size: optional "low" or "medium" or "high"`2398023981 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.2398223983 - `"low"`2398423985 - `"medium"`2398623987 - `"high"`2398823989 - `user_location: optional object { city, country, region, 2 more } or null`2399023991 The approximate location of the user.2399223993 - `city: optional string or null`2399423995 Free text input for the city of the user, e.g. `San Francisco`.2399623997 - `country: optional string or null`2399823999 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.2400024001 - `region: optional string or null`2400224003 Free text input for the region of the user, e.g. `California`.2400424005 - `timezone: optional string or null`2400624007 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.2400824009 - `type: optional "approximate"`2401024011 The type of location approximation. Always `approximate`.2401224013 - `"approximate"`2401424015 - `Mcp object { server_label, type, allowed_callers, 9 more }`2401624017 Give the model access to additional tools via remote Model Context Protocol24018 (MCP) servers. [Learn more about MCP](/api/docs/guides/tools-connectors-mcp).2401924020 - `server_label: string`2402124022 A label for this MCP server, used to identify it in tool calls.2402324024 - `type: "mcp"`2402524026 The type of the MCP tool. Always `mcp`.2402724028 - `"mcp"`2402924030 - `allowed_callers: optional array of "direct" or "programmatic" or null`2403124032 The tool invocation context(s).2403324034 - `"direct"`2403524036 - `"programmatic"`2403724038 - `allowed_tools: optional array of string or object { read_only, tool_names } or null`2403924040 List of allowed tool names or a filter object.2404124042 - `McpAllowedTools = array of string`2404324044 A string array of allowed tool names2404524046 - `McpToolFilter object { read_only, tool_names }`2404724048 A filter object to specify which tools are allowed.2404924050 - `read_only: optional boolean`2405124052 Indicates whether or not a tool modifies data or is read-only. If an24053 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),24054 it will match this filter.2405524056 - `tool_names: optional array of string`2405724058 List of allowed tool names.2405924060 - `authorization: optional string`2406124062 An OAuth access token that can be used with a remote MCP server, either24063 with a custom MCP server URL or a service connector. Your application24064 must handle the OAuth authorization flow and provide the token here.2406524066 - `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`2406724068 Identifier for service connectors, like those available in ChatGPT. One of24069 `server_url`, `connector_id`, or `tunnel_id` must be provided. Learn more24070 about service connectors [here](/api/docs/guides/tools-connectors-mcp#connectors).2407124072 This field is deprecated for models released after September 1, 2026.24073 Use `server_url` to connect to a remote MCP server, or `tunnel_id` to24074 connect through a Secure MCP Tunnel.2407524076 Currently supported `connector_id` values are:2407724078 - Dropbox: `connector_dropbox`24079 - Gmail: `connector_gmail`24080 - Google Calendar: `connector_googlecalendar`24081 - Google Drive: `connector_googledrive`24082 - Microsoft Teams: `connector_microsoftteams`24083 - Outlook Calendar: `connector_outlookcalendar`24084 - Outlook Email: `connector_outlookemail`24085 - SharePoint: `connector_sharepoint`2408624087 - `"connector_dropbox"`2408824089 - `"connector_gmail"`2409024091 - `"connector_googlecalendar"`2409224093 - `"connector_googledrive"`2409424095 - `"connector_microsoftteams"`2409624097 - `"connector_outlookcalendar"`2409824099 - `"connector_outlookemail"`2410024101 - `"connector_sharepoint"`2410224103 - `defer_loading: optional boolean`2410424105 Whether this MCP tool is deferred and discovered via tool search.2410624107 - `headers: optional map[string] or null`2410824109 Optional HTTP headers to send to the MCP server. Use for authentication24110 or other purposes.2411124112 - `require_approval: optional object { always, never } or "always" or "never" or null`2411324114 Specify which of the MCP server's tools require approval.2411524116 - `McpToolApprovalFilter object { always, never }`2411724118 Specify which of the MCP server's tools require approval. Can be24119 `always`, `never`, or a filter object associated with tools24120 that require approval.2412124122 - `always: optional object { read_only, tool_names }`2412324124 A filter object to specify which tools are allowed.2412524126 - `read_only: optional boolean`2412724128 Indicates whether or not a tool modifies data or is read-only. If an24129 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),24130 it will match this filter.2413124132 - `tool_names: optional array of string`2413324134 List of allowed tool names.2413524136 - `never: optional object { read_only, tool_names }`2413724138 A filter object to specify which tools are allowed.2413924140 - `read_only: optional boolean`2414124142 Indicates whether or not a tool modifies data or is read-only. If an24143 MCP server is [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),24144 it will match this filter.2414524146 - `tool_names: optional array of string`2414724148 List of allowed tool names.2414924150 - `McpToolApprovalSetting = "always" or "never"`2415124152 Specify a single approval policy for all tools. One of `always` or24153 `never`. When set to `always`, all tools will require approval. When24154 set to `never`, all tools will not require approval.2415524156 - `"always"`2415724158 - `"never"`2415924160 - `server_description: optional string`2416124162 Optional description of the MCP server, used to provide more context.2416324164 - `server_url: optional string`2416524166 The URL for the MCP server. One of `server_url`, `connector_id`, or24167 `tunnel_id` must be provided.2416824169 - `tunnel_id: optional string`2417024171 The Secure MCP Tunnel ID to use instead of a direct server URL. One of24172 `server_url`, `connector_id`, or `tunnel_id` must be provided.2417324174 - `CodeInterpreter object { container, type, allowed_callers }`2417524176 A tool that runs Python code to help generate a response to a prompt.2417724178 - `container: string or object { type, file_ids, memory_limit, network_policy }`2417924180 The code interpreter container. Can be a container ID or an object that24181 specifies uploaded file IDs to make available to your code, along with an24182 optional `memory_limit` setting.2418324184 - `string`2418524186 The container ID.2418724188 - `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`2418924190 Configuration for a code interpreter container. Optionally specify the IDs of the files to run the code on.2419124192 - `type: "auto"`2419324194 Always `auto`.2419524196 - `"auto"`2419724198 - `file_ids: optional array of string`2419924200 An optional list of uploaded files to make available to your code.2420124202 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`2420324204 The memory limit for the code interpreter container.2420524206 - `"1g"`2420724208 - `"4g"`2420924210 - `"16g"`2421124212 - `"64g"`2421324214 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`2421524216 Network access policy for the container.2421724218 - `ContainerNetworkPolicyDisabled object { type }`2421924220 - `type: "disabled"`2422124222 Disable outbound network access. Always `disabled`.2422324224 - `"disabled"`2422524226 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`2422724228 - `allowed_domains: array of string`2422924230 A list of allowed domains when type is `allowlist`.2423124232 - `type: "allowlist"`2423324234 Allow outbound network access only to specified domains. Always `allowlist`.2423524236 - `"allowlist"`2423724238 - `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`2423924240 Optional domain-scoped secrets for allowlisted domains.2424124242 - `domain: string`2424324244 The domain associated with the secret.2424524246 - `name: string`2424724248 The name of the secret to inject for the domain.2424924250 - `value: string`2425124252 The secret value to inject for the domain.2425324254 - `type: "code_interpreter"`2425524256 The type of the code interpreter tool. Always `code_interpreter`.2425724258 - `"code_interpreter"`2425924260 - `allowed_callers: optional array of "direct" or "programmatic" or null`2426124262 The tool invocation context(s).2426324264 - `"direct"`2426524266 - `"programmatic"`2426724268 - `ProgrammaticToolCalling object { type }`2426924270 - `type: "programmatic_tool_calling"`2427124272 The type of the tool. Always `programmatic_tool_calling`.2427324274 - `"programmatic_tool_calling"`2427524276 - `ImageGeneration object { type, action, background, 9 more }`2427724278 A tool that generates images using the GPT image models.2427924280 - `type: "image_generation"`2428124282 The type of the image generation tool. Always `image_generation`.2428324284 - `"image_generation"`2428524286 - `action: optional "generate" or "edit" or "auto"`2428724288 Whether to generate a new image or edit an existing image. Default: `auto`.2428924290 - `"generate"`2429124292 - `"edit"`2429324294 - `"auto"`2429524296 - `background: optional "transparent" or "opaque" or "auto"`2429724298 Set the background of the generated image. One of `transparent`, `opaque`,24299 or `auto`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`, including24300 their `2026-09-08` snapshots, support `opaque` and `transparent`24301 backgrounds. Transparent backgrounds are available for supported GPT Image24302 models. For `gpt-image-2` and `gpt-image-2-2026-04-21`, this support is in24303 preview. When using `transparent`, set the output format to `png` or `webp`.24304 Default: `auto`.2430524306 - `"transparent"`2430724308 - `"opaque"`2430924310 - `"auto"`2431124312 - `input_fidelity: optional "high" or "low" or null`2431324314 Control how much effort the model will exert to match the style and features, especially facial features, of input images. This parameter is only supported for `gpt-image-1` and `gpt-image-1.5` and later models, unsupported for `gpt-image-1-mini`. Supports `high` and `low`. Defaults to `low`.2431524316 - `"high"`2431724318 - `"low"`2431924320 - `input_image_mask: optional object { file_id, image_url }`2432124322 Optional mask for inpainting. Contains `image_url`24323 (string, optional) and `file_id` (string, optional).2432424325 - `file_id: optional string`2432624327 File ID for the mask image.2432824329 - `image_url: optional string`2433024331 Base64-encoded mask image.2433224333 - `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`2433424335 The image generation model to use. One of `gpt-image-1`,24336 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,24337 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,24338 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,24339 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:24340 `gpt-image-1`.2434124342 - `string`2434324344 - `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 6 more`2434524346 The image generation model to use. One of `gpt-image-1`,24347 `gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,24348 `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`,24349 `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`,24350 `gpt-image-2.5-flare-2026-09-08`, or `chatgpt-image-latest`. Default:24351 `gpt-image-1`.2435224353 - `"gpt-image-1"`2435424355 - `"gpt-image-1-mini"`2435624357 - `"gpt-image-1.5"`2435824359 - `"gpt-image-2"`2436024361 - `"gpt-image-2-2026-04-21"`2436224363 - `"gpt-image-2.5-sunburst"`2436424365 - `"gpt-image-2.5-sunburst-2026-09-08"`2436624367 - `"gpt-image-2.5-flare"`2436824369 - `"gpt-image-2.5-flare-2026-09-08"`2437024371 - `moderation: optional "auto" or "low"`2437224373 Moderation level for the generated image. Default: `auto`.2437424375 - `"auto"`2437624377 - `"low"`2437824379 - `output_compression: optional number`2438024381 Compression level for the output image. Default: 100.2438224383 - `output_format: optional "png" or "webp" or "jpeg"`2438424385 The output format of the generated image. One of `png`, `webp`, or24386 `jpeg`. Default: `png`.2438724388 - `"png"`2438924390 - `"webp"`2439124392 - `"jpeg"`2439324394 - `partial_images: optional number`2439524396 Number of partial images to generate in streaming mode, from 0 (default value) to 3.2439724398 - `quality: optional "low" or "medium" or "high" or 3 more`2439924400 The quality of the generated image. The GPT image models support `low`,24401 `medium`, and `high`. `gpt-image-2.5-sunburst` and `gpt-image-2.5-flare`,24402 including their `2026-09-08` snapshots, also support `xhigh` and `max`.24403 Default: `auto`.2440424405 - `"low"`2440624407 - `"medium"`2440824409 - `"high"`2441024411 - `"xhigh"`2441224413 - `"max"`2441424415 - `"auto"`2441624417 - `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`2441824419 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.2442024421 - `string`2442224423 - `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`2442424425 The size of the generated images. For `gpt-image-2`, `gpt-image-2-2026-04-21`, `gpt-image-2.5-sunburst`, `gpt-image-2.5-sunburst-2026-09-08`, `gpt-image-2.5-flare`, and `gpt-image-2.5-flare-2026-09-08`, arbitrary resolutions are supported as `WIDTHxHEIGHT` strings, for example `1536x864`. Width and height must both be divisible by 16 and the requested aspect ratio must be between 1:3 and 3:1. Resolutions above `2560x1440` are experimental, and the maximum supported resolution is `3840x2160`. The requested size must also satisfy the model's current pixel and edge limits. The standard sizes `1024x1024`, `1536x1024`, and `1024x1536` are supported by the GPT image models; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.2442624427 - `"1024x1024"`2442824429 - `"1024x1536"`2443024431 - `"1536x1024"`2443224433 - `"auto"`2443424435 - `LocalShell object { type }`2443624437 A tool that allows the model to execute shell commands in a local environment.2443824439 - `type: "local_shell"`2444024441 The type of the local shell tool. Always `local_shell`.2444224443 - `"local_shell"`2444424445 - `Shell object { type, allowed_callers, environment }`2444624447 A tool that allows the model to execute shell commands.2444824449 - `type: "shell"`2445024451 The type of the shell tool. Always `shell`.2445224453 - `"shell"`2445424455 - `allowed_callers: optional array of "direct" or "programmatic" or null`2445624457 The tool invocation context(s).2445824459 - `"direct"`2446024461 - `"programmatic"`2446224463 - `environment: optional ContainerAuto or LocalEnvironment or ContainerReference or null`2446424465 - `ContainerAuto object { type, file_ids, memory_limit, 2 more }`2446624467 - `type: "container_auto"`2446824469 Automatically creates a container for this request2447024471 - `"container_auto"`2447224473 - `file_ids: optional array of string`2447424475 An optional list of uploaded files to make available to your code.2447624477 - `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`2447824479 The memory limit for the container.2448024481 - `"1g"`2448224483 - `"4g"`2448424485 - `"16g"`2448624487 - `"64g"`2448824489 - `network_policy: optional ContainerNetworkPolicyDisabled or ContainerNetworkPolicyAllowlist`2449024491 Network access policy for the container.2449224493 - `ContainerNetworkPolicyDisabled object { type }`2449424495 - `ContainerNetworkPolicyAllowlist object { allowed_domains, type, domain_secrets }`2449624497 - `skills: optional array of SkillReference or InlineSkill`2449824499 An optional list of skills referenced by id or inline data.2450024501 - `SkillReference object { skill_id, type, version }`2450224503 - `skill_id: string`2450424505 The ID of the referenced skill.2450624507 - `type: "skill_reference"`2450824509 References a skill created with the /v1/skills endpoint.2451024511 - `"skill_reference"`2451224513 - `version: optional string`2451424515 Optional skill version. Use a positive integer or 'latest'. Omit for default.2451624517 - `InlineSkill object { description, name, source, type }`2451824519 - `description: string`2452024521 The description of the skill.2452224523 - `name: string`2452424525 The name of the skill.2452624527 - `source: InlineSkillSource`2452824529 Inline skill payload2453024531 - `data: string`2453224533 Base64-encoded skill zip bundle.2453424535 - `media_type: "application/zip"`2453624537 The media type of the inline skill payload. Must be `application/zip`.2453824539 - `"application/zip"`2454024541 - `type: "base64"`2454224543 The type of the inline skill source. Must be `base64`.2454424545 - `"base64"`2454624547 - `type: "inline"`2454824549 Defines an inline skill for this request.2455024551 - `"inline"`2455224553 - `LocalEnvironment object { type, skills }`2455424555 - `type: "local"`2455624557 Use a local computer environment.2455824559 - `"local"`2456024561 - `skills: optional array of LocalSkill`2456224563 An optional list of skills.2456424565 - `description: string`2456624567 The description of the skill.2456824569 - `name: string`2457024571 The name of the skill.2457224573 - `path: string`2457424575 The path to the directory containing the skill.2457624577 - `ContainerReference object { container_id, type }`2457824579 - `container_id: string`2458024581 The ID of the referenced container.2458224583 - `type: "container_reference"`2458424585 References a container created with the /v1/containers endpoint2458624587 - `"container_reference"`2458824589 - `Custom object { name, type, allowed_callers, 4 more }`2459024591 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)2459224593 - `name: string`2459424595 The name of the custom tool, used to identify it in tool calls.2459624597 - `type: "custom"`2459824599 The type of the custom tool. Always `custom`.2460024601 - `"custom"`2460224603 - `allowed_callers: optional array of "direct" or "programmatic" or null`2460424605 The tool invocation context(s).2460624607 - `"direct"`2460824609 - `"programmatic"`2461024611 - `async: optional boolean`2461224613 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2461424615 - `defer_loading: optional boolean`2461624617 Whether this tool should be deferred and discovered via tool search.2461824619 - `description: optional string`2462024621 Optional description of the custom tool, used to provide more context.2462224623 - `format: optional CustomToolInputFormat`2462424625 The input format for the custom tool. Default is unconstrained text.2462624627 - `Text object { type }`2462824629 Unconstrained free-form text.2463024631 - `type: "text"`2463224633 Unconstrained text format. Always `text`.2463424635 - `"text"`2463624637 - `Grammar object { definition, syntax, type }`2463824639 A grammar defined by the user.2464024641 - `definition: string`2464224643 The grammar definition.2464424645 - `syntax: "lark" or "regex"`2464624647 The syntax of the grammar definition. One of `lark` or `regex`.2464824649 - `"lark"`2465024651 - `"regex"`2465224653 - `type: "grammar"`2465424655 Grammar format. Always `grammar`.2465624657 - `"grammar"`2465824659 - `Namespace object { description, name, tools, type }`2466024661 Groups function/custom tools under a shared namespace.2466224663 - `description: string`2466424665 A description of the namespace shown to the model.2466624667 - `name: string`2466824669 The namespace name used in tool calls (for example, `crm`).2467024671 - `tools: array of object { name, type, allowed_callers, 6 more } or object { name, type, allowed_callers, 4 more }`2467224673 The function/custom tools available inside this namespace.2467424675 - `Function object { name, type, allowed_callers, 6 more }`2467624677 - `name: string`2467824679 - `type: "function"`2468024681 - `"function"`2468224683 - `allowed_callers: optional array of "direct" or "programmatic" or null`2468424685 The tool invocation context(s).2468624687 - `"direct"`2468824689 - `"programmatic"`2469024691 - `async: optional boolean`2469224693 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2469424695 - `defer_loading: optional boolean`2469624697 Whether this function should be deferred and discovered via tool search.2469824699 - `description: optional string or null`2470024701 - `output_schema: optional map[unknown] or null`2470224703 A JSON Schema describing the JSON value encoded in string outputs for this function tool. This does not describe content-array outputs.2470424705 - `parameters: optional unknown or null`2470624707 - `strict: optional boolean or null`2470824709 Whether to enforce strict parameter validation. If omitted, Responses attempts to use strict validation when the schema is compatible, and falls back to non-strict validation otherwise.2471024711 - `Custom object { name, type, allowed_callers, 4 more }`2471224713 A custom tool that processes input using a specified format. Learn more about [custom tools](/api/docs/guides/function-calling#custom-tools)2471424715 - `name: string`2471624717 The name of the custom tool, used to identify it in tool calls.2471824719 - `type: "custom"`2472024721 The type of the custom tool. Always `custom`.2472224723 - `"custom"`2472424725 - `allowed_callers: optional array of "direct" or "programmatic" or null`2472624727 The tool invocation context(s).2472824729 - `"direct"`2473024731 - `"programmatic"`2473224733 - `async: optional boolean`2473424735 Whether the tool response can be returned asynchronously versus immediately returned on next response creation.2473624737 - `defer_loading: optional boolean`2473824739 Whether this tool should be deferred and discovered via tool search.2474024741 - `description: optional string`2474224743 Optional description of the custom tool, used to provide more context.2474424745 - `format: optional CustomToolInputFormat`2474624747 The input format for the custom tool. Default is unconstrained text.2474824749 - `type: "namespace"`2475024751 The type of the tool. Always `namespace`.2475224753 - `"namespace"`2475424755 - `ToolSearch object { type, description, execution, parameters }`2475624757 Hosted or BYOT tool search configuration for deferred tools.2475824759 - `type: "tool_search"`2476024761 The type of the tool. Always `tool_search`.2476224763 - `"tool_search"`2476424765 - `description: optional string or null`2476624767 Description shown to the model for a client-executed tool search tool.2476824769 - `execution: optional "server" or "client"`2477024771 Whether tool search is executed by the server or by the client.2477224773 - `"server"`2477424775 - `"client"`2477624777 - `parameters: optional unknown or null`2477824779 Parameter schema for a client-executed tool search tool.2478024781 - `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`2478224783 This tool searches the web for relevant results to use in a response. Learn more about the [web search tool](/api/docs/guides/tools-web-search).2478424785 - `type: "web_search_preview" or "web_search_preview_2025_03_11"`2478624787 The type of the web search tool. One of `web_search_preview` or `web_search_preview_2025_03_11`.2478824789 - `"web_search_preview"`2479024791 - `"web_search_preview_2025_03_11"`2479224793 - `search_content_types: optional array of "text" or "image"`2479424795 - `"text"`2479624797 - `"image"`2479824799 - `search_context_size: optional "low" or "medium" or "high"`2480024801 High level guidance for the amount of context window space to use for the search. One of `low`, `medium`, or `high`. `medium` is the default.2480224803 - `"low"`2480424805 - `"medium"`2480624807 - `"high"`2480824809 - `user_location: optional object { type, city, country, 2 more } or null`2481024811 The user's location.2481224813 - `type: "approximate"`2481424815 The type of location approximation. Always `approximate`.2481624817 - `"approximate"`2481824819 - `city: optional string or null`2482024821 Free text input for the city of the user, e.g. `San Francisco`.2482224823 - `country: optional string or null`2482424825 The two-letter [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1) of the user, e.g. `US`.2482624827 - `region: optional string or null`2482824829 Free text input for the region of the user, e.g. `California`.2483024831 - `timezone: optional string or null`2483224833 The [IANA timezone](https://timeapi.io/documentation/iana-timezones) of the user, e.g. `America/Los_Angeles`.2483424835 - `ApplyPatch object { type, allowed_callers }`2483624837 Allows the assistant to create, delete, or update files using unified diffs.2483824839 - `type: "apply_patch"`2484024841 The type of the tool. Always `apply_patch`.2484224843 - `"apply_patch"`2484424845 - `allowed_callers: optional array of "direct" or "programmatic" or null`2484624847 The tool invocation context(s).2484824849 - `"direct"`2485024851 - `"programmatic"`2485224853 - `top_p: optional number`2485424855 An alternative to temperature for nucleus sampling; 1.0 includes all tokens.2485624857 - `error: EvalAPIError`2485824859 An object representing an error response from the Eval API.2486024861 - `code: string`2486224863 The error code.2486424865 - `message: string`2486624867 The error message.2486824869 - `eval_id: string`2487024871 The identifier of the associated evaluation.2487224873 - `metadata: Metadata or null`2487424875 Set of 16 key-value pairs that can be attached to an object. This can be24876 useful for storing additional information about the object in a structured24877 format, and querying for objects via API or the dashboard.2487824879 Keys are strings with a maximum length of 64 characters. Values are strings24880 with a maximum length of 512 characters.2488124882 - `model: string`2488324884 The model that is evaluated, if applicable.2488524886 - `name: string`2488724888 The name of the evaluation run.2488924890 - `object: "eval.run"`2489124892 The type of the object. Always "eval.run".2489324894 - `"eval.run"`2489524896 - `per_model_usage: array of object { cached_tokens, completion_tokens, invocation_count, 3 more }`2489724898 Usage statistics for each model during the evaluation run.2489924900 - `cached_tokens: number`2490124902 The number of tokens retrieved from cache.2490324904 - `completion_tokens: number`2490524906 The number of completion tokens generated.2490724908 - `invocation_count: number`2490924910 The number of invocations.2491124912 - `model_name: string`2491324914 The name of the model.2491524916 - `prompt_tokens: number`2491724918 The number of prompt tokens used.2491924920 - `total_tokens: number`2492124922 The total number of tokens used.2492324924 - `per_testing_criteria_results: array of object { failed, passed, testing_criteria }`2492524926 Results per testing criteria applied during the evaluation run.2492724928 - `failed: number`2492924930 Number of tests failed for this criteria.2493124932 - `passed: number`2493324934 Number of tests passed for this criteria.2493524936 - `testing_criteria: string`2493724938 A description of the testing criteria.2493924940 - `report_url: string`2494124942 The URL to the rendered evaluation run report on the UI dashboard.2494324944 - `result_counts: object { errored, failed, passed, total }`2494524946 Counters summarizing the outcomes of the evaluation run.2494724948 - `errored: number`2494924950 Number of output items that resulted in an error.2495124952 - `failed: number`2495324954 Number of output items that failed to pass the evaluation.2495524956 - `passed: number`2495724958 Number of output items that passed the evaluation.2495924960 - `total: number`2496124962 Total number of executed output items.2496324964 - `status: string`2496524966 The status of the evaluation run.2496724968# Output Items2496924970## Get eval run output items2497124972**get** `/evals/{eval_id}/runs/{run_id}/output_items`2497324974Get a list of output items for an evaluation run.2497524976### Path Parameters2497724978- `eval_id: string`2497924980- `run_id: string`2498124982### Query Parameters2498324984- `after: optional string`2498524986 Identifier for the last output item from the previous pagination request.2498724988- `limit: optional number`2498924990 Number of output items to retrieve.2499124992- `order: optional "asc" or "desc"`2499324994 Sort order for output items by timestamp. Use `asc` for ascending order or `desc` for descending order. Defaults to `asc`.2499524996 - `"asc"`2499724998 - `"desc"`2499925000- `status: optional "fail" or "pass"`2500125002 Filter output items by status. Use `failed` to filter by failed output25003 items or `pass` to filter by passed output items.2500425005 - `"fail"`2500625007 - `"pass"`2500825009### Returns2501025011- `data: array of object { id, created_at, datasource_item, 7 more }`2501225013 An array of eval run output item objects.2501425015 - `id: string`2501625017 Unique identifier for the evaluation run output item.2501825019 - `created_at: number`2502025021 Unix timestamp (in seconds) when the evaluation run was created.2502225023 - `datasource_item: map[unknown]`2502425025 Details of the input data source item.2502625027 - `datasource_item_id: number`2502825029 The identifier for the data source item.2503025031 - `eval_id: string`2503225033 The identifier of the evaluation group.2503425035 - `object: "eval.run.output_item"`2503625037 The type of the object. Always "eval.run.output_item".2503825039 - `"eval.run.output_item"`2504025041 - `results: array of object { name, passed, score, 2 more }`2504225043 A list of grader results for this output item.2504425045 - `name: string`2504625047 The name of the grader.2504825049 - `passed: boolean`2505025051 Whether the grader considered the output a pass.2505225053 - `score: number`2505425055 The numeric score produced by the grader.2505625057 - `sample: optional map[unknown] or null`2505825059 Optional sample or intermediate data produced by the grader.2506025061 - `type: optional string`2506225063 The grader type (for example, "string-check-grader").2506425065 - `run_id: string`2506625067 The identifier of the evaluation run associated with this output item.2506825069 - `sample: object { error, finish_reason, input, 7 more }`2507025071 A sample containing the input and output of the evaluation run.2507225073 - `error: EvalAPIError`2507425075 An object representing an error response from the Eval API.2507625077 - `code: string`2507825079 The error code.2508025081 - `message: string`2508225083 The error message.2508425085 - `finish_reason: string`2508625087 The reason why the sample generation was finished.2508825089 - `input: array of object { content, role }`2509025091 An array of input messages.2509225093 - `content: string`2509425095 The content of the message.2509625097 - `role: string`2509825099 The role of the message sender (e.g., system, user, developer).2510025101 - `max_completion_tokens: number`2510225103 The maximum number of tokens allowed for completion.2510425105 - `model: string`2510625107 The model used for generating the sample.2510825109 - `output: array of object { content, role }`2511025111 An array of output messages.2511225113 - `content: optional string`2511425115 The content of the message.2511625117 - `role: optional string`2511825119 The role of the message (e.g. "system", "assistant", "user").2512025121 - `seed: number`2512225123 The seed used for generating the sample.2512425125 - `temperature: number`2512625127 The sampling temperature used.2512825129 - `top_p: number`2513025131 The top_p value used for sampling.2513225133 - `usage: object { cached_tokens, completion_tokens, prompt_tokens, total_tokens }`2513425135 Token usage details for the sample.2513625137 - `cached_tokens: number`2513825139 The number of tokens retrieved from cache.2514025141 - `completion_tokens: number`2514225143 The number of completion tokens generated.2514425145 - `prompt_tokens: number`2514625147 The number of prompt tokens used.2514825149 - `total_tokens: number`2515025151 The total number of tokens used.2515225153 - `status: string`2515425155 The status of the evaluation run.2515625157- `first_id: string`2515825159 The identifier of the first eval run output item in the data array.2516025161- `has_more: boolean`2516225163 Indicates whether there are more eval run output items available.2516425165- `last_id: string`2516625167 The identifier of the last eval run output item in the data array.2516825169- `object: "list"`2517025171 The type of this object. It is always set to "list".2517225173 - `"list"`2517425175### Example2517625177```http25178curl https://api.openai.com/v1/evals/$EVAL_ID/runs/$RUN_ID/output_items \25179 -H "Authorization: Bearer $OPENAI_API_KEY"25180```2518125182#### Response2518325184```json25185{25186 "data": [25187 {25188 "id": "id",25189 "created_at": 0,25190 "datasource_item": {25191 "foo": "bar"25192 },25193 "datasource_item_id": 0,25194 "eval_id": "eval_id",25195 "object": "eval.run.output_item",25196 "results": [25197 {25198 "name": "name",25199 "passed": true,25200 "score": 0,25201 "sample": {25202 "foo": "bar"25203 },25204 "type": "type"25205 }25206 ],25207 "run_id": "run_id",25208 "sample": {25209 "error": {25210 "code": "code",25211 "message": "message"25212 },25213 "finish_reason": "finish_reason",25214 "input": [25215 {25216 "content": "content",25217 "role": "role"25218 }25219 ],25220 "max_completion_tokens": 0,25221 "model": "model",25222 "output": [25223 {25224 "content": "content",25225 "role": "role"25226 }25227 ],25228 "seed": 0,25229 "temperature": 0,25230 "top_p": 0,25231 "usage": {25232 "cached_tokens": 0,25233 "completion_tokens": 0,25234 "prompt_tokens": 0,25235 "total_tokens": 025236 }25237 },25238 "status": "status"25239 }25240 ],25241 "first_id": "first_id",25242 "has_more": true,25243 "last_id": "last_id",25244 "object": "list"25245}25246```2524725248### Example2524925250```http25251curl https://api.openai.com/v1/evals/egroup_67abd54d9b0081909a86353f6fb9317a/runs/erun_67abd54d60ec8190832b46859da808f7/output_items \25252 -H "Authorization: Bearer $OPENAI_API_KEY" \25253 -H "Content-Type: application/json"25254```2525525256#### Response2525725258```json25259{25260 "object": "list",25261 "data": [25262 {25263 "object": "eval.run.output_item",25264 "id": "outputitem_67e5796c28e081909917bf79f6e6214d",25265 "created_at": 1743092076,25266 "run_id": "evalrun_67abd54d60ec8190832b46859da808f7",25267 "eval_id": "eval_67abd54d9b0081909a86353f6fb9317a",25268 "status": "pass",25269 "datasource_item_id": 5,25270 "datasource_item": {25271 "input": "Stock Markets Rally After Positive Economic Data Released",25272 "ground_truth": "Markets"25273 },25274 "results": [25275 {25276 "name": "String check-a2486074-d803-4445-b431-ad2262e85d47",25277 "sample": null,25278 "passed": true,25279 "score": 1.025280 }25281 ],25282 "sample": {25283 "input": [25284 {25285 "role": "developer",25286 "content": "Categorize a given news headline into one of the following topics: Technology, Markets, World, Business, or Sports.\n\n# Steps\n\n1. Analyze the content of the news headline to understand its primary focus.\n2. Extract the subject matter, identifying any key indicators or keywords.\n3. Use the identified indicators to determine the most suitable category out of the five options: Technology, Markets, World, Business, or Sports.\n4. Ensure only one category is selected per headline.\n\n# Output Format\n\nRespond with the chosen category as a single word. For instance: \"Technology\", \"Markets\", \"World\", \"Business\", or \"Sports\".\n\n# Examples\n\n**Input**: \"Apple Unveils New iPhone Model, Featuring Advanced AI Features\" \n**Output**: \"Technology\"\n\n**Input**: \"Global Stocks Mixed as Investors Await Central Bank Decisions\" \n**Output**: \"Markets\"\n\n**Input**: \"War in Ukraine: Latest Updates on Negotiation Status\" \n**Output**: \"World\"\n\n**Input**: \"Microsoft in Talks to Acquire Gaming Company for $2 Billion\" \n**Output**: \"Business\"\n\n**Input**: \"Manchester United Secures Win in Premier League Football Match\" \n**Output**: \"Sports\" \n\n# Notes\n\n- If the headline appears to fit into more than one category, choose the most dominant theme.\n- Keywords or phrases such as \"stocks\", \"company acquisition\", \"match\", or technological brands can be good indicators for classification.\n",25287 "tool_call_id": null,25288 "tool_calls": null,25289 "function_call": null25290 },25291 {25292 "role": "user",25293 "content": "Stock Markets Rally After Positive Economic Data Released",25294 "tool_call_id": null,25295 "tool_calls": null,25296 "function_call": null25297 }25298 ],25299 "output": [25300 {25301 "role": "assistant",25302 "content": "Markets",25303 "tool_call_id": null,25304 "tool_calls": null,25305 "function_call": null25306 }25307 ],25308 "finish_reason": "stop",25309 "model": "gpt-6-astra",25310 "usage": {25311 "total_tokens": 325,25312 "completion_tokens": 2,25313 "prompt_tokens": 323,25314 "cached_tokens": 025315 },25316 "error": null,25317 "temperature": 1.0,25318 "max_completion_tokens": 2048,25319 "top_p": 1.0,25320 "seed": 4225321 }25322 }25323 ],25324 "first_id": "outputitem_67e5796c28e081909917bf79f6e6214d",25325 "last_id": "outputitem_67e5796c28e081909917bf79f6e6214d",25326 "has_more": true25327}25328```2532925330## Get an output item of an eval run2533125332**get** `/evals/{eval_id}/runs/{run_id}/output_items/{output_item_id}`2533325334Get an evaluation run output item by ID.2533525336### Path Parameters2533725338- `eval_id: string`2533925340- `run_id: string`2534125342- `output_item_id: string`2534325344### Returns2534525346- `id: string`2534725348 Unique identifier for the evaluation run output item.2534925350- `created_at: number`2535125352 Unix timestamp (in seconds) when the evaluation run was created.2535325354- `datasource_item: map[unknown]`2535525356 Details of the input data source item.2535725358- `datasource_item_id: number`2535925360 The identifier for the data source item.2536125362- `eval_id: string`2536325364 The identifier of the evaluation group.2536525366- `object: "eval.run.output_item"`2536725368 The type of the object. Always "eval.run.output_item".2536925370 - `"eval.run.output_item"`2537125372- `results: array of object { name, passed, score, 2 more }`2537325374 A list of grader results for this output item.2537525376 - `name: string`2537725378 The name of the grader.2537925380 - `passed: boolean`2538125382 Whether the grader considered the output a pass.2538325384 - `score: number`2538525386 The numeric score produced by the grader.2538725388 - `sample: optional map[unknown] or null`2538925390 Optional sample or intermediate data produced by the grader.2539125392 - `type: optional string`2539325394 The grader type (for example, "string-check-grader").2539525396- `run_id: string`2539725398 The identifier of the evaluation run associated with this output item.2539925400- `sample: object { error, finish_reason, input, 7 more }`2540125402 A sample containing the input and output of the evaluation run.2540325404 - `error: EvalAPIError`2540525406 An object representing an error response from the Eval API.2540725408 - `code: string`2540925410 The error code.2541125412 - `message: string`2541325414 The error message.2541525416 - `finish_reason: string`2541725418 The reason why the sample generation was finished.2541925420 - `input: array of object { content, role }`2542125422 An array of input messages.2542325424 - `content: string`2542525426 The content of the message.2542725428 - `role: string`2542925430 The role of the message sender (e.g., system, user, developer).2543125432 - `max_completion_tokens: number`2543325434 The maximum number of tokens allowed for completion.2543525436 - `model: string`2543725438 The model used for generating the sample.2543925440 - `output: array of object { content, role }`2544125442 An array of output messages.2544325444 - `content: optional string`2544525446 The content of the message.2544725448 - `role: optional string`2544925450 The role of the message (e.g. "system", "assistant", "user").2545125452 - `seed: number`2545325454 The seed used for generating the sample.2545525456 - `temperature: number`2545725458 The sampling temperature used.2545925460 - `top_p: number`2546125462 The top_p value used for sampling.2546325464 - `usage: object { cached_tokens, completion_tokens, prompt_tokens, total_tokens }`2546525466 Token usage details for the sample.2546725468 - `cached_tokens: number`2546925470 The number of tokens retrieved from cache.2547125472 - `completion_tokens: number`2547325474 The number of completion tokens generated.2547525476 - `prompt_tokens: number`2547725478 The number of prompt tokens used.2547925480 - `total_tokens: number`2548125482 The total number of tokens used.2548325484- `status: string`2548525486 The status of the evaluation run.2548725488### Example2548925490```http25491curl https://api.openai.com/v1/evals/$EVAL_ID/runs/$RUN_ID/output_items/$OUTPUT_ITEM_ID \25492 -H "Authorization: Bearer $OPENAI_API_KEY"25493```2549425495#### Response2549625497```json25498{25499 "id": "id",25500 "created_at": 0,25501 "datasource_item": {25502 "foo": "bar"25503 },25504 "datasource_item_id": 0,25505 "eval_id": "eval_id",25506 "object": "eval.run.output_item",25507 "results": [25508 {25509 "name": "name",25510 "passed": true,25511 "score": 0,25512 "sample": {25513 "foo": "bar"25514 },25515 "type": "type"25516 }25517 ],25518 "run_id": "run_id",25519 "sample": {25520 "error": {25521 "code": "code",25522 "message": "message"25523 },25524 "finish_reason": "finish_reason",25525 "input": [25526 {25527 "content": "content",25528 "role": "role"25529 }25530 ],25531 "max_completion_tokens": 0,25532 "model": "model",25533 "output": [25534 {25535 "content": "content",25536 "role": "role"25537 }25538 ],25539 "seed": 0,25540 "temperature": 0,25541 "top_p": 0,25542 "usage": {25543 "cached_tokens": 0,25544 "completion_tokens": 0,25545 "prompt_tokens": 0,25546 "total_tokens": 025547 }25548 },25549 "status": "status"25550}25551```2555225553### Example2555425555```http25556curl https://api.openai.com/v1/evals/eval_67abd54d9b0081909a86353f6fb9317a/runs/evalrun_67abd54d60ec8190832b46859da808f7/output_items/outputitem_67abd55eb6548190bb580745d5644a33 \25557 -H "Authorization: Bearer $OPENAI_API_KEY" \25558 -H "Content-Type: application/json"25559```2556025561#### Response2556225563```json25564{25565 "object": "eval.run.output_item",25566 "id": "outputitem_67e5796c28e081909917bf79f6e6214d",25567 "created_at": 1743092076,25568 "run_id": "evalrun_67abd54d60ec8190832b46859da808f7",25569 "eval_id": "eval_67abd54d9b0081909a86353f6fb9317a",25570 "status": "pass",25571 "datasource_item_id": 5,25572 "datasource_item": {25573 "input": "Stock Markets Rally After Positive Economic Data Released",25574 "ground_truth": "Markets"25575 },25576 "results": [25577 {25578 "name": "String check-a2486074-d803-4445-b431-ad2262e85d47",25579 "sample": null,25580 "passed": true,25581 "score": 1.025582 }25583 ],25584 "sample": {25585 "input": [25586 {25587 "role": "developer",25588 "content": "Categorize a given news headline into one of the following topics: Technology, Markets, World, Business, or Sports.\n\n# Steps\n\n1. Analyze the content of the news headline to understand its primary focus.\n2. Extract the subject matter, identifying any key indicators or keywords.\n3. Use the identified indicators to determine the most suitable category out of the five options: Technology, Markets, World, Business, or Sports.\n4. Ensure only one category is selected per headline.\n\n# Output Format\n\nRespond with the chosen category as a single word. For instance: \"Technology\", \"Markets\", \"World\", \"Business\", or \"Sports\".\n\n# Examples\n\n**Input**: \"Apple Unveils New iPhone Model, Featuring Advanced AI Features\" \n**Output**: \"Technology\"\n\n**Input**: \"Global Stocks Mixed as Investors Await Central Bank Decisions\" \n**Output**: \"Markets\"\n\n**Input**: \"War in Ukraine: Latest Updates on Negotiation Status\" \n**Output**: \"World\"\n\n**Input**: \"Microsoft in Talks to Acquire Gaming Company for $2 Billion\" \n**Output**: \"Business\"\n\n**Input**: \"Manchester United Secures Win in Premier League Football Match\" \n**Output**: \"Sports\" \n\n# Notes\n\n- If the headline appears to fit into more than one category, choose the most dominant theme.\n- Keywords or phrases such as \"stocks\", \"company acquisition\", \"match\", or technological brands can be good indicators for classification.\n",25589 "tool_call_id": null,25590 "tool_calls": null,25591 "function_call": null25592 },25593 {25594 "role": "user",25595 "content": "Stock Markets Rally After Positive Economic Data Released",25596 "tool_call_id": null,25597 "tool_calls": null,25598 "function_call": null25599 }25600 ],25601 "output": [25602 {25603 "role": "assistant",25604 "content": "Markets",25605 "tool_call_id": null,25606 "tool_calls": null,25607 "function_call": null25608 }25609 ],25610 "finish_reason": "stop",25611 "model": "gpt-6-astra",25612 "usage": {25613 "total_tokens": 325,25614 "completion_tokens": 2,25615 "prompt_tokens": 323,25616 "cached_tokens": 025617 },25618 "error": null,25619 "temperature": 1.0,25620 "max_completion_tokens": 2048,25621 "top_p": 1.0,25622 "seed": 4225623 }25624}25625```2562625627## Domain Types2562825629### Output Item List Response2563025631- `OutputItemListResponse object { id, created_at, datasource_item, 7 more }`2563225633 A schema representing an evaluation run output item.2563425635 - `id: string`2563625637 Unique identifier for the evaluation run output item.2563825639 - `created_at: number`2564025641 Unix timestamp (in seconds) when the evaluation run was created.2564225643 - `datasource_item: map[unknown]`2564425645 Details of the input data source item.2564625647 - `datasource_item_id: number`2564825649 The identifier for the data source item.2565025651 - `eval_id: string`2565225653 The identifier of the evaluation group.2565425655 - `object: "eval.run.output_item"`2565625657 The type of the object. Always "eval.run.output_item".2565825659 - `"eval.run.output_item"`2566025661 - `results: array of object { name, passed, score, 2 more }`2566225663 A list of grader results for this output item.2566425665 - `name: string`2566625667 The name of the grader.2566825669 - `passed: boolean`2567025671 Whether the grader considered the output a pass.2567225673 - `score: number`2567425675 The numeric score produced by the grader.2567625677 - `sample: optional map[unknown] or null`2567825679 Optional sample or intermediate data produced by the grader.2568025681 - `type: optional string`2568225683 The grader type (for example, "string-check-grader").2568425685 - `run_id: string`2568625687 The identifier of the evaluation run associated with this output item.2568825689 - `sample: object { error, finish_reason, input, 7 more }`2569025691 A sample containing the input and output of the evaluation run.2569225693 - `error: EvalAPIError`2569425695 An object representing an error response from the Eval API.2569625697 - `code: string`2569825699 The error code.2570025701 - `message: string`2570225703 The error message.2570425705 - `finish_reason: string`2570625707 The reason why the sample generation was finished.2570825709 - `input: array of object { content, role }`2571025711 An array of input messages.2571225713 - `content: string`2571425715 The content of the message.2571625717 - `role: string`2571825719 The role of the message sender (e.g., system, user, developer).2572025721 - `max_completion_tokens: number`2572225723 The maximum number of tokens allowed for completion.2572425725 - `model: string`2572625727 The model used for generating the sample.2572825729 - `output: array of object { content, role }`2573025731 An array of output messages.2573225733 - `content: optional string`2573425735 The content of the message.2573625737 - `role: optional string`2573825739 The role of the message (e.g. "system", "assistant", "user").2574025741 - `seed: number`2574225743 The seed used for generating the sample.2574425745 - `temperature: number`2574625747 The sampling temperature used.2574825749 - `top_p: number`2575025751 The top_p value used for sampling.2575225753 - `usage: object { cached_tokens, completion_tokens, prompt_tokens, total_tokens }`2575425755 Token usage details for the sample.2575625757 - `cached_tokens: number`2575825759 The number of tokens retrieved from cache.2576025761 - `completion_tokens: number`2576225763 The number of completion tokens generated.2576425765 - `prompt_tokens: number`2576625767 The number of prompt tokens used.2576825769 - `total_tokens: number`2577025771 The total number of tokens used.2577225773 - `status: string`2577425775 The status of the evaluation run.2577625777### Output Item Retrieve Response2577825779- `OutputItemRetrieveResponse object { id, created_at, datasource_item, 7 more }`2578025781 A schema representing an evaluation run output item.2578225783 - `id: string`2578425785 Unique identifier for the evaluation run output item.2578625787 - `created_at: number`2578825789 Unix timestamp (in seconds) when the evaluation run was created.2579025791 - `datasource_item: map[unknown]`2579225793 Details of the input data source item.2579425795 - `datasource_item_id: number`2579625797 The identifier for the data source item.2579825799 - `eval_id: string`2580025801 The identifier of the evaluation group.2580225803 - `object: "eval.run.output_item"`2580425805 The type of the object. Always "eval.run.output_item".2580625807 - `"eval.run.output_item"`2580825809 - `results: array of object { name, passed, score, 2 more }`2581025811 A list of grader results for this output item.2581225813 - `name: string`2581425815 The name of the grader.2581625817 - `passed: boolean`2581825819 Whether the grader considered the output a pass.2582025821 - `score: number`2582225823 The numeric score produced by the grader.2582425825 - `sample: optional map[unknown] or null`2582625827 Optional sample or intermediate data produced by the grader.2582825829 - `type: optional string`2583025831 The grader type (for example, "string-check-grader").2583225833 - `run_id: string`2583425835 The identifier of the evaluation run associated with this output item.2583625837 - `sample: object { error, finish_reason, input, 7 more }`2583825839 A sample containing the input and output of the evaluation run.2584025841 - `error: EvalAPIError`2584225843 An object representing an error response from the Eval API.2584425845 - `code: string`2584625847 The error code.2584825849 - `message: string`2585025851 The error message.2585225853 - `finish_reason: string`2585425855 The reason why the sample generation was finished.2585625857 - `input: array of object { content, role }`2585825859 An array of input messages.2586025861 - `content: string`2586225863 The content of the message.2586425865 - `role: string`2586625867 The role of the message sender (e.g., system, user, developer).2586825869 - `max_completion_tokens: number`2587025871 The maximum number of tokens allowed for completion.2587225873 - `model: string`2587425875 The model used for generating the sample.2587625877 - `output: array of object { content, role }`2587825879 An array of output messages.2588025881 - `content: optional string`2588225883 The content of the message.2588425885 - `role: optional string`2588625887 The role of the message (e.g. "system", "assistant", "user").2588825889 - `seed: number`2589025891 The seed used for generating the sample.2589225893 - `temperature: number`2589425895 The sampling temperature used.2589625897 - `top_p: number`2589825899 The top_p value used for sampling.2590025901 - `usage: object { cached_tokens, completion_tokens, prompt_tokens, total_tokens }`2590225903 Token usage details for the sample.2590425905 - `cached_tokens: number`2590625907 The number of tokens retrieved from cache.2590825909 - `completion_tokens: number`2591025911 The number of completion tokens generated.2591225913 - `prompt_tokens: number`2591425915 The number of prompt tokens used.2591625917 - `total_tokens: number`2591825919 The total number of tokens used.2592025921 - `status: string`2592225923 The status of the evaluation run.25924