Skip to main content

MCP server for iRacing

Project description

iRacing MCP Server

An MCP (Model Context Protocol) server for accessing iRacing telemetry data and game functionality.

Overview

This project provides real-time telemetry data, leaderboard information, camera control, pit commands, replay functionality, and more from iRacing through the MCP protocol. It enables AI assistants and other applications to easily access iRacing data.

Key Features

📊 Telemetry Data

  • Retrieve real-time telemetry values
  • Get list of available telemetry variables

🏁 Race Information

  • Get leaderboard (competitive positions only)
  • Access driver information, session information, weekend information, and split time information
  • Monitor current flags and engine warnings

📹 Camera Control

  • Get available camera groups
  • Switch cameras (by car number, position, group specification)
  • Check current camera status

🔧 Pit Operations

  • Check pit service status
  • Execute pit commands (refueling, tire changes, repairs, etc.)
  • Manage safe pit operations

🎬 Replay Features

  • Search and navigate replays
  • Move between sessions, laps, and frames
  • Jump to incident markers

Requirements

  • Python 3.13 or higher
  • iRacing (must be running)
  • uv

Usage

1. Installation

uv tool install

2. Configure mcp.json

{
    "mcpServers": {
        "iracing-mcp-server": {
            "command": "iracing-mcp"
        }
    }
}

Available Tools

Telemetry Related

  • get_telemetry_names() - Get available telemetry variables
  • get_telemetry_values(names) - Get specified telemetry values

Race Information

  • get_leaderboard() - Get leaderboard
  • get_driver_info() - Get driver information
  • get_session_info() - Get session information
  • get_qualify_results_info() - Get qualification results information
  • get_weekend_info() - Get weekend information
  • get_split_time_info() - Get split time information
  • get_radio_info() - Get radio infomation
  • get_current_flags() - Get current flags
  • get_current_engine_warnings() - Get engine warnings

Camera Control

  • get_camera_info() - Get camera information
  • get_current_camera_status() - Get current camera status
  • cam_switch(group_number, car_number_raw, position) - Switch camera

Pit Operations

  • get_current_pit_service_status() - Get current pit service status
  • pit_command(commands_and_values) - Execute pit command

Replay Features

  • replay_search(search_commands) - Search and navigate replay

Development

Dependencies

  • mcp[cli]>=1.12.2 - MCP protocol implementation
  • pyirsdk>=1.3.5 - iRacing SDK Python bindings

Project Structure

iracing-mcp-server/
├── src/iracing_mcp_server/
│   ├── __init__.py          # Main entry point
│   ├── server.py            # MCP server implementation
│   ├── leaderboard.py       # Leaderboard processing
│   └── prompt.py            # Prompt templates
├── pyproject.toml           # Project configuration
└── README.md               # This file

License

This project is released under the MIT License.

Acknowledgments

  • pyirsdk - Python bindings for iRacing SDK
  • MCP - Model Context Protocol

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

iracing_mcp_server-0.1.0.tar.gz (29.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

iracing_mcp_server-0.1.0-py3-none-any.whl (12.8 kB view details)

Uploaded Python 3

File details

Details for the file iracing_mcp_server-0.1.0.tar.gz.

File metadata

  • Download URL: iracing_mcp_server-0.1.0.tar.gz
  • Upload date:
  • Size: 29.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.17

File hashes

Hashes for iracing_mcp_server-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6b0060b9d0f1b334330238b99ab479eaf329659be55c90580faee65862061517
MD5 03ab604a908ac3544f01312f146f335e
BLAKE2b-256 5595cffd12088eb5e9ebbafeca1f61511808cd456e28e4681af72efd60726fae

See more details on using hashes here.

File details

Details for the file iracing_mcp_server-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for iracing_mcp_server-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a46332a17a3e4760ebc8bbf8ca8dfc66652ba3047e3c04fd959bd60711c8b465
MD5 377cbcc9af0a827f7155cdcf7bc40e24
BLAKE2b-256 abc037838f47e3f5b80357c1bdf6f4633722d37bd8a3f10f0f132de70c161974

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page