Skip to content

Repository files navigation

mcs

A simple, unofficial CLI for Mazda Connected Services, ported from pymazda.

Install

go build -o mcs ./cmd/mcs
mv mcs /usr/local/bin/ # or anywhere in PATH

Configuration

Create ~/.config/mcs/config.toml:

email = "your@email.com"password = "yourpassword"region = "MNAO"# MNAO=North America, MME=Europe, MJO=Japan

Or use environment variables: MCS_EMAIL, MCS_PASSWORD, MCS_REGION

Usage

# Status
mcs status # Full vehicle status
mcs status --json # JSON output
mcs status --refresh # Request fresh status from vehicle# Control
mcs lock # Lock doors
mcs unlock # Unlock doors
mcs start # Remote start engine
mcs stop # Stop engine# Charging
mcs charge start # Start charging
mcs charge stop # Stop charging# Climate
mcs climate on # Turn on HVAC
mcs climate off # Turn off HVAC
mcs climate set --temp 21 # Set temperature (Celsius)# Debug
mcs raw status # Raw vehicle status JSON
mcs raw ev # Raw EV status JSON# Shell completions
mcs completion bash # Also: zsh, fish, powershell

Example

$ mcs status
CX-90 PHEV 2.5L (2025)
VIN: JM3KKDHA*********
Status as of 2025-12-19 09:17:02 (5 min ago)
BATTERY: 43%
FUEL: 92% (10 km EV + 610 km fuel = 620 km total)
CLIMATE: Off
DOORS: All locked
WINDOWS: All closed
TIRES: FL:32.0 FR:32.0 RL:32.0 RR:32.0 PSI
ODOMETER: 5,279.4 km

Note: Tire pressures are color-coded based on deviation from target (36 PSI):

  • Green: within ±3 PSI (33-39)
  • Yellow: 4-6 PSI deviation
  • Red: >6 PSI deviation (potential safety issue)

Claude Code Integration

mcs includes a Claude Code skill for natural language vehicle control. Install it once:

mcs skill install

Then in Claude Code, just tell Claude what you want:

You: "warm up the car"
Claude: runs `mcs climate on`
You: "what's my battery level?"
Claude: runs `mcs status` and shows battery info
You: "lock the doors"
Claude: runs `mcs lock`

Supported phrases:

  • Climate: "warm up the car", "cool it down", "set to 22 degrees"
  • Locks: "lock the car", "unlock the doors"
  • Engine: "start the car", "stop the engine"
  • Charging: "start charging", "stop the charge"
  • Status: "check the battery", "where is my car", "tire pressure"

Skill management:

mcs skill install # Install to ~/.claude/skills/mcs-control/
mcs skill uninstall # Remove the skill
mcs skill path # Show installation path

Notes

  • Uses vehicle manufacturer's API (reverse-engineered from mobile app)
  • Tokens cached in ~/.cache/mcs/token.json
  • Remote start limited to 2 consecutive starts without driving

For developer documentation, see CLAUDE.md

About

CLI tool for controlling Mazda Connected Services vehicles

Resources

Stars

6 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages