Installing Optic

Learn how to set up Optic in your development environment.

Install the Optic CLI

$ yarn global add @useoptic/cli
$ npm install @useoptic/cli -g

1. Change your working directory to the root directory of the API you want to add Optic to

cd /path/to/api

2. Run Optic's init command

api init

3. Pick your API framework and follow the on-screen instructions to finish the integration.

If your API framework is not listed click Other. If you take the time to contribute docs for the framework we'll add you as a contributor, and send you some Optic swag!

Run your API with `api start`

From now on run your API locally with api start. This command allows Optic to watch your API

api start

Need Help?

Click here to schedule a setup call with someone on Optic's team: