# Content

## Download file content

`client.Files.Content.Get(ctx, fileID, query) (*FileContentGetResponse, error)`

**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`

- `query FileContentGetParams`

  - `XProjectID param.Field[string]`

### Returns

- `type FileContentGetResponse interface{…}`

### Example

```go
package main

import (
  "context"
  "fmt"

  "github.com/scaleapi/sgp-dev-go"
  "github.com/scaleapi/sgp-dev-go/option"
)

func main() {
  client := sgpdev.NewClient(
    option.WithAPIKey("My API Key"),
    option.WithAccountID("My Account ID"),
  )
  content, err := client.Files.Content.Get(
    context.TODO(),
    "file_id",
    sgpdev.FileContentGetParams{

    },
  )
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", content)
}
```

#### Response

```json
{}
```
