# CLI

The Airtable MCP CLI lets you call MCP tools directly from your terminal without a chat client. Useful for scripting, debugging, and quick lookups.

## Install

Install via npm:

```
npm install -g @airtable/mcp-cli
```

Or use the standalone installer:

```
curl -fsSL https://raw.githubusercontent.com/Airtable/airtable-mcp-cli/main/install.sh | sh
```

## Authenticate

1. [Create a personal access token](/create/tokens/new?scopes=data.records:read,data.records:write,schema.bases:read,schema.bases:write,data.recordComments:read,data.recordComments:write,workspacesAndBases:read) with the Airtable MCP scopes pre-selected (remove any you don't need to limit access).
2. Run the configure command and paste your token when prompted:

```
airtable-mcp configure
```

Alternatively, set the `AIRTABLE_TOKEN` environment variable to skip the configure step.

## Verify

1. Confirm your credentials are working:

```
airtable-mcp whoami
```

2. List your accessible bases:

```
airtable-mcp list-bases
```

## Commands

| Command                            | Description                                |
| ---------------------------------- | ------------------------------------------ |
| `airtable-mcp tools`               | Discover available MCP tools               |
| `airtable-mcp list-bases`          | View accessible bases                      |
| `airtable-mcp list-records`        | Retrieve records from a table              |
| `airtable-mcp whoami`              | Verify authentication status               |
| `airtable-mcp completions <shell>` | Generate shell completions (bash/zsh/fish) |

Pass `--json` for JSON output, or `--input -` to pipe JSON arguments via stdin. See the [CLI repository](https://github.com/Airtable/airtable-mcp-cli) for full documentation.
