CircleCI
Overview
CircleCI is your continuous integration and delivery platform for building, testing, and deploying code with confidence. Connect to CircleCI to build custom internal tools that turbocharge CI/CD. Monitor pipelines, report on job executions, manage job runs, and more.
Setting up CircleCI
Create an access token
- In the CircleCI application, go to your User settings
- Click Personal API Tokens
- Click the Create New Token button
- In the Token name field, type a memorable name for the token
- Click the Add API Token button
- Copy the API key to configure your integration's connection
Learn more about CircleCI Authentication
Add integration
Once you have an access token, you're ready to set up your Superblocks integration.
- In the web app, navigate to the Integrations page
- Click on the CircleCI tile
- Name the integration
- Paste your credentials into the relevant fields
- Optionally, add more configurations to set credentials for different environments
- Click Create
CircleCI connected Now you can use CircleCI in any Application, Workflow, or Scheduled Job.
Use CircleCI in APIs
Once your CircleCI integration is created, you can start calling CircleCI actions in Superblocks APIs.
CircleCI actions are REST requests. To learn more about REST requests in Superblocks, see the Building REST requests guide.
Supported actions
List contexts
List all contexts for an owner.Create a new context
Get a context
Returns basic information about a context.Delete a context
List environment variables
List information about environment variables in a context, not including their values.Add or update an environment variable
Create or update an environment variable within a context. Returns information about the environment variable, not including its value.Remove an environment variable
Delete an environment variable from a context.Get summary metrics and trends for a project across it's workflows and branches
Get summary metrics and trends for a project at workflow and branch level. Workflow runs going back at most 90 days are included in the aggregation window. Trends are only supported upto last 30 days. Please note that Insights is not a financial reporting tool and should not be used for precise credit reporting. Credit reporting from Insights does not use the same source of truth as the billing information that is found in the Plan Overview page in the CircleCI UI, nor does the underlying data have the same data accuracy guarantees as the billing information in the CircleCI UI. This may lead to discrepancies between credits reported from Insights and the billing information in the Plan Overview page of the CircleCI UI. For precise credit reporting, always use the Plan Overview page in the CircleCI UI.Job timeseries data
Get timeseries data for all jobs within a workflow.Get summary metrics with trends for the entire org, and for each project.
Gets aggregated summary metrics with trends for the entire org. Also gets aggregated metrics and trends for each project belonging to the org.Get all branches for a project
Get a list of all branches for a specified project. The list will only contain branches currently available within Insights. The maximum number of branches returned by this endpoint is 5,000.Get flaky tests for a project
Get a list of flaky tests for a given project. Flaky tests are branch agnostic. A flaky test is a test that passed and failed in the same commit.Get summary metrics for a project's workflows
Get summary metrics for a project's workflows. Workflow runs going back at most 90 days are included in the aggregation window. Metrics are refreshed daily, and thus may not include executions from the last 24 hours. Please note that Insights is not a financial reporting tool and should not be used for precise credit reporting. Credit reporting from Insights does not use the same source of truth as the billing information that is found in the Plan Overview page in the CircleCI UI, nor does the underlying data have the same data accuracy guarantees as the billing information in the CircleCI UI. This may lead to discrepancies between credits reported from Insights and the billing information in the Plan Overview page of the CircleCI UI. For precise credit reporting, always use the Plan Overview page in the CircleCI UI.Get recent runs of a workflow
Get recent runs of a workflow. Runs going back at most 90 days are returned. Please note that Insights is not a financial reporting tool and should not be used for precise credit reporting. Credit reporting from Insights does not use the same source of truth as the billing information that is found in the Plan Overview page in the CircleCI UI, nor does the underlying data have the same data accuracy guarantees as the billing information in the CircleCI UI. This may lead to discrepancies between credits reported from Insights and the billing information in the Plan Overview page of the CircleCI UI. For precise credit reporting, always use the Plan Overview page in the CircleCI UI.Get summary metrics for a project workflow's jobs.
Get summary metrics for a project workflow's jobs. Job runs going back at most 90 days are included in the aggregation window. Metrics are refreshed daily, and thus may not include executions from the last 24 hours. Please note that Insights is not a financial reporting tool and should not be used for precise credit reporting. Credit reporting from Insights does not use the same source of truth as the billing information that is found in the Plan Overview page in the CircleCI UI, nor does the underlying data have the same data accuracy guarantees as the billing information in the CircleCI UI. This may lead to discrepancies between credits reported from Insights and the billing information in the Plan Overview page of the CircleCI UI. For precise credit reporting, always use the Plan Overview page in the CircleCI UI.Generic HTTP Request
Every SaaS integration in Superblocks comes with a built in Generic HTTP Request Action. This is a powerful action you can use to call CircleCI API endpoints not in the Superblocks supported actions.
To use this action simply add the method, path, required query parameters, and body for the desired endpoint.
Learn more about REST requests in Superblocks in our Building REST requests guide.
Generic HTTP Requests use the authentication set up and base URL you've configured for your integration, making it an easy for your team to extend Superblocks Integrations to meet their needs.