Create document upload url
create_document_upload_urlGet a one-time signed URL to put a local file into the tenant's storage, plus the path it will live at. The bytes never pass through the agent: upload with curl -H "Content-Type: <mime>" -T <file> "<upload_url>" from the shell — without the header the bucket answers 415, then call finalize_document_upload with the returned path. base64 through a tool call costs about 55.600 tokens for one screenshot and twice that for a scanned certificate, for content the agent never reads. The URL is valid for two hours and for exactly one path. Nothing is written to any record until you finalize — an abandoned upload leaves the target untouched.
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": {
"entity": "<entity>",
"entity_id": "<entity_id>",
"file_name": "<file_name>"
},
"name": "create_document_upload_url"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| entity | Yes | What the file belongs to. personnel means the person's CV file (cv_file_url); personnel_credential a degree or certificate. | |
| entity_id | Yes | ||
| file_name | Yes | Name as it should be kept, e.g. "Yuxiang He.pdf". Path separators are stripped. |