Record Created or Updated

trigger.salesforce_event
TriggerCRM & salesconnection requiredruns in-engine

Polls SOQL on SystemModstamp; one run per changed record.

Start a run when a Salesforce record is created or updated (polled).

Connection

Required
Yes — the node will not save without one
Auth type
OAuth 2.0
Providers
Salesforce
Secret shape
{"client_id", "client_secret", "refresh_token"}
Config it needs
login_url, api_version
Resolved by
config.connection_id, else node.connection_id

Configuration

5 fields, none required. A dotted path is a nested object and name[] an array of objects — the editor renders the same tree.

FieldTypeRequiredDefaultConstraintsExample
object_name
The sObject to watch: Lead, Contact, Account, Opportunity, Case, Task, or any custom object (its API name, ending in __c).
stringNoLead—Lead
mode
created fires only on a record's first save; updated only on later ones; created_or_updated fires on both.
stringNocreated_or_updatedone of "created", "updated", "created_or_updated"—
fields
Comma-separated field API names to return, e.g. Id, Name, Email, Status. Relationship fields work (Account.Name). Id is always included.
stringNoId—Id, Name, Email, Status
where_clause
Optional extra SOQL filter, ANDed with the cursor, e.g. Status = 'Open' AND Country = 'IN'. A boolean expression only — ORDER BY / LIMIT / subqueries are refused.
stringNo——Status = 'Open'
poll_interval_sec
How often to check (30-86400 seconds).
numberNo6030–86400—

Example configuration

Every value below is the contract’s own example or default — nothing invented.

{
  "fields": "Id, Name, Email, Status",
  "mode": "created_or_updated",
  "object_name": "Lead",
  "poll_interval_sec": 60,
  "where_clause": "Status = 'Open'"
}

Output

One shape.

record

FieldTypeExample
object_name
The sObject polled, e.g. Lead.
stringLead
record_id
The Salesforce record id.
string00Q5f000004abcEAA
record
The fields named in `fields`, keyed by their Salesforce API names (Salesforce's `attributes` envelope is removed).
object—
created
True when this poll is seeing the record's creation (CreatedDate == LastModifiedDate), False when it is an update.
boolean—
system_modstamp
SystemModstamp as Salesforce returned it, e.g. 2026-09-09T12:00:00.000+0000.
string—
{
  "created": false,
  "object_name": "Lead",
  "record": {},
  "record_id": "00Q5f000004abcEAA",
  "system_modstamp": ""
}

Notes

  • This polls SOQL — it is not the Streaming or Pub/Sub API. Salesforce's push mechanisms need a process holding a long-lived subscription, which Mantle has no role for, so latency is up to one poll interval (30 s minimum).
  • The poll reads current state, not a change log: a field changed and changed back within one interval is seen once, at its final value.
  • SystemModstamp also moves for system writes (roll-up recalculations, archive jobs), so `updated` can fire without a person having edited the record.
  • Existing records are never replayed: the first poll only sets the cursor to the org's newest SystemModstamp.
  • Bulk updates share one millisecond; the cursor keeps the ids at its instant so none of them is dropped. Runs are idempotent per record id + modstamp, so a re-poll of the same change cannot start a second run.
  • `created` is CreatedDate == LastModifiedDate. A record created and edited between two polls arrives once, as an update.

See Record Created or Updated run in a workflow.

In a technical demo we add the Salesforce connection, drop the node on the canvas and let Workflow Health pre-flight it before the first real run.