Skip to content

Directories

Create Directory
client.beta.directories.create(DirectoryCreateParams { name, organization_id, project_id, description } params, RequestOptionsoptions?): DirectoryCreateResponse { id, name, project_id, 4 more }
POST/api/v1/beta/directories
List Directories
client.beta.directories.list(DirectoryListParams { include_deleted, name, organization_id, 4 more } query?, RequestOptionsoptions?): PaginatedCursor<DirectoryListResponse { id, name, project_id, 4 more } >
GET/api/v1/beta/directories
Get Directory
client.beta.directories.get(stringdirectoryID, DirectoryGetParams { organization_id, project_id } query?, RequestOptionsoptions?): DirectoryGetResponse { id, name, project_id, 4 more }
GET/api/v1/beta/directories/{directory_id}
Update Directory
client.beta.directories.update(stringdirectoryID, DirectoryUpdateParams { organization_id, project_id, description, name } params, RequestOptionsoptions?): DirectoryUpdateResponse { id, name, project_id, 4 more }
PATCH/api/v1/beta/directories/{directory_id}
Delete Directory
client.beta.directories.delete(stringdirectoryID, DirectoryDeleteParams { organization_id, project_id } params?, RequestOptionsoptions?): void
DELETE/api/v1/beta/directories/{directory_id}
ModelsExpand Collapse
DirectoryCreateResponse { id, name, project_id, 4 more }

API response schema for a directory.

id: string

Unique identifier for the directory.

name: string

Human-readable name for the directory.

minLength1
project_id: string

Project the directory belongs to.

created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Optional timestamp of when the directory was deleted. Null if not deleted.

formatdate-time
description?: string | null

Optional description shown to users.

updated_at?: string | null

Update datetime

formatdate-time
DirectoryListResponse { id, name, project_id, 4 more }

API response schema for a directory.

id: string

Unique identifier for the directory.

name: string

Human-readable name for the directory.

minLength1
project_id: string

Project the directory belongs to.

created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Optional timestamp of when the directory was deleted. Null if not deleted.

formatdate-time
description?: string | null

Optional description shown to users.

updated_at?: string | null

Update datetime

formatdate-time
DirectoryGetResponse { id, name, project_id, 4 more }

API response schema for a directory.

id: string

Unique identifier for the directory.

name: string

Human-readable name for the directory.

minLength1
project_id: string

Project the directory belongs to.

created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Optional timestamp of when the directory was deleted. Null if not deleted.

formatdate-time
description?: string | null

Optional description shown to users.

updated_at?: string | null

Update datetime

formatdate-time
DirectoryUpdateResponse { id, name, project_id, 4 more }

API response schema for a directory.

id: string

Unique identifier for the directory.

name: string

Human-readable name for the directory.

minLength1
project_id: string

Project the directory belongs to.

created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Optional timestamp of when the directory was deleted. Null if not deleted.

formatdate-time
description?: string | null

Optional description shown to users.

updated_at?: string | null

Update datetime

formatdate-time

DirectoriesFiles

Add Directory File
client.beta.directories.files.add(stringdirectoryID, FileAddParams { file_id, organization_id, project_id, 3 more } params, RequestOptionsoptions?): FileAddResponse { id, directory_id, display_name, 8 more }
POST/api/v1/beta/directories/{directory_id}/files
List Directory Files
client.beta.directories.files.list(stringdirectoryID, FileListParams { display_name, display_name_contains, expand, 9 more } query?, RequestOptionsoptions?): PaginatedCursor<FileListResponse { id, directory_id, display_name, 8 more } >
GET/api/v1/beta/directories/{directory_id}/files
Get Directory File
client.beta.directories.files.get(stringdirectoryFileID, FileGetParams { directory_id, expand, organization_id, project_id } params, RequestOptionsoptions?): FileGetResponse { id, directory_id, display_name, 8 more }
GET/api/v1/beta/directories/{directory_id}/files/{directory_file_id}
Update Directory File
client.beta.directories.files.update(stringdirectoryFileID, FileUpdateParams { body_directory_id, organization_id, project_id, 3 more } params, RequestOptionsoptions?): FileUpdateResponse { id, directory_id, display_name, 8 more }
PATCH/api/v1/beta/directories/{directory_id}/files/{directory_file_id}
Delete Directory File
client.beta.directories.files.delete(stringdirectoryFileID, FileDeleteParams { directory_id, organization_id, project_id } params, RequestOptionsoptions?): void
DELETE/api/v1/beta/directories/{directory_id}/files/{directory_file_id}
Upload File To Directory
client.beta.directories.files.upload(stringdirectoryID, FileUploadParams { upload_file, organization_id, project_id, 4 more } params, RequestOptionsoptions?): FileUploadResponse { id, directory_id, display_name, 8 more }
POST/api/v1/beta/directories/{directory_id}/files/upload
ModelsExpand Collapse
FileAddResponse { id, directory_id, display_name, 8 more }

