v0.3.1 — nested refs + TeamRef metadata
Bundles the 0.3.0 (nested refs) and 0.3.1 (TeamRef metadata) work into a single published release. 0.3.0 was never tagged; install 0.3.1 to get all of it.
Added
Nested reference objects (was 0.3.0)
Every odds, opportunity, and reference-list row may now carry optional structured ref objects alongside the legacy flat fields. All additive — clients on older API versions just see undefined and behave identically.
- New interfaces:
TeamRef,SportRef,EntityRef,Team,Market,NestedRefsbundle - Typed
LowHoldOpportunity(was loosely typed before) NormalizedOdds,EVOpportunity,ArbitrageOpportunity,MiddleOpportunityextendNestedRefsArbitrageLeggainssportsbook_refClosingOddgainsmarket_ref+sportsbook_refClosingSnapshotgainshome,away,sport_ref,league_refSport,League,Sportsbookgainnumerical_id
TeamRef metadata (was 0.3.1)
TeamRef and the Team reference shape gain five optional metadata fields:
logo— full CDN URL (~93% coverage)city,mascot,conference,division
All default to undefined. Older servers that omit them keep working.
Repo / packaging hygiene
- Add
LICENSE(MIT) andSECURITY.md(hello@sharpapi.io) - Author email updated
support@→hello@ - Fix README install + JSDoc import: package is
@sharp-api/client(not@sharpapi/client) - Strip
sourcesContentfrom npm sourcemaps so the.mapfiles no longer ship a full copy ofsrc/index.ts. Tarball: 57.7 kB → 31.0 kB. - Drop
tests/from the repo (kept locally for development); CI gate is now biome + tsc across Node 18/20/22
Compatibility
No existing field was renamed, retyped, or removed. Code on 0.2.x continues to compile.