Rename, activate or pause

PATCH /api/v1/sequences/{sequenceId} Renames the sequence, activates it or pauses it. Send one field, or both.
ConditionAnswer
body carries neither field400 — nothing to change
status is anything else400active and paused are the only two
active with no published version400 — publish first, an "active" sequence with nothing published would enrol nobody
Pausing stops sends: contacts stay where they are, and their deadlines are never recomputed. Activating again replays them at the date they were already due.

Authorization

Role in the organizationThis endpoint
OWNERAllowed
ADMINAllowed
MEMBERRefused — 403
A key carries the role its creator holds in this organization — never a role on AgentsMail itself. See API keys.

Request body

FieldTypeRequiredDescription
namestringno1 to 100 characters
statusstringnoactive or paused

Example

bash
curl -X PATCH -H "x-api-key: $AGENTMAIL_API_KEY" -H "content-type: application/json" \
  -d '{"status":"active"}' \
  "https://www.agentsmail.io/api/v1/sequences/$SEQUENCE_ID"

Response

  • 200 OK — the call succeeded.
  • 401 Unauthorized — missing or invalid key, or its owner left the organization.
  • 403 Forbidden — the key's owner is a member of the organization, not an admin.
  • 404 Not Found — no such resource, or it belongs to another organization. The API never confirms that an id exists to a caller who has no right to it.
  • 429 Too Many Requests — over 120 requests in a minute for this key.

Response fields

FieldTypeDescription
successbooleanIndicates if the operation was successful
data.idstringUnique identifier for the sequence
data.namestringIts name
data.statusstringactive or paused
data.publishedVersionIdstringnull
data.createdAtstringISO creation date
data.updatedAtstringISO date of the last change

Example response

json
{
  "success": true,
  "data": {
    "id": "4d19c0a2",
    "name": "Newsletter",
    "status": "subscribed",
    "publishedVersionId": "c41a7e55",
    "createdAt": "2026-08-23T10:22:05.000Z",
    "updatedAt": "2026-08-23T10:22:05.000Z"
  }
}