# Install the CLI

The CLI can be used to create, test and publish integrations for GitBook’s integration platform. To start using the CLI, you’ll first need to install it globally on your machine:

```bash
npm install @gitbook/cli -g
```

After installing the CLI, you’ll need to authenticate your user in order to create and publish an integration.

To authenticate your user, run:

```bash
gitbook auth
```

This will prompt you to add your developer token from your GitBook account. You can generate a personal developer token in your [GitBook Developer settings](https://app.gitbook.com/account/developer).

After authenticating your user, you’ll be able to bootstrap an integration, publish an integration, and more. Refer to the [Quickstart](/docs/developers/integrations/quickstart.md) to learn more about building an integration using the CLI.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://gitbook.com/docs/developers/integrations/reference.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
