Connect to CircleCI
Connect CircleCI to Retool and manage pipelines, workflows, and jobs.
CircleCI is a continuous integration and delivery platform for building, testing, and deploying software.
What you can do with CircleCI in Retool
After you create a CircleCI resource in Retool, you can:
- Retrieve pipelines, workflows, and jobs.
- Trigger new pipeline runs.
- Approve pending workflow jobs.
- Build CI/CD dashboards and admin panels on top of CircleCI data.
Before you begin
To connect CircleCI to Retool, you need the following:
- Cloud
- Self-hosted
- CircleCI personal API token: A token with permission to access the projects you plan to query.
- Retool permissions: Ability to create and manage resources in your organization.
- CircleCI personal API token: A token with permission to access the projects you plan to query.
- Network access: Your Retool instance must be able to reach
circleci.comover outbound HTTPS. - Retool permissions: Ability to create and manage resources in your organization.
Create a CircleCI resource
Follow these steps to create a CircleCI resource in Retool.
Create a new resource
In your Retool organization, navigate to Resources in the main navigation and click Create new → Resource. Search for CircleCI and click the CircleCI tile to begin configuration.
Configure general settings
Specify a name and description for the resource that indicates which CircleCI account it connects to. The description provides more context to users and Assist about how to use the resource.
| Example name | Example description |
|---|---|
| CircleCI (Platform team) | CircleCI account used to monitor and trigger the platform team's pipelines. |
| CircleCI (Release automation) | CircleCI account used to automate release pipeline approvals. |
Configure authentication
CircleCI resources authenticate using a personal API token.
Paste your CircleCI personal API token into the Personal API Token field. Generate one from the Personal API Tokens page of your CircleCI account.
Personal API Token: CCIPAT_1234567890abcdefghijklmnopqrstuvwxyz
Test the connection
Click Test connection to verify Retool can connect to CircleCI. If the test succeeds, you see a success message. If it fails, check the following:
- Token is correct: Confirm the token hasn't been revoked or expired in CircleCI.
- Project access: Confirm the account that generated the token has access to the projects you're querying.
After testing the connection, click View in console to open the Debug Tools console. The console displays request details (URL, method, headers) and the response (status code, body), along with execution time and error details if the test fails. This information is helpful for troubleshooting connection issues.
Save the resource
Click Create resource to save your CircleCI resource. You can now use it in queries across your Retool apps and automations.
Interact with CircleCI data
Once you've created a CircleCI resource, you can interact with CircleCI data using Retool.
CircleCI isn't yet supported in the new app builder. Use a classic app, workflow, or agent instead.
For classic apps, workflows, and agents, refer to the REST API queries documentation to learn how to write a resource query.
Best practices
Follow these best practices to maintain the security of your CircleCI resource.
- Use a token with least privilege: Personal API tokens inherit the permissions of the CircleCI account that created them. Use a dedicated account scoped to only the projects the resource needs.
- Use configuration variables: Store the CircleCI personal API token in configuration variables or Retool secrets rather than hardcoding it in queries.
- Rotate credentials regularly: Regenerate the personal API token on a regular schedule, and immediately if it's ever exposed.
- Use resource environments: Organizations on an Enterprise plan can configure multiple resource environments to maintain separate CircleCI credentials for production, staging, and development.
Related resources
Create a resource
Learn how to create and manage resources in Retool.
Resource environments
Configure separate credentials for production and non-production environments.
Configuration variables
Store sensitive values securely for use in queries and apps.
Retool community
Community discussions and solutions for connecting resources to Retool.
CircleCI API documentation
Official CircleCI API documentation.