上传文件
browser_upload_fileUploads local files into a page's file input using an element ref and absolute paths, with a 20MB total size limit.
Instructions
Upload local file(s) into a element by ref. Accepts absolute local paths; total size capped at 20MB. Fire-and-forget is enough — the change event fires for the page.
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": {
"ref": "<ref>",
"paths": "<paths>"
},
"name": "browser_upload_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | Yes | Element ref of the file input | |
| paths | Yes | Absolute local file path(s) | |
| tabId | No | Tab id (default: active tab) |