Skip to content
Framework Docs

Create Index

$ llamacloud-prod beta:indexes create
POST/api/v1/indexes

Create a searchable index over a source directory.

ParametersExpand Collapse
--source-directory-id: string

Body param: ID of the source directory containing your documents.

--organization-id: optional string

Query param

--project-id: optional string

Query param

--description: optional string

Body param: Optional description of the index.

--name: optional string

Body param: Optional display name for the index. If omitted, the index is named after the source directory.

--product: optional array of object { product_config_id, product_type }

Body param: Product configurations for syncing. Omit to use a default parse configuration. Include an explicit entry per product type (e.g. parse, extract) to override the default.

--store-attachment: optional array of string

Body param: Attachment kinds to store alongside parsed output. Each entry must be one of: screenshots, items. For example, [‘screenshots’] renders and stores per-page screenshots; [‘items’] stores structured items with bounding boxes. Omit or pass an empty list to skip attachments.

--sync-frequency: optional string

Body param: How often to re-run the sync. One of: manual, daily, on_source_change. Defaults to manual.

--vector-target: optional "DEFAULT" or "DISABLED"

Body param: Vector export destination for the index. ‘DEFAULT’ exports to the managed vector DB destination resolved from configuration. ‘DISABLED’ skips vector export — the export destination falls back to ‘Download’.

ReturnsExpand Collapse
BetaIndexNewResponse: object { id, export_config_id, name, 9 more }

A searchable index over a directory of documents.

id: string

Unique identifier

export_config_id: string

ID of the export configuration.

name: string

Index name.

project_id: string

Project this index belongs to.

source_directory_id: string

ID of the source directory.

sync_config_id: string

ID of the sync configuration.

created_at: optional string

Creation datetime

description: optional string

Index description.

last_exported_at: optional string

Last export time.

last_synced_at: optional string

Last sync time.

metadata: optional map[unknown]

Build state and diagnostic info.

updated_at: optional string

Update datetime

Create Index

llamacloud-prod beta:indexes create \
  --api-key 'My API Key' \
  --source-directory-id dir-abc123
{
  "id": "id",
  "export_config_id": "export_config_id",
  "name": "name",
  "project_id": "project_id",
  "source_directory_id": "source_directory_id",
  "sync_config_id": "sync_config_id",
  "created_at": "2019-12-27T18:11:19.117Z",
  "description": "description",
  "last_exported_at": "2019-12-27T18:11:19.117Z",
  "last_synced_at": "2019-12-27T18:11:19.117Z",
  "metadata": {
    "foo": "bar"
  },
  "updated_at": "2019-12-27T18:11:19.117Z"
}
Returns Examples
{
  "id": "id",
  "export_config_id": "export_config_id",
  "name": "name",
  "project_id": "project_id",
  "source_directory_id": "source_directory_id",
  "sync_config_id": "sync_config_id",
  "created_at": "2019-12-27T18:11:19.117Z",
  "description": "description",
  "last_exported_at": "2019-12-27T18:11:19.117Z",
  "last_synced_at": "2019-12-27T18:11:19.117Z",
  "metadata": {
    "foo": "bar"
  },
  "updated_at": "2019-12-27T18:11:19.117Z"
}