| Description | : Gets a list of runs for a specified thread. |
| Reference | : Link ¶ |
⚶ Changes
{
"#id": "Runs_ListRuns",
"$responses": {
"200": {
"$properties": {
"data": {
"$properties": [
{
"#name": "status",
"Enum": {
"new": [
[
"queued",
"Represents a run that is queued to start."
],
[
"in_progress",
"Represents a run that is in progress."
],
[
"requires_action",
"Represents a run that needs another operation, such as tool output submission, to continue."
],
[
"cancelling",
"Represents a run that is in the process of cancellation."
],
[
"cancelled",
"Represents a run that has been cancelled."
],
[
"failed",
"Represents a run that failed."
],
[
"completed",
"Represents a run that successfully completed."
],
[
"expired",
"Represents a run that expired before it could otherwise finish."
],
[
"incomplete",
"Represents a run that cannot be completed due to safety guardrails."
]
],
"old": [
[
"queued",
"Represents a run that is queued to start."
],
[
"in_progress",
"Represents a run that is in progress."
],
[
"requires_action",
"Represents a run that needs another operation, such as tool output submission, to continue."
],
[
"cancelling",
"Represents a run that is in the process of cancellation."
],
[
"cancelled",
"Represents a run that has been cancelled."
],
[
"failed",
"Represents a run that failed."
],
[
"completed",
"Represents a run that successfully completed."
],
[
"expired",
"Represents a run that expired before it could otherwise finish."
]
]
}
}
]
}
}
}
}
}
⚼ 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:
string
,
}
parallel_tool_calls:
boolean
,
}
last_id:
string
,
has_more:
boolean
,
}
⚐ Response (default)
{
error:
}
{
,
message:
string
,
type:
string
,
param:
string
,
code:
string
,
}