The official Python library for the terminal API
Terminal MCP server is a locally run integration for AI assistants that speak the Model Context Protocol. The official Python library for the terminal API.
The Terminal Python library provides convenient access to the Terminal REST API from any Python 3.9+ application. The library includes type definitions for all request params and response fields, and offers both synchronous and asynchronous clients powered by httpx.
Installation goes through your MCP client rather than a global install: point it at terminal-shop on PyPI and it is fetched when the client starts. The copy-paste blocks for Claude Desktop, Claude Code and Cursor are further down this page.
Once Terminal is connected, these are the calls the assistant has available:
Retries — Certain errors are automatically retried 2 times by default, with a short exponential backoff. Connection errors (for example, due to a networkTimeouts — By default requests time out after 1 minute. You can configure this with a timeout option, which accepts a float or anLogging — We use the standard library logging moduleYou will need 3 environment variables: TERMINAL_LOG, TERMINAL_BEARER_TOKEN, TERMINAL_BASE_URL. The server will not start without them, which is usually why the tools fail to appear on a first run. Keep credentials in your client's env block or a secrets manager rather than in a file you might commit.
Python 3.9 or higher.
This sits in the developer tooling group, where several servers overlap in what they claim to do but differ sharply once you actually set them up. Terminal's toolset — Retries, Timeouts, Logging — is a fair guide to whether it matches your workflow.
This entry was verified against Terminal's own documentation before publication; SyncDev keeps the directory reviewed rather than auto-generated.
| Tool | What it does |
|---|---|
| Retries | Certain errors are automatically retried 2 times by default, with a short exponential backoff. Connection errors (for example, due to a network connectivity problem), 408 Request Timeout, 409 Conflict, 429 Rate Limit, an |
| Timeouts | By default requests time out after 1 minute. You can configure this with a timeout option, which accepts a float or an [httpx.Timeout](https://www.python-httpx.org/advanced/timeouts/#fine-tuning-the-configuration) object |
| Logging | We use the standard library [logging](https://docs.python.org/3/library/logging.html) module. |
{
"mcpServers": {
"terminal-shop": {
"command": "uvx",
"args": ["terminal-shop"],
"env": {
"TERMINAL_LOG": "your-value",
"TERMINAL_BEARER_TOKEN": "your-value",
"TERMINAL_BASE_URL": "your-value"
}
}
}
}Add to claude_desktop_config.json, then restart Claude Desktop.
Python 3.9 or higher.
| Variable | Description | Required |
|---|---|---|
| TERMINAL_LOG | Configuration value read at startup. | Optional |
| TERMINAL_BEARER_TOKEN | Credential the server authenticates with. | Yes |
| TERMINAL_BASE_URL | Endpoint or connection string the server talks to. | Yes |
Kill hallucinated APIs — version-accurate, up-to-date library documentation injected straight into context.
Microsoft's official browser automation server — drive a real browser through the accessibility tree, no screenshots needed.
GitHub's official server — repos, issues, pull requests, Actions and code security, straight from your assistant.
Issue tracking at the speed of conversation — Linear's official hosted server with OAuth and zero install.
Local repository surgery — status, diffs, commits, branches and history for any repo on disk.
Timezone sanity for AI — current time anywhere and correct conversions, without the model doing date math.