Start Building for Free
CircleCI.comAcademyBlogCommunitySupport

CircleCI config SDK

5 days ago1 min read
Cloud
On This Page
  • Overview
  • Install the SDK
  • Contribute

Overview

The CircleCI Config SDK is a JavaScript package library (also compatible with TypeScript) for generating a CircleCI YAML configuration file. Use the SDK to:

  • Replace writing YAML conguration files

  • Generate a static YAML configuration file

  • Modularize and manage your configuration as JavaScript packages

  • Enhance CircleCI’s dynamic configuration

  • Build integrations with CLI tools or browser-based experiences

For example, generating a static configuration file can be useful for CLI tools where you want to create a CircleCI configuration, or browser-based tooling, such as a visual config editor.

Components created with the CircleCI Config SDK can be packaged and distributed as Node packages.

Install the SDK

Install the CircleCI Config SDK with NPM or Yarn, and include it in your project via Node.js or the browser.

NPM installation:

$ npm i @circleci/circleci-config-sdk

Yarn installation:

yarn add @circleci/circleci-config-sdk

Use in Node.js

import CircleCI from '@circleci/circleci-config-sdk';

Use in the browser:

const CircleCI = require('@circleci/circleci-config-sdk');

Visit the SDK page to view a full example of generating a CircleCI configuration.

Contribute

The CircleCI Config SDK is open source, and contributions are welcome. Visit the contributing guide to view the guidelines and release process.


Help make this document better

This guide, as well as the rest of our docs, are open source and available on GitHub. We welcome your contributions.

Need support?

Our support engineers are available to help with service issues, billing, or account related questions, and can help troubleshoot build configurations. Contact our support engineers by opening a ticket.

You can also visit our support site to find support articles, community forums, and training resources.