Modify assistant (v1)
POST
https://api.openai.com/v1/assistants/asst_abc123
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.openai.com/v1/assistants/asst_abc123' \
--header 'Authorization: Bearer $OPENAI_API_KEY' \
--header 'OpenAI-Beta: assistants=v1' \
--header 'Content-Type: application/json' \
--data-raw '{
"instructions": "You are an HR bot, and you have access to files to answer employee questions about company policies. Always response with info from either of the files.",
"tools": [{"type": "retrieval"}],
"model": "gpt-4-turbo",
"file_ids": ["file-abc123", "file-abc456"]
}'
Response Response Example
{
"id": "asst_abc123",
"object": "assistant",
"created_at": 1699009709,
"name": "HR Helper",
"description": null,
"model": "gpt-4-turbo",
"instructions": "You are an HR bot, and you have access to files to answer employee questions about company policies. Always response with info from either of the files.",
"tools": [
{
"type": "retrieval"
}
],
"file_ids": [
"file-abc123",
"file-abc456"
],
"metadata": {},
"top_p": 1,
"temperature": 1,
"response_format": "auto"
}
Request
Header Params
Content-Type
stringΒ
required
Example:
application/json
Authorization
stringΒ
required
Example:
Bearer $OPENAI_API_KEY
OpenAI-Beta
stringΒ
required
Example:
assistants=v1
Body Params application/json
Responses
Modified atΒ 2024-12-12 08:11:48