Setting up Integrations Setting up Integrations

Setting up Integrations

Ismaen Aboubakare Ismaen Aboubakare

Setting up Authenticated Integrations

Standard Integrations

Applications have the ability to natively integrate with many popular services, including Twilio, Zendesk, Salesforce, and more. When setting up an integration, the services can be displayed and managed right from your application. For example, when setting up a Salesforce integration, Airkit will bring in all of the tables that are associated with a Salesforce account and can then leverage the built in operations such as Create Record, Delete Record, Update Record, Find Records or Query Records.

Create a custom integration

Custom integrations can be used to connect to external data sources that are not a part of Airkit's standard integrations. Any one of these standard authentication methods can be used for your API.

Using OAuth 2.0 to integrate Twitter

This example demonstrates how to create a custom authenticated integration with the Twitter API that uses OAuth 2.0 and connect it to an Airkit application. 

Prerequisites

Set up your custom integration

  1. Sign in to console.airkit.com and select Integrations and then Custom Integrations. This is where to manage the integrations associated with an organization.

    mceclip0.png
  2. Then click on +New to add a new Custom Integration. Enter the name of the service  and a unique key. This key is a global unique identifier associated with your custom integration. Then select OAuth 2.0 for the Authentication Type. This will then expand the fields that are required to create the integration.

    mceclip0.png

  3. For the Twitter API, provide the following for the configuration fields:
    • Authorization Grant Type: choose 'Client Credentials'
    • Access Token Endpoint: enter https://api.twitter.com/oauth2/token
    • Access Token Verb: choose 'POST'
    • Authorization Endpoint: enter https://api.twitter.com/oauth2/token
      mceclip1.png
    • OAuth Scope: enter 'read'
    • Client ID: enter your API key that was generated from the Twitter App
    • Client Secret: enter in your API Secret generated from the Twitter App
    • Token Parameter Type: choose 'Header' 
    • Token Parameter name: enter 'Authorization'
    • Token Parameter Value Template: enter 'Bearer {token}'
      mceclip2.png

  4. Click on Create to finish creating the custom integration

Connect the custom integration to Airkit

After setting up the custom integration, you need to connect the integration to Airkit. This will surface the integration to your application and make it usable in the app. 

  1. In the Airkit Console, go to Integrations and then Credentials

    mceclip1.png
  2. Click on +New and give the credential a name and choose the Twitter integration in the drop down menu. Then click on Createwhich then enables you to connect Twitter to your Airkit App!

    mceclip2.png

Using an API Token to integrate with GIPHY

This example demonstrates how to create a custom integration with the GIPHY API that uses an API Token and connect it to an application.

Prerequisites

Set up your custom integration

  1. Sign in to console.airkit.com and select Integrations and then Custom Integrations. This is where to manage the integrations associated within organization.
    mceclip0.png

  2. Then click on +New to add a new Custom Integration. Enter the name of the service and a unique key. This key is a global unique identifier associated with your custom integration. Then select API Token for the Authentication Type. This will then expand the fields that are required to create the integration.

    mceclip3.png

  3. For the GIPHY API, provide the following for the configuration fields:
    • Token Paramater Type: choose 'URL Parameter'
    • Token Parameter Name: enter 'api_key'
    • Token Parameter Value Template: enter '{token}'
      mceclip4.png
  4. Click on Create to finish creating the custom integration

Connect your custom integration to Airkit

After setting up the custom integration, you need to connect the integration to Airkit. This will surface the integration to your application and make it usable in the app. 

  1. In the Airkit Console, go to Integrations and then Credentials

    mceclip1.png
  2. Click on +New and give the credential a name and choose the GIPHY integration in the drop down menu. 

    mceclip5.png

  3. Then provide your API Token from your GIPHY app and click on Create to create an integration from GIPHY to Airkit. 

    mceclip6.png

Using Integrations in an App

Now that the integrations is added, they can now be used in an application.  Integrations can be used to call API endpoints directly from Connection Builder using the HTTP Operation. 

Adding an integration into an Airkit App

To use the integration, the integration will need to be added to your app in Configuration Builder

  1. In the Airkit studio, go to Configuration Builder and scroll down to Integrations

    2021-03-16_13-23-18-revised.png

  2. Click on +New and then Adapters and select the custom integration that was created in the console.

    mceclip7.png
  3. Then select the credential that is associated with your custom integration and Save your app. This will enable your app to leverage your integration in the HTTP Operation in Connection Builder.

    mceclip8.png

Understanding Profiles and Integrations

Oftentimes when building out an application, there's the need to have separate environments such as a DEV, QA, and Production environment. For example, you can set up a DEV environment with a dev instance of a custom integration, and be able to test and debug an application without needing to touch production data. To configure this, you need to set up different profiles within your application, and each profile would have different configuration settings. 

Next steps

Now with the integrations set up, an application can then be used for inbound requests to query and manipulate data on external systems. Integrations can also be used for outbound requests to push data from Airkit to external systems as well.