anon_email
API referenceRecipients

Update a recipient

PATCH
/recipients/{recipient_id}

Partial update of a recipient's name, active state, encryption requirement, or PGP public key. At least one field is required.

  • Setting pgp_public_key re-derives the fingerprint and expiry.
  • name and pgp_public_key must not be empty when present.
  • Deactivating a recipient stops it receiving forwarded mail without deleting the address or detaching it from aliases.

Authorization

CognitoUserPool
headerAuthorizationBearer <token>

Cognito user pool ID token. API Gateway validates the token (identity token: no OAuth scopes are configured on the authorizer) and forwards its claims; the sub claim is the tenant key.

Path Parameters

recipient_id*string

Opaque recipient id.

Request Body

application/json
  1. body
Properties1 <= properties
name?string

New label. Must not be empty.

Length1 <= length
active?boolean

Set false to stop this recipient receiving forwarded mail.

require_encryption?boolean

Require encryption to this recipient's PGP key.

pgp_public_key?string

Armored PGP public key. Must not be empty. Replaces any existing key and re-derives the fingerprint and expiry.

Length1 <= length

Response Body

The updated recipient.

application/json
  1. response
recipient_id*string

Opaque id, stable for the life of the recipient.

email*string
Formatemail
name*string

Free-form label. Empty when never set.

active*boolean

Whether this recipient currently receives forwarded mail.

verified*boolean

Set once the confirmation link has been opened.

pgp_public_key*|

Armored PGP public key, when one is registered.

pgp_fingerprint*|

Fingerprint derived from the public key.

pgp_expires_at*|

Key expiry, unix epoch milliseconds, when the key declares one.

require_encryption*boolean

When true, mail to this recipient is encrypted to pgp_public_key (and rejected if that fails). When false, mail is forwarded as-is.

datetime_created*integer

Creation time, unix epoch milliseconds.

datetime_deleted*|

Unix epoch milliseconds, or null when the event has not occurred.

curl -X PATCH "https://example.com/recipients/string" \  -H "Content-Type: application/json" \  -d '{}'
{  "recipient_id": "string",  "email": "user@example.com",  "name": "string",  "active": true,  "verified": true,  "pgp_public_key": "string",  "pgp_fingerprint": "string",  "pgp_expires_at": 0,  "require_encryption": true,  "datetime_created": 0,  "datetime_deleted": 0}