OpenSourceGolf Initiative

The Open Course
Data Model

A free, open, community-maintained standard for structured golf course data — designed so any developer, researcher, or app builder can read it, write it, and build on top of it without permission or proprietary lock-in.

Fully Open — CC BY 4.0
Structured JSON Schema
Any Course, Any Platform
Community Contributed

What is Open Course?

Golf course data that belongs to everyone.

Golf is full of proprietary course databases locked inside paid subscriptions and closed APIs. Open Course is our answer to that — a lightweight, human-readable JSON data model that describes a golf course completely enough to power real, game-day applications.

T'doff uses Open Course as its native data layer. Every course powered by T'doff is represented as an Open Course document. That means the data that improves your game is transparent, auditable, and exportable — not trapped.

You can use Open Course data to build GPS apps, handicap trackers, practice simulators, course-review platforms, or anything else a golf developer can imagine. No license fees. No API keys. No middlemen.

18 Holes per course document
4 Tee sets supported per hole
∞ Hazards & targets per hole
CC BY 4.0 licensed — free forever

The Specification

Schema Structure

The recent San Marcos record contains 18 holes, four tee sets, and mapped hazard geometry. Its structure separates tee distances, hole coordinates, and hazard shapes, as shown below.

Course object

{
  "id":                 "string  — Course UUID",
  "name":               "string  — Course name",
  "courseName":         "string  — Name alias also present in this record",
  "slug":               "string  — URL-safe course identifier",
  "location":           { ... }, // see Location object
  "teeSets":            [ ... ], // array of TeeSet objects
  "holes":              [ ... ], // array of Hole objects
  "sharedHazards":      [ ... ], // shared hazard polygons
  "hazardAssignments":  [ ... ], // links hazards to holes
  "hazardShapes":       [ ... ], // hole-specific hazard polygons
  "defaultTeeSetId":    "string  — ID of the default tee set",
  "activeTeeSetId":     "string  — ID of the selected tee set",
  "createdAt":          "number  — Numeric timestamp; unit not specified",
  "updatedAt":          "number  — Numeric timestamp; unit not specified",
  "isFavorite":         "boolean — App-level favorite state"
}

Location object

{
  "address":    "string — Street address",
  "city":       "string — City name",
  "region":     "string — State or province",
  "countryCode":"string — Country code",
  "postalCode": "string — Postal or ZIP code"
}

TeeSet object

{
  "id":           "string  — Tee-set UUID; referenced by holes",
  "name":         "string  — Tee label e.g. Black | Blue | White | Red",
  "colorHex":     "string  — Display color",
  "courseRating": "number  — Course rating",
  "slopeRating":  "number  — Slope rating",
  "yards":        "number[] — One distance per hole, in hole order"
}

Hole object × 18

{
  "id":          "number  — Hole number, 1–18",
  "par":         "number  — Hole par",
  "handicapMen": "number  — Men's stroke index",
  "teeBoxes":    { ... }, // tee-set ID to Coordinate
  "green":       { ... }  // front, middle, and back Coordinates
}

Coordinate object

{
  "lat": "number — Latitude in decimal degrees",
  "lon": "number — Longitude in decimal degrees"
}

Hazard geometry

{
  "id":             "string — Hazard or shape UUID",
  "type":           "string — Hazard type e.g. bunker",
  "coordinates":    "Coordinate[] — Polygon points",
  "isClosed":       "boolean — Whether the polygon is closed",
  "holeNumber":     "number — Present on hole-specific shapes",
  "sharedHazardId": "string — Shared hazard reference on a shape"
}

Hazard assignment

{
  "id":         "string — Shape UUID",
  "hazardId":   "string — Shared hazard UUID",
  "holeNumber": "number — Hole that contains the hazard"
}

Tee-box coordinates are keyed by tee-set ID and may be absent when a position is unavailable. Selection and favorite fields describe app state, not course geometry.

Course File Example

San Marcos record excerpt

This excerpt shows one tee set and one hole. Download the complete San Marcos sample (JSON) for all 18 holes, four tee sets, and mapped hazards.

{
  "id": "9d3b6c2e-7a14-4f91-8b63-2e5c7a9d1048",
  "name": "San Marcos Golf Course",
  "courseName": "San Marcos Golf Course",
  "slug": "san-marcos-golf-course",
  "location": {
    "address": "100 N Dakota St",
    "city": "Chandler",
    "region": "AZ",
    "countryCode": "US",
    "postalCode": "85225"
  },
  "defaultTeeSetId": "41f5b7a8-3e62-4a1c-94d8-7b2f5c903e11",
  "activeTeeSetId": "41f5b7a8-3e62-4a1c-94d8-7b2f5c903e11",
  "teeSets": [
    {
      "id": "41f5b7a8-3e62-4a1c-94d8-7b2f5c903e11",
      "name": "White",
      "colorHex": "#FFFFFF",
      "courseRating": 67.8,
      "slopeRating": 117,
      "yards": [360, 329, 169, 425, 440, 340, 320, 139, 415, 392, 360, 277, 100, 302, 179, 330, 459, 467]
    }
  ],
  "holes": [
    {
      "id": 1,
      "par": 4,
      "handicapMen": 1,
      "teeBoxes": {
        "41f5b7a8-3e62-4a1c-94d8-7b2f5c903e11": {
          "lat": 33.30480803271721,
          "lon": -111.84747600057193
        }
      },
      "green": {
        "front": {
          "lat": 33.30516034574717,
          "lon": -111.85079209079205
        },
        "middle": {
          "lat": 33.30515707962432,
          "lon": -111.8509287451333
        },
        "back": {
          "lat": 33.30517538615457,
          "lon": -111.85108856588957
        }
      }
    }
  ]
}

Build With It

How to leverage Open Course in your project

The model is intentionally simple — a JSON file you can store, query, or serve any way you like.

Flat file storage

Each course is a single .json file. Drop them in a folder, a CDN, or commit them straight to a GitHub repo. Zero database required to get started.

REST or GraphQL API

Wrap the files in any HTTP server and you have a course data API instantly. The flat structure maps directly to REST routes — /courses/:id/holes/:number.

Mobile apps

Bundle course documents in your app binary for offline play. Parse with any JSON library on iOS, Android, or React Native — no proprietary SDK required.

GPS & mapping

Combine lat / lng from the location object with hole distances and hazard positions to render tee-to-green overlays on any mapping platform.

Handicap & scoring

Par, stroke-index, and tee distances are all first-class fields. Your handicap calculator or scorecard app can consume Open Course documents directly.

AI & analytics

Structured hazard, layup, and pin-position data feeds naturally into ML models for shot recommendation, course strategy, and performance analysis pipelines.

Open Course by OpenSourceGolf

Build something great for golf.

The spec is live, the schema is stable, and the community is growing. Grab the template and ship your first course today.

CC BY 4.0 — Free Forever JSON Schema Validated No API Key Needed