fansunited-data-layer 0.2.0 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/api/fansunited/constants.d.ts +5 -0
- package/api/fansunited/constants.d.ts.map +1 -0
- package/api/fansunited/football/competition/index.d.ts +30 -0
- package/api/fansunited/football/competition/index.d.ts.map +1 -0
- package/api/fansunited/football/competition/transformer.d.ts +11 -0
- package/api/fansunited/football/competition/transformer.d.ts.map +1 -0
- package/api/fansunited/football/competition/types.d.ts +70 -0
- package/api/fansunited/football/competition/types.d.ts.map +1 -0
- package/api/fansunited/football/competitions/index.d.ts +27 -0
- package/api/fansunited/football/competitions/index.d.ts.map +1 -0
- package/api/fansunited/football/competitions/transformer.d.ts +14 -0
- package/api/fansunited/football/competitions/transformer.d.ts.map +1 -0
- package/api/fansunited/football/competitions/types.d.ts +67 -0
- package/api/fansunited/football/competitions/types.d.ts.map +1 -0
- package/api/fansunited/football/http.d.ts +8 -0
- package/api/fansunited/football/http.d.ts.map +1 -0
- package/api/fansunited/football/index.d.ts +19 -0
- package/api/fansunited/football/index.d.ts.map +1 -0
- package/api/fansunited/football/matches/index.d.ts +61 -0
- package/api/fansunited/football/matches/index.d.ts.map +1 -0
- package/api/fansunited/football/matches/transformer.d.ts +28 -0
- package/api/fansunited/football/matches/transformer.d.ts.map +1 -0
- package/api/fansunited/football/matches/types.d.ts +328 -0
- package/api/fansunited/football/matches/types.d.ts.map +1 -0
- package/api/fansunited/football/players/index.d.ts +30 -0
- package/api/fansunited/football/players/index.d.ts.map +1 -0
- package/api/fansunited/football/players/transformer.d.ts +10 -0
- package/api/fansunited/football/players/transformer.d.ts.map +1 -0
- package/api/fansunited/football/players/types.d.ts +70 -0
- package/api/fansunited/football/players/types.d.ts.map +1 -0
- package/api/fansunited/football/search/index.d.ts +49 -0
- package/api/fansunited/football/search/index.d.ts.map +1 -0
- package/api/fansunited/football/search/transformer.d.ts +10 -0
- package/api/fansunited/football/search/transformer.d.ts.map +1 -0
- package/api/fansunited/football/search/types.d.ts +151 -0
- package/api/fansunited/football/search/types.d.ts.map +1 -0
- package/api/fansunited/football/teams/index.d.ts +30 -0
- package/api/fansunited/football/teams/index.d.ts.map +1 -0
- package/api/fansunited/football/teams/transformer.d.ts +10 -0
- package/api/fansunited/football/teams/transformer.d.ts.map +1 -0
- package/api/fansunited/football/teams/types.d.ts +87 -0
- package/api/fansunited/football/teams/types.d.ts.map +1 -0
- package/api/fansunited/http.d.ts +54 -0
- package/api/fansunited/http.d.ts.map +1 -0
- package/api/fansunited/index.d.ts +10 -0
- package/api/fansunited/index.d.ts.map +1 -0
- package/api/sportal365-sports/constants.d.ts +16 -0
- package/api/sportal365-sports/constants.d.ts.map +1 -0
- package/api/sportal365-sports/football/competitions/competition.types.d.ts +148 -0
- package/api/sportal365-sports/football/competitions/competition.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/competitions/index.d.ts +54 -0
- package/api/sportal365-sports/football/competitions/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/competitions/utils.d.ts +14 -0
- package/api/sportal365-sports/football/competitions/utils.d.ts.map +1 -0
- package/api/sportal365-sports/football/http.d.ts +8 -0
- package/api/sportal365-sports/football/http.d.ts.map +1 -0
- package/api/sportal365-sports/football/index.d.ts +19 -0
- package/api/sportal365-sports/football/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/index.d.ts +151 -0
- package/api/sportal365-sports/football/matches/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/transformers/commentary.d.ts +12 -0
- package/api/sportal365-sports/football/matches/transformers/commentary.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/transformers/index.d.ts +10 -0
- package/api/sportal365-sports/football/matches/transformers/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/transformers/lineup.d.ts +11 -0
- package/api/sportal365-sports/football/matches/transformers/lineup.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/transformers/match-event.d.ts +12 -0
- package/api/sportal365-sports/football/matches/transformers/match-event.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/transformers/match.d.ts +11 -0
- package/api/sportal365-sports/football/matches/transformers/match.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/transformers/odds.d.ts +11 -0
- package/api/sportal365-sports/football/matches/transformers/odds.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/transformers/statistics.d.ts +11 -0
- package/api/sportal365-sports/football/matches/transformers/statistics.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/commentary.types.d.ts +27 -0
- package/api/sportal365-sports/football/matches/types/commentary.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/event.types.d.ts +19 -0
- package/api/sportal365-sports/football/matches/types/event.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/index.d.ts +16 -0
- package/api/sportal365-sports/football/matches/types/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/lineup.types.d.ts +80 -0
- package/api/sportal365-sports/football/matches/types/lineup.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/match.types.d.ts +47 -0
- package/api/sportal365-sports/football/matches/types/match.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/minute.types.d.ts +8 -0
- package/api/sportal365-sports/football/matches/types/minute.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/odds.types.d.ts +80 -0
- package/api/sportal365-sports/football/matches/types/odds.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/option.types.d.ts +129 -0
- package/api/sportal365-sports/football/matches/types/option.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/referee.types.d.ts +13 -0
- package/api/sportal365-sports/football/matches/types/referee.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/statistics.types.d.ts +45 -0
- package/api/sportal365-sports/football/matches/types/statistics.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/status.types.d.ts +13 -0
- package/api/sportal365-sports/football/matches/types/status.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/team.types.d.ts +17 -0
- package/api/sportal365-sports/football/matches/types/team.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/matches/types/winner.types.d.ts +15 -0
- package/api/sportal365-sports/football/matches/types/winner.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/search/index.d.ts +45 -0
- package/api/sportal365-sports/football/search/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/search/search.transformer.d.ts +10 -0
- package/api/sportal365-sports/football/search/search.transformer.d.ts.map +1 -0
- package/api/sportal365-sports/football/search/search.types.d.ts +147 -0
- package/api/sportal365-sports/football/search/search.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/standings/index.d.ts +43 -0
- package/api/sportal365-sports/football/standings/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/standings/standing.transformer.d.ts +15 -0
- package/api/sportal365-sports/football/standings/standing.transformer.d.ts.map +1 -0
- package/api/sportal365-sports/football/standings/standing.types.d.ts +73 -0
- package/api/sportal365-sports/football/standings/standing.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/statistics/index.d.ts +42 -0
- package/api/sportal365-sports/football/statistics/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/statistics/player-season.transformer.d.ts +11 -0
- package/api/sportal365-sports/football/statistics/player-season.transformer.d.ts.map +1 -0
- package/api/sportal365-sports/football/statistics/player-season.types.d.ts +84 -0
- package/api/sportal365-sports/football/statistics/player-season.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/teams/index.d.ts +53 -0
- package/api/sportal365-sports/football/teams/index.d.ts.map +1 -0
- package/api/sportal365-sports/football/teams/squad.types.d.ts +63 -0
- package/api/sportal365-sports/football/teams/squad.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/teams/team.types.d.ts +58 -0
- package/api/sportal365-sports/football/teams/team.types.d.ts.map +1 -0
- package/api/sportal365-sports/football/teams/utils.d.ts +24 -0
- package/api/sportal365-sports/football/teams/utils.d.ts.map +1 -0
- package/api/sportal365-sports/http.d.ts +59 -0
- package/api/sportal365-sports/http.d.ts.map +1 -0
- package/api/sportal365-sports/index.d.ts +14 -0
- package/api/sportal365-sports/index.d.ts.map +1 -0
- package/api/sportal365-sports/search/http.d.ts +8 -0
- package/api/sportal365-sports/search/http.d.ts.map +1 -0
- package/api/sportal365-sports/search/index.d.ts +43 -0
- package/api/sportal365-sports/search/index.d.ts.map +1 -0
- package/api/sportal365-sports/search/search.transformer.d.ts +10 -0
- package/api/sportal365-sports/search/search.transformer.d.ts.map +1 -0
- package/api/sportal365-sports/search/search.types.d.ts +209 -0
- package/api/sportal365-sports/search/search.types.d.ts.map +1 -0
- package/api/sportal365-sports/shared/index.d.ts +6 -0
- package/api/sportal365-sports/shared/index.d.ts.map +1 -0
- package/api/sportal365-sports/shared/providerRef.helper.d.ts +79 -0
- package/api/sportal365-sports/shared/providerRef.helper.d.ts.map +1 -0
- package/api/sportal365-sports/shared/types.d.ts +189 -0
- package/api/sportal365-sports/shared/types.d.ts.map +1 -0
- package/api/sportal365-sports/statistics/http.d.ts +8 -0
- package/api/sportal365-sports/statistics/http.d.ts.map +1 -0
- package/api/sportal365-sports/statistics/index.d.ts +55 -0
- package/api/sportal365-sports/statistics/index.d.ts.map +1 -0
- package/api/sportal365-sports/statistics/team-stats.transformer.d.ts +14 -0
- package/api/sportal365-sports/statistics/team-stats.transformer.d.ts.map +1 -0
- package/api/sportal365-sports/statistics/team-stats.types.d.ts +45 -0
- package/api/sportal365-sports/statistics/team-stats.types.d.ts.map +1 -0
- package/client.cjs +8 -0
- package/client.d.ts +20 -0
- package/client.d.ts.map +1 -0
- package/client.js +12065 -0
- package/config/index.d.ts +31 -0
- package/config/index.d.ts.map +1 -0
- package/config/types.d.ts +36 -0
- package/config/types.d.ts.map +1 -0
- package/fansunited-data-layer.cjs +1 -0
- package/fansunited-data-layer.js +1739 -0
- package/helpers/competition.helpers.d.ts +22 -0
- package/helpers/competition.helpers.d.ts.map +1 -0
- package/helpers/index.d.ts +7 -0
- package/helpers/index.d.ts.map +1 -0
- package/helpers/team.helpers.d.ts +289 -0
- package/helpers/team.helpers.d.ts.map +1 -0
- package/index-Cogo-Kkd.cjs +1 -0
- package/index-D7T2Yy11.js +1170 -0
- package/index.d.ts +39 -0
- package/index.d.ts.map +1 -0
- package/package.json +14 -17
- package/providers/competition/hooks/index.d.ts +6 -0
- package/providers/competition/hooks/index.d.ts.map +1 -0
- package/providers/competition/hooks/useCompetitionStats.d.ts +8 -0
- package/providers/competition/hooks/useCompetitionStats.d.ts.map +1 -0
- package/providers/competition/hooks/useGoalDistribution.d.ts +11 -0
- package/providers/competition/hooks/useGoalDistribution.d.ts.map +1 -0
- package/providers/competition/hooks/useMatchHelpers.d.ts +16 -0
- package/providers/competition/hooks/useMatchHelpers.d.ts.map +1 -0
- package/providers/competition/hooks/useStandingsCalculations.d.ts +18 -0
- package/providers/competition/hooks/useStandingsCalculations.d.ts.map +1 -0
- package/providers/competition/hooks/useStandingsHelpers.d.ts +23 -0
- package/providers/competition/hooks/useStandingsHelpers.d.ts.map +1 -0
- package/providers/competition/hooks/useTeamPosition.d.ts +8 -0
- package/providers/competition/hooks/useTeamPosition.d.ts.map +1 -0
- package/providers/competition/hooks/useTeamResultsTable.d.ts +9 -0
- package/providers/competition/hooks/useTeamResultsTable.d.ts.map +1 -0
- package/providers/competition/utils/competitionStats.d.ts +42 -0
- package/providers/competition/utils/competitionStats.d.ts.map +1 -0
- package/providers/competition/utils/goalDistribution.d.ts +41 -0
- package/providers/competition/utils/goalDistribution.d.ts.map +1 -0
- package/providers/competition/utils/index.d.ts +6 -0
- package/providers/competition/utils/index.d.ts.map +1 -0
- package/providers/competition/utils/standingsCalculations.d.ts +24 -0
- package/providers/competition/utils/standingsCalculations.d.ts.map +1 -0
- package/providers/competition.context.d.ts +8 -0
- package/providers/competition.context.d.ts.map +1 -0
- package/providers/competition.provider.d.ts +3 -0
- package/providers/competition.provider.d.ts.map +1 -0
- package/providers/competition.types.d.ts +118 -0
- package/providers/competition.types.d.ts.map +1 -0
- package/providers/fansunited-config.context.d.ts +6 -0
- package/providers/fansunited-config.context.d.ts.map +1 -0
- package/providers/fansunited-config.hooks.d.ts +19 -0
- package/providers/fansunited-config.hooks.d.ts.map +1 -0
- package/providers/fansunited-config.provider.d.ts +44 -0
- package/providers/fansunited-config.provider.d.ts.map +1 -0
- package/providers/fansunited-config.types.d.ts +48 -0
- package/providers/fansunited-config.types.d.ts.map +1 -0
- package/providers/fansunited-sdk.hook.d.ts +40 -0
- package/providers/fansunited-sdk.hook.d.ts.map +1 -0
- package/providers/index.d.ts +20 -0
- package/providers/index.d.ts.map +1 -0
- package/providers/match/hooks/useEventHelpers.d.ts +12 -0
- package/providers/match/hooks/useEventHelpers.d.ts.map +1 -0
- package/providers/match/hooks/useHeadToHeadHelpers.d.ts +13 -0
- package/providers/match/hooks/useHeadToHeadHelpers.d.ts.map +1 -0
- package/providers/match/hooks/useLineupHelpers.d.ts +13 -0
- package/providers/match/hooks/useLineupHelpers.d.ts.map +1 -0
- package/providers/match/hooks/useMatchStandingsCalculations.d.ts +20 -0
- package/providers/match/hooks/useMatchStandingsCalculations.d.ts.map +1 -0
- package/providers/match/hooks/useMatchStatus.d.ts +12 -0
- package/providers/match/hooks/useMatchStatus.d.ts.map +1 -0
- package/providers/match/hooks/useOddsHelpers.d.ts +10 -0
- package/providers/match/hooks/useOddsHelpers.d.ts.map +1 -0
- package/providers/match/hooks/useScoreHelpers.d.ts +16 -0
- package/providers/match/hooks/useScoreHelpers.d.ts.map +1 -0
- package/providers/match/hooks/useStandingsHelpers.d.ts +22 -0
- package/providers/match/hooks/useStandingsHelpers.d.ts.map +1 -0
- package/providers/match/hooks/useStatisticsHelpers.d.ts +13 -0
- package/providers/match/hooks/useStatisticsHelpers.d.ts.map +1 -0
- package/providers/match/hooks/useTeamHelpers.d.ts +11 -0
- package/providers/match/hooks/useTeamHelpers.d.ts.map +1 -0
- package/providers/match/hooks/useTeamStatsHelpers.d.ts +12 -0
- package/providers/match/hooks/useTeamStatsHelpers.d.ts.map +1 -0
- package/providers/match.context.d.ts +8 -0
- package/providers/match.context.d.ts.map +1 -0
- package/providers/match.provider.d.ts +3 -0
- package/providers/match.provider.d.ts.map +1 -0
- package/providers/match.types.d.ts +151 -0
- package/providers/match.types.d.ts.map +1 -0
- package/providers/team/hooks/useFormStats.d.ts +49 -0
- package/providers/team/hooks/useFormStats.d.ts.map +1 -0
- package/providers/team/hooks/useMatchHelpers.d.ts +12 -0
- package/providers/team/hooks/useMatchHelpers.d.ts.map +1 -0
- package/providers/team/hooks/useSquadHelpers.d.ts +17 -0
- package/providers/team/hooks/useSquadHelpers.d.ts.map +1 -0
- package/providers/team.context.d.ts +8 -0
- package/providers/team.context.d.ts.map +1 -0
- package/providers/team.provider.d.ts +3 -0
- package/providers/team.provider.d.ts.map +1 -0
- package/providers/team.types.d.ts +68 -0
- package/providers/team.types.d.ts.map +1 -0
- package/types/canonical/base.types.d.ts +366 -0
- package/types/canonical/base.types.d.ts.map +1 -0
- package/types/canonical/commentary.types.d.ts +42 -0
- package/types/canonical/commentary.types.d.ts.map +1 -0
- package/types/canonical/event.types.d.ts +31 -0
- package/types/canonical/event.types.d.ts.map +1 -0
- package/types/canonical/index.d.ts +17 -0
- package/types/canonical/index.d.ts.map +1 -0
- package/types/canonical/lineup.types.d.ts +33 -0
- package/types/canonical/lineup.types.d.ts.map +1 -0
- package/types/canonical/match.types.d.ts +153 -0
- package/types/canonical/match.types.d.ts.map +1 -0
- package/types/canonical/odds.types.d.ts +73 -0
- package/types/canonical/odds.types.d.ts.map +1 -0
- package/types/canonical/search.types.d.ts +101 -0
- package/types/canonical/search.types.d.ts.map +1 -0
- package/types/canonical/sports-search.types.d.ts +151 -0
- package/types/canonical/sports-search.types.d.ts.map +1 -0
- package/types/canonical/squad.types.d.ts +30 -0
- package/types/canonical/squad.types.d.ts.map +1 -0
- package/types/canonical/standing.types.d.ts +85 -0
- package/types/canonical/standing.types.d.ts.map +1 -0
- package/types/canonical/statistics.types.d.ts +81 -0
- package/types/canonical/statistics.types.d.ts.map +1 -0
- package/types/index.d.ts +10 -0
- package/types/index.d.ts.map +1 -0
- package/utilities/stats/core/helpers.d.ts +65 -0
- package/utilities/stats/core/helpers.d.ts.map +1 -0
- package/utilities/stats/core/index.d.ts +7 -0
- package/utilities/stats/core/index.d.ts.map +1 -0
- package/utilities/stats/core/types.d.ts +39 -0
- package/utilities/stats/core/types.d.ts.map +1 -0
- package/utilities/stats/index.d.ts +27 -0
- package/utilities/stats/index.d.ts.map +1 -0
- package/utilities/stats/match/headToHead.d.ts +73 -0
- package/utilities/stats/match/headToHead.d.ts.map +1 -0
- package/utilities/stats/match/homeVsAway.d.ts +30 -0
- package/utilities/stats/match/homeVsAway.d.ts.map +1 -0
- package/utilities/stats/match/index.d.ts +8 -0
- package/utilities/stats/match/index.d.ts.map +1 -0
- package/utilities/stats/match/overUnder.d.ts +59 -0
- package/utilities/stats/match/overUnder.d.ts.map +1 -0
- package/utilities/stats/match/result.d.ts +13 -0
- package/utilities/stats/match/result.d.ts.map +1 -0
- package/utilities/stats/team/commonOpponents.d.ts +28 -0
- package/utilities/stats/team/commonOpponents.d.ts.map +1 -0
- package/utilities/stats/team/goalStats.d.ts +42 -0
- package/utilities/stats/team/goalStats.d.ts.map +1 -0
- package/utilities/stats/team/index.d.ts +7 -0
- package/utilities/stats/team/index.d.ts.map +1 -0
- package/utilities/stats/team/streaks.d.ts +48 -0
- package/utilities/stats/team/streaks.d.ts.map +1 -0
- package/vite.svg +1 -0
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Match options types for Sportal365 Sports API
|
|
3
|
+
*/
|
|
4
|
+
import type { NextCacheOptions } from "../../../http";
|
|
5
|
+
export type OddType = "LIVE" | "PRE_EVENT" | "ALL";
|
|
6
|
+
export type ScopeType = "ORDINARY_TIME" | "FULL_TIME";
|
|
7
|
+
export type OddFormat = "FRACTIONAL" | "DECIMAL" | "MONEYLINE";
|
|
8
|
+
export type MarketType = "1x2" | "12" | "OVER_UNDER" | "DOUBLE_CHANCE" | "BOTH_TO_SCORE" | "DRAW_NO_BET" | "FIRST_TEAM_TO_SCORE" | "CORRECT_SCORE" | "FIRST_HALF_GOALS" | "FIRST_PLAYER_TO_SCORE" | "PLAYER_TO_SCORE_DURING_GAME" | "PLAYER_TO_RECEIVE_CARD" | "FIRST_HALF_AND_FINAL_RESULT";
|
|
9
|
+
export type OptionalMatchData = "MAIN_EVENTS" | "LINEUP_STATUS";
|
|
10
|
+
export interface GetFootballMatchOptions {
|
|
11
|
+
/** Language code for translations (e.g., 'en', 'bg'). Defaults to 'en' */
|
|
12
|
+
languageCode?: string;
|
|
13
|
+
/** Filter matches by odd client */
|
|
14
|
+
oddClient?: string;
|
|
15
|
+
/** Type of odds to include. Defaults to 'ALL' */
|
|
16
|
+
oddType?: OddType;
|
|
17
|
+
/** Scope type for odds. Defaults to 'ORDINARY_TIME' */
|
|
18
|
+
scopeType?: ScopeType;
|
|
19
|
+
/** Format of odds */
|
|
20
|
+
oddFormat?: OddFormat;
|
|
21
|
+
/** Market types to include */
|
|
22
|
+
marketTypes?: MarketType[];
|
|
23
|
+
/** Optional data to include in response */
|
|
24
|
+
optionalData?: OptionalMatchData[];
|
|
25
|
+
/** Filter odds by bookmaker IDs */
|
|
26
|
+
bookmakerIds?: string[];
|
|
27
|
+
/** Next.js cache options for ISR/on-demand revalidation */
|
|
28
|
+
next?: NextCacheOptions;
|
|
29
|
+
}
|
|
30
|
+
export interface GetFootballMatchEventsOptions {
|
|
31
|
+
/** Language code for translations. Defaults to 'en' */
|
|
32
|
+
languageCode?: string;
|
|
33
|
+
/** Next.js cache options for ISR/on-demand revalidation */
|
|
34
|
+
next?: NextCacheOptions;
|
|
35
|
+
}
|
|
36
|
+
export interface GetFootballMatchLineupsOptions {
|
|
37
|
+
/** Language code for translations. Defaults to 'en' */
|
|
38
|
+
languageCode?: string;
|
|
39
|
+
/** Next.js cache options for ISR/on-demand revalidation */
|
|
40
|
+
next?: NextCacheOptions;
|
|
41
|
+
}
|
|
42
|
+
export interface GetFootballMatchOddsOptions {
|
|
43
|
+
/** Language code for translations. Defaults to 'en' */
|
|
44
|
+
languageCode?: string;
|
|
45
|
+
/** Filter by odd client */
|
|
46
|
+
oddClient?: string;
|
|
47
|
+
/** Type of odds to include */
|
|
48
|
+
oddType?: OddType;
|
|
49
|
+
/** Scope type for odds */
|
|
50
|
+
scopeType?: ScopeType;
|
|
51
|
+
/** Format of odds */
|
|
52
|
+
oddFormat?: OddFormat;
|
|
53
|
+
/** Market types to include */
|
|
54
|
+
marketTypes?: MarketType[];
|
|
55
|
+
/** Filter odds by bookmaker IDs */
|
|
56
|
+
bookmakerIds?: string[];
|
|
57
|
+
/** Next.js cache options for ISR/on-demand revalidation */
|
|
58
|
+
next?: NextCacheOptions;
|
|
59
|
+
}
|
|
60
|
+
export interface GetFootballMatchStatisticsOptions {
|
|
61
|
+
/** Language code for translations. Defaults to 'en' */
|
|
62
|
+
languageCode?: string;
|
|
63
|
+
/** Next.js cache options for ISR/on-demand revalidation */
|
|
64
|
+
next?: NextCacheOptions;
|
|
65
|
+
}
|
|
66
|
+
/** Status types for filtering matches */
|
|
67
|
+
export type MatchStatusType = "FINISHED" | "NOT_STARTED" | "LIVE" | "INTERRUPTED" | "CANCELLED" | "UNKNOWN" | "POSTPONED";
|
|
68
|
+
/** Sort direction for matches */
|
|
69
|
+
export type SortDirection = "asc" | "desc";
|
|
70
|
+
/**
|
|
71
|
+
* Options for fetching multiple football matches
|
|
72
|
+
*/
|
|
73
|
+
export interface GetFootballMatchesOptions {
|
|
74
|
+
/** Language code for translations (e.g., 'en', 'bg'). Defaults to 'en' */
|
|
75
|
+
languageCode?: string;
|
|
76
|
+
/** Maximum number of matches to return */
|
|
77
|
+
limit: number;
|
|
78
|
+
/** Offset for pagination */
|
|
79
|
+
offset: number;
|
|
80
|
+
/** Filter by tournament IDs */
|
|
81
|
+
tournamentIds?: string[];
|
|
82
|
+
/** Filter by season IDs */
|
|
83
|
+
seasonIds?: string[];
|
|
84
|
+
/** Filter by stage IDs */
|
|
85
|
+
stageIds?: string[];
|
|
86
|
+
/** Filter by group IDs */
|
|
87
|
+
groupIds?: string[];
|
|
88
|
+
/** Filter by round IDs */
|
|
89
|
+
roundIds?: string[];
|
|
90
|
+
/** Filter by stage:round combinations (format: "stageId:roundId") */
|
|
91
|
+
roundFilter?: string[];
|
|
92
|
+
/** Filter matches from this kickoff time (ISO 8601 format) */
|
|
93
|
+
fromKickoffTime?: string;
|
|
94
|
+
/** Filter matches until this kickoff time (ISO 8601 format) */
|
|
95
|
+
toKickoffTime?: string;
|
|
96
|
+
/** Filter by team IDs */
|
|
97
|
+
teamIds?: string[];
|
|
98
|
+
/** Operator for teamIds filter ('AND' or 'OR'). Defaults to 'AND' */
|
|
99
|
+
teamIdsOperator?: "AND" | "OR";
|
|
100
|
+
/** Filter by referee ID */
|
|
101
|
+
refereeId?: string;
|
|
102
|
+
/** Filter by venue ID */
|
|
103
|
+
venueId?: string;
|
|
104
|
+
/** Filter by player ID */
|
|
105
|
+
playerId?: string;
|
|
106
|
+
/** Filter by status types (e.g., 'FINISHED', 'LIVE') */
|
|
107
|
+
statusTypes?: MatchStatusType[];
|
|
108
|
+
/** Filter by status codes */
|
|
109
|
+
statusCodes?: string[];
|
|
110
|
+
/** Filter by odd client */
|
|
111
|
+
oddClient?: string;
|
|
112
|
+
/** Type of odds to include */
|
|
113
|
+
oddType?: OddType;
|
|
114
|
+
/** Scope type for odds */
|
|
115
|
+
scopeType?: ScopeType;
|
|
116
|
+
/** Format of odds */
|
|
117
|
+
oddFormat?: OddFormat;
|
|
118
|
+
/** Market types to include */
|
|
119
|
+
marketTypes?: MarketType[];
|
|
120
|
+
/** Filter odds by bookmaker IDs */
|
|
121
|
+
bookmakerIds?: string[];
|
|
122
|
+
/** Sort direction by kickoff time */
|
|
123
|
+
sortDirection?: SortDirection;
|
|
124
|
+
/** Optional data to include ('MAIN_EVENTS') */
|
|
125
|
+
optionalData?: "MAIN_EVENTS"[];
|
|
126
|
+
/** Next.js cache options for ISR/on-demand revalidation */
|
|
127
|
+
next?: NextCacheOptions;
|
|
128
|
+
}
|
|
129
|
+
//# sourceMappingURL=option.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"option.types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/api/sportal365-sports/football/matches/types/option.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAEtD,MAAM,MAAM,OAAO,GAAG,MAAM,GAAG,WAAW,GAAG,KAAK,CAAC;AACnD,MAAM,MAAM,SAAS,GAAG,eAAe,GAAG,WAAW,CAAC;AACtD,MAAM,MAAM,SAAS,GAAG,YAAY,GAAG,SAAS,GAAG,WAAW,CAAC;AAC/D,MAAM,MAAM,UAAU,GAChB,KAAK,GACL,IAAI,GACJ,YAAY,GACZ,eAAe,GACf,eAAe,GACf,aAAa,GACb,qBAAqB,GACrB,eAAe,GACf,kBAAkB,GAClB,uBAAuB,GACvB,6BAA6B,GAC7B,wBAAwB,GACxB,6BAA6B,CAAC;AACpC,MAAM,MAAM,iBAAiB,GAAG,aAAa,GAAG,eAAe,CAAC;AAEhE,MAAM,WAAW,uBAAuB;IACpC,0EAA0E;IAC1E,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mCAAmC;IACnC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iDAAiD;IACjD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,uDAAuD;IACvD,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,qBAAqB;IACrB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,8BAA8B;IAC9B,WAAW,CAAC,EAAE,UAAU,EAAE,CAAC;IAC3B,2CAA2C;IAC3C,YAAY,CAAC,EAAE,iBAAiB,EAAE,CAAC;IACnC,mCAAmC;IACnC,YAAY,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ACnC,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IAGxB,qCAAqC;IACrC,aAAa,CAAC,EAAE,aAAa,CAAC;IAG9B,+CAA+C;IAC/C,YAAY,CAAC,EAAE,aAAa,EAAE,CAAC;IAE/B,2DAA2D;IAC3D,IAAI,CAAC,EAAE,gBAAgB,CAAC;CAC3B"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Match referee types for Sportal365 Sports API
|
|
3
|
+
*/
|
|
4
|
+
import type { RawAssets } from "../../../shared/types";
|
|
5
|
+
export interface RawMatchReferee {
|
|
6
|
+
id: string;
|
|
7
|
+
name: string;
|
|
8
|
+
slug: string;
|
|
9
|
+
role?: "REFEREE";
|
|
10
|
+
gender?: "MALE" | "FEMALE";
|
|
11
|
+
assets?: RawAssets | null;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=referee.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"referee.types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/api/sportal365-sports/football/matches/types/referee.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAEvD,MAAM,WAAW,eAAe;IAC5B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,GAAG,QAAQ,CAAC;IAC3B,MAAM,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC;CAC7B"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Team statistics types for Sportal365 Sports API
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Statistics object nested inside each team's data
|
|
6
|
+
*/
|
|
7
|
+
export interface RawStatisticsData {
|
|
8
|
+
pass?: number;
|
|
9
|
+
possession?: number;
|
|
10
|
+
goals?: number;
|
|
11
|
+
corners?: number;
|
|
12
|
+
crosses?: number;
|
|
13
|
+
offside?: number;
|
|
14
|
+
shots_on?: number;
|
|
15
|
+
shots_blocked?: number;
|
|
16
|
+
shots_off?: number;
|
|
17
|
+
throw_in?: number;
|
|
18
|
+
goal_kicks?: number;
|
|
19
|
+
treatments?: number;
|
|
20
|
+
yellow_cards?: number;
|
|
21
|
+
substitutions?: number;
|
|
22
|
+
counter_attacks?: number;
|
|
23
|
+
fouls_committed?: number;
|
|
24
|
+
[key: string]: unknown;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Single team statistics entry from the API array
|
|
28
|
+
*/
|
|
29
|
+
export interface RawTeamStatisticsEntry {
|
|
30
|
+
team: {
|
|
31
|
+
id: number | string;
|
|
32
|
+
name: string;
|
|
33
|
+
slug?: string;
|
|
34
|
+
[key: string]: unknown;
|
|
35
|
+
};
|
|
36
|
+
home_team: boolean;
|
|
37
|
+
statistics: RawStatisticsData;
|
|
38
|
+
event_id: number;
|
|
39
|
+
[key: string]: unknown;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* The API returns an array of team statistics entries
|
|
43
|
+
*/
|
|
44
|
+
export type RawMatchStatisticsResponse = RawTeamStatisticsEntry[];
|
|
45
|
+
//# sourceMappingURL=statistics.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"statistics.types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/api/sportal365-sports/football/matches/types/statistics.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACnC,IAAI,EAAE;QACF,EAAE,EAAE,MAAM,GAAG,MAAM,CAAC;QACpB,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;KAC1B,CAAC;IACF,SAAS,EAAE,OAAO,CAAC;IACnB,UAAU,EAAE,iBAAiB,CAAC;IAC9B,QAAQ,EAAE,MAAM,CAAC;IACjB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,MAAM,0BAA0B,GAAG,sBAAsB,EAAE,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Match status types for Sportal365 Sports API
|
|
3
|
+
*/
|
|
4
|
+
export type RawMatchStatusType = "FINISHED" | "NOT_STARTED" | "LIVE" | "INTERRUPTED" | "CANCELLED" | "UNKNOWN" | "POSTPONED";
|
|
5
|
+
export interface RawMatchStatus {
|
|
6
|
+
id: string;
|
|
7
|
+
name: string;
|
|
8
|
+
short_name: string;
|
|
9
|
+
type: RawMatchStatusType;
|
|
10
|
+
code?: string;
|
|
11
|
+
uuid?: string;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=status.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status.types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/api/sportal365-sports/football/matches/types/status.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,MAAM,kBAAkB,GACxB,UAAU,GACV,aAAa,GACb,MAAM,GACN,aAAa,GACb,WAAW,GACX,SAAS,GACT,WAAW,CAAC;AAElB,MAAM,WAAW,cAAc;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,kBAAkB,CAAC;IACzB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Match team types for Sportal365 Sports API
|
|
3
|
+
*/
|
|
4
|
+
import type { RawAssets } from "../../../shared/types";
|
|
5
|
+
export interface RawMatchTeam {
|
|
6
|
+
id: string;
|
|
7
|
+
name: string;
|
|
8
|
+
slug: string;
|
|
9
|
+
three_letter_code?: string;
|
|
10
|
+
gender?: string;
|
|
11
|
+
short_name?: string | null;
|
|
12
|
+
type?: "placeholder" | "national" | "club";
|
|
13
|
+
shirt_color?: string;
|
|
14
|
+
assets?: RawAssets | null;
|
|
15
|
+
uuid?: string;
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=team.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"team.types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/api/sportal365-sports/football/matches/types/team.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAEvD,MAAM,WAAW,YAAY;IACzB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,IAAI,CAAC,EAAE,aAAa,GAAG,UAAU,GAAG,MAAM,CAAC;IAC3C,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Match winner types for Sportal365 Sports API
|
|
3
|
+
*/
|
|
4
|
+
export interface RawMatchWinnerReason {
|
|
5
|
+
name: string;
|
|
6
|
+
}
|
|
7
|
+
export interface RawMatchOrAggregateWinner {
|
|
8
|
+
id: string;
|
|
9
|
+
reason?: RawMatchWinnerReason;
|
|
10
|
+
}
|
|
11
|
+
export interface RawMatchWinner {
|
|
12
|
+
match?: RawMatchOrAggregateWinner;
|
|
13
|
+
aggregate?: RawMatchOrAggregateWinner;
|
|
14
|
+
}
|
|
15
|
+
//# sourceMappingURL=winner.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"winner.types.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/api/sportal365-sports/football/matches/types/winner.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,MAAM,WAAW,oBAAoB;IACjC,IAAI,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,yBAAyB;IACtC,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,CAAC,EAAE,oBAAoB,CAAC;CACjC;AAED,MAAM,WAAW,cAAc;IAC3B,KAAK,CAAC,EAAE,yBAAyB,CAAC;IAClC,SAAS,CAAC,EAAE,yBAAyB,CAAC;CACzC"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Football search endpoints for Sportal365 API
|
|
3
|
+
*/
|
|
4
|
+
import type { FUSportsSearchResults } from "../../../../types/canonical/search.types";
|
|
5
|
+
import { type DataLayerConfig } from "../../../../config";
|
|
6
|
+
import type { GetFootballSearchOptions } from "./search.types";
|
|
7
|
+
export type { GetFootballSearchOptions, SearchEntityType } from "./search.types";
|
|
8
|
+
/**
|
|
9
|
+
* Search for football entities (tournaments, players, teams, presidents, venues, coaches)
|
|
10
|
+
*
|
|
11
|
+
* Returns empty results if no query is provided or no results are found.
|
|
12
|
+
* If no entity types are specified, all types are included in the search.
|
|
13
|
+
*
|
|
14
|
+
* @param options - Search options including query and optional entity types
|
|
15
|
+
* @param config - Optional data layer config (uses singleton if not provided)
|
|
16
|
+
* @returns Search results with canonical FUSports types
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* ```typescript
|
|
20
|
+
* // Search for all entity types
|
|
21
|
+
* const results = await searchFootball({ query: 'lionel' });
|
|
22
|
+
* console.log(`Found ${results.results.length} results`);
|
|
23
|
+
*
|
|
24
|
+
* // Search only for players and teams
|
|
25
|
+
* const results = await searchFootball({
|
|
26
|
+
* query: 'messi',
|
|
27
|
+
* entityTypes: ['player', 'team']
|
|
28
|
+
* });
|
|
29
|
+
*
|
|
30
|
+
* // Handle results by entity type
|
|
31
|
+
* results.results.forEach(result => {
|
|
32
|
+
* switch (result.entityType) {
|
|
33
|
+
* case 'player':
|
|
34
|
+
* console.log(`Player: ${result.name} (${result.position})`);
|
|
35
|
+
* break;
|
|
36
|
+
* case 'team':
|
|
37
|
+
* console.log(`Team: ${result.name} (${result.threeLetterCode})`);
|
|
38
|
+
* break;
|
|
39
|
+
* // ... handle other types
|
|
40
|
+
* }
|
|
41
|
+
* });
|
|
42
|
+
* ```
|
|
43
|
+
*/
|
|
44
|
+
export declare function searchFootball(options: GetFootballSearchOptions, config?: DataLayerConfig): Promise<FUSportsSearchResults>;
|
|
45
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/api/sportal365-sports/football/search/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,0CAA0C,CAAC;AACtF,OAAO,EAAa,KAAK,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErE,OAAO,KAAK,EAAE,wBAAwB,EAAqB,MAAM,gBAAgB,CAAC;AAIlF,YAAY,EAAE,wBAAwB,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAEjF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,wBAAsB,cAAc,CAChC,OAAO,EAAE,wBAAwB,EACjC,MAAM,CAAC,EAAE,eAAe,GACzB,OAAO,CAAC,qBAAqB,CAAC,CAgDhC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Transform raw search results to canonical FUSports types
|
|
3
|
+
*/
|
|
4
|
+
import type { FUSportsSearchResult } from "../../../../types/canonical/search.types";
|
|
5
|
+
import type { RawSearchResult } from "./search.types";
|
|
6
|
+
/**
|
|
7
|
+
* Transform raw search result to canonical type
|
|
8
|
+
*/
|
|
9
|
+
export declare function transformSearchResult(raw: RawSearchResult): FUSportsSearchResult;
|
|
10
|
+
//# sourceMappingURL=search.transformer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search.transformer.d.ts","sourceRoot":"","sources":["../../../../../src/lib/api/sportal365-sports/football/search/search.transformer.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EACR,oBAAoB,EAOvB,MAAM,0CAA0C,CAAC;AAClD,OAAO,KAAK,EACR,eAAe,EAOlB,MAAM,gBAAgB,CAAC;AAsLxB;;GAEG;AACH,wBAAgB,qBAAqB,CAAC,GAAG,EAAE,eAAe,GAAG,oBAAoB,CAkBhF"}
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Football search types for Sportal365 API
|
|
3
|
+
*/
|
|
4
|
+
import type { NextCacheOptions } from "../../http";
|
|
5
|
+
/**
|
|
6
|
+
* Entity types that can be searched
|
|
7
|
+
*/
|
|
8
|
+
export type SearchEntityType = "tournament" | "player" | "team" | "president" | "venue" | "coach";
|
|
9
|
+
/**
|
|
10
|
+
* Options for football search
|
|
11
|
+
*/
|
|
12
|
+
export interface GetFootballSearchOptions {
|
|
13
|
+
/** Search query string (required) */
|
|
14
|
+
query: string;
|
|
15
|
+
/** Entity types to search for (if not provided, all types are included) */
|
|
16
|
+
entityTypes?: SearchEntityType[];
|
|
17
|
+
/** Language code for localized results */
|
|
18
|
+
languageCode?: string;
|
|
19
|
+
/** Next.js cache options for ISR/on-demand revalidation */
|
|
20
|
+
next?: NextCacheOptions;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Raw country in search results
|
|
24
|
+
*/
|
|
25
|
+
export interface RawSearchCountry {
|
|
26
|
+
id: number;
|
|
27
|
+
uuid: string;
|
|
28
|
+
name: string;
|
|
29
|
+
url_flag: string | null;
|
|
30
|
+
slug: string;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Raw city in search results
|
|
34
|
+
*/
|
|
35
|
+
export interface RawSearchCity {
|
|
36
|
+
id: number;
|
|
37
|
+
uuid: string;
|
|
38
|
+
name: string;
|
|
39
|
+
country: RawSearchCountry;
|
|
40
|
+
slug: string;
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Raw venue profile in search results
|
|
44
|
+
*/
|
|
45
|
+
export interface RawSearchVenueProfile {
|
|
46
|
+
lat: number;
|
|
47
|
+
lng: number;
|
|
48
|
+
capacity: number;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Raw tournament search result
|
|
52
|
+
*/
|
|
53
|
+
export interface RawSearchTournament {
|
|
54
|
+
id: number;
|
|
55
|
+
name: string;
|
|
56
|
+
slug: string;
|
|
57
|
+
country: RawSearchCountry;
|
|
58
|
+
gender: "MALE" | "FEMALE";
|
|
59
|
+
type: "LEAGUE" | "CUP";
|
|
60
|
+
region: "DOMESTIC" | "INTERNATIONAL";
|
|
61
|
+
url_logo: string | null;
|
|
62
|
+
uuid: string;
|
|
63
|
+
entity_type: "tournament";
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Raw player search result
|
|
67
|
+
*/
|
|
68
|
+
export interface RawSearchPlayer {
|
|
69
|
+
id: number;
|
|
70
|
+
name: string;
|
|
71
|
+
slug: string;
|
|
72
|
+
position: string;
|
|
73
|
+
gender: "MALE" | "FEMALE";
|
|
74
|
+
country: RawSearchCountry;
|
|
75
|
+
birthdate: string;
|
|
76
|
+
url_thumb: string | null;
|
|
77
|
+
uuid: string;
|
|
78
|
+
entity_type: "player";
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Raw team search result
|
|
82
|
+
*/
|
|
83
|
+
export interface RawSearchTeam {
|
|
84
|
+
id: number;
|
|
85
|
+
name: string;
|
|
86
|
+
slug: string;
|
|
87
|
+
short_name: string | null;
|
|
88
|
+
three_letter_code: string | null;
|
|
89
|
+
type: "club" | "national" | "placeholder";
|
|
90
|
+
gender: "MALE" | "FEMALE";
|
|
91
|
+
country: RawSearchCountry;
|
|
92
|
+
venue: unknown | null;
|
|
93
|
+
url_logo: string | null;
|
|
94
|
+
national: boolean;
|
|
95
|
+
undecided: boolean;
|
|
96
|
+
uuid: string;
|
|
97
|
+
entity_type: "team";
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* Raw president search result
|
|
101
|
+
*/
|
|
102
|
+
export interface RawSearchPresident {
|
|
103
|
+
id: number;
|
|
104
|
+
name: string;
|
|
105
|
+
slug: string;
|
|
106
|
+
country: RawSearchCountry;
|
|
107
|
+
birthdate: string | null;
|
|
108
|
+
url_thumb: string | null;
|
|
109
|
+
uuid: string;
|
|
110
|
+
entity_type: "president";
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Raw venue search result
|
|
114
|
+
*/
|
|
115
|
+
export interface RawSearchVenue {
|
|
116
|
+
id: number;
|
|
117
|
+
name: string;
|
|
118
|
+
slug: string;
|
|
119
|
+
country: RawSearchCountry;
|
|
120
|
+
city: RawSearchCity;
|
|
121
|
+
profile: RawSearchVenueProfile;
|
|
122
|
+
url_thumb: string | null;
|
|
123
|
+
uuid: string;
|
|
124
|
+
entity_type: "venue";
|
|
125
|
+
}
|
|
126
|
+
/**
|
|
127
|
+
* Raw coach search result
|
|
128
|
+
*/
|
|
129
|
+
export interface RawSearchCoach {
|
|
130
|
+
id: number;
|
|
131
|
+
name: string;
|
|
132
|
+
slug: string;
|
|
133
|
+
country: RawSearchCountry;
|
|
134
|
+
birthdate: string | null;
|
|
135
|
+
url_thumb: string | null;
|
|
136
|
+
uuid: string;
|
|
137
|
+
entity_type: "coach";
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* Union type for all search result types
|
|
141
|
+
*/
|
|
142
|
+
export type RawSearchResult = RawSearchTournament | RawSearchPlayer | RawSearchTeam | RawSearchPresident | RawSearchVenue | RawSearchCoach;
|
|
143
|
+
/**
|
|
144
|
+
* Raw search response from API
|
|
145
|
+
*/
|
|
146
|
+
export type RawSearchResponse = RawSearchResult[];
|
|
147
|
+
//# sourceMappingURL=search.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search.types.d.ts","sourceRoot":"","sources":["../../../../../src/lib/api/sportal365-sports/football/search/search.types.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAEnD;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG,YAAY,GAAG,QAAQ,GAAG,MAAM,GAAG,WAAW,GAAG,OAAO,GAAG,OAAO,CAAC;AAElG;;GAEG;AACH,MAAM,WAAW,wB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,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,gBAAgB,CAAC;IAC1B,IAAI,EAAE,aAAa,CAAC;IACpB,OAAO,EAAE,qBAAqB,CAAC;IAC/B,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,OAAO,CAAC;CACxB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,gBAAgB,CAAC;IAC1B,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,OAAO,CAAC;CACxB;AAED;;GAEG;AACH,MAAM,MAAM,eAAe,GACrB,mBAAmB,GACnB,eAAe,GACf,aAAa,GACb,kBAAkB,GAClB,cAAc,GACd,cAAc,CAAC;AAErB;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG,eAAe,EAAE,CAAC"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Sportal365 Sports API - Football Standings
|
|
3
|
+
*
|
|
4
|
+
* Fetches standings data from the Football API and transforms to canonical FUSports types.
|
|
5
|
+
*/
|
|
6
|
+
import type { FUSportsStandings } from "../../../../types/canonical";
|
|
7
|
+
import { type DataLayerConfig } from "../../../../config";
|
|
8
|
+
import type { GetFootballStandingsOptions } from "./standing.types";
|
|
9
|
+
export type { RawFootballStandingTeam, RawFootballEventStatus, RawFootballFormEvent, RawFootballFormEntry, RawFootballStandingRule, RawFootballStandingEntry, RawFootballStandingsResponse, GetFootballStandingsOptions, FootballStandingsExpandOption, } from "./standing.types";
|
|
10
|
+
/**
|
|
11
|
+
* Get football standings for a stage
|
|
12
|
+
*
|
|
13
|
+
* @param options - Options including stageId (required), languageCode, and expand options
|
|
14
|
+
* @param config - Optional data layer config (uses singleton if not provided)
|
|
15
|
+
* @returns FUSportsStandings object with entries and metadata (including legend)
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* ```typescript
|
|
19
|
+
* // Get all standings with form data
|
|
20
|
+
* const standings = await getFootballStandings({
|
|
21
|
+
* stageId: '8009708',
|
|
22
|
+
* expand: ['rules', 'form.events']
|
|
23
|
+
* });
|
|
24
|
+
*
|
|
25
|
+
* // Get standings in a specific language
|
|
26
|
+
* const standingsBg = await getFootballStandings({
|
|
27
|
+
* stageId: '8009708',
|
|
28
|
+
* languageCode: 'bg'
|
|
29
|
+
* });
|
|
30
|
+
*
|
|
31
|
+
* // Access entries and metadata
|
|
32
|
+
* standings.entries.forEach(entry => {
|
|
33
|
+
* console.log(`${entry.rank}. ${entry.competitor.name} - ${entry.stats.points} pts`);
|
|
34
|
+
* });
|
|
35
|
+
*
|
|
36
|
+
* // Access legend for rules/zones
|
|
37
|
+
* standings.metadata.legend.forEach(item => {
|
|
38
|
+
* console.log(`${item.name} (${item.position})`);
|
|
39
|
+
* });
|
|
40
|
+
* ```
|
|
41
|
+
*/
|
|
42
|
+
export declare function getFootballStandings(options: GetFootballStandingsOptions, config?: DataLayerConfig): Promise<FUSportsStandings>;
|
|
43
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/api/sportal365-sports/football/standings/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AACrE,OAAO,EAAa,KAAK,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErE,OAAO,KAAK,EAAgC,2BAA2B,EAAE,MAAM,kBAAkB,CAAC;AAIlG,YAAY,EACR,uBAAuB,EACvB,sBAAsB,EACtB,oBAAoB,EACpB,oBAAoB,EACpB,uBAAuB,EACvB,wBAAwB,EACxB,4BAA4B,EAC5B,2BAA2B,EAC3B,6BAA6B,GAChC,MAAM,kBAAkB,CAAC;AAE1B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,wBAAsB,oBAAoB,CACtC,OAAO,EAAE,2BAA2B,EACpC,MAAM,CAAC,EAAE,eAAe,GACzB,OAAO,CAAC,iBAAiB,CAAC,CA0B5B"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Football API Standings Transformer
|
|
3
|
+
* Converts raw Football API standings to canonical FUSports types
|
|
4
|
+
*/
|
|
5
|
+
import type { FUSportsStandingEntry, FUSportsStandings } from "../../../../types/canonical";
|
|
6
|
+
import type { RawFootballStandingEntry } from "./standing.types";
|
|
7
|
+
/**
|
|
8
|
+
* Transform a single Football API standing entry to canonical format
|
|
9
|
+
*/
|
|
10
|
+
export declare function transformStandingEntry(raw: RawFootballStandingEntry): FUSportsStandingEntry;
|
|
11
|
+
/**
|
|
12
|
+
* Transform Football API standing entries to canonical standings with legend
|
|
13
|
+
*/
|
|
14
|
+
export declare function transformStandings(rawEntries: RawFootballStandingEntry[]): FUSportsStandings;
|
|
15
|
+
//# sourceMappingURL=standing.transformer.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"standing.transformer.d.ts","sourceRoot":"","sources":["../../../../../src/lib/api/sportal365-sports/football/standings/standing.transformer.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAER,qBAAqB,EAErB,iBAAiB,EACpB,MAAM,6BAA6B,CAAC;AACrC,OAAO,KAAK,EAAE,wBAAwB,EAAiD,MAAM,kBAAkB,CAAC;AA4EhH;;GAEG;AACH,wBAAgB,sBAAsB,CAAC,GAAG,EAAE,wBAAwB,GAAG,qBAAqB,CA+B3F;AAED;;GAEG;AACH,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,wBAAwB,EAAE,GAAG,iBAAiB,CAuB5F"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Football API Standings Types
|
|
3
|
+
* Based on the Football API response structure from /tournaments/seasons/stages/{stageId}/standing
|
|
4
|
+
*/
|
|
5
|
+
import type { NextCacheOptions } from "../../http";
|
|
6
|
+
export interface RawFootballStandingTeam {
|
|
7
|
+
id: number;
|
|
8
|
+
name: string;
|
|
9
|
+
slug: string;
|
|
10
|
+
three_letter_code: string;
|
|
11
|
+
type: string;
|
|
12
|
+
gender: string;
|
|
13
|
+
short_name: string | null;
|
|
14
|
+
uuid: string;
|
|
15
|
+
url_logo: string;
|
|
16
|
+
form?: RawFootballFormEntry[];
|
|
17
|
+
}
|
|
18
|
+
export interface RawFootballEventStatus {
|
|
19
|
+
id: number;
|
|
20
|
+
name: string;
|
|
21
|
+
type: string;
|
|
22
|
+
code: string;
|
|
23
|
+
short_name: string;
|
|
24
|
+
uuid: string | null;
|
|
25
|
+
}
|
|
26
|
+
export interface RawFootballFormEvent {
|
|
27
|
+
id: number;
|
|
28
|
+
event_status: RawFootballEventStatus;
|
|
29
|
+
start_time: string;
|
|
30
|
+
home_team: RawFootballStandingTeam;
|
|
31
|
+
away_team: RawFootballStandingTeam;
|
|
32
|
+
round: string;
|
|
33
|
+
goal_home: number;
|
|
34
|
+
goal_away: number;
|
|
35
|
+
slug: string;
|
|
36
|
+
}
|
|
37
|
+
export interface RawFootballFormEntry {
|
|
38
|
+
outcome: "W" | "L" | "D";
|
|
39
|
+
event: RawFootballFormEvent;
|
|
40
|
+
}
|
|
41
|
+
export interface RawFootballStandingRule {
|
|
42
|
+
id: number;
|
|
43
|
+
code: string;
|
|
44
|
+
name: string;
|
|
45
|
+
type: string;
|
|
46
|
+
}
|
|
47
|
+
export interface RawFootballStandingEntry {
|
|
48
|
+
rank: number;
|
|
49
|
+
team: RawFootballStandingTeam;
|
|
50
|
+
played: number;
|
|
51
|
+
wins: number;
|
|
52
|
+
draws: number;
|
|
53
|
+
defeits: number;
|
|
54
|
+
goals_for: number;
|
|
55
|
+
goals_against: number;
|
|
56
|
+
points: number;
|
|
57
|
+
rules: RawFootballStandingRule[];
|
|
58
|
+
}
|
|
59
|
+
export type RawFootballStandingsResponse = RawFootballStandingEntry[];
|
|
60
|
+
/** Expand options for football API standings */
|
|
61
|
+
export type FootballStandingsExpandOption = "rules" | "form.events";
|
|
62
|
+
/** Options for fetching football standings */
|
|
63
|
+
export interface GetFootballStandingsOptions {
|
|
64
|
+
/** Stage ID (required) */
|
|
65
|
+
stageId: string;
|
|
66
|
+
/** Expand options to include additional data (e.g., "rules", "form.events") */
|
|
67
|
+
expand?: FootballStandingsExpandOption[];
|
|
68
|
+
/** Language code for the response (e.g., 'en', 'bg'). Falls back to config default if not provided */
|
|
69
|
+
languageCode?: string;
|
|
70
|
+
/** Next.js cache options for ISR/on-demand revalidation */
|
|
71
|
+
next?: NextCacheOptions;
|
|
72
|
+
}
|
|
73
|
+
//# sourceMappingURL=standing.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"standing.types.d.ts","sourceRoot":"","sources":["../../../../../src/lib/api/sportal365-sports/football/standings/standing.types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAMnD,MAAM,WAAW,uBAAuB;IACpC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,iBAAiB,EAAE,MAAM,CAAC;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,oBAAoB,EAAE,CAAC;CACjC;AAMD,MAAM,WAAW,sBAAsB;IACnC,EAA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