Files
MCP tools for the Files module. See the Files module docs for permissions and data model.
list-files
List all files
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
project_id | string | no | Filter files by project ID |
path_prefix | string | no | Only files under this directory. The prefix is a path boundary, not a substring: /reports returns /reports/q1.txt and never /reports-archive/q1.txt, and / selects the whole project. A leading slash is optional and a trailing one is ignored, so reports, /reports and /reports/ are the same filter. % and _ are literal characters, not wildcards. Naming a directory under /.system/ is what includes platform-written files, which a list without this parameter leaves out. |
tags | array | no | Filter by tag pairs, written key:value (split on the first colon, so a value may contain colons). Repeat the parameter for several pairs; all must be present with exactly that value. |
limit | number | no | Maximum number of results to return |
offset | number | no | Number of results to skip |
create-file
Create a file
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
project_id | string | no | Public ID of the project. Optional when authenticating with a project-scoped API key, which defaults to the key's project; required otherwise. |
prefix | string | no | Directory within the project (e.g. /images). Optional; defaults to / (root). Combined with filename to form the file's key (path). |
filename | string | no | Original / download name and the key's leaf segment (e.g. logo.png). |
content_type | string | no | MIME type of the file |
size | number | null | no | File size in bytes |
metadata | any | no | Caller-owned annotations on a resource, stored as the object they were written as: the types a value was written with are the types a read returns, so a filter can ask an ordering question about a number. Unlike other body fields, keys are stored and returned verbatim in the casing supplied — they are not converted between snake_case and camelCase. No key is reserved, and that is the point: every piece of state the platform owns lives in its own typed column, so nothing written here reaches platform state. The platform never reads the bag — it is not an IAM context, not a policy input and not part of a prompt — which is what separates it from a tag bag. |
upload-file
Upload a file
Arguments
This tool takes no arguments.
upload-file-base64
Upload a file using base64 encoding
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
project_id | string | no | Public ID of the project |
content | string | yes | Base64-encoded file content |
prefix | string | no | Directory within the project (e.g. /documents). Optional; defaults to / (root). |
filename | string | no | Original / download name and the key's leaf segment. |
content_type | string | no | MIME type of the file |
metadata | any | no | Caller-owned annotations on a resource, stored as the object they were written as: the types a value was written with are the types a read returns, so a filter can ask an ordering question about a number. Unlike other body fields, keys are stored and returned verbatim in the casing supplied — they are not converted between snake_case and camelCase. No key is reserved, and that is the point: every piece of state the platform owns lives in its own typed column, so nothing written here reaches platform state. The platform never reads the bag — it is not an IAM context, not a policy input and not part of a prompt — which is what separates it from a tag bag. |
create-presigned-url
Create a presigned upload URL
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
project_id | string | yes | Public ID of the project |
prefix | string | no | Directory within the project (e.g. /documents). Optional; defaults to / (root). |
filename | string | no | Original / download name and the key's leaf segment. |
content_type | string | no | MIME type of the file to be uploaded |
upload-file-with-token
Upload a file using an upload token
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
token | string | yes | The single-use upload token (e.g. upt_...) |
content | string | no | Base64-encoded file content (alternative to multipart file) |
filename | string | no | Original / download name (overrides the token's filename) |
content_type | string | no | MIME type of the file (overrides the token's content type) |
metadata | any | no | Caller-owned annotations on a resource, stored as the object they were written as: the types a value was written with are the types a read returns, so a filter can ask an ordering question about a number. Unlike other body fields, keys are stored and returned verbatim in the casing supplied — they are not converted between snake_case and camelCase. No key is reserved, and that is the point: every piece of state the platform owns lives in its own typed column, so nothing written here reaches platform state. The platform never reads the bag — it is not an IAM context, not a policy input and not part of a prompt — which is what separates it from a tag bag. |
get-file
Get a file by ID
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
file_id | string | yes | File ID |
delete-file
Delete a file
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
file_id | string | yes | ID of the file to delete |
update-file-metadata
Update file metadata
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
file_id | string | yes | File ID |
metadata | any | no | Replaces the stored bag; null clears it. |
prefix | string | no | New directory — moves the file. The resulting path (prefix + filename) must be unique within the project. |
filename | string | no | New filename — renames the key's leaf and the download name. |
download-file-base64
Download file as base64
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
file_id | string | yes | File ID |
token | string | no | Signed single-file download token, an alternative to a bearer credential (issued for ingestion-rule converters). |
get-file-tags
Get file tags
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
file_id | string | yes | File ID |
replace-file-tags
Replace file tags
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
file_id | string | yes | File ID |
merge-file-tags
Merge file tags
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
file_id | string | yes | File ID |