Case Studies/

Sports Platform · League Management

HoopCulture Basketball Stats

A comprehensive basketball statistics platform for running leagues end to end — real-time game scoring, player and team analytics, and public standings across multiple leagues, seasons, and divisions.

The problem

Community and semi-pro basketball leagues run on paper scoresheets and spreadsheets. A scorer tracks the game by hand, then someone re-keys it hours or days later, so box scores lag the games and season standings are perpetually stale. There is no single source of truth for a league's data, and no way to answer performance questions — player trends, team form, historical matchups — without a manual export-and-pivot exercise every time. The people who need the data are not one audience but four — league admins, team captains, courtside scorers, and the public — each needing a different slice at a different moment, from a laptop in the office to a phone at the scorer's table.

Key challenges

Live scoring has to work at the scorer's table, where connectivity is unreliable and a dropped network can't be allowed to lose a game's worth of entries. Multiple roles need multiple permission boundaries — a team captain should manage their roster but not another team's, a scorer should log a game but not edit league structure. And the public views have to be fast and open, serving standings and stats to fans without authentication while the same data stays write-protected behind roles.

What we built

AR Data built HoopCulture as a Turborepo monorepo with three surfaces over one shared domain: a Fastify + Prisma API, a public Next.js website, and a dedicated offline-capable PWA for live scoring. Scorers log games in real time from a phone; the PWA holds state locally and syncs back when connectivity returns, so a network gap at the table never costs a game record. Leagues, seasons, divisions, and teams are modeled as first-class entities, with role-based access spanning Super Admin, League Admin, Team Captain, and Scorer. Player and team statistics roll up from logged game events into historical trends, and public standings, schedules, and stats are served without authentication so fans reach them directly.

Our approach

  1. 1

    One domain, three surfaces

    A Turborepo monorepo shares types, schemas, and constants across the API, the public web app, and the scorer PWA — so a rule defined once (how a stat is derived, what a role can do) holds identically everywhere it's used.

  2. 2

    Offline-first scorer PWA

    The live-scoring app is a PWA that keeps the current game's state on-device and syncs back when the network returns. Scorer-table connectivity is unreliable by default, so offline is the primary case, not the fallback.

  3. 3

    Role-based access across four roles

    Super Admin, League Admin, Team Captain, and Scorer each get a scoped permission boundary — enough to do their job, nothing beyond it. The same API serves all four without leaking write access.

  4. 4

    Public read views, protected writes

    Standings, schedules, and stats are open and fast for fans, served without auth, while every write path stays gated behind roles. Read and write are separated so openness never compromises data integrity.

Key architectural decisions

Monorepo with a shared domain package

Three apps that must agree on the same rules are far safer sharing one typed domain package than re-implementing logic three times. Turborepo keeps the build fast as the surfaces grow.

Offline-first scoring over a thin online client

A scorer can't stop the game because the wifi dropped. Local-first state with sync-back is the only architecture that survives the real conditions of a scorer's table.

PostgreSQL + Redis + optional Meilisearch

Postgres as the durable record via Prisma, Redis for sessions and caching, and Meilisearch when a league needs fast full-text search — each added only where it earns its place.

Public data without authentication

Fans shouldn't need an account to check standings. Serving public views openly, with writes protected separately, matches how a league's data is actually consumed.

Results

  • Real-time live scoring from a phone at the scorer's table
  • Offline-capable scorer PWA with sync-back — survives connectivity gaps
  • Box scores and standings that update as games are played, not days later
  • Player and team statistics with historical trends
  • Multi-league, multi-season, multi-division structure
  • Role-based access across Super Admin, League Admin, Team Captain, and Scorer
  • Public standings, schedules, and stats served without authentication

Impact

HoopCulture replaces the paper-and-spreadsheet workflow with a single platform a league owns end to end. Games are scored live, standings update as they happen, and a clean historical dataset accumulates as a by-product of running the league normally. The offline-first scorer app is the pattern that makes it real on the ground — the system works in the actual conditions of a gym with bad wifi, which is where basketball is actually played. It's the kind of work AR Data does end to end: the workflow redesigned around how the game is actually run, then shipped as a production system, not a demo.

Tech stack

Next.js 14TypeScriptFastifyPrismaPostgreSQLRedisMeilisearchReact QueryZustandTailwindCSSTurborepoPWA

Want a case study like this?

30 minutes. We scope the real problem and figure out what to build.

Book a call
AR Logo

AR Data Intelligence Solutions Inc. · Agentic Workflow Transformation · AI, Blockchain, and Decentralized Tech

7030 Woodbine Avenue, Suite 500, Markham, Ontario, L3R 6G2, Canada

AnthropicAnthropic PartnerClaudeClaude Partner Network

©2026 AR Data Intelligence Solutions, Inc. All Rights Reserved.