upload_file
Upload a local file to ERPNext, optionally attaching it to a document and controlling privacy settings.
Instructions
Upload a local file to ERPNext.
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": {
"file_path": "<file_path>"
},
"name": "upload_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filename | No | Optional name for the uploaded file (defaults to original filename) | |
| file_path | Yes | Local file path to upload (e.g. "/mnt/nas/files/report.pdf") | |
| is_private | No | Whether file should be private (default True) | |
| attached_to_name | No | Optional document name to attach file to (e.g. "PROJ-0001") | |
| attached_to_doctype | No | Optional DocType to attach file to (e.g. "Project", "Item") |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||