# Method: media.download

- [HTTP request](https://developers.google.com/workspace/keep/api/reference/rest/v1/media/download#body.HTTP_TEMPLATE)
- [Path parameters](https://developers.google.com/workspace/keep/api/reference/rest/v1/media/download#body.PATH_PARAMETERS)
- [Query parameters](https://developers.google.com/workspace/keep/api/reference/rest/v1/media/download#body.QUERY_PARAMETERS)
- [Request body](https://developers.google.com/workspace/keep/api/reference/rest/v1/media/download#body.request_body)
- [Response body](https://developers.google.com/workspace/keep/api/reference/rest/v1/media/download#body.response_body)
- [Authorization scopes](https://developers.google.com/workspace/keep/api/reference/rest/v1/media/download#body.aspect)

Gets an attachment. To download attachment media via REST requires the alt=media query parameter. Returns a 400 bad request error if attachment media is not available in the requested MIME type.

### HTTP request

`GET https://keep.googleapis.com/v1/{name=notes/*/attachments/*}`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. The name of the attachment. |

### Query parameters

| Parameters ||
|---|---|
| `mimeType` | `string` The IANA MIME type format requested. The requested MIME type must be one specified in the attachment.mime_type. Required when downloading attachment media and ignored otherwise. |

### Request body

The request body must be empty.

### Response body

If successful, the response body contains an instance of `https://developers.google.com/workspace/keep/api/reference/rest/v1/notes#Attachment`.

### Authorization scopes

Requires one of the following OAuth scopes:

- `https://www.googleapis.com/auth/keep`
- `https://www.googleapis.com/auth/keep.readonly`

For more information, see the [Authorization guide](https://developers.google.com/workspace/guides/configure-oauth-consent).