Skip to content

Mandate

A Mandate is a standing authorization for an Agent to act for a Party, within Permissions and Limits, until it expires.

Properties

PropertyTypeRequiredDescription
expiresAtdatetimerequiredWhen it lapses.
limitLimitThe Limit that bounds it.
verbstringThe Verb it covers, as Noun.verb.
topicsstring[]What it may act on; an Action outside them becomes an Approval.
channelslist of ChannelThe Channels it may send through.
statusstringrequiredOne of active, paused, revoked or expired.

Object

JSON
{
  "$id": "https://api.sb/tutorloop.com/mandates/mandate_1",
  "$type": "Mandate",
  "expiresAt": "2026-10-22T12:00:00Z",
  "limit": "limit_1",
  "verb": "Example verb",
  "topics": [
    "Example topics"
  ],
  "channels": [
    "channel_1"
  ],
  "status": "active"
}

Relationships

  • A Mandate authorizes one Agent: a Mandate lets an Agent act without asking each time, within its Permissions and Limits, until it expires or is revoked. authorizes, inverse mandates.
  • A Mandate funds many Cards: a Mandate funds the Cards that spend under it; pausing it freezes them and revoking it closes them. funds, inverse fundedBy.
  • A Mandate is issued by one Party: the Party who grants a Mandate is its principal: the Agent acts for them, and each Action records them as for. issuedBy, inverse issues.

Lifecycle

Mandate lifecycle: active, paused, revoked (ends), expired (ends)active → paused: Mandate.pauseactive → revoked: Mandate.revokeactive → expired: on Mandate.expiredpaused → active: Mandate.resumepaused → revoked: Mandate.revokepaused → expired: on Mandate.expiredactivepausedrevokedexpired
StateMeaningMoves to
active (first)The Agent calls the Mandate’s Verb without asking each time, within its Limit.paused by Mandate.pause; revoked by Mandate.revoke; expired on Mandate.expired when the Mandate reaches its expiresAt
pausedNew Actions under it are refused, and its scope and Limit wait unchanged for the resume.active by Mandate.resume; revoked by Mandate.revoke; expired on Mandate.expired when the Mandate reaches its expiresAt
revokedEnded early: new Actions under it are refused, running ones finish, and its record stays.None: it ends here.
expiredIt reached its expiresAt, so new Actions under it are refused; its record stays.None: it ends here.

Verbs

  1. createCreates a Mandate.
    POST /{namespace}/mandatesdoMandate.created
  2. getReturns one Mandate by id.
    GET /{namespace}/mandates/{id}readNo Event
  3. listReturns Mandates, newest first, one page at a time.
    GET /{namespace}/mandatesreadNo Event
  4. updateChanges the given properties of a Mandate.
    PATCH /{namespace}/mandates/{id}doMandate.updated
  5. deleteDeletes a Mandate; its history is kept.
    DELETE /{namespace}/mandates/{id}doMandate.deleted
  6. authorizeAuthorize grants an Agent a standing Mandate to perform a Verb within a Limit, without asking each time.
    POST /{namespace}/mandates/authorizedoMandate.authorized
  7. pausePause stops every new Action under a Mandate at once and keeps its scope, so it can resume unchanged.
    POST /{namespace}/mandates/{mandate}/pausedoMandate.paused
  8. resumeResume restarts a paused Mandate with its scope, Limits and approval rule unchanged.
    POST /{namespace}/mandates/{mandate}/resumedoMandate.resumed
  9. revokeRevoke ends a Mandate at once, so new Actions under it are refused and running ones finish.
    POST /{namespace}/mandates/{mandate}/revokedoMandate.revoked
  10. spendSpend pays an outside party for a Startup with a single-use card, within a Mandate and its Limit.
    POST /{namespace}/mandates/{mandate}/spenddoMandate.spent

Events

Events no Verb emits. Each Verb’s Event is in the Verbs table above; every Event is delivered in the same shape.

Mandate.expired

A Mandate reached its expiresAt, so the Agent asks again before each Action it covered. Raised by a clock.

FieldTypeRequiredDescription
namestringrequiredMandate.expired.
atdatetimerequiredWhen it happened.
seqintegerIts position in the namespace, one more than the Event before; any seq is a cursor into the history.
datajsonrequiredThe Thing as the Action left it.
data.mandateMandaterequiredThe Mandate as the change left it.
data.mandate.expiresAtdatetimerequiredWhen it lapses.
data.mandate.limitLimitThe Limit that bounds it.
data.mandate.verbstringThe Verb it covers, as Noun.verb.
data.mandate.topicsstring[]What it may act on; an Action outside them becomes an Approval.
data.mandate.channelslist of ChannelThe Channels it may send through.
data.mandate.statusstringrequiredOne of active, paused, revoked or expired.
data.previous.statusstringrequiredThe status before this Event: active.
JSON
{
  "$id": "https://api.sb/tutorloop.com/events/event_1",
  "$type": "Event",
  "name": "Mandate.expired",
  "at": "2026-10-22T12:00:00Z",
  "data": {
    "mandate": {
      "$id": "https://api.sb/tutorloop.com/mandates/mandate_1",
      "$type": "Mandate",
      "expiresAt": "2026-10-22T12:00:00Z",
      "limit": "limit_1",
      "verb": "Example verb",
      "topics": [
        "Example topics"
      ],
      "channels": [
        "channel_1"
      ],
      "status": "expired"
    },
    "previous": {
      "status": "active"
    }
  },
  "seq": 1
}

Permissions

Which Access level may call each Verb. One-way Verbs wait their delay window.

Operationowneradminmemberviewer
Mandate.createYesYesNoNo
Mandate.getYesYesYesYes
Mandate.listYesYesYesYes
Mandate.updateYesYesNoNo
Mandate.deleteYesYesNoNo
Mandate.authorizeYesNoNoNo
Mandate.pauseYesYesNoNo
Mandate.resumeYesYesNoNo
Mandate.revokeYesYesNoNo
Mandate.spendYesNoNoNo

Call it

Text
Authorize the latest mandate with an agent and a limit.

Example

A dental group gives its purchasing Agent a Mandate to buy reminder bundles up to $300 a month for 12 months. A $500 bundle exceeds its limit, so the Agent asks the group first.