Get the FREE Ultimate OpenClaw Setup Guide →

tesla-streamable

MCP Server for interacting with Tesla (via Tessie API). Written in TypeScript, Node and Hono.dev

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio iceener-tesla-streamable-mcp-server npx mcp-remote http://127.0.0.1:3000/mcp --transport http-only \
  --env NO_PROXY="127.0.0.1,localhost"

How to use

Tesla MCP Server provides a streamable HTTP interface to interact with a Tesla vehicle via the Tessie API. It exposes a unified set of tools for querying vehicle state and issuing commands (e.g., lock/unlock, climate control, trunk operations, sentry mode, and navigation) with location context to enable AI agents to reason about where the car is and what it can do. The server supports two runtimes: a local Node.js/Bun-based server for development and a Cloudflare Worker deployment for remote access. To connect clients, configure a bearer-token protected MCP endpoint and pass Tessie API credentials via secrets or environment variables as described in the installation notes. Typical usage involves running the local server, then connecting an MCP client (like Claude Desktop or Cursor) to the provided /mcp endpoint using the appropriate transport (http-only) and including the Authorization: Bearer token for client authentication.

How to install

Prerequisites:

  • Node.js/Bun installed (depending on runtime preference)
  • Tessie account and API credentials

Install and run locally (Node/Bun runtime):

  1. Clone the repository and navigate to the project directory
  2. Install dependencies:
bun install
  1. Create and configure environment variables in a .env file (see example below)
  2. Start the server:
bun dev
  1. Connect your MCP client to http://127.0.0.1:3000/mcp

Cloudflare Worker deployment (remote access):

  1. Install Wrangler and Bun if not already installed
  2. Configure secrets (BEARER_TOKEN, TESSIE_ACCESS_TOKEN, TESSIE_VIN) as described in the README
  3. Deploy the worker:
bun x wrangler deploy
  1. Use the provided Worker URL ending in /mcp for the MCP endpoint

Environment setup (example .env for local):

PORT=3000
AUTH_ENABLED=true
AUTH_STRATEGY=bearer
BEARER_TOKEN=your-random-auth-token
TESSIE_ACCESS_TOKEN=your-tessie-access-token
TESSIE_VIN=your-vehicle-vin

Additional notes

Tips and caveats:

  • The HTTP layer is intended for development and testing; for production deployments, implement proper TLS termination, strict CORS/origin checks, and audit logging.
  • Keep Tessie API credentials and Bearer tokens secure; use environment variables or Cloudflare Secrets as described.
  • If you switch between local and remote runtimes, ensure the MCP client is pointed at the correct /mcp endpoint and that authorization tokens are updated accordingly.
  • When running locally, the MCP endpoint is typically http://127.0.0.1:3000/mcp; when deployed to Cloudflare Workers, use the https://<worker>.workers.dev/mcp URL.
  • The included tools (tesla_state and tesla_command) provide structured inputs/outputs; validate responses for any command success or failure messages before acting on them in an automation workflow.

Related MCP Servers

Sponsor this space

Reach thousands of developers