Skip to content

Commit

Permalink
add OpenAI-Beta: assistants=v2 header parameter to all assistant APIs
Browse files Browse the repository at this point in the history
This will allow to use the openapi.yaml as is from the swagger UI
  • Loading branch information
jrudolph committed Oct 24, 2024
1 parent 2577b8c commit 3a488a6
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ tags:
description: List user actions and configuration changes within this organization.
paths:
/assistants:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
get:
operationId: listAssistants
tags:
Expand Down Expand Up @@ -5365,6 +5367,8 @@ paths:
"deleted": true
}
/threads:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
post:
operationId: createThread
tags:
Expand Down Expand Up @@ -5491,6 +5495,8 @@ paths:
"tool_resources": {}
}
/threads/runs:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
post:
operationId: createThreadAndRun
tags:
Expand Down Expand Up @@ -5978,6 +5984,8 @@ paths:

data: [DONE]
/threads/{thread_id}:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
get:
operationId: getThread
tags:
Expand Down Expand Up @@ -6424,6 +6432,8 @@ paths:
"metadata": {}
}
/threads/{thread_id}/messages/{message_id}:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
get:
operationId: getMessage
tags:
Expand Down Expand Up @@ -6682,6 +6692,8 @@ paths:
"deleted": true
}
/threads/{thread_id}/runs:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
get:
operationId: listRuns
tags:
Expand Down Expand Up @@ -7331,6 +7343,8 @@ paths:

data: [DONE]
/threads/{thread_id}/runs/{run_id}:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
get:
operationId: getRun
tags:
Expand Down Expand Up @@ -7566,6 +7580,8 @@ paths:
"parallel_tool_calls": true
}
/threads/{thread_id}/runs/{run_id}/cancel:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
post:
operationId: cancelRun
tags:
Expand Down Expand Up @@ -7666,6 +7682,8 @@ paths:
"parallel_tool_calls": true
}
/threads/{thread_id}/runs/{run_id}/steps:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
get:
operationId: listRunSteps
tags:
Expand Down Expand Up @@ -7822,6 +7840,8 @@ paths:
"has_more": false
}
/threads/{thread_id}/runs/{run_id}/steps/{step_id}:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
get:
operationId: getRunStep
tags:
Expand Down Expand Up @@ -7939,6 +7959,8 @@ paths:
}
}
/threads/{thread_id}/runs/{run_id}/submit_tool_outputs:
parameters:
- $ref: '#/components/parameters/AssistantBetaHeader'
post:
operationId: submitToolOuputsToRun
tags:
Expand Down Expand Up @@ -9668,6 +9690,15 @@ paths:
deleted: true
}
components:
parameters:
AssistantBetaHeader:
name: OpenAI-Beta
in: header
required: true
schema:
type: string
default: "assistants=v2"
description: The Assistant API is still marked as beta
schemas:
AddUploadPartRequest:
type: object
Expand Down

0 comments on commit 3a488a6

Please sign in to comment.