---
title: "Create a share link for a sent email"
method: POST
path: "/v1/emails/{id}/share"
tags: ["Emails"]
---

# Create a share link for a sent email

`POST /v1/emails/{id}/share`

## Request

- Base URL: `https://smtpfa.st/api`
- URL: `https://smtpfa.st/api/v1/emails/{id}/share`
- Auth: HTTP bearer

Mint a public, expiring link to the rendered view of one sent email (the stored HTML or text body, in a sandboxed frame). Nothing is stored; the link stops working when it expires. Default lifetime 7 days, maximum 30. Requires the email:read scope.

## Path parameters

- `id` string, required

## Request body

- object
  - `expires_in` integer: Lifetime in seconds (60 to 2592000)

## Response `200`

Share link

- object
  - `object` string
  - `id` string
  - `url` string, uri
  - `expires_at` string, date-time

## Other responses

- `401`: Invalid or missing API key
- `403`: Forbidden - domain not verified or insufficient permissions
- `404`: Resource not found
- `429`: Rate limit exceeded - retry after the period indicated in the Retry-After header
- `500`: Internal server error

---

[API](https://skmtc.dev/smtpfa/apis/smtpfast-api.md) · [All operations](https://skmtc.dev/smtpfa/apis/smtpfast-api/llms.txt) · [OpenAPI document](https://skmtc.dev/smtpfa/apis/smtpfast-api/revisions/79dda742f53e?raw)
