TokenLab

Gemini Files & Cache

Get Gemini file

Reads metadata for a Gemini file.

GET
/v1beta/files/{fileId}
Reads metadata for a Gemini file. Resources can only be read, referenced, changed, or deleted in their owning Workspace. Missing, expired, or inaccessible resources return a Gemini-format error.
curl -X GET "https://example.com/v1beta/files/string"
{  "name": "string",  "displayName": "string",  "mimeType": "string",  "sizeBytes": "string",  "uri": "string",  "state": "string",  "createTime": "2019-08-24T14:15:22Z",  "updateTime": "2019-08-24T14:15:22Z",  "expirationTime": "2019-08-24T14:15:22Z",  "error": {}}

Authorization

AuthorizationBearer <token>

API Key authentication. Create or manage API keys in Dashboard > API > API Keys.

In: header

Path Parameters

fileId*string

Suffix of the returned files/{fileId} name.

Query Parameters

key?string

API key alternative to Bearer or x-goog-api-key.

Response

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json