pb_files_upload
Attach files to specific records in a PocketBase collection by uploading Base64 encoded data, specifying the record ID, field name, and file details for storage.
Instructions
Upload a file to a record field
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"collection": "<collection>",
"recordId": "<recordId>",
"fieldName": "<fieldName>",
"fileData": "<fileData>",
"fileName": "<fileName>"
},
"name": "pb_files_upload"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| collection | Yes | Collection name or ID | |
| fieldName | Yes | Field name to store the file in | |
| fileData | Yes | Base64 encoded file data | |
| fileName | Yes | Original file name | |
| mimeType | No | File MIME type | |
| recordId | Yes | Record ID to attach the file to |