File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22
33All notable changes to ` @sharp-api/client ` are documented here.
44
5+ ## 0.4.1 — 2026-06-02
6+
7+ ### Added — structured ` team_side ` + ` market_segment ` (issue #76 / #689 )
8+
9+ - ` NormalizedOdds ` , ` EVOpportunity ` , and ` ClosingOdd ` gain optional ` team_side `
10+ (` 'home' | 'away' | 'draw' | 'over' | 'under' ` ) and ` market_segment `
11+ (` string ` ). Wire keys are snake_case (the client returns raw JSON without key
12+ transforms), matching ` is_active ` .
13+ - ` team_side ` is the raw structured side decomposed out of the compound
14+ ` selectionType ` / ` selection_type ` vocabulary — prefer it over parsing compound
15+ prefixes like ` 'home_over' ` . ` market_segment ` is the canonical contest slice.
16+ - ` NormalizedOdds.selectionType ` widened with ` (string & {}) ` so it accepts the
17+ team-total compound forms (` 'home_over' ` , ...) the server emits without a major
18+ bump. Additive, non-breaking.
19+
520## 0.4.0 — 2026-06-02
621
722### Changed
Original file line number Diff line number Diff line change 11{
22 "name" : " @sharp-api/client" ,
3- "version" : " 0.4.0 " ,
3+ "version" : " 0.4.1 " ,
44 "description" : " Official TypeScript/JavaScript client for the SharpAPI real-time sports betting odds API" ,
55 "type" : " module" ,
66 "main" : " ./dist/index.cjs" ,
Original file line number Diff line number Diff line change @@ -301,6 +301,17 @@ export interface NormalizedOdds extends NestedRefs {
301301 | 'home_draw'
302302 | 'away_draw'
303303 | 'home_away'
304+ | ( string & { } )
305+ /**
306+ * Raw structured side axis ("home" | "away" | "draw") decomposed out of the
307+ * compound selectionType vocabulary (issue #76). Optional + additive — absent
308+ * when the adapter didn't stamp it. Wire key is snake_case `team_side` (the
309+ * client returns raw JSON without key transforms). Prefer over parsing
310+ * compound selectionType prefixes like "home_over".
311+ */
312+ team_side ?: 'home' | 'away' | 'draw' | 'over' | 'under'
313+ /** Canonical contest slice ("full_game" | "1st_half" | ...) — issue #689. Wire key snake_case. */
314+ market_segment ?: string
304315 odds : OddsValue
305316 line ?: number
306317 eventStartTime : string
@@ -336,6 +347,10 @@ export interface EVOpportunity extends NestedRefs {
336347 fairProbability : number
337348 evPercentage : number
338349 kellyPercent : number
350+ /** Raw structured side axis ("home" | "away" | "draw") — issue #76. Optional; wire key snake_case `team_side`. */
351+ team_side ?: 'home' | 'away' | 'draw' | 'over' | 'under'
352+ /** Canonical contest slice ("full_game" | "1st_half" | ...) — issue #689. Wire key snake_case. */
353+ market_segment ?: string
339354 detectedAt : string
340355}
341356
@@ -550,6 +565,10 @@ export interface ClosingOdd {
550565 | 'away_draw'
551566 | 'home_away'
552567 | ( string & { } )
568+ /** Raw structured side axis ("home" | "away" | "draw") — issue #76. Optional + additive. */
569+ team_side ?: 'home' | 'away' | 'draw' | 'over' | 'under'
570+ /** Canonical contest slice ("full_game" | "1st_half" | ...) — issue #689. */
571+ market_segment ?: string
553572 odds_american : number
554573 odds_decimal : number
555574 /** Spread / total line — present only on point-spread and totals markets. */
You can’t perform that action at this time.
0 commit comments