API response schema for a directory file.

id: string

Unique identifier for the directory file.

directory_id: string

Directory the file belongs to.

display_name: string

Display name for the file.

minLength1
project_id: string

Project the directory file belongs to.

unique_id: string

Unique identifier for the file in the directory

minLength1
created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Soft delete marker when the file is removed upstream or by user action.

formatdate-time
download_url?: PresignedURL { expires_at, url, form_fields } | null

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?: Record<string, string> | null

Form fields for a presigned POST request

file_id?: string | null

File ID for the storage location.

metadata?: Record<string, string | number | boolean | Array<string> | null>

Merged metadata from all sources. Higher-priority sources override lower.

One of the following:
string
number
boolean
Array<string>
updated_at?: string | null

Update datetime

formatdate-time
FileListResponse { id, directory_id, display_name, 8 more }

API response schema for a directory file.

id: string

Unique identifier for the directory file.

directory_id: string

Directory the file belongs to.

display_name: string

Display name for the file.

minLength1
project_id: string

Project the directory file belongs to.

unique_id: string

Unique identifier for the file in the directory

minLength1
created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Soft delete marker when the file is removed upstream or by user action.

formatdate-time
download_url?: PresignedURL { expires_at, url, form_fields } | null

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?: Record<string, string> | null

Form fields for a presigned POST request

file_id?: string | null

File ID for the storage location.

metadata?: Record<string, string | number | boolean | Array<string> | null>

Merged metadata from all sources. Higher-priority sources override lower.

One of the following:
string
number
boolean
Array<string>
updated_at?: string | null

Update datetime

formatdate-time
FileGetResponse { id, directory_id, display_name, 8 more }

API response schema for a directory file.

id: string

Unique identifier for the directory file.

directory_id: string

Directory the file belongs to.

display_name: string

Display name for the file.

minLength1
project_id: string

Project the directory file belongs to.

unique_id: string

Unique identifier for the file in the directory

minLength1
created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Soft delete marker when the file is removed upstream or by user action.

formatdate-time
download_url?: PresignedURL { expires_at, url, form_fields } | null

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?: Record<string, string> | null

Form fields for a presigned POST request

file_id?: string | null

File ID for the storage location.

metadata?: Record<string, string | number | boolean | Array<string> | null>

Merged metadata from all sources. Higher-priority sources override lower.

One of the following:
string
number
boolean
Array<string>
updated_at?: string | null

Update datetime

formatdate-time
FileUpdateResponse { id, directory_id, display_name, 8 more }

API response schema for a directory file.

id: string

Unique identifier for the directory file.

directory_id: string

Directory the file belongs to.

display_name: string

Display name for the file.

minLength1
project_id: string

Project the directory file belongs to.

unique_id: string

Unique identifier for the file in the directory

minLength1
created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Soft delete marker when the file is removed upstream or by user action.

formatdate-time
download_url?: PresignedURL { expires_at, url, form_fields } | null

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?: Record<string, string> | null

Form fields for a presigned POST request

file_id?: string | null

File ID for the storage location.

metadata?: Record<string, string | number | boolean | Array<string> | null>

Merged metadata from all sources. Higher-priority sources override lower.

One of the following:
string
number
boolean
Array<string>
updated_at?: string | null

Update datetime

formatdate-time
FileUploadResponse { id, directory_id, display_name, 8 more }

API response schema for a directory file.

id: string

Unique identifier for the directory file.

directory_id: string

Directory the file belongs to.

display_name: string

Display name for the file.

minLength1
project_id: string

Project the directory file belongs to.

unique_id: string

Unique identifier for the file in the directory

minLength1
created_at?: string | null

Creation datetime

formatdate-time
deleted_at?: string | null

Soft delete marker when the file is removed upstream or by user action.

formatdate-time
download_url?: PresignedURL { expires_at, url, form_fields } | null

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?: Record<string, string> | null

Form fields for a presigned POST request

file_id?: string | null

File ID for the storage location.

metadata?: Record<string, string | number | boolean | Array<string> | null>

Merged metadata from all sources. Higher-priority sources override lower.

One of the following:
string
number
boolean
Array<string>
updated_at?: string | null

Update datetime

formatdate-time