import { Resend } from 'resend';
const resend = new Resend('re_xxxxxxxxx');
const { data, error } = await resend.emails.receiving.attachments.list({
emailId: '4ef9a417-02e9-4d39-ad75-9611e0fcc33c',
});
{
"object": "list",
"has_more": false,
"data": [
{
"id": "2a0c9ce0-3112-4728-976e-47ddcd16a318",
"filename": "avatar.png",
"size": 4096,
"content_type": "image/png",
"content_disposition": "inline",
"content_id": "img001",
"download_url": "https://inbound-cdn.resend.com/4ef9a417-02e9-4d39-ad75-9611e0fcc33c/attachments/2a0c9ce0-3112-4728-976e-47ddcd16a318?some-params=example&signature=sig-123",
"expires_at": "2025-10-17T14:29:41.521Z"
}
]
}
Retrieve a list of attachments from a received email.
import { Resend } from 'resend';
const resend = new Resend('re_xxxxxxxxx');
const { data, error } = await resend.emails.receiving.attachments.list({
emailId: '4ef9a417-02e9-4d39-ad75-9611e0fcc33c',
});
{
"object": "list",
"has_more": false,
"data": [
{
"id": "2a0c9ce0-3112-4728-976e-47ddcd16a318",
"filename": "avatar.png",
"size": 4096,
"content_type": "image/png",
"content_disposition": "inline",
"content_id": "img001",
"download_url": "https://inbound-cdn.resend.com/4ef9a417-02e9-4d39-ad75-9611e0fcc33c/attachments/2a0c9ce0-3112-4728-976e-47ddcd16a318?some-params=example&signature=sig-123",
"expires_at": "2025-10-17T14:29:41.521Z"
}
]
}
limit parameter is optional. If you do not provide a limit, all attachments will be returned in a single response.1001before parameter.after parameter.after or before parameter, not both. See our pagination guide for more information.import { Resend } from 'resend';
const resend = new Resend('re_xxxxxxxxx');
const { data, error } = await resend.emails.receiving.attachments.list({
emailId: '4ef9a417-02e9-4d39-ad75-9611e0fcc33c',
});
{
"object": "list",
"has_more": false,
"data": [
{
"id": "2a0c9ce0-3112-4728-976e-47ddcd16a318",
"filename": "avatar.png",
"size": 4096,
"content_type": "image/png",
"content_disposition": "inline",
"content_id": "img001",
"download_url": "https://inbound-cdn.resend.com/4ef9a417-02e9-4d39-ad75-9611e0fcc33c/attachments/2a0c9ce0-3112-4728-976e-47ddcd16a318?some-params=example&signature=sig-123",
"expires_at": "2025-10-17T14:29:41.521Z"
}
]
}
Was this page helpful?