Skip to main content
Glama
intelligent-golf-mcp

intelligent-golf-mcp

by mpvii

intelligent-golf-mcp

An MCP server for your Intelligent Golf club website — WHS handicap, the handicap record, every round you have played with hole-by-hole scorecards, the competitions you have entered (with tee times, partners and published results), your own tee bookings, and the club's course status, news and diary — so an agent can answer "how am I playing?", "who am I playing with?" and "what's on at the club?" without you opening the member site.

Unofficial. Intelligent Golf publishes no API for individual members. This uses the club's own website with a session you create yourself by logging in normally. It is fine for your own data; it is not an integration and is not endorsed by Intelligent Golf.

Why it works this way

Intelligent Golf runs a member website for each club on its own subdomain, and those sites are server-rendered PHP. There is no OAuth and no JSON API for members: the sign-in is a form asking for a member id and a PIN, and the member pages are HTML.

So the MCP:

  • opens a real browser for you to sign in, and stores only the resulting cookies;

  • never receives your member id or PIN in this process;

  • keeps the session in the macOS Keychain, not in a file;

  • parses the member pages, and returns small, stable dictionaries.

One quirk matters: with no live session a member page still answers 200, but serves the login page. The page title is the only reliable signal — Login Required means "sign in again", Sorry, we couldn't find this page means the site moved. Status codes cannot tell them apart.

Related MCP server: Timesheet Portal MCP server

Pages used

All relative to your club's host (https://<club>.intelligentgolf.co.uk).

Page

Gives

/hcaprecord.php

name, club, CDH id, current and low Handicap Index, the WHS record

/roundmgmt.php

every round: competition, date, course, tee, gross, nett, Stableford points

/competition2.php?time=future

upcoming competitions, fee and whether you are entered

/competition2.php?tab=details&compid=N

one competition: entry, tee time, partners and team

/competition.php?compid=N

published results and your finishing position

/viewround.php?roundid=N

one round, hole by hole

/memberbooking/?date=DD-MM-YYYY&course=1&group=1

the tee sheet (group=2 is the 10th tee)

/course_status, /news.php, /diary.php

course status, news and the club diary

handicap.php, teetimes.php and booking.php are administrative pages and answer Access Denied to ordinary members, so the member-facing routes above are the ones used.

Install

git clone https://github.com/mpvii/intelligent-golf-mcp.git
cd intelligent-golf-mcp

uv sync --extra login
uv run playwright install chromium   # one-time browser download

--extra login is only needed to sign in; reading works with the base install once a session exists.

Configure your club

Every club has its own host, so the club is configuration, not code — the repository stays generic. Set IG_CLUB to the subdomain (or a full host/custom domain):

export IG_CLUB=myclub                       # myclub.intelligentgolf.co.uk
export IG_CLUB=myclub.intelligentgolf.co.uk # the same host, explicitly
export IG_CLUB=https://golf.example.com     # a club on its own domain

Pass --club to override it for one command.

Sign in

uv run intelligent-golf-mcp --club myclub login

A Chromium window opens at the club's login. Enter your member id and PIN there. When the member area loads, the window closes and the session is saved.

uv run intelligent-golf-mcp --club myclub status   # is the session still live?
uv run intelligent-golf-mcp --club myclub logout   # forget it

If a page changes shape, capture the raw pages:

uv run intelligent-golf-mcp --club myclub discover --out samples

Use it as an MCP server

It speaks stdio by default (no arguments is serve).

OpenCode / Claude Code — add to your MCP config:

{
  "mcp": {
    "servers": {
      "ig": {
        "type": "local",
        "command": ["/absolute/path/to/intelligent-golf-mcp/.venv/bin/intelligent-golf-mcp", "serve"],
        "environment": {
          "IG_CLUB": "myclub",
          "PATH": "/opt/homebrew/bin:/usr/local/bin:/usr/bin:/bin"
        }
      }
    }
  }
}

Replace the path with your clone and myclub with your club's subdomain.

Tools

Tool

Returns

ig_status

Whether a live session is stored, for which club, and the member's name

ig_login / ig_logout

Start the browser sign-in / remove the stored session

