Introduction to Procedures

In Sugar Integrate, you can build procedure templates, reusable workflow templates that are independent of API providers. Procedure templates include triggers, such as events or schedules, that kick off a series of steps. Procedures support a large variety of different use cases across different services. For example, they can keep systems in sync, migrate data between systems, or automate business workflows.

After you build procedure templates, you can use the templates to create procedure instances. In procedure instances, you replace the variables in the templates with actual adapters and values.

Procedures are a great way to move the logic out of your apps and into Sugar Integrate. This helps keep your code less complex and more maintainable so you can focus on meeting your customers' needs.


We give detailed examples of procedures in the Examples article, but to help you understand the power of procedures, here's a common example.

A common use case is keeping contacts synced across many systems. You might need to make sure that whenever a contact is added to Salesforce, it also syncs to HubSpot. To do this, you must first transform the data. Then, create a procedure template that listens for updates to contacts in one API provider, and then pushes those contacts to another. After you set up the template, create a procedure instance where you plug in Salesforce as the source adapter and HubSpot as the target adapter.


To help you understand procedures, review the definitions in this section.

procedure template
A reusable workflow that is independent of the adapter and includes the triggers, steps, and variables for a procedure instance to execute the workflow.
procedure instance
A specific instance of a procedure template configured with explicit variables and associated with specific adapter instances.
An action that occurs and kicks off a procedure. Triggers can be events set up on an adapter instance, an API call to an adapter instance, a scheduled occurrence, or manually triggered.
An individual step within a procedure workflow that can include branches to subsequent success and failure steps.
Variables that represent either adapter instances or specific values that must be supplied for each procedure instance.

Working with Procedures

Procedure Execution Timeouts

The longer a procedure execution runs, the more likely it is to experience performance issues. Accordingly, as a best practice, test to ensure your procedure executions are not running any longer than 15 minutes. 

In addition to performance-related best practice, procedures generally have a 15-minute execution timeout, meaning that if an execution of a procedure runs for fifteen minutes, the execution will stop, even if the entire procedure isn't complete. While true as a general rule, test your procedures in the staging environment to make sure they don't incur overage charges after moving them to your production environment.

If a procedure execution extends beyond fifteen minutes, Sugar Integrate will automatically look at the context and metadata of the instance, and in some cases, start a new execution in order to continue and—ideally—complete the procedure execution.

For optimal performance, the maximum time a complete procedure execution should run is 100 minutes; however, the maximum possible time for a procedure execution to run is 150 minutes.

Restarting Procedures Mid-subprocedure

If a procedure execution stops or times out during an in-progress sub{snippet.termformulalcsingular}} step, the parent procedure will restart from the beginning of the subprocedure, regardless of how much of the subprocedure was completed.

Procedure Step Timeouts

For consistent performance, a single procedure step should not last longer than 5 minutes; this is In addition to the above-mentioned 15-minute timeouts.

Procedure Engine Versions

We support two versions of the procedure engine: V1 and V3. All procedures created prior to 2018 were created with the V1 engine. The V3 engine utilizes many architectural and technological improvements to offer efficiency and performance gains. The V3 engine is the default engine for all new that are created via the UI.

While you can access the functionality to upgrade a procedure through the Procedure Edit page, we encourage you to contact Sugar Integrate before doing so. 

Note that there is some functionality that is supported by V1 but not V3. Single-threaded procedures and PaaF are not supported for V3. There are also some legacy usage practices that are not supported in V3.