Skip to content
Get started

Read File Content

GET/api/v1/beta/files/{file_id}/content

Returns a presigned url to read the file content.

Path ParametersExpand Collapse
file_id: string
Query ParametersExpand Collapse
expires_at_seconds: optional number
organization_id: optional string
project_id: optional string
Cookie ParametersExpand Collapse
session: optional string
ReturnsExpand Collapse
PresignedURL = object { expires_at, url, form_fields }

Schema for a presigned URL.

expires_at: string

The time at which the presigned URL expires

formatdate-time
url: string

A presigned URL for IO operations against a private file

minLength1
formaturi
form_fields: optional map[string]

Form fields for a presigned POST request

Read File Content

curl https://api.cloud.llamaindex.ai/api/v1/beta/files/$FILE_ID/content \
    -H "Authorization: Bearer $LLAMA_CLOUD_API_KEY"
{
  "expires_at": "2019-12-27T18:11:19.117Z",
  "url": "https://example.com",
  "form_fields": {
    "foo": "string"
  }
}
Returns Examples
{
  "expires_at": "2019-12-27T18:11:19.117Z",
  "url": "https://example.com",
  "form_fields": {
    "foo": "string"
  }
}