ig_profile

Name, club, CDH id, current and low Handicap Index, member type

ig_handicap

Current and low index, scores in the record, last score date, best differential

ig_scores

The WHS record: date, course, tee, gross, PCC, differential

ig_results

Your round history: competition, date, course, gross, nett, Stableford

ig_competitions

Upcoming competitions with fee, entry status and signup opening/closing dates

ig_competition

One competition: entry status, fee, tee time, partners and team members

ig_leaderboard

Published results for one competition, with your own row

ig_round

Hole-by-hole scorecard: par, SI, score, points, front/back splits

ig_bookings

Your own tee reservations over the next N days, on both tees

ig_course_status

Course status, winter rules and the update date

ig_news

Club news: title, date, summary and link

ig_diary

The club diary for a month: events, times and competition links

ig_tee_times

Bookable tee slots for a date, by 1st or 10th tee

Everything is read-only. The tools never book, cancel or enter anything: only ig_login/ig_logout change local state.

ig_tee_times returns counts for taken slots, never other members' names. The two honest exceptions: ig_bookings names the players in your own slot (so you can see who you are playing with), and ig_leaderboard returns the club's published results, which name entrants. There is deliberately no member-directory tool.

Notes and limits

  • Session lifetime is the club's call. When the site expires the cookies, the tools return a not signed in error — run login again.

  • This is markup, not an API. Intelligent Golf can change a page at any time; if a field disappears, discover shows the current markup and parse.py is the one place to adjust.

  • The round-history table is malformed. Its rows are not closed with </tr>, so the parser uses lxml (libxml2), which repairs them the way a browser does.

  • Competition dates on the lists have no year. They are placed in the next or previous year relative to today; the round history does print a full date.

  • ig_bookings scans the tee sheets. There is no "my bookings" page, so it fetches one sheet per day per tee: 14 days is the default, 60 the maximum. ig_tee_times is the cheap way to look at a single date.

  • ig_news reads the front page. Older items need the site's own archive; the tool does not page through it.

  • ig_leaderboard follows the field size. limit trims the returned rows, but mine is always filled in from the full table.

  • Keychain item is service intelligent-golf-mcp, account = your club's host, so sessions for different clubs can coexist. It holds bearer cookies — treat it like a password.

  • One member per machine. A session belongs to you; there is no shared account.

Privacy

  • The only credential stored is the session cookie, in the macOS Keychain.

  • Traffic goes to your club's Intelligent Golf host and nowhere else. There is no telemetry, no server component and no shared account.

  • Other members' names appear only where they are part of your own golf: the players in your booking, and the club's published competition results.

  • samples/ holds raw pages from your account; it is git-ignored. Never commit it.

  • Tests use a made-up member and club.

Development

uv sync --extra login
uv run pytest
uv run ruff check .

Layout:

src/intelligent_golf_mcp/config.py    club host from IG_CLUB
src/intelligent_golf_mcp/keychain.py  macOS Keychain, one account per club
src/intelligent_golf_mcp/session.py   browser login + status
src/intelligent_golf_mcp/client.py    httpx client; login-page title -> not signed in
src/intelligent_golf_mcp/parse.py     HTML -> small, stable tool dicts
src/intelligent_golf_mcp/service.py   page fetch per tool
src/intelligent_golf_mcp/server.py    MCP tools + CLI

Licence

MIT.

Available Tools

16 tools
ig_bookingsA

The member's own tee reservations over the next days (max 60).

Scans both the 1st and 10th tees, because the site has no "my bookings" page. Only the names in the member's own slot are returned as partners.

Inputs: days. Returns: object

ig_competitionA

One competition: entry status, fee, tee time, partners and team members.

competition_id comes from ig_competitions or ig_results.

Inputs: competition_id (required). Returns: object

ig_competitionsC

Upcoming competitions: fee, entry status, and when signup opens/closes.

Inputs: limit. Returns: object

ig_course_statusA

The club's course status and winter rules, with the time it was updated.

Inputs: no named parameters. Returns: object

ig_diaryC

The club diary for a month: events, times and competition links.

Inputs: year, limit, month. Returns: object

