Soubory
Seznam souborů
Načtení stránkovaného seznamu vašich nahraných souborů.
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)`);
}
result = client.files.list(page=1, limit=10)
for file in result["data"]:
print(f"{file['filename']} ({file['size']} bytes)")
curl -X GET "https://hub.banditshq.com/api/v1/files?page=1&limit=10" \
-H "Authorization: Bearer lasso_..."
{
"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 parametry
integer
výchozí:"1"
Číslo stránky pro stránkování.
integer
výchozí:"25"
Počet položek na stránku (max 100).
Odpověď
array
object
const result = await client.files.list({ page: 1, limit: 10 });
for (const file of result.data) {
console.log(`${file.filename} (${file.size} bytes)`);
}
result = client.files.list(page=1, limit=10)
for file in result["data"]:
print(f"{file['filename']} ({file['size']} bytes)")
curl -X GET "https://hub.banditshq.com/api/v1/files?page=1&limit=10" \
-H "Authorization: Bearer lasso_..."
{
"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 }
}
⌘I
const result = await client.files.list({ page: 1, limit: 10 });
for (const file of result.data) {
console.log(`${file.filename} (${file.size} bytes)`);
}
result = client.files.list(page=1, limit=10)
for file in result["data"]:
print(f"{file['filename']} ({file['size']} bytes)")
curl -X GET "https://hub.banditshq.com/api/v1/files?page=1&limit=10" \
-H "Authorization: Bearer lasso_..."
{
"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 }
}

