# Read a picked cloud file's bytes

One file from the caller's own connected storage, base64: :source is drive (a Google Drive file that is NOT a Google-native document - an .xlsx, .csv, .pdf or image) or onedrive (an id from get_onedrive_files). Answers {name, contentType, contentB64}. A Google Sheet is refused with 422 because it has no bytes of its own - read it through the Drive export instead. Refuses over 25 MB with 413 rather than truncating. Reach for it once a person has picked the file to attach.

Access class: `workspace`.

## Endpoint

`GET /v1/cloud-files/{source}/{id}/content`

## Parameters

| Name | In | Type | Required |
| --- | --- | --- | --- |
| source | path | string | Yes |
| id | path | string | Yes |
| body | query | null | No |
| params | query | object | No |
| query | query | object | No |

## Responses

### 200

the action's answer

Content type: `application/json`.

```json
{
  "data": {
    "contentB64": "string",
    "contentType": "string",
    "name": "string"
  }
}
```

### default

a refusal: `{"error": "<what a person needs to read>"}`. 401 no credential, 402 the plan does not include this, 403 the seat does not, 404 the thing does not exist or is not yours to see.

Content type: `application/json`.

```json
{
  "error": "string"
}
```
