Azure.AI.Agents (preview:2025-05-15)

2025/07/15 • 15 updated methods

ListAgents (updated)
Description Gets a list of agents that were previously created.
Reference Link ¶

⚶ Changes

{
  "#id": "ListAgents",
  "$responses": {
    "200": {
      "$properties": {
        "data": {
          "$properties": {
            "tool_resources": [
              {
                "@added_6efcdc117dc2462d99fad601249017de": {
                  "#name": "mcp",
                  "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Description": "A set of resources that are used by the `mcp` tool.",
                    "Type": "object",
                    "$properties": [
                      {
                        "#name": "server_label",
                        "Description": "The label for the MCP server",
                        "Required": true,
                        "Type": "string"
                      },
                      {
                        "#name": "headers",
                        "Description": "The headers for the MCP server updates",
                        "Required": true,
                        "Type": "object"
                      },
                      {
                        "#name": "require_approval",
                        "Description": "Does MCP server require approval",
                        "Enum": [
                          [
                            "never",
                            ""
                          ],
                          [
                            "always",
                            ""
                          ]
                        ],
                        "Required": false,
                        "Type": "string"
                      }
                    ]
                  }
                }
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /assistants
{
api-version: string ,
limit: integer ,
order: string ,
after: string ,
before: string ,
}

⚐ Response (200)

{
data:
[
{
id: string ,
object: enum ,
created_at: integer ,
name: string ,
description: string ,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
temperature: number ,
top_p: number ,
response_format: string ,
metadata: object ,
}
,
]
,
last_id: string ,
has_more: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
CreateAgent (updated)
Description Creates a new agent.
Reference Link ¶

⚶ Changes

{
  "#id": "CreateAgent",
  "$parameters": {
    "body": {
      "$properties": {
        "tool_resources": [
          {
            "@added_74455e3c2882465bb62d2b1a5b13751c": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_d3c60ecb70084db3a15a8a7bceedb210": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /assistants
{
api-version: string ,
body:
{
model: string ,
name: string ,
description: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
temperature: number ,
top_p: number ,
response_format: string ,
metadata: object ,
}
,
}

⚐ Response (200)

{
id: string ,
object: enum ,
created_at: integer ,
name: string ,
description: string ,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
temperature: number ,
top_p: number ,
response_format: string ,
metadata: object ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
GetAgent (updated)
Description Retrieves an existing agent.
Reference Link ¶

⚶ Changes

{
  "#id": "GetAgent",
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_0eb83266cf2e41758273b043021a3b4f": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

GET:  /assistants/{assistantId}
{
api-version: string ,
assistantId: string ,
}

⚐ Response (200)

{
id: string ,
object: enum ,
created_at: integer ,
name: string ,
description: string ,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
temperature: number ,
top_p: number ,
response_format: string ,
metadata: object ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
UpdateAgent (updated)
Description Modifies an existing agent.
Reference Link ¶

⚶ Changes

{
  "#id": "UpdateAgent",
  "$parameters": {
    "body": {
      "$properties": {
        "tool_resources": [
          {
            "@added_cf9faa67f6544c9bb55fa2e9dc6e635d": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_a0d27396db274d609d25975888e3688a": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /assistants/{assistantId}
{
api-version: string ,
assistantId: string ,
body:
{
model: string ,
name: string ,
description: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
temperature: number ,
top_p: number ,
response_format: string ,
metadata: object ,
}
,
}

⚐ Response (200)

{
id: string ,
object: enum ,
created_at: integer ,
name: string ,
description: string ,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
temperature: number ,
top_p: number ,
response_format: string ,
metadata: object ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Threads_ListThreads (updated)
Description Gets a list of threads that were previously created.
Reference Link ¶

⚶ Changes

{
  "#id": "Threads_ListThreads",
  "$responses": {
    "200": {
      "$properties": {
        "data": {
          "$properties": {
            "tool_resources": [
              {
                "@added_f8868478aebc4273b2858977aeafe5f1": {
                  "#name": "mcp",
                  "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Description": "A set of resources that are used by the `mcp` tool.",
                    "Type": "object",
                    "$properties": [
                      {
                        "#name": "server_label",
                        "Description": "The label for the MCP server",
                        "Required": true,
                        "Type": "string"
                      },
                      {
                        "#name": "headers",
                        "Description": "The headers for the MCP server updates",
                        "Required": true,
                        "Type": "object"
                      },
                      {
                        "#name": "require_approval",
                        "Description": "Does MCP server require approval",
                        "Enum": [
                          [
                            "never",
                            ""
                          ],
                          [
                            "always",
                            ""
                          ]
                        ],
                        "Required": false,
                        "Type": "string"
                      }
                    ]
                  }
                }
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /threads
{
api-version: string ,
limit: integer ,
order: string ,
after: string ,
before: string ,
}

⚐ Response (200)

{
data:
[
{
id: string ,
object: enum ,
created_at: integer ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
metadata: object ,
}
,
]
,
last_id: string ,
has_more: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Threads_CreateThread (updated)
Description Creates a new thread. Threads contain messages and can be run by agents.
Reference Link ¶

⚶ Changes

{
  "#id": "Threads_CreateThread",
  "$parameters": {
    "body": {
      "$properties": {
        "tool_resources": [
          {
            "@added_fcd9917fa0e348b4a0f032580710c9ad": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_159501efeeea496392ef295cc4b90675": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /threads
{
api-version: string ,
body:
{
messages:
[
{
role: enum ,
content: string ,
attachments:
[
{
file_id: string ,
data_source:
{
uri: string ,
type: enum ,
}
,
tools:
[
string ,
]
,
}
,
]
,
metadata: object ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
metadata: object ,
}
,
}

⚐ Response (200)

{
id: string ,
object: enum ,
created_at: integer ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
metadata: object ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Threads_GetThread (updated)
Description Gets information about an existing thread.
Reference Link ¶

⚶ Changes

{
  "#id": "Threads_GetThread",
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_a8f1cb629ef84fe082ac2f091b4e3d64": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

GET:  /threads/{threadId}
{
api-version: string ,
threadId: string ,
}

⚐ Response (200)

{
id: string ,
object: enum ,
created_at: integer ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
metadata: object ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Threads_UpdateThread (updated)
Description Modifies an existing thread.
Reference Link ¶

⚶ Changes

{
  "#id": "Threads_UpdateThread",
  "$parameters": {
    "body": {
      "$properties": {
        "tool_resources": [
          {
            "@added_2e8369071941499494600e973c5f2558": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_c5a0e5f9aa8f432580a82b8af9f1a53e": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /threads/{threadId}
{
api-version: string ,
threadId: string ,
body:
{
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
metadata: object ,
}
,
}

⚐ Response (200)

{
id: string ,
object: enum ,
created_at: integer ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
metadata: object ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Runs_ListRuns (updated)
Description Gets a list of runs for a specified thread.
Reference Link ¶

⚶ Changes

{
  "#id": "Runs_ListRuns",
  "$responses": {
    "200": {
      "$properties": {
        "data": {
          "$properties": {
            "tool_resources": [
              {
                "@added_c029e08efd2f49c2a2b7ae78df49f662": {
                  "#name": "mcp",
                  "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Description": "A set of resources that are used by the `mcp` tool.",
                    "Type": "object",
                    "$properties": [
                      {
                        "#name": "server_label",
                        "Description": "The label for the MCP server",
                        "Required": true,
                        "Type": "string"
                      },
                      {
                        "#name": "headers",
                        "Description": "The headers for the MCP server updates",
                        "Required": true,
                        "Type": "object"
                      },
                      {
                        "#name": "require_approval",
                        "Description": "Does MCP server require approval",
                        "Enum": [
                          [
                            "never",
                            ""
                          ],
                          [
                            "always",
                            ""
                          ]
                        ],
                        "Required": false,
                        "Type": "string"
                      }
                    ]
                  }
                }
              }
            ]
          }
        }
      }
    }
  }
}

⚼ Request

GET:  /threads/{threadId}/runs
{
threadId: string ,
api-version: string ,
limit: integer ,
order: string ,
after: string ,
before: string ,
}

⚐ Response (200)

{
data:
[
{
id: string ,
object: enum ,
thread_id: string ,
assistant_id: string ,
status: enum ,
required_action:
{
type: string ,
}
,
last_error:
{
code: string ,
message: string ,
}
,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
created_at: integer ,
expires_at: integer ,
started_at: integer ,
completed_at: integer ,
cancelled_at: integer ,
failed_at: integer ,
incomplete_details:
{
reason: enum ,
}
,
usage:
{
completion_tokens: integer ,
prompt_tokens: integer ,
total_tokens: integer ,
}
,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
metadata: object ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
parallel_tool_calls: boolean ,
}
,
]
,
last_id: string ,
has_more: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Runs_CreateRun (updated)
Description Creates a new run for an agent thread.
Reference Link ¶

⚶ Changes

{
  "#id": "Runs_CreateRun",
  "$parameters": {
    "body": {
      "$properties": {
        "@added_5c79be1215724e9e9eb3254be4850e3d": {
          "#name": "tool_resources",
          "Description": "The overridden enabled tool resources that the agent should use to run the thread.",
          "Required": false,
          "Type": "object",
          "$properties": [
            {
              "#name": "code_interpreter",
              "Description": "Resources to be used by the `code_interpreter` tool consisting of file IDs.",
              "Required": false,
              "Type": "object",
              "$properties": [
                {
                  "#name": "file_ids",
                  "Description": "A list of file IDs made available to the `code_interpreter` tool. There can be a maximum of 20 files\nassociated with the tool.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Type": "string"
                  }
                },
                {
                  "#name": "data_sources",
                  "Description": "The data sources to be used. This option is mutually exclusive with the `fileIds` property.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Description": "The structure, containing Azure asset URI path and the asset type of the file used as a data source\nfor the enterprise file search.",
                    "Type": "object",
                    "$properties": [
                      {
                        "#name": "uri",
                        "Description": "Asset URI.",
                        "Required": true,
                        "Type": "string"
                      },
                      {
                        "#name": "type",
                        "Description": "The asset type",
                        "Enum": [
                          [
                            "uri_asset",
                            "Azure URI"
                          ],
                          [
                            "id_asset",
                            "The data ID"
                          ]
                        ],
                        "Required": true,
                        "Type": "string"
                      }
                    ]
                  }
                }
              ]
            },
            {
              "#name": "file_search",
              "Description": "Resources to be used by the `file_search` tool consisting of vector store IDs.",
              "Required": false,
              "Type": "object",
              "$properties": [
                {
                  "#name": "vector_store_ids",
                  "Description": "The ID of the vector store attached to this agent. There can be a maximum of 1 vector\nstore attached to the agent.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Type": "string"
                  }
                },
                {
                  "#name": "vector_stores",
                  "Description": "The list of vector store configuration objects from Azure.\nThis list is limited to one element.\nThe only element of this list contains the list of azure asset IDs used by the search tool.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Description": "The structure, containing the list of vector storage configurations i.e. the list of azure asset IDs.",
                    "Type": "object",
                    "$properties": [
                      {
                        "#name": "name",
                        "Description": "Name",
                        "Required": true,
                        "Type": "string"
                      },
                      {
                        "#name": "configuration",
                        "Description": "Configurations",
                        "Required": true,
                        "Type": "object",
                        "$properties": [
                          {
                            "#name": "data_sources",
                            "Description": "Data sources",
                            "Required": true,
                            "Type": "array",
                            "$items": {
                              "Description": "The structure, containing Azure asset URI path and the asset type of the file used as a data source\nfor the enterprise file search.",
                              "Type": "object",
                              "$properties": [
                                {
                                  "#name": "uri",
                                  "Description": "Asset URI.",
                                  "Required": true,
                                  "Type": "string"
                                },
                                {
                                  "#name": "type",
                                  "Description": "The asset type",
                                  "Enum": [
                                    [
                                      "uri_asset",
                                      "Azure URI"
                                    ],
                                    [
                                      "id_asset",
                                      "The data ID"
                                    ]
                                  ],
                                  "Required": true,
                                  "Type": "string"
                                }
                              ]
                            }
                          }
                        ]
                      }
                    ]
                  }
                }
              ]
            },
            {
              "#name": "azure_ai_search",
              "Description": "Resources to be used by the `azure_ai_search` tool consisting of index IDs and names.",
              "Required": false,
              "Type": "object",
              "$properties": [
                {
                  "#name": "indexes",
                  "Description": "The indices attached to this agent. There can be a maximum of 1 index\nresource attached to the agent.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Description": "A AI Search Index resource.",
                    "Type": "object",
                    "$properties": [
                      {
                        "#name": "index_connection_id",
                        "Description": "An index connection id in an IndexResource attached to this agent.",
                        "Required": false,
                        "Type": "string"
                      },
                      {
                        "#name": "index_name",
                        "Description": "The name of an index in an IndexResource attached to this agent.",
                        "Required": false,
                        "Type": "string"
                      },
                      {
                        "#name": "query_type",
                        "Description": "Type of query in an AIIndexResource attached to this agent.",
                        "Enum": [
                          [
                            "simple",
                            "Query type `simple`"
                          ],
                          [
                            "semantic",
                            "Query type `semantic`"
                          ],
                          [
                            "vector",
                            "Query type `vector`"
                          ],
                          [
                            "vector_simple_hybrid",
                            "Query type `vector_simple_hybrid`"
                          ],
                          [
                            "vector_semantic_hybrid",
                            "Query type `vector_semantic_hybrid`"
                          ]
                        ],
                        "Required": false,
                        "Type": "string"
                      },
                      {
                        "#name": "top_k",
                        "Description": "Number of documents to retrieve from search and present to the model.",
                        "Format": "int32",
                        "Required": false,
                        "Type": "integer"
                      },
                      {
                        "#name": "filter",
                        "Description": "filter string for search resource.",
                        "Required": false,
                        "Type": "string"
                      },
                      {
                        "#name": "index_asset_id",
                        "Description": "Index asset id for search resource.",
                        "Required": false,
                        "Type": "string"
                      }
                    ]
                  }
                }
              ]
            },
            {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          ]
        }
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_86d057da196c41c59fd3350407e030df": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /threads/{threadId}/runs
{
api-version: string ,
threadId: string ,
include[]: array ,
body:
{
assistant_id: string ,
model: string ,
instructions: string ,
additional_instructions: string ,
additional_messages:
[
{
role: enum ,
content: string ,
attachments:
[
{
file_id: string ,
data_source:
{
uri: string ,
type: enum ,
}
,
tools:
[
string ,
]
,
}
,
]
,
metadata: object ,
}
,
]
,
tools:
[
{
type: string ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
stream: boolean ,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
parallel_tool_calls: boolean ,
metadata: object ,
}
,
}

⚐ Response (200)

{
id: string ,
object: enum ,
thread_id: string ,
assistant_id: string ,
status: enum ,
required_action:
{
type: string ,
}
,
last_error:
{
code: string ,
message: string ,
}
,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
created_at: integer ,
expires_at: integer ,
started_at: integer ,
completed_at: integer ,
cancelled_at: integer ,
failed_at: integer ,
incomplete_details:
{
reason: enum ,
}
,
usage:
{
completion_tokens: integer ,
prompt_tokens: integer ,
total_tokens: integer ,
}
,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
metadata: object ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
parallel_tool_calls: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Runs_GetRun (updated)
Description Gets an existing run from an existing thread.
Reference Link ¶

⚶ Changes

{
  "#id": "Runs_GetRun",
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_7f8587df5ba44e068e146b77c2fea4de": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

GET:  /threads/{threadId}/runs/{runId}
{
api-version: string ,
threadId: string ,
runId: string ,
}

⚐ Response (200)

{
id: string ,
object: enum ,
thread_id: string ,
assistant_id: string ,
status: enum ,
required_action:
{
type: string ,
}
,
last_error:
{
code: string ,
message: string ,
}
,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
created_at: integer ,
expires_at: integer ,
started_at: integer ,
completed_at: integer ,
cancelled_at: integer ,
failed_at: integer ,
incomplete_details:
{
reason: enum ,
}
,
usage:
{
completion_tokens: integer ,
prompt_tokens: integer ,
total_tokens: integer ,
}
,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
metadata: object ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
parallel_tool_calls: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Runs_UpdateRun (updated)
Description Modifies an existing thread run.
Reference Link ¶

⚶ Changes

{
  "#id": "Runs_UpdateRun",
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_4bee597f43f04a3aa72903dddc3c109f": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /threads/{threadId}/runs/{runId}
{
api-version: string ,
threadId: string ,
runId: string ,
body:
{
metadata: object ,
}
,
}

⚐ Response (200)

{
id: string ,
object: enum ,
thread_id: string ,
assistant_id: string ,
status: enum ,
required_action:
{
type: string ,
}
,
last_error:
{
code: string ,
message: string ,
}
,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
created_at: integer ,
expires_at: integer ,
started_at: integer ,
completed_at: integer ,
cancelled_at: integer ,
failed_at: integer ,
incomplete_details:
{
reason: enum ,
}
,
usage:
{
completion_tokens: integer ,
prompt_tokens: integer ,
total_tokens: integer ,
}
,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
metadata: object ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
parallel_tool_calls: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Runs_CancelRun (updated)
Description Cancels a run of an in‐progress thread.
Reference Link ¶

⚶ Changes

{
  "#id": "Runs_CancelRun",
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_422bc3c5af91400395821860fca721d9": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /threads/{threadId}/runs/{runId}/cancel
{
api-version: string ,
threadId: string ,
runId: string ,
}

⚐ Response (200)

{
id: string ,
object: enum ,
thread_id: string ,
assistant_id: string ,
status: enum ,
required_action:
{
type: string ,
}
,
last_error:
{
code: string ,
message: string ,
}
,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
created_at: integer ,
expires_at: integer ,
started_at: integer ,
completed_at: integer ,
cancelled_at: integer ,
failed_at: integer ,
incomplete_details:
{
reason: enum ,
}
,
usage:
{
completion_tokens: integer ,
prompt_tokens: integer ,
total_tokens: integer ,
}
,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
metadata: object ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
parallel_tool_calls: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
Runs_SubmitToolOutputsToRun (updated)
Description Submits outputs from tools as requested by tool calls in a run.
Reference Link ¶

⚶ Changes

{
  "#id": "Runs_SubmitToolOutputsToRun",
  "$parameters": {
    "body": {
      "$properties": [
        {
          "#name": "tool_outputs",
          "Required": {
            "new": false,
            "old": true
          }
        },
        {
          "@added_bf209c076caa4fbc908476402ddcd98c": {
            "#name": "tool_approvals",
            "Description": "A list of tool approvals allowing data to be sent to tools.",
            "Required": false,
            "Type": "array",
            "$items": {
              "Description": "The data provided during a tool outputs submission to resolve pending tool calls and allow the model to continue.",
              "Type": "object",
              "$properties": [
                {
                  "#name": "tool_call_id",
                  "Description": "The ID of the tool call being resolved, as provided in the tool calls of a required action from a run.",
                  "Required": true,
                  "Type": "string"
                },
                {
                  "#name": "approve",
                  "Description": "The approval boolean value to be submitted.",
                  "Required": true,
                  "Type": "boolean"
                },
                {
                  "#name": "headers",
                  "Description": "Headers to be attached to the approval.",
                  "Required": false,
                  "Type": "object"
                }
              ]
            }
          }
        }
      ]
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_437a4341ee164531944335ef99770724": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /threads/{threadId}/runs/{runId}/submit_tool_outputs
{
api-version: string ,
threadId: string ,
runId: string ,
body:
{
tool_outputs:
[
{
tool_call_id: string ,
output: string ,
}
,
]
,
tool_approvals:
[
{
tool_call_id: string ,
approve: boolean ,
headers: object ,
}
,
]
,
stream: boolean ,
}
,
}

⚐ Response (200)

{
id: string ,
object: enum ,
thread_id: string ,
assistant_id: string ,
status: enum ,
required_action:
{
type: string ,
}
,
last_error:
{
code: string ,
message: string ,
}
,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
created_at: integer ,
expires_at: integer ,
started_at: integer ,
completed_at: integer ,
cancelled_at: integer ,
failed_at: integer ,
incomplete_details:
{
reason: enum ,
}
,
usage:
{
completion_tokens: integer ,
prompt_tokens: integer ,
total_tokens: integer ,
}
,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
metadata: object ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
parallel_tool_calls: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}
CreateThreadAndRun (updated)
Description Creates a new agent thread and immediately starts a run using that new thread.
Reference Link ¶

⚶ Changes

{
  "#id": "CreateThreadAndRun",
  "$parameters": {
    "body": {
      "$properties": {
        "thread": [
          {
            "tool_resources": [
              {
                "@added_6f913545d5864a039c2254150debdae2": {
                  "#name": "mcp",
                  "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
                  "Required": false,
                  "Type": "array",
                  "$items": {
                    "Description": "A set of resources that are used by the `mcp` tool.",
                    "Type": "object",
                    "$properties": [
                      {
                        "#name": "server_label",
                        "Description": "The label for the MCP server",
                        "Required": true,
                        "Type": "string"
                      },
                      {
                        "#name": "headers",
                        "Description": "The headers for the MCP server updates",
                        "Required": true,
                        "Type": "object"
                      },
                      {
                        "#name": "require_approval",
                        "Description": "Does MCP server require approval",
                        "Enum": [
                          [
                            "never",
                            ""
                          ],
                          [
                            "always",
                            ""
                          ]
                        ],
                        "Required": false,
                        "Type": "string"
                      }
                    ]
                  }
                }
              }
            ]
          }
        ],
        "tool_resources": [
          {
            "@added_bfb5610265c641dba11c568eabbd0eaa": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  },
  "$responses": {
    "200": {
      "$properties": {
        "tool_resources": [
          {
            "@added_536201686cf747ebaf8d91bc8bcfc7e4": {
              "#name": "mcp",
              "Description": "Resources to be used by the `mcp` tool consisting of a server label and headers.",
              "Required": false,
              "Type": "array",
              "$items": {
                "Description": "A set of resources that are used by the `mcp` tool.",
                "Type": "object",
                "$properties": [
                  {
                    "#name": "server_label",
                    "Description": "The label for the MCP server",
                    "Required": true,
                    "Type": "string"
                  },
                  {
                    "#name": "headers",
                    "Description": "The headers for the MCP server updates",
                    "Required": true,
                    "Type": "object"
                  },
                  {
                    "#name": "require_approval",
                    "Description": "Does MCP server require approval",
                    "Enum": [
                      [
                        "never",
                        ""
                      ],
                      [
                        "always",
                        ""
                      ]
                    ],
                    "Required": false,
                    "Type": "string"
                  }
                ]
              }
            }
          }
        ]
      }
    }
  }
}

⚼ Request

POST:  /threads/runs
{
api-version: string ,
body:
{
assistant_id: string ,
thread:
{
messages:
[
{
role: enum ,
content: string ,
attachments:
[
{
file_id: string ,
data_source:
{
uri: string ,
type: enum ,
}
,
tools:
[
string ,
]
,
}
,
]
,
metadata: object ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
metadata: object ,
}
,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
stream: boolean ,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
parallel_tool_calls: boolean ,
metadata: object ,
}
,
}

⚐ Response (200)

{
id: string ,
object: enum ,
thread_id: string ,
assistant_id: string ,
status: enum ,
required_action:
{
type: string ,
}
,
last_error:
{
code: string ,
message: string ,
}
,
model: string ,
instructions: string ,
tools:
[
{
type: string ,
}
,
]
,
created_at: integer ,
expires_at: integer ,
started_at: integer ,
completed_at: integer ,
cancelled_at: integer ,
failed_at: integer ,
incomplete_details:
{
reason: enum ,
}
,
usage:
{
completion_tokens: integer ,
prompt_tokens: integer ,
total_tokens: integer ,
}
,
temperature: number ,
top_p: number ,
max_prompt_tokens: integer ,
max_completion_tokens: integer ,
truncation_strategy:
{
type: enum ,
last_messages: integer ,
}
,
tool_choice: string ,
response_format: string ,
metadata: object ,
tool_resources:
{
code_interpreter:
{
file_ids:
[
string ,
]
,
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
file_search:
{
vector_store_ids:
[
string ,
]
,
vector_stores:
[
{
name: string ,
configuration:
{
data_sources:
[
{
uri: string ,
type: enum ,
}
,
]
,
}
,
}
,
]
,
}
,
azure_ai_search:
{
indexes:
[
{
index_connection_id: string ,
index_name: string ,
query_type: enum ,
top_k: integer ,
filter: string ,
index_asset_id: string ,
}
,
]
,
}
,
mcp:
[
{
server_label: string ,
headers: object ,
require_approval: enum ,
}
,
]
,
}
,
parallel_tool_calls: boolean ,
}

⚐ Response (default)

{
error:
{
message: string ,
type: string ,
param: string ,
code: string ,
}
,
}