Skip to content

The workflows/ folder: one file and what it compiles to

What one workflows/ file holds, what each key compiles to, and the checks that read it.

One workflows/ file is one sales Process, holding only what differs from the hub’s. SalesBuilder compiles it, and show traces every key.

workflows/outbound.mdx
---
process: outbound
hours: "Mon-Fri 08:00-17:00 America/Chicago"
---
Outbound sends only in Dana’s working hours.
show
$ npx startup-builder show workflows/outbound.mdx
process  outbound                               workflows/outbound.mdx:2
hours    "Mon-Fri 08:00-17:00 America/Chicago"  workflows/outbound.mdx:3
owner    SalesBuilder
leaseline.app
leaseline.app/
├── plays/
│   ├── cold-email.mdx
│   ├── warm-intros.mdx
│   ├── signup-interviews.mdx
│   ├── lead-reactivation.mdx
│   └── events-and-webinars.mdx
├── audiences/
│   ├── small-property-managers.mdx
│   ├── lapsed-leads.mdx
│   └── renewal-season.mdx
├── sequences/
│   └── cold-email-thread-founder.mdx
├── funnels/
│   └── signup.mdx
├── workflows/   ← this folder
│   └── outbound.mdx
├── agents/
│   ├── sales/prospector.mdx
│   └── marketing/content-lead.mdx
├── systems/
│   └── sequences.mdx
├── domains/
│   └── leaseline.app.mdx
├── offers/
│   ├── pro.mdx
│   └── team.mdx
├── content/
│   └── webinars/60-day-notices.mdx
├── metrics/
│   ├── q4.mdx
│   └── positive-reply-rate.mdx
└── startups.lock

The file

KeyOn the pageCompiles toChecked by
processAutomationthe hub Process it overrides, by id—
hoursSends inthe window every send of the Process waits for—

Refusals

CodeFix, then the call that clears it
availabilityOffer only free calendar slots, and fix any line that says it ships; it pauses until fixed. Then POST /{namespace}/meetings/book.
exit-never-waitsLeave the cancel standing; the Customer takes it back with one press while access lasts. Then POST /{namespace}/subscriptions/{subscription}/keep.
no-meeting-heldBook a call with the buyer and hold it, then send the proposal again. Then POST /{namespace}/meetings/book.
priceGet the discount approved, or quote at the floor. Then POST /{namespace}/approvals/{approval}/approve.
question-capHold the rest for one Meeting with their admin. Then POST /{namespace}/meetings/book.
recordingAsk each attendee on the call, then start recording. Then POST /{namespace}/meetings/book.
renewal-noticeSend the renewal notice with its amount; the renewal waits 30 days after it. Then POST /{namespace}/messages/{message}/schedule.
stage-fieldsFill each field the refusal names, then move the Deal on again. Then PATCH /{namespace}/deals/{id}.
kill-switchReview what fired, then turn the Process back on. Then POST /{namespace}/processes/{process}/enable.

Calls

workflows/ compiledMode try
You, to your agent

Turn on outbound and show me what it did.

curl -X POST "https://api.sb/leaseline.app/processes/process_1/enable?mode=try" \
  -H "Authorization: Bearer $STARTUP_BUILDER_API_KEY"

curl "https://api.sb/leaseline.app/actions?limit=20" \
  -H "Authorization: Bearer $STARTUP_BUILDER_API_KEY"
import { $ } from 'startup-builder'

await $.Process.enable({ process: 'process_1' }, { mode: 'try' })   // workflows/outbound.mdx
return await $.Action.list({ limit: 20 })   // every Action, with its status
npx startup-builder do Process.enable --json '{"process":"process_1"}' --try
npx startup-builder do Action.list --json '{"limit":20}'
{
  "name": "do",
  "arguments": {
    "code": "await $.Process.enable({ process: 'process_1' }, { mode: 'try' })   // workflows/outbound.mdx\nreturn await $.Action.list({ limit: 20 })   // every Action, with its status",
    "mode": "try"
  }
}
Response200application/json
{
  "$type": "Action",
  "actions": [
    {
      "$id": "https://api.sb/leaseline.app/actions/action_1",
      "$type": "Action",
      "status": "pending",
      "mode": "try"
    }
  ],
  "meta": {
    "limit": 20,
    "after": "cursor_2"
  }
}
samplePreview
CallWhat it does
POST /{namespace}/processes/{process}/enableEnable turns a Process on for a Startup, so its Workflows start on their Triggers. Emits Process.enabled.
POST /{namespace}/processes/{process}/pausePause stops a Process from starting new Actions; Actions already in progress finish. Emits Process.paused.
POST /{namespace}/meetings/bookBook schedules a Meeting with a Contact at a time both calendars hold free. Emits Meeting.booked.
POST /{namespace}/deals/{deal}/advanceAdvance moves a Deal to its next stage once every field that stage requires is filled. Emits Deal.advanced.
POST /{namespace}/deals/{deal}/winWin closes a Deal as won, which places its Order and makes the buyer a Customer. Emits Deal.won.
POST /{namespace}/quotes/{quote}/sendSend presents a drafted Quote to its buyer and freezes its lines, total and payment terms. Emits Quote.sent.
POST /{namespace}/renewals/openOpen starts the Renewal for a term Subscription before its term ends. Emits Renewal.opened.
POST /{namespace}/subscriptions/{subscription}/keepKeep takes back a cancel before the period closes, so the Subscription renews on its date at the same terms. Emits Subscription.kept.
Not live yetUse today
Referral.inviteGaps #3. Today: One ask as a POST /{namespace}/messages/{message}/schedule.

Compiled, not written: edit the records it reads (compile table; cap), then regenerate. Every step runs from a sentence or a line of code. In your words: the CRM words you know, and where each lives here.

Contents