Generic Rest API

Overview

The Generic REST API integration allows autobotAI to interact with any third-party service that exposes a REST API. This integration supports various authentication methods, enabling you to connect to a wide range of APIs, such as those requiring no authentication, Bearer tokens, Basic Authentication, or API Keys.

Prerequisites

Before you begin, ensure you have the following:

  1. API URL: The base URL of the API you want to connect to.
  2. Authentication Credentials: Depending on the chosen authentication method, you may need:
    1. Bearer Token
    2. Username and Password (for Basic Authentication)
    3. API Key (along with the API Key Name and Location)

Steps to Set Up Generic-Rest-API Integration

Step 1: Navigate to the Integrations Page

Go to the Integrations page by selecting Integrations from the menu. Then, click + Add Integration in the top-right corner to view available integrations.

add_integration

Step 2: Select Generic REST API Integration

Under the Others category, select Generic REST API + Add to initiate the integration setup for Generic REST API.

select_generic_rest_api

Step 3: Fill in the Required Details

Complete the required fields based on the authentication method for your API:

Note: Fields marked with an asterisk (*) are mandatory.

1. No Authentication:

  1. Alias: Provide a descriptive name for this integration.
  2. Groups: Use groups to organize multiple integrations, similar to how labels work in Gmail.
  3. API URL: Enter the base URL of the API.

no_auth

2. Bearer Token:

  1. Alias: Provide a descriptive name for this integration.
  2. Groups: Use groups to organize multiple integrations, similar to how labels work in Gmail.
  3. API URL: Enter the base URL of the API.
  4. Bearer Token: Enter the Bearer Token required for authentication.

bearer_token

3. Basic Authentication:

  1. Alias: Provide a descriptive name for this integration.
  2. Groups: Use groups to organize multiple integrations, similar to how labels work in Gmail.
  3. API URL: Enter the base URL of the API.
  4. Username: Enter the username for authentication.
  5. Password: Enter the password for authentication.

basic_auth

4. API Key:

  1. Alias: Provide a descriptive name for this integration.
  2. Groups: Use groups to organize multiple integrations, similar to how labels work in Gmail.
  3. API URL: Enter the base URL of the API.
  4. API Key Name: Enter the name of the API key.
  5. API Key Value: Enter the value of the API key.
  6. API Key Location: Specify where the API key is located (e.g., Header, Query Parameter).

Api_key

Once you've entered the necessary information, click Create to finalize the integration setup.

Step 4: Test the Integration

After completing the setup, go to the Integrations page and locate your newly created Generic REST API integration. Click on the three dots next to it and select Test to ensure your API is successfully connected to autobotAI.

validation

Additional Information

How to Obtain the Required API Keys and Credentials

Depending on the authentication method, here are steps to obtain the necessary credentials:

1. No Authentication:

This method requires no credentials. You only need the API URL to connect to the service.

2. Bearer Token:

To obtain a Bearer Token, you may need to:

  1. Register your application with the service provider to receive a client ID and client secret.
  2. Use OAuth2 or similar protocols to retrieve the token via the service’s authentication endpoint.

3. Basic Authentication:

For Basic Authentication, you will need:

  1. Username and Password: These are typically provided when registering for the API service or can be found in the API documentation or user settings.

4. API Key:

To obtain an API Key, follow these general steps:

  1. Go to the API provider’s developer portal or settings page.
  2. Register your application or request an API key.
  3. Find the API Key Name, API Key Value, and decide on the API Key Location (usually in the header or as a query parameter).

Check the provider's documentation for specific instructions on retrieving the API key.