Skip to content

docs: nested refs + numerical_id (Phase 1g)#214

Draft
Mlaz-code wants to merge 1 commit into
mainfrom
docs/nested-refs-numerical-ids
Draft

docs: nested refs + numerical_id (Phase 1g)#214
Mlaz-code wants to merge 1 commit into
mainfrom
docs/nested-refs-numerical-ids

Conversation

@Mlaz-code
Copy link
Copy Markdown
Collaborator

Summary

Phase 1g of the OpticOdds-parity migration. Documents the new numerical_id and nested reference objects shipping in:

What changes

New concept page: content/en/concepts/entity-reference-ids.mdx (110 lines) — numerical_id contract (frozen, dense-from-1, never reused), nested object reference, migration guidance.

Reference endpoint pages updated (5 pages, +73 lines): /sports, /leagues, /sportsbooks, /markets, /teams schemas + sample JSON gain numerical_id (and abbreviation on /teams). Each new field marked "New (May 2026)" and explicitly tagged optional.

Odds + opportunity pages updated (4 pages, +128 lines): /odds, /ev, /arbitrage, /middles document the six nested ref blocks (home, away, sport_ref, league_ref, market_ref, sportsbook_ref). Arbitrage and middles document the per-leg / per-side fan-out.

Wire-format invariants documented

  • All new fields optional (omitempty)
  • Existing string fields (sport, league, homeTeam, etc.) preserved indefinitely with no deprecation timeline
  • numerical_id is frozen — never reassigned on rename, never reused on delete

Test plan

  • npm run build clean (only benign Nextra warning that the new MDX has no git timestamp yet — resolves on commit)
  • npm run typecheck clean
  • New concept page renders to out/en/concepts/entity-reference-ids.html

🤖 Generated with Claude Code

@vercel
Copy link
Copy Markdown

vercel Bot commented May 7, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs.sharpapi.io Ready Ready Preview, Comment May 7, 2026 2:00pm

Request Review

Document the new optional `numerical_id` field on each reference endpoint
(/sports, /leagues, /sportsbooks, /markets, /teams) plus the nested
`home`, `away`, `sport_ref`, `league_ref`, `market_ref`, `sportsbook_ref`
blocks emitted on every odds row and EV / arbitrage / middles opportunity
leg. Adds /teams `abbreviation` field. New concept page
`entity-reference-ids.mdx` covers the dense-from-1 / frozen / never-reused
contract and migration guidance.

Additive only — every flat string field remains in every response.

Companion to api-adapters#489 (atlas backfill + Python adapter wire format)
and sharp-api-go#345 (Go decode + reference endpoint surface). Both ship
under the OpticOdds-parity Phase 1 work.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@Mlaz-code Mlaz-code force-pushed the docs/nested-refs-numerical-ids branch from 4687402 to 34c1ab3 Compare May 13, 2026 01:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant