box.api.* operation is listed below with parameter shapes and return types from the plugin Zod schemas.
Files
copy
files.copy
Copy a Box file to a destination folder
Risk: write
await corsair.box.api.files.copy({});
| Name | Type | Required | Description |
|---|---|---|---|
file_id | string | Yes | — |
parent | object | Yes | — |
name | string | No | — |
version | string | No | — |
parent full type
parent full type
{
id: string
}
| Name | Type | Required | Description |
|---|---|---|---|
type | file | No | — |
id | string | Yes | — |
sequence_id | string | No | — |
etag | string | No | — |
sha1 | string | No | — |
name | string | No | — |
description | string | No | — |
size | number | No | — |
path_collection | object | No | — |
created_at | string | No | — |
modified_at | string | No | — |
trashed_at | string | No | — |
purged_at | string | No | — |
content_created_at | string | No | — |
content_modified_at | string | No | — |
created_by | object | No | — |
modified_by | object | No | — |
owned_by | object | No | — |
shared_link | object | No | — |
parent | object | No | — |
item_status | string | No | — |
extension | string | No | — |
is_package | boolean | No | — |
path_collection full type
path_collection full type
{
total_count?: number,
entries?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}[]
}
created_by full type
created_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
modified_by full type
modified_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
owned_by full type
owned_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
shared_link full type
shared_link full type
{
url?: string,
download_url?: string | null,
vanity_url?: string | null,
access?: string,
effective_access?: string,
effective_permission?: string,
unshared_at?: string | null,
is_password_enabled?: boolean,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
},
download_count?: number,
preview_count?: number
}
parent full type
parent full type
{
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}
delete
files.delete
Delete a Box file [DESTRUCTIVE]
Risk: destructive
await corsair.box.api.files.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
file_id | string | Yes | — |
if_match | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
success | boolean | Yes | — |
download
files.download
Download the content of a Box file
Risk: read
await corsair.box.api.files.download({});
| Name | Type | Required | Description |
|---|---|---|---|
file_id | string | Yes | — |
version | string | No | — |
string
get
files.get
Get metadata for a Box file by ID
Risk: read
await corsair.box.api.files.get({});
| Name | Type | Required | Description |
|---|---|---|---|
file_id | string | Yes | — |
fields | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
type | file | No | — |
id | string | Yes | — |
sequence_id | string | No | — |
etag | string | No | — |
sha1 | string | No | — |
name | string | No | — |
description | string | No | — |
size | number | No | — |
path_collection | object | No | — |
created_at | string | No | — |
modified_at | string | No | — |
trashed_at | string | No | — |
purged_at | string | No | — |
content_created_at | string | No | — |
content_modified_at | string | No | — |
created_by | object | No | — |
modified_by | object | No | — |
owned_by | object | No | — |
shared_link | object | No | — |
parent | object | No | — |
item_status | string | No | — |
extension | string | No | — |
is_package | boolean | No | — |
path_collection full type
path_collection full type
{
total_count?: number,
entries?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}[]
}
created_by full type
created_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
modified_by full type
modified_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
owned_by full type
owned_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
shared_link full type
shared_link full type
{
url?: string,
download_url?: string | null,
vanity_url?: string | null,
access?: string,
effective_access?: string,
effective_permission?: string,
unshared_at?: string | null,
is_password_enabled?: boolean,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
},
download_count?: number,
preview_count?: number
}
parent full type
parent full type
{
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}
search
files.search
Search for files in Box
Risk: read
await corsair.box.api.files.search({});
| Name | Type | Required | Description |
|---|---|---|---|
query | string | Yes | — |
limit | number | No | — |
offset | number | No | — |
ancestor_folder_ids | string | No | — |
content_types | string | No | — |
created_at_range | string | No | — |
file_extensions | string | No | — |
owner_user_ids | string | No | — |
size_range | string | No | — |
sort | modified_at | name | No | — |
direction | ASC | DESC | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
total_count | number | No | — |
offset | number | No | — |
limit | number | No | — |
entries | object[] | No | — |
entries full type
entries full type
{
type?: string,
id: string,
name?: string
}[]
share
files.share
Create or update a shared link for a Box file
Risk: write
await corsair.box.api.files.share({});
| Name | Type | Required | Description |
|---|---|---|---|
file_id | string | Yes | — |
shared_link | object | Yes | — |
shared_link full type
shared_link full type
{
access?: open | company | collaborators,
password?: string,
unshared_at?: string,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
}
}
| Name | Type | Required | Description |
|---|---|---|---|
type | file | No | — |
id | string | Yes | — |
sequence_id | string | No | — |
etag | string | No | — |
sha1 | string | No | — |
name | string | No | — |
description | string | No | — |
size | number | No | — |
path_collection | object | No | — |
created_at | string | No | — |
modified_at | string | No | — |
trashed_at | string | No | — |
purged_at | string | No | — |
content_created_at | string | No | — |
content_modified_at | string | No | — |
created_by | object | No | — |
modified_by | object | No | — |
owned_by | object | No | — |
shared_link | object | No | — |
parent | object | No | — |
item_status | string | No | — |
extension | string | No | — |
is_package | boolean | No | — |
path_collection full type
path_collection full type
{
total_count?: number,
entries?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}[]
}
created_by full type
created_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
modified_by full type
modified_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
owned_by full type
owned_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
shared_link full type
shared_link full type
{
url?: string,
download_url?: string | null,
vanity_url?: string | null,
access?: string,
effective_access?: string,
effective_permission?: string,
unshared_at?: string | null,
is_password_enabled?: boolean,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
},
download_count?: number,
preview_count?: number
}
parent full type
parent full type
{
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}
upload
files.upload
Upload a new file to Box
Risk: write
await corsair.box.api.files.upload({});
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | — |
parent_id | string | Yes | — |
content | string | Yes | — |
content_created_at | string | No | — |
content_modified_at | string | No | — |
description | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
total_count | number | No | — |
entries | object[] | No | — |
entries full type
entries full type
{
type?: file,
id: string,
sequence_id?: string,
etag?: string,
sha1?: string,
name?: string,
description?: string,
size?: number,
path_collection?: {
total_count?: number,
entries?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}[]
},
created_at?: string,
modified_at?: string,
trashed_at?: string | null,
purged_at?: string | null,
content_created_at?: string,
content_modified_at?: string,
created_by?: {
type?: string,
id?: string,
name?: string,
login?: string
},
modified_by?: {
type?: string,
id?: string,
name?: string,
login?: string
},
owned_by?: {
type?: string,
id?: string,
name?: string,
login?: string
},
shared_link?: {
url?: string,
download_url?: string | null,
vanity_url?: string | null,
access?: string,
effective_access?: string,
effective_permission?: string,
unshared_at?: string | null,
is_password_enabled?: boolean,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
},
download_count?: number,
preview_count?: number
} | null,
parent?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
} | null,
item_status?: string,
extension?: string,
is_package?: boolean
}[]
Folders
create
folders.create
Create a new folder in Box
Risk: write
await corsair.box.api.folders.create({});
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | — |
parent_id | string | Yes | — |
folder_upload_email_access | string | No | — |
sync_state | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
type | folder | No | — |
id | string | Yes | — |
sequence_id | string | No | — |
etag | string | No | — |
name | string | No | — |
description | string | No | — |
path_collection | object | No | — |
created_at | string | No | — |
modified_at | string | No | — |
trashed_at | string | No | — |
purged_at | string | No | — |
content_created_at | string | No | — |
content_modified_at | string | No | — |
created_by | object | No | — |
modified_by | object | No | — |
owned_by | object | No | — |
shared_link | object | No | — |
parent | object | No | — |
item_status | string | No | — |
is_externally_owned | boolean | No | — |
has_collaborations | boolean | No | — |
item_collection | object | No | — |
path_collection full type
path_collection full type
{
total_count?: number,
entries?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}[]
}
created_by full type
created_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
modified_by full type
modified_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
owned_by full type
owned_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
shared_link full type
shared_link full type
{
url?: string,
download_url?: string | null,
vanity_url?: string | null,
access?: string,
effective_access?: string,
effective_permission?: string,
unshared_at?: string | null,
is_password_enabled?: boolean,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
},
download_count?: number,
preview_count?: number
}
parent full type
parent full type
{
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}
item_collection full type
item_collection full type
{
total_count?: number,
entries?: {
}[]
}
delete
folders.delete
Delete a Box folder [DESTRUCTIVE]
Risk: destructive
await corsair.box.api.folders.delete({});
| Name | Type | Required | Description |
|---|---|---|---|
folder_id | string | Yes | — |
recursive | boolean | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
success | boolean | Yes | — |
get
folders.get
Get metadata for a Box folder by ID
Risk: read
await corsair.box.api.folders.get({});
| Name | Type | Required | Description |
|---|---|---|---|
folder_id | string | Yes | — |
fields | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
type | folder | No | — |
id | string | Yes | — |
sequence_id | string | No | — |
etag | string | No | — |
name | string | No | — |
description | string | No | — |
path_collection | object | No | — |
created_at | string | No | — |
modified_at | string | No | — |
trashed_at | string | No | — |
purged_at | string | No | — |
content_created_at | string | No | — |
content_modified_at | string | No | — |
created_by | object | No | — |
modified_by | object | No | — |
owned_by | object | No | — |
shared_link | object | No | — |
parent | object | No | — |
item_status | string | No | — |
is_externally_owned | boolean | No | — |
has_collaborations | boolean | No | — |
item_collection | object | No | — |
path_collection full type
path_collection full type
{
total_count?: number,
entries?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}[]
}
created_by full type
created_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
modified_by full type
modified_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
owned_by full type
owned_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
shared_link full type
shared_link full type
{
url?: string,
download_url?: string | null,
vanity_url?: string | null,
access?: string,
effective_access?: string,
effective_permission?: string,
unshared_at?: string | null,
is_password_enabled?: boolean,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
},
download_count?: number,
preview_count?: number
}
parent full type
parent full type
{
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}
item_collection full type
item_collection full type
{
total_count?: number,
entries?: {
}[]
}
search
folders.search
Search for folders in Box
Risk: read
await corsair.box.api.folders.search({});
| Name | Type | Required | Description |
|---|---|---|---|
query | string | Yes | — |
limit | number | No | — |
offset | number | No | — |
ancestor_folder_ids | string | No | — |
owner_user_ids | string | No | — |
sort | modified_at | name | No | — |
direction | ASC | DESC | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
total_count | number | No | — |
offset | number | No | — |
limit | number | No | — |
entries | object[] | No | — |
entries full type
entries full type
{
type?: string,
id: string,
name?: string
}[]
share
folders.share
Create or update a shared link for a Box folder
Risk: write
await corsair.box.api.folders.share({});
| Name | Type | Required | Description |
|---|---|---|---|
folder_id | string | Yes | — |
shared_link | object | Yes | — |
shared_link full type
shared_link full type
{
access?: open | company | collaborators,
password?: string,
unshared_at?: string,
permissions?: {
can_download?: boolean,
can_preview?: boolean
}
}
| Name | Type | Required | Description |
|---|---|---|---|
type | folder | No | — |
id | string | Yes | — |
sequence_id | string | No | — |
etag | string | No | — |
name | string | No | — |
description | string | No | — |
path_collection | object | No | — |
created_at | string | No | — |
modified_at | string | No | — |
trashed_at | string | No | — |
purged_at | string | No | — |
content_created_at | string | No | — |
content_modified_at | string | No | — |
created_by | object | No | — |
modified_by | object | No | — |
owned_by | object | No | — |
shared_link | object | No | — |
parent | object | No | — |
item_status | string | No | — |
is_externally_owned | boolean | No | — |
has_collaborations | boolean | No | — |
item_collection | object | No | — |
path_collection full type
path_collection full type
{
total_count?: number,
entries?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}[]
}
created_by full type
created_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
modified_by full type
modified_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
owned_by full type
owned_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
shared_link full type
shared_link full type
{
url?: string,
download_url?: string | null,
vanity_url?: string | null,
access?: string,
effective_access?: string,
effective_permission?: string,
unshared_at?: string | null,
is_password_enabled?: boolean,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
},
download_count?: number,
preview_count?: number
}
parent full type
parent full type
{
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}
item_collection full type
item_collection full type
{
total_count?: number,
entries?: {
}[]
}
update
folders.update
Update properties of a Box folder
Risk: write
await corsair.box.api.folders.update({});
| Name | Type | Required | Description |
|---|---|---|---|
folder_id | string | Yes | — |
name | string | No | — |
description | string | No | — |
parent_id | string | No | — |
tags | string[] | No | — |
is_collaboration_restricted_to_enterprise | boolean | No | — |
can_non_owners_invite | boolean | No | — |
can_non_owners_view_collaborators | boolean | No | — |
fields | string | No | — |
| Name | Type | Required | Description |
|---|---|---|---|
type | folder | No | — |
id | string | Yes | — |
sequence_id | string | No | — |
etag | string | No | — |
name | string | No | — |
description | string | No | — |
path_collection | object | No | — |
created_at | string | No | — |
modified_at | string | No | — |
trashed_at | string | No | — |
purged_at | string | No | — |
content_created_at | string | No | — |
content_modified_at | string | No | — |
created_by | object | No | — |
modified_by | object | No | — |
owned_by | object | No | — |
shared_link | object | No | — |
parent | object | No | — |
item_status | string | No | — |
is_externally_owned | boolean | No | — |
has_collaborations | boolean | No | — |
item_collection | object | No | — |
path_collection full type
path_collection full type
{
total_count?: number,
entries?: {
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}[]
}
created_by full type
created_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
modified_by full type
modified_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
owned_by full type
owned_by full type
{
type?: string,
id?: string,
name?: string,
login?: string
}
shared_link full type
shared_link full type
{
url?: string,
download_url?: string | null,
vanity_url?: string | null,
access?: string,
effective_access?: string,
effective_permission?: string,
unshared_at?: string | null,
is_password_enabled?: boolean,
permissions?: {
can_download?: boolean,
can_preview?: boolean,
can_edit?: boolean
},
download_count?: number,
preview_count?: number
}
parent full type
parent full type
{
type?: string,
id?: string,
sequence_id?: string | null,
etag?: string | null,
name?: string | null
}
item_collection full type
item_collection full type
{
total_count?: number,
entries?: {
}[]
}