List assistants
GEThttps:/api.openai.com/v1/assistants
Returns a list of assistants.
Query parameters
limit
integer
Defaults: 20
A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20.order
string
Defaults: desc
Sort order by the
created_at
timestamp of the objects.asc
for ascending order anddesc
for descending order.after
string
A cursor for use in pagination.
after
is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with obj_foo, your subsequent call can include after=obj_foo in order to fetch the next page of the list.before
string
A cursor for use in pagination.
before
is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with obj_foo, your subsequent call can include before=obj_foo in order to fetch the previous page of the list.
Response
A list of assistant objects.
Example request
1 curl "https://api.openai.com/v1/assistants?order=desc&limit=20" \2 -H "Content-Type: application/json" \3 -H "Authorization: Bearer $OPENAI_API_KEY" \4 -H "OpenAI-Beta: assistants=v2"
Example response
1 {2 "object": "list",3 "data": [4 {5 "id": "asst_abc123",6 "object": "assistant",7 "created_at": 1698982736,8 "name": "Coding Tutor",9 "description": null,10 "model": "gpt-4o",11 "instructions": "You are a helpful assistant designed to make me better at coding!",12 "tools": [],13 "tool_resources": {},14 "metadata": {},15 "top_p": 1.0,16 "temperature": 1.0,17 "response_format": "auto"18 },19 {20 "id": "asst_abc456",21 "object": "assistant",22 "created_at": 1698982718,23 "name": "My Assistant",24 "description": null,25 "model": "gpt-4o",26 "instructions": "You are a helpful assistant designed to make me better at coding!",27 "tools": [],28 "tool_resources": {},29 "metadata": {},30 "top_p": 1.0,31 "temperature": 1.0,32 "response_format": "auto"33 },34 {35 "id": "asst_abc789",36 "object": "assistant",37 "created_at": 1698982643,38 "name": null,39 "description": null,40 "model": "gpt-4o",41 "instructions": null,42 "tools": [],43 "tool_resources": {},44 "metadata": {},45 "top_p": 1.0,46 "temperature": 1.0,47 "response_format": "auto"48 }49 ],50 "first_id": "asst_abc123",51 "last_id": "asst_abc789",52 "has_more": false53 }
Built with