files.extend_file
Extend retention for a file that was uploaded with files.upload_file and appears in files.list_uploaded_files with retained_until.
Adds additional_retention_days to the current schedule (or from now if retention already expired). Only files with a completed upload session and retention metadata can be extended.
Cost = max(1, ceil(size_gibibytes * additional_retention_days * 2)) tokens.
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_name": "<file_name>",
"additional_retention_days": "<additional_retention_days>"
},
"name": "files.extend_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_name | Yes | Relative file name or path to extend. Use files.list_uploaded_files and choose a file that includes retained_until. | |
| additional_retention_days | Yes | Days to add to the file's retention schedule. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_name | No | Extended file name. | |
| size_bytes | No | File size in bytes used for billing. | |
| token_cost | No | Tokens billed for this extension. | |
| retained_until | No | ISO 8601 timestamp when the file is now scheduled to be removed. | |
| additional_retention_days | No | Days added in this request. |