ig_handicapB

Current Handicap Index, Low Index and a summary of the WHS record.

Inputs: no named parameters. Returns: object

ig_leaderboardC

Published results for one competition, with the member's own row.

The field is named, because a leaderboard is public club results.

Inputs: competition_id (required), limit. Returns: object

ig_loginA

Open a browser for the member to sign in; store only the session cookies.

The member types their own member id and PIN in the window. Requires the optional login extra and a desktop session.

Inputs: force, timeout_seconds. Returns: object

ig_logoutA

Remove the stored session from the Keychain.

Inputs: no named parameters. Returns: object

ig_newsC

Club news items: title, date, summary and link to the full item.

Inputs: limit. Returns: object

ig_profileC

Name, club, CDH id, current/low Handicap Index and member type.

Inputs: no named parameters. Returns: object

ig_resultsB

Every round in the member's history: competition, date, course, gross, nett and Stableford points, newest first.

Inputs: limit. Returns: object

ig_roundC

Hole-by-hole scorecard for one round: par, SI, score, points and splits.

Inputs: round_id (required). Returns: object

ig_scoresB

The WHS handicap record: date, course, tee, gross, PCC and differential.

The record holds at most 20 scores; limit only trims the list.

Inputs: limit. Returns: object

ig_statusA

Whether the machine holds a live session for the configured club.

Inputs: no named parameters. Returns: object

ig_tee_timesA

Bookable tee slots for a date (default today).

date is YYYY-MM-DD; group is 1 for the 1st tee or 2 for the 10th. Only counts are returned for taken slots — never other members' names.

Inputs: date, group, available_only. Returns: object

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.2/5.0

    Scored across 16 tools

    Disambiguation4/5

    Most tools target clearly distinct resources, and the descriptions explicitly disambiguate the tricky pairs (ig_competitions list vs. ig_competition detail, ig_tee_times availability vs. ig_bookings own reservations). Minor overlaps remain: ig_scores vs. ig_results vs. ig_round all expose round data at different granularity, ig_handicap partially duplicates ig_profile, and ig_status vs. ig_course_status share a name stem.

    Naming Consistency4/5

    Every tool carries the same ig_ prefix in snake_case, and the singular/plural split (competition/competitions, score/result/round) is used meaningfully rather than randomly. The only deviation is that ig_login/ig_logout are verbs while the rest are resource nouns, which is conventional and harmless.

    Tool Count4/5

    16 tools is at the upper edge of comfortable, but each maps to a genuinely different data view in the member portal (session, profile, handicap, records, competitions, leaderboard, scorecard, bookings, course status, news, diary, tee times), so little feels padded.

    Completeness3/5

    Read coverage is strong, but the surface is almost entirely read-only: there is no tool to actually book a tee slot found via ig_tee_times, cancel a booking, or enter a competition whose status is shown by ig_competitions/ig_competition. These are core member actions, so an agent will hit a dead end at the point of acting.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      C
      maintenance
      It enables MCP clients such as Claude and ChatGPT to read an estate agency's Dezrez Rezi CRM data, including properties and their timelines, people, groups, and offers. It is read-only and applies privacy redactions by default.
      10
      MIT
    • A
      license
      A
      quality
      C
      maintenance
      Enables MCP clients such as Claude and ChatGPT to read a Timesheet Portal account, including timesheet time and cost reports, invoices, leave bookings and balances, projects or jobs, clients, users and cost centres, across both the Standard and Recruitment editions. It is read-only, with personal and pay data withheld unless explicitly requested.
      8
      MIT
    • A
      license
      A
      quality
      C
      maintenance
      Enables Claude, ChatGPT and other MCP clients to look up members, their memberships and credentials, events and event bookings, and clubs and other organisations in a sports membership platform, and, when writes are enabled, to change the dates of a member's membership.
      9
      MIT
    • A
      license
      B
      quality
      B
      maintenance
      Provides read-only access to a Ryde account so agents can pull completed rides and GPS routes, owned and available RidePasses, payments, city fare rules, and ride summaries or pass-cost comparisons. Requires an SMS-authenticated login and never modifies account data.
      20
      1
      MIT