MCP Server
Connect a client
Add the GolfCourseAPI MCP server to Claude Code, Claude, Cursor, VS Code, Windsurf or Codex.
Before you start
- Your API key. Use the key you got when you signed up. If you no longer have it, rotate it on the API Usage page. See Authentication.
- The server URL:
https://mcp.golfcourseapi.com/mcp
Client support
| Client | Status | Notes |
|---|---|---|
| Claude Code | Supported | One command with an Authorization header. |
| Cursor | Supported | JSON config with headers. |
| VS Code (Copilot) | Supported | JSON config; key stored securely. |
| Windsurf | Supported | JSON config with headers. |
| Codex | Supported | Key read from an environment variable. |
| Claude.ai & Claude Desktop | Beta | Needs the Request headers option on custom connectors, which is in beta. |
| ChatGPT | Not yet | ChatGPT needs OAuth, which this server doesn't support yet. |
Setup
Run this in your terminal, replacing YOUR_API_KEY with your key:
claude mcp add --transport http golfcourseapi https://mcp.golfcourseapi.com/mcp \ --header "Authorization: Bearer YOUR_API_KEY"
Add --scope user to use it in every project, or --scope project to share it with your team through .mcp.json. If you share it, keep the key out of the file and have each person add their own.
Start Claude Code and run /mcp. golfcourseapi should show as connected with three tools.
Try it
Once connected, ask your assistant something like:
Find Torrey Pines South and list every tee with its course rating, slope rating and yardage.
This uses two tool calls, so two requests from your quota: search_courses to find the course, then get_course for its tees. Broad prompts, like comparing every course in a city, can use many requests. On the Free plan, keep an eye on the API Usage page.
Other clients
Any MCP client that supports the Streamable HTTP transport and custom headers can connect. Point it at https://mcp.golfcourseapi.com/mcp and send Authorization: Bearer YOUR_API_KEY on every request.
Something not working the way this page describes? .