Skip to main content
GET
/
files
/
metadata
curl https://api.u1.archetypeai.app/v0.5/files/metadata \
  -H "Authorization: Bearer $ATAI_API_KEY"
[
  {
    "file_id": "file-abc123",
    "file_uid": "8f2c1e5a-7b3d-4d9e-9c1a-2f5b7d8e4a6c",
    "is_valid": true,
    "file_type": "image/png",
    "num_bytes": 482931,
    "file_status": "FILE_STATUS_INGESTED",
    "file_attributes": {
      "width": 1920,
      "height": 1080,
      "num_channels": 3,
      "channel_bands": ["R", "G", "B"]
    },
    "ingested": true,
    "file_index": 0,
    "file_tags": {}
  },
  {
    "file_id": "file-def456",
    "file_uid": "1d4f9b2e-3a8c-4e1d-bb02-7d6c9f0a3b51",
    "is_valid": true,
    "file_type": "text/csv",
    "num_bytes": 12483910,
    "file_status": "FILE_STATUS_INGESTED",
    "file_attributes": {
      "num_rows": 50000,
      "num_columns": 24,
      "column_headers": ["timestamp", "value", "label"]
    },
    "ingested": true,
    "file_index": 1,
    "file_tags": {}
  }
]

Documentation Index

Fetch the complete documentation index at: https://docs.archetypeai.app/llms.txt

Use this file to discover all available pages before exploring further.

Overview

This endpoint returns a list of metadata records for files belonging to your organization. Use the optional sharding parameters to page through large file collections. The list is partitioned into shards of max_items_per_shard items, and shard_index selects which shard to return. Both parameters are optional — when omitted, the server returns the full set, up to 1000 maximum records.

Query Parameters

shard_index
integer
default:"-1"
Zero-based index of the shard to return. Use together with max_items_per_shard to page through results. Specify -1 to retrieve all files.
max_items_per_shard
integer
default:"-1"
Maximum number of metadata records per shard. Specify -1 for the maximum allowed number of records per shard. At the time of this writing, the maximum number of records per shard is 1000.
file_type
string
Filter results to a single exact MIME type (e.g. image/png, text/csv). Omit to return files of all types.

Response

Returns an array of file metadata records. Each record has the same shape as the response from Get File Metadata.
curl https://api.u1.archetypeai.app/v0.5/files/metadata \
  -H "Authorization: Bearer $ATAI_API_KEY"
[
  {
    "file_id": "file-abc123",
    "file_uid": "8f2c1e5a-7b3d-4d9e-9c1a-2f5b7d8e4a6c",
    "is_valid": true,
    "file_type": "image/png",
    "num_bytes": 482931,
    "file_status": "FILE_STATUS_INGESTED",
    "file_attributes": {
      "width": 1920,
      "height": 1080,
      "num_channels": 3,
      "channel_bands": ["R", "G", "B"]
    },
    "ingested": true,
    "file_index": 0,
    "file_tags": {}
  },
  {
    "file_id": "file-def456",
    "file_uid": "1d4f9b2e-3a8c-4e1d-bb02-7d6c9f0a3b51",
    "is_valid": true,
    "file_type": "text/csv",
    "num_bytes": 12483910,
    "file_status": "FILE_STATUS_INGESTED",
    "file_attributes": {
      "num_rows": 50000,
      "num_columns": 24,
      "column_headers": ["timestamp", "value", "label"]
    },
    "ingested": true,
    "file_index": 1,
    "file_tags": {}
  }
]