Skip to content

Newsletter

A Newsletter is a list of Contacts who subscribed to a Startup’s issues by email, with the Offer that gates its paid issues.

Properties

PropertyTypeRequiredDescription
namestringrequiredWhat subscribers see it called.
fromMailboxrequiredThe broadcast Mailbox each issue sends from.
topicstringThe topic a Contact subscribes to, recorded with their Consent.
subscribersintegerContacts subscribed now, counted from their Consent.
offerOfferThe Offer whose Subscription unlocks paid issues and the archive.

Object

JSON
{
  "$id": "https://api.sb/leaseline.app/newsletters/newsletter_FLjN3aQujc",
  "$type": "Newsletter",
  "name": "Leaseline notes",
  "from": "mailbox_93HvOnR17L",
  "topic": "product-updates",
  "subscribers": 1,
  "offer": "offer_2hzYe1ERo0"
}

Relationships

Verbs

  1. createCreates a Newsletter.
    POST /{namespace}/newslettersdoNewsletter.created
  2. getReturns one Newsletter by id.
    GET /{namespace}/newsletters/{id}readNo Event
  3. listReturns Newsletters, newest first, one page at a time.
    GET /{namespace}/newslettersreadNo Event
  4. updateChanges the given properties of a Newsletter.
    PATCH /{namespace}/newsletters/{id}doNewsletter.updated
  5. deleteDeletes a Newsletter: a soft delete that keeps its history, undone by `Thing.restore`.
    DELETE /{namespace}/newsletters/{id}doNewsletter.deleted
  6. importImport adds subscribers from a CSV File, keeping each one’s consent basis and the date they subscribed.
    POST /{namespace}/newsletters/{newsletter}/importdoNewsletter.imported
  7. sendSend emails one issue, a piece of Content, to every subscribed Contact, and a paid issue only to those whose Offer covers it.
    POST /{namespace}/newsletters/{newsletter}/senddoNewsletter.sent

Permissions

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

Operationowneradminmemberviewer
Newsletter.createYesYesYesNo
Newsletter.getYesYesYesYes
Newsletter.listYesYesYesYes
Newsletter.updateYesYesYesNo
Newsletter.deleteYesYesYesNo
Newsletter.importYesYesYesNo
Newsletter.sendYesNoNoNo

Call it

In code: API · SDK · CLI · MCP.

Text
Send the latest newsletter with content.

Works with

Example

Leaseline’s Newsletter on lease law sends from its broadcast Mailbox to 900 subscribers. The monthly issue goes to all of them; the weekly issue goes only to subscribers whose Subscription to the $8 Offer covers it.