Business Function Properties
This section explains all core properties used to configure a business process. These settings define how, when, and under what conditions a process runs.
1. Type
Type function defines the nature of the process which can be either Business or UI.
Business processes run on the server and have access to the database, email, external APIs, and the rest of the Business Functions Reference. UI processes run in the browser and act on the interface.
2. Active
Master switch for the whole process.
- On — the process runs when its event fires.
- Off — the process is ignored entirely, whatever else is configured.
Turn a process off rather than deleting it while you are investigating a problem.
3. Trigger
Used when the process should react to data changes.
This turns the process into an event-driven automation.
Typical use cases:
- Status Changes – The process fires automatically whenever a record's status field changes to a specific value. For example, when a ticket's status changes from "In Progress" to "Resolved", a trigger can automatically send a notification email to the client, or when an order is marked as "Shipped", it can update the delivery tracking record accordingly.
- Record Creation – The process fires whenever a new record is created in a specific entity. For example, when a new user registers, a trigger can automatically create a default profile record for them, send a welcome email, or assign them to a default user group - all without any manual intervention.
- Field Updates – The process fires whenever a specific field's value is changed on an existing record. For example, when the "Assigned To" field on a task is updated, a trigger can notify the newly assigned team member, or when a contract's expiry date is changed, it can automatically reschedule a reminder notification.
3.a) Event
Event defines what kind of change activates the process.
| Event | Fires | Can cancel the operation |
|---|---|---|
| Before Create | Before a new record is written | Yes |
| After Create | Once the record has been written | No |
| Before Update | Before changes are written | Yes |
| After Update | Once changes have been written | No |
| Before Delete | Before the record is removed | Yes |
| After Delete | Once the record has been removed | No |
| Before Fetch | Before records are read | Yes |
| After Fetch | Once records have been read | No |
| Scheduled | On a cron schedule — see CRON Job below | — |
| Webhook | When the process's route is called | — |
| Agent Skill | When an agent invokes the process as a tool | — |
Choose a Before event to validate or adjust data. Throwing an error there cancels the operation and shows your message to the user, and assigning to context.record changes what gets saved. Choose an After event for side effects — notifications, related records, external syncs — where the data is already committed and throwing will not undo it.
A process with no event set never fires by itself. It runs only when started manually or through a route. This is deliberate: a mis-configured process that defaulted to a data event would run on every single read.
3.b) Entity
Entity specifies which entity the trigger listens to. The process will run only when changes occur on this entity.
Several processes may listen to the same entity and event. They run one after another in a stable order and share the same context, so a change one Before process makes to context.record is visible to the next.
3.c) Custom Timeout
Custom Timeout overrides the default execution timeout, which is 30 seconds. The value is in seconds.
Use this when:
- The process runs long operations
- External APIs are involved
- Large datasets are processed
When the timeout is reached the run is aborted part-way through. Anything already written stays written — there is no rollback — so a long process can leave work half-done.
Be practical. Increasing timeout hides performance issues if abused. Before raising it, check whether the process is looping over records one at a time: bulk functions usually turn a timeout into a non-issue.
4. CRON Job
Runs automatically based on time rules. Use this section only if the process is time-based, and set the Event to Scheduled.
CRON jobs are ideal for:
- Nightly Syncs – Automatically synchronize data between systems at a set time during the night, when traffic is low and performance impact is minimal. For example, syncing customer records from an external CRM into your platform every night at 2:00 AM, ensuring data is always up to date by the start of the business day.
- Scheduled Reports – Automatically generate and distribute reports at defined intervals without any manual trigger. For example, sending a weekly sales summary every Monday morning at 7:00 AM to all managers, or generating a monthly invoice report on the 1st of each month.
- Cleanup Tasks – Automatically remove outdated, redundant, or temporary data to keep the system clean and performant. For example, deleting all records with a "Draft" status that haven't been updated in over 30 days, or clearing temporary log files every Sunday night.
- Periodic Recalculations – Automatically recalculate field values or aggregated data on a schedule, especially useful when real-time calculation would be too resource-intensive. For example, recalculating each client's total spending based on their order history every night, so the value is ready to display instantly without querying large datasets on demand.
4.a) Schedule
The schedule is a standard cron expression, evaluated in UTC.
| Expression | Runs |
|---|---|
0 2 * * * | Every day at 02:00 |
0 7 * * 1 | Every Monday at 07:00 |
0 0 1 * * | The first day of every month at midnight |
*/15 * * * * | Every 15 minutes |
0 3 * * 0 | Every Sunday at 03:00 |
An invalid expression means the process is never scheduled, so check it after saving.
There is no signed-in user behind a scheduled run. context.claims comes back as { system: true, manualExecution: true } rather than with a userId, and context.record is empty. Guard any code that reads user details.
5. Route
Exposes the process at a URL so an external system can call it. Set the Event to Webhook.
The request body arrives as context.req.body, with context.req.route and context.req.headers alongside it.
const payload = context.req.body;
if (!context.req.headers["x-signature"]) throw new Error("Missing signature");
await context.functions.create("webhookevents", { Payload: JSON.stringify(payload) });A route-triggered process can be called without authentication, and context.claims carries { system: true, routeExecution: true } rather than a user. Validate a shared secret or signature yourself — keep it in context.env rather than in the process code.
6. Library
A collection of reusable code blocks with built in logic designed for specific tasks. Helps to visually separate complex logic so it is easier to follow and understand.
Nodes execute in sequence, each following its first outgoing connection. Branching is not supported, so use if statements inside a Code block rather than drawing two paths from one node.