Skip to main content
GET
/
v1
/
files
const result = await client.files.list({ page: 1, limit: 10 });

for (const file of result.data) {
  console.log(`${file.filename} (${file.size} bytes)`);
}
{
  "data": [
    {
      "id": "file_abc123",
      "filename": "catalog.pdf",
      "size": 1048576,
      "content_type": "application/pdf",
      "created_at": "2025-03-10T14:30:00.000Z"
    }
  ],
  "pagination": { "page": 1, "limit": 10, "total": 5 }
}

Query parameters

page
integer
default:"1"
Page number for pagination.
limit
integer
default:"25"
Number of items per page (max 100).

Response

data
array
pagination
object
const result = await client.files.list({ page: 1, limit: 10 });

for (const file of result.data) {
  console.log(`${file.filename} (${file.size} bytes)`);
}
{
  "data": [
    {
      "id": "file_abc123",
      "filename": "catalog.pdf",
      "size": 1048576,
      "content_type": "application/pdf",
      "created_at": "2025-03-10T14:30:00.000Z"
    }
  ],
  "pagination": { "page": 1, "limit": 10, "total": 5 }
}