---
title: "Return Attachment metadata"
method: GET
path: "/v3/grants/{grant_id}/attachments/{attachment_id}"
tags: ["Attachments"]
---

# Return Attachment metadata

`GET /v3/grants/{grant_id}/attachments/{attachment_id}`

Returns the metadata of the specified attachment.

## Response `200`

Attachment metadata

- object
  - `request_id` string — The request ID.
  - `data` object — Metadata for a file attached to an email message.
    - `id` string — A globally unique object identifier for Microsoft accounts. An email address for Google accounts.
    - `content_type` string — The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types) of the attachment, used by the email client to determine how to display the attachment. If you don't provide a type, Nylas infers it from the file name. The value of this field is exactly the same as the email attachment's `Content-Type` header. The provider might set additional parameters, such as `name` and `charset`. Nylas returns an empty `content_type` field if an attachment file name contains non-ASCII characters (for example, accented characters like `ü`). This is because Google can't detect its content type.
    - `filename` string — The file name of the attachment.
    - `grant_id` string — The ID of grant for the connected user.
    - `content_id` string — (Inline attachments only) The alphanumeric `cid` from the `<img>` tag in the message's HTML. For example, you might see something like `<img src=\"cid:ce9b9547-9eeb-43b2-ac4e-58768bdf04e4\">` in the message body.
    - `content_disposition` string — (Not supported for Microsoft and EWS) The content disposition of the attachment. Usually, this is `inline` or `attachment` followed by the file name (for example, `inline; filename="some-image.jpeg"`).
    - `is_inline` boolean — Whether the attachment is inline (embedded in the message body, such as an image).
    - `size` integer — The size of the attachment, in bytes.

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `404` — Not Found
- `429` — Rate Limit
- `504` — Provider Failure

---

[API](https://skmtc.dev/nylas/apis/nylas-api.md) · [All operations](https://skmtc.dev/nylas/apis/nylas-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/nylas/nylas-api/revisions/51c2c1b4ecff/schema)
