curl -X POST 'https://api.resend.com/emails/49a3999c-0ce1-4ea6-ab68-afcd6dc2e794/share' \
-H 'Authorization: Bearer re_xxxxxxxxx' \
-H 'Content-Type: application/json' \
-d $'{
"expires_in": "2 hours"
}'
{
"object": "email",
"id": "49a3999c-0ce1-4ea6-ab68-afcd6dc2e794",
"url": "https://resend.com/shared?token=eyJhbGciOiJIUzI1NiJ9..."
}
Share Email
Create a shareable link to view a sent or received email.
POST
/
emails
/
:email_id
/
share
curl -X POST 'https://api.resend.com/emails/49a3999c-0ce1-4ea6-ab68-afcd6dc2e794/share' \
-H 'Authorization: Bearer re_xxxxxxxxx' \
-H 'Content-Type: application/json' \
-d $'{
"expires_in": "2 hours"
}'
{
"object": "email",
"id": "49a3999c-0ce1-4ea6-ab68-afcd6dc2e794",
"url": "https://resend.com/shared?token=eyJhbGciOiJIUzI1NiJ9..."
}
Path Parameters
Body Parameters
curl -X POST 'https://api.resend.com/emails/49a3999c-0ce1-4ea6-ab68-afcd6dc2e794/share' \
-H 'Authorization: Bearer re_xxxxxxxxx' \
-H 'Content-Type: application/json' \
-d $'{
"expires_in": "2 hours"
}'
{
"object": "email",
"id": "49a3999c-0ce1-4ea6-ab68-afcd6dc2e794",
"url": "https://resend.com/shared?token=eyJhbGciOiJIUzI1NiJ9..."
}
Was this page helpful?
⌘I