Skip to Content
Pouch
Addresses

Extend or update an address

PATCH
/v1/addresses/{id}

Auth: Bearer live key scoped to the address's domain.

Moving an expired address's expiry forward makes it active again, within the organization's limit. A revoked address can't be edited.

Authorization

bearer
headerAuthorizationBearer <token>

An API key in the Authorization header.

Path Parameters

id*string

An opaque, type-prefixed id.

Request Body

application/json
  1. body
expires_at?string

When the address stops delivering, as an ISO 8601 timestamp. Give this or expires_in. An expired address comes back when its expiry moves forward.

Match^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z|([+-](?:[01]\d|2[0-3]):[0-5]\d)))$
Formatdate-time
expires_in?integer

Seconds from now until the address stops delivering, 60 to 31536000. Give this or expires_at.

Range60 <= value <= 31536000
label?|

A note for your own use. null clears it.

message_cap?|

Most messages the address delivers over its life. null removes the cap.

Response Body

The updated address.

application/json
  1. response
id?string

Opaque id, prefixed adr_.

address?string

The full address: <local_part>@<the domain's inbound host>.

domain_id?string

The domain it lives on.

local_part?string

The part before the @, lowercased.

label?|

Your note, or null.

status?string

active delivers. expired and revoked drop mail silently and count it. Only revoked is final.

Value in"active""expired""revoked"
expires_at?string

ISO 8601 timestamp the address stops delivering.

message_cap?|

Most messages it delivers over its life, or null for no cap.

key_id?|

The key that created it. That key's endpoints subscribed to address.received hear its mail.

counts?

Messages delivered, over its life and on the current UTC day, and messages dropped after expiry or revocation, past the cap or the daily limit, or for failing a virus scan. forwarded counts copies sent on to forward targets.

last_received_at?|

ISO 8601 timestamp of the last delivered message, or null.

revoked_at?|

ISO 8601 timestamp, or null.

created_at?string

ISO 8601 timestamp.

updated_at?string

ISO 8601 timestamp.

Example Request
curl -X PATCH 'https://pouch.example.com/v1/addresses/string' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "id": "string",  "address": "string",  "domain_id": "string",  "local_part": "string",  "label": "string",  "status": "active",  "expires_at": "string",  "message_cap": 0,  "key_id": "string",  "counts": {    "received": 0,    "received_today": 0,    "dropped_expired": 0,    "dropped_over_limit": 0,    "dropped_virus": 0,    "forwarded": 0  },  "last_received_at": "string",  "revoked_at": "string",  "created_at": "string",  "updated_at": "string"}