Skip to main content

Connect to the Retool API

Learn how to connect the Retool API using the OpenAPI integration.

Available on:Enterprise plan

You can use the OpenAPI integration to create a Retool API resource and make it available in Retool. Once complete, your users can write queries that interact with your organization using the Retool API.


The OpenAPI integration requirements depend on whether you have a cloud-hosted or self-hosted Retool organization. You may also need to make OpenAPI configuration changes before creating the resource.

Sufficient user permissions to create resources

All users for Retool organizations on Free or Team plans have global Edit permissions and can add, edit, and remove resources. If your organization manages user permissions for resources, you must be a member of a group with Edit all permissions.

Retool API key

Authentication is performed using Bearer HTTP authentication with an API key. You must first create an API key with the required permission scopes. Refer to the Retool API authentication guide for instructions.

Configure the resource

Sign in to your Retool organization and navigate to the Resources tab. Click Create new > Resource, then select OpenAPI.


Specify the name, location, and description to use for your OpenAPI resource. Retool displays the resource name and type in query editors to help users identify them.

Provide the following configuration settings to create the resource. Depending on how your data source is configured, you may also need to provide optional settings for Retool to connect.


The name to use for the resource.


A description of the resource.

Specification URL

The URL for the OpenAPI specification to use.

Use for cloud-hosted organizations.


The OpenAPI integration supports the following authentication methods. Depending on which authentication method you use, you may need to make changes to your OpenAPI configuration.

Bearer Token

Authentication is performed using Bearer HTTP authentication with a token. You must be able to obtain and provide these credentials to create the resource.

Refer to the Retool API authentication guide for instructions on creating an API token.

Test the connection

Click Test Connection to verify that Retool can successfully connect to the data source. If the test fails, check the resource settings and try again.

Testing only verifies connection

Testing a connection only checks whether Retool can successfully connect to the resource. It cannot check whether the provided credentials have sufficient privileges or can perform every supported action.

Save the resource

Click Create resource to complete the setup. You can then click either Create app to immediately start building a Retool app or Back to resources to return to the list of resources.

Wrap up

Your Retool API resource is now ready to use. To start querying data:

  1. Add a Resource query to an app or workflow.
  2. Select the Retool API resource from the resources dropdown.
  3. Write and run a query.