List files

Returns a list of files that can be optionally limited to a set of results (e.g., limit, after), ordered (e.g., order), and filtered (e.g., purpose).

Query Params
string

Only return files with the given purpose.

integer
1 to 10000
Defaults to 10000

A limit on the number of objects to be returned. Limit can range between 1 and 10,000.

string
enum
Defaults to desc

Sort order by the created_at timestamp of the objects. asc for ascending order and desc for descending order.

Allowed:
string

A cursor for use in pagination. after is the file ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with file-xyz, your subsequent call can include "after": "file-xyz" in order to fetch the next page of the list.

Responses

5XX

Server Error

This indicates our servers are experiencing high traffic or having an unexpected issue. Please see our Error Codes guide.

Language
Credentials
Header
Request
Response
Choose an example:
application/json