Reference
Nurture
132 published documents
-
Approve AI draft
Approve a proposed draft as the calling person (recorded in decidedBy). Refused when a finding is an error, when flags exist without acknowledgeFlags true, or (with requireSecondApprover) when the caller requested it. Copy for a template becomes a NEW non-current version (make it current by saving it with app_topolo_nurture.templates.update); other copy becomes a new template; subject_lines applies candidate subjectIndex; a journey becomes a DRAFT journey with new templates. Nothing is published or sent.
-
Approve broadcast
Approve a broadcast awaiting approval. The approver must be a different verified user from the submitter (both ids come from the caller's credential); the same user is refused with approval_requires_second_person. Approval does not send anything; schedule it next.
-
Archive broadcast
Archive a broadcast that is a draft or has finished (sent, cancelled or failed) so it leaves the working list. Its recipients and history are kept. A broadcast awaiting approval, approved, scheduled or sending must be cancelled first.
-
Archive contact
Archive a contact so segments stop matching it and imports no longer update it. The record is kept; use erase for a right-to-erasure request.
-
Archive email template
Archive an email template so it can no longer be edited or chosen for new email. Its versions are kept for history.
-
Archive journey
Archive a journey: it stops enrolling contacts, every active enrollment exits with reason journey_archived, and the draft can no longer change. Versions, enrollment history and intended sends are kept.
-
Archive segment
Archive a segment so it can no longer be used for new work. Its history is kept.
-
Archive signup form
Archive a signup form so it can no longer be used for new work. Its history is kept.
-
Archive subscription topic
Archive a subscription topic so it can no longer be used for new work. Its history is kept.
-
Cancel broadcast
Cancel a broadcast that is awaiting approval, approved, scheduled or sending. Every recipient not yet processed is marked cancelled and never sent; recipients already processed keep their outcome (their consumed reservations still count toward caps). Cancelling is final.
-
Check send eligibility
Decide, without reserving anything, whether a message may be sent now to up to 100 contacts. Rules come from @topolo-io/audience over Nurture's own data: suppression blocks (hard bounce, complaint, wrong person, erased address, manual block, unsubscribes), topic subscription state when purpose is marketing with a topicKey, and the workspace pacing policy (rolling 24h and 7d caps counting reserved and consumed sends, quiet hours in the recipient's timezone). Transactional messages need messageCategory and skip subscription, caps and quiet hours but still honour hard_bounce, wrong_person, erased and manual_block. A missing or archived contact is ineligible with no_contact_point. nextEligibleAt is present only when every reason clears with time.
-
Choose sender profile
Choose the Nexus email profile (an id from app_topolo_nexus.email.profiles.list) that this workspace sends as, or null to stop sending through Nexus (sends are then recorded only). A new profile starts unverified and nothing is emailed until sending_settings.verify passes.
-
Connect a Notify event source
Subscribe this workspace to one TopoloNotify event type from one app, so each matching platform event is recorded as a Nurture lifecycle event. For Nexus delivery events connect each nexus.email.* type from app_topolo_nexus: only events for Nurture's own sends (app_id and entity_ref_id) in this workspace are applied, and with all seven connected delivery polling stops. Creates a Notify webhook subscription as the caller and sets its signing secret to one Nurture derives; no secret is stored.
-
Connect a provider
Connect one provider to this workspace with the chosen capabilities and its non-secret config (topolo_crm: crmWorkspaceId; topolo_engage: engageWorkspaceId, plus optional campaignId and seatId, checked in Engage). Calls act as the caller's credential; no secret is stored. One connector per provider per workspace; reconnecting a disconnected one reactivates it with the new settings. Capabilities: contact_source (connectors.sync copies remote contacts into Nurture, source connector, source_ref crm:<id>); suppression_sync (connectors.sync pushes unsubscribed, hard_bounce, complaint and manual_block events for those contacts to TopoloCRM, and eligibility.reserve also reserves in TopoloCRM, stricter wins); interaction_writeback (records sends on the CRM timeline; nothing writes yet); lead_handoff (TopoloCRM: a task per newly qualified CRM-linked lead; TopoloEngage: enrol each newly qualified lead into the chosen campaign from the chosen seat, creating the Engage contact when missing).
-
Create broadcast
Create a draft broadcast: a template (optionally a pinned templateVersion), a subscription topic, one to 20 segments, a schedule and an optional throttlePerHour. Purpose is always marketing. Nothing is sent; the draft must be submitted, approved by a different person, and scheduled. schedule is {mode:"now"} (default), {mode:"at", sendAt ISO-8601} or {mode:"recipient_local", date YYYY-MM-DD, time HH:MM, fallbackTimezone IANA}: recipient_local sends at that wall-clock time in each contact's own zone, using fallbackTimezone when the contact has none.
-
Create contact
Add one contact to the workspace audience with source manual. The email is stored as entered (trimmed) and must be unique per workspace, case-insensitively; attributes is a flat map of up to 50 string, number or boolean values that segment rules can match by key.
-
Create email template
Create an email template (version 1) in the caller's Nurture workspace. Nothing is sent. blocks is an ordered list of typed blocks: heading {text, level 1-3}, text {text with **bold**, _italic_ and [label](https://…) only}, image {src https, alt, width?, href?}, button {label, href https or mailto}, divider, spacer {height}, columns {2-3 columns of the other leaf blocks}, and exactly one footer {text?} as the LAST block, which always renders the unsubscribe and preference links plus the brand footer and postal address. Raw HTML is never accepted; every value is escaped. Merge tags {{contact.firstName|fallback}}, {{contact.lastName}} and {{contact.email}} are allowed in the subject, preheader and text.
-
Create experiment
Set up an A/B test. kind broadcast: on a DRAFT broadcast, 2-5 arms { key, weight, templateVersion?, subject? } (an arm without overrides sends the broadcast as-is), optional holdoutPercent (0-50, receives nothing) and testPercent (1-99: only that share is tested at launch; the winner goes to the rest on promote). kind journey: journeyId and the nodeId of a split node in the draft; arms and holdout come from the node. Each contact's arm is hash(experiment id, contact id), recorded once. controlArm defaults to the first arm. Conversion, within goal.windowHours after exposure (send, split or withheld holdout): goal.kind event (default) = the lifecycle eventType (e.g. purchase); click = a tracked-link click on the experiment's own sends, only URLs starting with urlPrefix if set.
-
Create journey draft
Create a journey as an unpublished draft. definition = { trigger { eventTypes[], segmentIds[] }, entryNodeId, nodes[], allowReentry? }. Nodes: delay { delay { mode duration, minutes } | { mode time_of_day, time HH:MM, fallbackTimezone }, next }, branch { condition contact_field | event (withinDays) | segment (member/not_member), yes, no }, send { templateRef, purpose, topicKey (required unless transactional), messageCategory (transactional), next }, split { arms [{ key, weight 0-100, next }] (2-5), holdoutPercent 0-50 } (A/B test: hash of experiment and contact picks the arm; holdout exits), goal { eventType } (journey-wide: a goal event exits the contact as converted), exit. The draft is saved even when the graph is incomplete; problems[] lists what publish would reject. Nothing is enrolled or sent.
-
Create journey from blueprint
Create a DRAFT journey from a blueprint. Pass requestKey (a retry with the same key returns the same draft and templates, replayed true), topicKey (an active subscription topic), optional name, purpose (marketing or outreach), segmentId (required for win_back, where entering it enrolls; otherwise an audience filter), delays {delayStepId: minutes} and templateIds {sendStepId: templateId}. Send steps without a template id need createStarterTemplates true: each gets a new template holding only bracketed placeholders ([Subject], [Heading], [Write your message here]) for a person to replace. Nothing is published, enrolled or sent; publish with app_topolo_nurture.journeys.publish after editing.
-
Create segment
Create a segment in the caller's Nurture workspace. Rules match all or any of up to 20 conditions on contact fields or event recency.
-
Create signup form
Create a signup form in the caller's Nurture workspace. The topic must be active. collectName (default false) adds optional first and last name fields. The page answers every valid submission identically, has a honeypot field and starts at most one confirmation per contact and topic every 10 minutes.
-
Create subscription topic
Create a subscription topic in the caller's Nurture workspace. The key is unique per workspace and doubleOptIn defaults to true.
-
Disconnect a connector
Stop using a connector: it no longer syncs or delegates eligibility. Contacts it synced stay in Nurture with their source, and nothing in the remote system changes. Repeating it is harmless.
-
Disconnect an event source
Delete the source's TopoloNotify webhook subscription (app_topolo_notify.webhooks.subscriptions.delete) as the caller and mark the source disconnected. Events already recorded are kept. Repeating it on a disconnected source is harmless.
-
Draft with AI
Propose email copy (template_copy), subject lines (subject_lines) or a journey (journey) for a person to review, written by the Nexus completions gateway from goal and audience in the workspace's TopoloBrand voice. Only approved Brand claims may be stated; banned terms block the draft. templateId rewrites that template's copy; journey needs topicKey and may follow blueprintId (with segmentId). The draft is stored as proposed with guardrail findings and provenance; nothing is applied or published until app_topolo_nurture.drafts.approve.
-
Duplicate email template
Copy a template's current version into a new active template (version 1). Works on archived templates too. The name defaults to "<name> (copy)".
-
Enroll contact in journey
Put one active contact on a published journey's live version, due immediately: the scheduler (every 5 minutes) then advances it, and each send node takes an eligibility reservation, so suppression, subscriptions, caps and quiet hours apply. Idempotent: a contact already active on the journey returns that enrollment with created false. Refused when the journey is not published, or the contact already went through it and the version has allowReentry off.
-
Erase contact permanently
Right to erasure: permanently delete one contact, remove all of its segment membership history, journey enrollments (with their steps and intended sends), lead score, score history and lead handoff records, subscription history, confirmation tokens, send reservations and contact-scoped suppression events, and detach it from every lifecycle event (the events remain without a contact). Org-wide address suppressions (hard_bounce, deliverable, complaint, wrong_person) are deliberately KEPT, keyed only by the salted address hash, so an erased address that bounced or complained can never be mailed again, and an address-scoped erased suppression event is recorded so the erased address stays suppressed org-wide for every purpose, even if it is imported again (nothing lifts it). Requires confirm: true. Event properties sent by callers are not rewritten.
-
Exit journey enrollment
End one active enrollment now with status exited and the given reason; it takes no further steps. Already-ended enrollments are refused.
-
Export contacts
Export the workspace's contacts as JSON for data portability, optionally filtered by status, ordered by email. Returns at most 5000 contacts; truncated is true when more exist, in which case page through contacts.list instead.
-
Get AI draft
Read one AI draft: its inputs, generated output, guardrail findings (error blocks approval; flag needs acknowledgement), approvable, provenance (Nexus route and model, Brand kit and voice version, claims version, prompt inputs hash, acting user) and, once approved, what was created.
-
Get AI drafting settings
Read the workspace's AI drafting approval policy: requireSecondApprover means the person who requested a draft cannot approve it.
-
Get attribution settings
Read how Nurture credits conversions: goalEventTypes (lifecycle event types that count as a conversion, default ["purchase"]), windowDays (default 7) and basis (send: the window opens at each send; click: only clicked sends compete). The model is always last_touch.
-
Get broadcast
Read one broadcast with its template pin, audience, schedule, throttle, approval trail (who submitted, approved, rejected, scheduled or cancelled it, and when) and its 20 most recent test sends.
-
Get broadcast progress
Read delivery progress: the broadcast status, total recipients, counts per recipient status, processed (sent_intended + skipped + failed), progress 0-1, and how many recipients were skipped for each reason.
-
Get broadcast report
Report one broadcast's recipient sends: headline conversions and revenue, clicks, delivery engagement and opens with a privacy caveat. Delivery progress (pending/skipped recipients) is broadcasts.stats. Covers messages sent in the last days (default 30, max 365). Conversions are goal lifecycle events (attribution_settings, default purchase) credited last-touch: the latest send (or click, basis click) to that contact within windowDays before the event gets it and its revenue (properties amountMinor + currency, summed per currency). Engagement is unique per send. Opens only count with open tracking on and are approximate (opens.caveat); judge on conversions and revenue.
-
Get contact
Read one Nurture contact by id, including its attributes and source.
-
Get contact lead score
Read one contact's current lead score (fit, behaviour, total, qualified, per-rule reasons, model version, when it first qualified) with the current MQL threshold and its lead handoffs. score is null until the contact has been scored against a published model.
-
Get email template
Read one email template with its subject, preheader and blocks. Without version it returns the current version; with version it returns that immutable historical version.