# Custom integrations: V1

{% hint style="info" %}
Note that this is V1 of our custom integrations feature. Customers who have installed V2 of custom integrations or newer customers who only need documentation for our newer V2 of custom integrations may find that setup documentation [here](https://docs.rewst.help/documentation/integrations/custom-integrations/custom-integrations-v2).  V1 of custom integrations is deprecated and should no longer be used. Documentation for V1 remains to assist existing customers with the migration to the V2 method. If you have questions about migrating from V1 to V2, please reach out to [ROC support](https://docs.rewst.help/~/revisions/VmxzEdeNWvX54TqYxxOB/support-and-community/roc-support).&#x20;
{% endhint %}

This guide provides an overview of how to configure custom integrations within our platform. Custom integrations allow you to connect with a wide range of REST APIs that are not currently supported by our official integration offerings.

To enable the `Custom Integrations` feature for your organization, follow these steps:

1. Click on the `Settings` option in the left-hand side navigation bar.
2. Select `Feature Preview` in the expanded menu.
3. Select `Custom Integrations` the resulting page.
4. Click the `Enable` button in the top right corner of the panel.

After these steps, the `Custom` integration will be available for installation.

### Installation

Start by installing the `Custom` integration. This integration leverages the features of Integration Multi-tenancy to support configuring many different integrations.

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-6a3f7eec3d1415a48098e65be03b70813c075046%2Fcustom-integrations-install.png?alt=media" alt=""><figcaption></figcaption></figure>

### Configuration Steps

#### Step 1: Name your integration

Choose a name for your integration. Note that you cannot use the name `Default` for this purpose. We recommend naming configurations after the product you're integrating with.

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-dca9abe776a9b7baedb2c271756f3f235364b3f6%2Fcustom-integrations-step-1.png?alt=media" alt=""><figcaption></figcaption></figure>

#### Step 2: API Hostname and authentication method

Enter the hostname to be used as the base URL for API requests and select the authentication method from a drop-down of supported options.

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-85a30e5d50929e8c5b896a2474232fa855542b6a%2Fcustom-integrations-step-2.png?alt=media" alt=""><figcaption></figcaption></figure>

#### Step 3: Authentication details

Enter the authentication details relevant to the selected authentication method.

**API Key**

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-b7302df751974d17eea04b60a3d8db8889829224%2Fcustom-integrations-step-3-api-key.png?alt=media" alt=""><figcaption></figcaption></figure>

**Basic authentication**

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-772d20ca66f78394e5100ee8511eac7f7d937d2e%2Fcustom-integrations-step-3-basic-auth.png?alt=media" alt=""><figcaption></figcaption></figure>

**OAuth 2.0**

This authentication method requires setting up an OAuth client within your account with the relevant service provider. Please see vendor documentation for specific details on how to get the required information. For example, to integrate with Spotify you would need to follow the documentation [here](https://developer.spotify.com/documentation/web-api/tutorials/getting-started) and set up a Spotify App.

Ensure that when prompted for a Redirect URI you use the following value: `https://engine.rewst.io/integrations/custom/callback`.

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-312c6cb6ffec3b2d2cc5b494c3d83706d350894c%2Fcustom-integrations-step-3-oauth-1.png?alt=media" alt=""><figcaption></figcaption></figure>

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-d775ef231fb1db3f66f75eae7bcb582af7b31538%2Fcustom-integrations-step-3-oauth-2.png?alt=media" alt=""><figcaption></figcaption></figure>

#### Step 4: OAuth authorization code

This step is only used when the selected authentication method is `OAuth 2.0` and the selected grant type is `Authorization Code`. An `Authorize` button will be displayed, which works similarly to the rest of our integration authorization buttons.

In this case, the page will look like this:

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-df23d91d3db96f5ea8929b7c7f60a5dc9481c13c%2Fcustom-integrations-step-4-oauth.png?alt=media" alt=""><figcaption></figcaption></figure>

Otherwise, you will see this page, and no action is needed for this step:

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-8983e73754ee9ba67a1f585ce572bac7f824f727%2Fcustom-integrations-step-4-no-reqs.png?alt=media" alt=""><figcaption></figcaption></figure>

#### Step 5: Configuration test

This is an optional step to ensure that the integration configuration was successful and the API can be reached.

To test the configuration, enter the URL path for an endpoint that we can send a GET request to in order to validate that a 200 response code is returned.

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-e8c42f49bd4d68c2a43f90dcab03640c4309c6ce%2Fcustom-integrations-step-5.png?alt=media" alt=""><figcaption></figcaption></figure>

If the connection attempt was successful you will see the following:

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-64531787900877314539d94b9ec7ce625dcab882%2Fcustom-integrations-step-5-success.png?alt=media" alt=""><figcaption></figcaption></figure>

### Usage in Workflow Builder

Once your custom integration is set up, you can use it in your workflows and tasks using the `Custom API Request` action. You select which custom integration configuration to use for a workflow using `Integration Overrides`, which is covered in more detail in the Integration Multitenancy page at the top.

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-c4b81d026add88b1272cb37cb9a54328f79c19a4%2Fcustom-integrations-action.png?alt=media" alt=""><figcaption></figcaption></figure>

<figure><img src="https://1835401289-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAQQ1EHVcEsGKBPVHmiav%2Fuploads%2Fgit-blob-03093d03b53a828a44c013cf2dd07c525ff51f39%2Fcustom-integrations-integration-overrides.png?alt=media" alt=""><figcaption></figcaption></figure>
