Working With Your Records in Workflows
Our Commitment
MountDev Ops is built security first. Your business data belongs to you, and you can export all of it at any time. We never use analytics or tracking of any kind inside MountDev Ops.
What the Record Steps Are
A workflow can look up a record, find records, add a record, change a record, and work through every record that matches, running your own connection actions for each one. These are five steps, and they work with any module in any of your apps, including the modules you made yourself: Get a Record (action core.record_get), Find Records (core.record_find), Create a Record (core.record_create), Update a Record (core.record_update), and For Each Record (core.record_for_each). They appear in the list of actions your assistant sees, and saving a workflow checks their inputs like any other step.
Who a Record Step Runs As
A record step runs as the person who turned the workflow on, with that person's access at the time of the step, not the access they had when they turned it on. It uses the same checks the screens use: that person's role, which fields are hidden or read only for them, the records they may see, and Client Protection. If a person could not open or change a record on a screen, the workflow cannot either.
- If that person is turned off or removed, the step stops and says so: "The person who turned this workflow on no longer has access." Nothing runs as anyone else. Turn the workflow on again to choose who it runs as.
- A workflow that was never turned on has nobody to run as. A record step in it stops and says "Turn this workflow on." Press Run only on a workflow that is on.
- Turning a workflow off clears who it ran as. Turning it on again records the person who turned it on.
- A workflow turned on before record steps existed has no person recorded, and turns on again to choose one. This matters only for workflows with record steps.
Marked as a Workflow
Every record a step changes shows "via workflow" in its history, next to the person it ran as. The Activity Log also has one line for each step that names the workflow, the run, and the step, such as Workflow "Tidy Up" run 42 step each: worked 4 records of custom.vendors. A change a workflow makes never starts another workflow, an automation, or a rule, so a workflow can never start itself.
Passwords Are Never Touched
A login field (a saved web address, user name, and password) can never be set by a step. A step that tries stops with "A workflow cannot set a login field." A password typed into a step is not saved at all. A record that is read by a step comes back the way it shows on screen, with a login shown without its password.
Get a Record
Pick the kind of record and its number. The step hands the record's values on to the steps after it (for example, a later step can use the email the record holds). A hidden field is left out. The run keeps only the record's number, its version, and yes or no for found. The values themselves are kept with the run in your own account and shown to no one else.
Find Records
Pick the kind of record and, if you like, up to 5 checks that all have to match: is, is not, is more than, is at least, is less than, is at most, contains, starts with, is there, and is not there. Capital letters and extra spaces do not matter, and 1,250 is the same as 1250 for numbers. You cannot check a field you cannot see, or a login.
Records come oldest first. The step keeps these settings:
- Records per page is how many matching records the step hands on. It starts at 200 and cannot be more than 200.
- Records per run is how many records one run of the step looks at, matching or not. It starts at 1,000 and cannot be more than 1,000.
- Offset is the place in the list to start. Find Records tells you where it stopped (
next_offset) and whether it reached the end (done), so a long list can be worked a piece at a time.
A person limited by Client Protection finds only what the screens would list for them.
Create a Record and Update a Record
Pick the kind of record and the values to save, as field names and values. Values can come from earlier steps like in any other step. Update a Record also takes a record number and, if you give a version, refuses a record that changed since you read it. The same checks as a screen apply: required fields, the right kind of value, read only fields, and conflicts with other clients. Each step hands on the record's number.
For Each Record
For Each Record does something for every record that matches, however many there are, and takes as many steps for each record as you need. There is no limit on records and no limit on steps. It works a few records at a time across as many turns as it takes, in strict order (the lowest record number first), and remembers where it is, so a crash or a deploy never repeats a record or a step.
- Checks are the same as Find Records.
- Steps for each record are any of these: Get a Record, Create a Record, Update a Record, Tell People Something Is Waiting, one of your own turned on connection actions, and If This, Do That (a branch). Inside them,
{record.id}is the current record's number and{record.<field key>}is its value. A connection action's kept values go on to the later steps of the same record as{step.<name>.<value>}, when you give the step a name. A step that has no record number of its own uses the current record. - A branch checks the record (
record.<field key>) or a value an earlier step kept for it (steps.<name>.<value>), with the same checks as any branch (up to 5 combined, all or any). Its two sets hold the same steps and one more branch. The other set can be empty. - Place name is the name for where this step stopped. With a name, each run freezes only the records numbered above the highest one the last run froze under that name, so each record is handled once. Without a name, every run works every matching record. A place saved before this change (a position in the list) is read once as a record number, then replaced.
- What it cannot hold: a wait, Wait Until, Ask a Client, an AI step, a repeat, or another For Each Record. A run waits in one place at a time. A connection action that waits for a job is fine: the loop holds that record's place until the job is done (the wait costs nothing and uses no retries), then goes on to the next record. This makes the loop one record after another, so its time is the time of all its records.
How a Run of the Loop Goes
- It freezes the batch. It reads the matching records, the same way and as the same person as every record step, and writes one row for each into your own account, lowest number first. The batch is exactly what matched. A record made or changed by the loop afterward is not in it, so a loop that creates matching records can never feed itself. A record deleted after this is passed over and counted as skipped.
- It asks once, if it must. If any step is a connection action that still has a flag, the run stops once, before any record is worked, with one card for the whole batch. See Flagged Actions below.
- It works the batch, record by record. Each record keeps how many of its steps are finished, which side of each branch it took, and the values its steps kept. A try after a crash starts at the first unfinished step of the first unfinished record. Every connection action call carries its own key (run, step, record, and the step's place), so the service is never asked twice either.
A connection action that ends for a record can start a workflow that listens for it, once for each record (Starting a Workflow When an Action Finishes). A workflow cannot listen for an action its own loop runs.
When it finishes, it hands on how many it worked (processed), how many failed (failed), how many were skipped (skipped), and how many it froze (count).
How Many at a Time
A turn has to stay short, so each turn works a few records and the run goes back in your queue, behind whatever arrived before it. Two numbers, in Workflows Settings, say how big a turn is (actions workflows.each_settings and workflows.each_settings_save, people only):
- Records Frozen Per Turn starts at 500.
- Records Worked Per Turn starts at 25.
A turn also ends when it has used its time. These numbers decide how many turns a loop takes, never how many records it works. Any whole number from 1 is accepted.
Flagged Actions
A connection action with no flag, or one whose flag an owner lowered with a reason, runs for every matching record once the workflow is on, with no question. An action that still has a flag stops once for the whole batch, with one card that lists every record and the action, never one card for each record.
- The card is made after the batch is frozen and before any record is worked, so nothing runs for any record until a person answers. It names the step, the action, what it does (spends money, deletes data, or emails a client), and how many records. See the record numbers, a page at a time, with action
workflows.each_card. Numbers only, never a value. - If the flagged action sits inside a branch, the card says "up to N records", and each record's own check decides.
- Confirm runs it for the batch with no second card. Decline stops the run and nothing after that step happens. Money waits for an owner; every other card is for an owner, an admin, or a role that may confirm cards.
- A new run freezes a new batch and makes a new card. Changing the workflow or the action turns off what was agreed.
When a Record Fails
A record whose step used its last try is a failed record. It is logged on its own with the step and a plain reason (no key, no address, and nothing from a record), and the loop goes on to the next record. One record failing never stops the others, and there is no count after which the loop gives up.
- The run is not failed because of a failed record. The run finishes after the last record. A failure that is not about one record (the list cannot be read, the person who turned the workflow on no longer has access, a card was declined) fails the run as always.
- Each failed record is told, to the people its step's notice group names, once for each failed record and with no summary (see the Reliable Workflow Run Queue). Until that part is built, the failed records are listed on the run.
- See them: Run History lists each failed record with its number, the step, and the reason (action
workflows.each_failed). - Run Again for Failed Records (action
workflows.each_retry, people only) puts every failed record, or one chosen record, back at its first unfinished step. Steps that finished are not done again. It works while no step after the loop has run; after that, start a new run. - A step's own tries and waits are as for any connection action: a service saying "too many requests" waits the time it asked for, then tries again, holding that record's place.
Private Inputs
A Private input of a connection action in a loop must come from the current record ({record.<field key>}), an earlier step of the loop, or an earlier step of the workflow. It can never be typed in (a workflow with a typed one is not saved). It is never shown in a test, a card, an error, the Activity Log, a failed record's reason, or an email. A login field can never be its source.
The place is each record's own row, so records deleted between runs never make another record skip.
Your Own Fields on a Website
A website's own fields, the ones you add in CRM's Settings, work in these steps like any field (Your Own Fields on a Website). Get a Record and Find Records return them, a Find Records filter and a Branch can check them, and a connection action takes one as an input with {record.<field>}. To save a value an action returned, such as a new site's ID, add an Update a Record step on Websites with the field and the kept value. There is no separate step for it. The run log keeps only counts and ids, never the text. A kept value named like a key, such as site_key, is refused, so keep it under a plain name like site_id.
Test Runs
A test run checks the step's inputs and says what it would do. Create a Record, Update a Record, and For Each Record change nothing in a test, and a loop in a test freezes nothing, sends nothing, and calls no connection action. Get a Record and Find Records read nothing in a test either, and show an empty answer, so a test never opens a record.
Limits and What They Count
For Each Record has no limit on records, on steps for each record, or on how many records fail. What changed: the old limit of 200 records a run, 1,000 records looked at, 5 steps for each record, a batch size of 1 to 20, and the stop after 5 failed records are gone. A saved workflow that still has a limit, run limit, batch size, or offset keeps opening and saving; those values are ignored and every matching record is worked.
What counts in Usage: every try of a connection action for every record, and each Create a Record and Update a Record. A branch, a check, getting a record, and the freezing are free. The For Each Record step itself counts 1. There is no cap on usage and no alert. Before you turn a workflow on, its page shows what each loop will do: about how many records match now, and how many counted steps each uses (action workflows.will_use), counts only.
Find Records still has its own limits: Records per page (up to 200) and Records per run (up to 1,000), described above.
What Is Kept
A run keeps record numbers, counts, and yes or no. It does not keep field text in its log. Get a Record and Find Records hand values on to later steps, and these are kept with the run in your account and are part of Export Everything. No one outside your account can see them.
Who Can Do What
Anyone who may manage workflows can build a workflow with record steps. What the steps can do depends on the person who turns the workflow on: they cannot do anything that person could not do on a screen. Your AI assistant can save a workflow with record steps, and only a person turns it on.
Where to Find It
Workflows, then Workflows, then Add a Step. The record steps are in the same list. Owners, admins, and anyone whose role or permission group allows it see it.
!The Add a Step pop up set to create a record.
!The Add a Step pop up set to create a record, in dark mode.
!The Add a Step pop up set to create a record, on a phone.
!The Add a Step pop up set to create a record, on a phone in dark mode.