> For the complete documentation index, see [llms.txt](https://docs.work-relay.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.work-relay.com/administration/setup/migrating-between-environments.md).

# Migrating between environments

**Actions, Processes & Forms:**

For deploying Actions, Processes and Forms between organizations you need to use the Work-Relay export/import tool since the actions, processes and forms are data, not meta-data. Here is an overview of the deployment process.

Many clients store these export files in Github to keep a history.

Exporting can be done in any sequence, however for importing, you should start with any Actions/Action Groups, then Forms, then Processes.

## Deploying actions/action groups

{% stepper %}
{% step %}

### Export actions or action groups

On Source org, go to Actions tab.

Select Actions or Action Groups to export using checkboxes (1) on left (if you export an Action Group, the export will contain all Actions within the Group).

Click "Export" button (2) and provide a meaningful name to export file (by default it has **.wri** extension).

![](/files/6fdf0078b1a4165674467016aba1e9136299a66a)
{% endstep %}

{% step %}

### Import actions or action groups

On the destination organization go to Actions and click "Import" button (3).

Select whether to update existing Actions/Action Groups or to import as new (4).

Choose exported file (5). When chosen, system will try to import it automatically.

![](/files/3259b3c5737a219693a637c91f5c5228943c6e3a)

![](/files/f4a593e9c1aef0658d34207a924143c24d37985f)
{% endstep %}
{% endstepper %}

{% hint style="info" %}
**Notes:**

* File must have .wri ("Work-Relay Imported") extension.
* If file has incorrect format or it is damaged, system will show an error message.
  {% endhint %}

## Deploying forms

{% stepper %}
{% step %}

### Export forms

On source org, go to Forms tab.

Select Forms to export using checkboxes on left.

Click Export and provide a meaningful name to export file (with **.wri** extension).
{% endstep %}

{% step %}

### Import forms

On destination org, go to Forms tab and click Import.

Select whether to update existing forms or to import as new.

Choose exported file and it will be imported (or not, if any error occurs).
{% endstep %}
{% endstepper %}

## Deploying new processes (primary versions only)

{% stepper %}
{% step %}

### Export processes

On source org, go to Processes tab.

Select Processes to export using checkboxes on left.

{% hint style="info" %}
When exporting from this page, it will only export the Primary version of a process.
{% endhint %}

Click "Export" and provide a meaningful name to export file (with **.wri** extension).
{% endstep %}

{% step %}

### Import processes

On destination org, go to Processes tab and click "Import" button.

Choose exported file and it will be imported (or not, if any error occurs).
{% endstep %}
{% endstepper %}

**Additional points:**

* If you import the same name as an existing process, it will not overwrite the original (this could be problematic if the structure of the process has changed) but import as a new process.
* If you need to deploy a new version of a process, you should instead use the Version import/export tool.

## Deploying new versions of a process

{% stepper %}
{% step %}

### Export a process version

On source org, go to Processes tab.

Click on Process name to drill into the Process details page.

Click on Versions.

Click Export link next to Version you want to export (6).

File will be named based on the Version name + **.wrpv** extension.

![](/files/0129f4c5fa204dc98a826cce41c06448d559aa5a)
{% endstep %}

{% step %}

### Import a process version

On destination org, go to Processes tab.

Click on Process name to drill into the Process home page.

Click on Versions.

Click Import button on top.

Select exported file and click Import button (7).
{% endstep %}
{% endstepper %}

**Additional points:**

* If you import the same name as an existing version, it will not overwrite the original (this could be problematic if the structure of the process has changed) but import as a new version.

## Settings tab configuration (for new installs)

The following need to be set up in the Settings tab and sub-tabs on new installs:

### Add licenses

To use the same license across multiple sandboxes, you would follow this process:

{% stepper %}
{% step %}

### Switch to salesforce classic

Switch to Salesforce Classic (8) - License Tool is not Lightning ready yet.
{% endstep %}

{% step %}

### Open license settings

Click on "Settings" tab (click on "+" in tab bar to locate).

Click on the "Licenses Settings" sub tab.
{% endstep %}

{% step %}

### Enter license details

Click on Enter License Key.

Enter Org ID of the originally set up sandbox.

Enter the sandbox license key.

![](/files/60eeb8bf33a09c13b3184ead0f0c4c53e66478a3)
{% endstep %}
{% endstepper %}

### Turn on workflow scheduler

Go to Settings tab (best in Classic) > Schedulers Settings sub-tab and click the Turn On link.

### Add email delivery contact (used for Salesforce email templates)

Go to Settings tab > Notifications Settings and add an Email Delivery Contact that is set up as a Contact in that org.

### Add super admins if desired

Go to Settings tab (Classic only) > General Settings and add the User IDs of any super admins (users that can edit all processes and forms in the org).

### Set up allowed objects (option to import from another org)

{% stepper %}
{% step %}

### Save the allowed objects file

On the source org, go to "Documents" tab and open "Work-Relay" folder.

Open the "Allowed Objects" document detail page.

On the "View File" link, do "Save Link As.." using the context menu.
{% endstep %}

{% step %}

### Replace the allowed objects file

On the destination org, replace the "Allowed Objects" file with the saved file from the source org.

You can also manually add or adjust those Allowed Objects by going to Settings tab > Objects Settings.

You can push this same file to all sandboxes.
{% endstep %}
{% endstepper %}

### Activate top level processes

When processes are deployed to a different org, they need to be activated. You can load the parent and activate it and all sub-processes by selecting Activate and choosing the option to activate parent and subs.
