---
title: "Read a Google Drive file's text or binary content as the calling member"
method: GET
path: "/v1/capabilities/google-workspace/drive-file/{fileId}"
tags: ["Capability Sources"]
---

# Read a Google Drive file's text or binary content as the calling member

`GET /v1/capabilities/google-workspace/drive-file/{fileId}`

Reads one Google Drive file, exporting Google Docs editors files as plain text. Downloaded files are content-sniffed with strict UTF-8 detection, so text is returned regardless of MIME type; binary content is returned as standard base64 up to 10 MiB.

## Path parameters

- `fileId` string, required

## Response `200`

Google Drive file returned.

- GoogleWorkspaceDriveFileResponse
  - `ok` true, required
  - `file` object, required
    - `id` string, required
    - `name` string, required
    - `mimeType` string, required
    - `modifiedTime` string, required
    - `webViewLink` string, required
    - `size` string, nullable, required
    - `content` string, nullable, required
    - `contentBase64` string, nullable, required — Standard base64-encoded file bytes for binary files; decode locally. Same encoding as the gmail-attachment capability's dataBase64 — it can be passed directly to the Drive upload capability's dataBase64 field.
    - `encoding` 'text' | 'base64' | 'none', required
    - `truncated` boolean, required
    - `contentUnavailableReason` 'file_too_large', nullable, required

## Other responses

- `401` — The caller must be signed in.
- `409` — The calling member has not connected their Google account or is missing permission.
- `502` — Google rejected the request.

---

[API](https://skmtc.net/openworklabs/apis/den-api.md) · [All operations](https://skmtc.net/openworklabs/apis/den-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/openworklabs/den-api/versions/55ba7d5c7a7b/schema)
