# Content

## Download file content

`client.files.content.retrieve(stringfileID, ContentRetrieveParamsparams?, RequestOptionsoptions?): ContentRetrieveResponse`

**get** `/v5/files/{file_id}/content`

Download the raw bytes of a file by id.

Streams the stored object's content back directly (not a redirect or signed
URL), with the response Content-Type set to the file's stored MIME type and
Content-Disposition set to attachment. Use the metadata endpoint for size,
filename, and other attributes.

### Parameters

- `fileID: string`

- `params: ContentRetrieveParams`

  - `xProjectID?: string`

### Returns

- `ContentRetrieveResponse = unknown`

### Example

```typescript
import SGPClient from 'scale-gp';

const client = new SGPClient({
  accountID: 'My Account ID',
  apiKey: process.env['SGP_API_KEY'], // This is the default and can be omitted
});

const content = await client.files.content.retrieve('file_id');

console.log(content);
```

#### Response

```json
{}
```

## Domain Types

### Content Retrieve Response

- `ContentRetrieveResponse = unknown`
