get_file
Retrieve file metadata from Gemini API to verify file state, check expiration, and refresh cache entries using the file URI.
Instructions
GET FILE METADATA & UPDATE CACHE - Retrieves current metadata for specific file from Gemini API and updates cache. USAGE: Pass fileUri from upload response or list_files. RETURNS: Complete file info including uri, displayName, mimeType, sizeBytes, create/update/expiration times, sha256Hash, state. Automatically adds to cache if missing. USE CASE: Verify file state, check expiration, refresh cache entry.
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": {
"fileUri": "<fileUri>"
},
"name": "get_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fileUri | Yes | The file URI or name returned from upload_file |