# Amp CLI

[Amp](https://ampcode.com) is an agentic coding tool built by [Sourcegraph](https://sourcegraph.com). It runs in VS Code (and compatible forks like Cursor, Windsurf, and VSCodium) and as a command-line tool. It's also multiplayer — you can share threads and collaborate with your team.

## Installation

Install globally with your preferred package manager:

```bash
pnpm add -g @sourcegraph/amp
# or
yarn global add @sourcegraph/amp
# or
npm install -g @sourcegraph/amp
```

Alternatively, run without installing:

```bash
npx @sourcegraph/amp
```

## Usage

After installation, run:

```bash
amp
```

See [**Amp Owner's Manual**](https://ampcode.com/manual) for more information about Amp.

## Authentication

**Option 1: Interactive Login (Recommended)**

The first time you run `amp`, use the login command to authenticate via [ampcode.com](https://ampcode.com):

```bash
amp login
```

This opens your browser to complete authentication. Your threads will be synced and shareable across all clients.

**Option 2: API Key Environment Variable**

If you can't use the interactive flow, set your API key as an environment variable:

1. Go to [ampcode.com/settings](https://ampcode.com/settings) to get your API key
2. Set it in your environment:

```bash
export AMP_API_KEY=your-api-key-here
```

## Proxies and Certificates

The Amp CLI supports proxy servers and custom certificates for corporate environments. See the [Proxies and Certificates section](https://ampcode.com/manual#proxies-and-certificates) in the Amp Owner's Manual for configuration details.

## Configuration

For detailed configuration options including all available settings, see the [Configuration Settings](https://ampcode.com/manual#configuration) section in the Owner's Manual.
