fansunited-sdk-esm 1.3.4 → 1.4.0
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/Core/Configurator/Enums/ValidationMessageEnum.d.ts +2 -2
- package/Core/Configurator/Models/SDKConfiguraitonModel.d.ts +4 -6
- package/Core/Configurator/Types/ConfiguratorTypes.d.ts +3 -0
- package/Core/Global/Interfaces/GlobalInterfaces.d.ts +3 -0
- package/Core/Global/Messages/Messages.d.ts +2 -1
- package/Core/Global/Types/GlobalTypes.d.ts +1 -0
- package/Core/Https/LoyaltyHttps.d.ts +4 -0
- package/Core/Https/PredictorHttps.d.ts +1 -0
- package/Core/Namespaces/Activity/Service/ActivityService.d.ts +2 -2
- package/Core/Namespaces/Football/Models/Player/PlayerMarketResultModel.d.ts +6 -0
- package/Core/Namespaces/Loyalty/Facade/LoyaltyFacade.d.ts +8 -1
- package/Core/Namespaces/Loyalty/Loyalty.d.ts +5 -0
- package/Core/Namespaces/Loyalty/Models/Filters/LoyaltyFilters.d.ts +5 -4
- package/Core/Namespaces/Loyalty/Models/Filters/RankingsFilters.d.ts +11 -0
- package/Core/Namespaces/Loyalty/Models/Leaderboard/LeaderboardRemapper.d.ts +3 -4
- package/Core/Namespaces/Loyalty/Models/Rankings/RankingsModel.d.ts +6 -0
- package/Core/Namespaces/Loyalty/Models/Rankings/RankingsRemapper.d.ts +6 -0
- package/Core/Namespaces/Loyalty/Service/LoyaltyService.d.ts +2 -0
- package/Core/Namespaces/Loyalty/Types/LoyaltyTypes.d.ts +2 -0
- package/Core/Namespaces/MatchQuiz/Facade/MatchQuizFacade.d.ts +2 -1
- package/Core/Namespaces/MatchQuiz/MatchQuiz.d.ts +2 -0
- package/Core/Namespaces/MatchQuiz/Models/GameMarketsResults/GameMarketsResults.d.ts +14 -0
- package/Core/Namespaces/Predictor/Enums/MarketEnum.d.ts +1 -0
- package/Core/Namespaces/Predictor/Service/PredictorService.d.ts +2 -0
- package/Core/Namespaces/TopX/Facade/TopXFacade.d.ts +2 -0
- package/Core/Namespaces/TopX/Models/Games/GamesRemapper.d.ts +6 -0
- package/Core/Namespaces/TopX/TopX.d.ts +2 -0
- package/index.js +14 -14
- package/index.js.map +3 -3
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare enum ValidationMessageEnum {
|
|
2
|
-
API_KEY = "The field apiKey with valid value must be provided to use
|
|
3
|
-
CLIENT_ID = "The field clientId must be provided to use
|
|
2
|
+
API_KEY = "The field apiKey with valid value must be provided to use Fans United JS SDK",
|
|
3
|
+
CLIENT_ID = "The field clientId must be provided to use Fans United JS SDK",
|
|
4
4
|
LANG_MISSING = "If no lang is passed the default one will be set which is: EN",
|
|
5
5
|
LANG_INVALID = "This lang value is not supported, the default one will be set which is: EN",
|
|
6
6
|
ID_SCHEMA_MISSING = "If no idSchema is passed the default one will be set which is: native",
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { IdSchemaEnum } from "../Enums/IdSchemaEnum";
|
|
3
|
-
import { LangEnum } from "../Enums/LangEnum";
|
|
1
|
+
import { EnvironmentType, IdSchemaType, LangType } from "../Types/ConfiguratorTypes";
|
|
4
2
|
import FansUnitedAuthInterface from "./FansUnitedAuthInterface";
|
|
5
3
|
export default class SDKConfigurationModel {
|
|
6
4
|
apiKey: string;
|
|
7
|
-
environment: EnvironmentEnum;
|
|
8
|
-
idSchema: IdSchemaEnum;
|
|
9
5
|
clientId: string;
|
|
10
|
-
|
|
6
|
+
environment?: EnvironmentType;
|
|
7
|
+
idSchema?: IdSchemaType;
|
|
8
|
+
lang?: LangType;
|
|
11
9
|
authProvider: FansUnitedAuthInterface;
|
|
12
10
|
}
|
|
@@ -2,7 +2,8 @@ export declare enum ErrorMessages {
|
|
|
2
2
|
LOYALTY_INVALID_TEMPLATE_ID = "Provided template ID does NOT exist! Try again with existing template ID.",
|
|
3
3
|
INVALID_MATCH_ID = "Match id is invalid!",
|
|
4
4
|
INVALID_PLAYER_ID = "Player id is invalid!",
|
|
5
|
-
QUERY_PARAM_MATCH_IDS_EXCEEDED = "Maximum matchIds in PredictionFilters should be 10 or less."
|
|
5
|
+
QUERY_PARAM_MATCH_IDS_EXCEEDED = "Maximum matchIds in PredictionFilters should be 10 or less.",
|
|
6
|
+
INVALID_PREDICTION_MODEL = "The prediction is invalid. Please check again have you passed appropriate prediction model. For more information please visit our offical documentation: \n https://docs.fansunitedmedia.com/sdks/js/match.quiz#gamerelatedoperations"
|
|
6
7
|
}
|
|
7
8
|
export declare const WarningMessages: {
|
|
8
9
|
UNEXPECTED_STATUS_PROP: string;
|
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
import SDKConfiguraitonModel from "../Configurator/Models/SDKConfiguraitonModel";
|
|
2
2
|
import PaginationModel from "../Global/Models/Pagination/PaginationModel";
|
|
3
|
+
import FootballPaginationModel from "../Namespaces/Football/Models/Pagination/FootballPaginationModel";
|
|
3
4
|
import LoyaltyFilters from "../Namespaces/Loyalty/Models/Filters/LoyaltyFilters";
|
|
5
|
+
import RankingsFilters from "../Namespaces/Loyalty/Models/Filters/RankingsFilters";
|
|
4
6
|
import TemplateModel from "../Namespaces/Loyalty/Models/Template/TemplateModel";
|
|
5
7
|
export default class LoyaltyHttps {
|
|
6
8
|
private instance;
|
|
7
9
|
private apiSignInUrl;
|
|
8
10
|
private templateRemapper;
|
|
9
11
|
private leaderboardRemapper;
|
|
12
|
+
private rankingsRemapper;
|
|
10
13
|
constructor(config: SDKConfiguraitonModel);
|
|
11
14
|
getTemplates: (disableCache: boolean, isPaginated: boolean) => Promise<PaginationModel | TemplateModel[]>;
|
|
12
15
|
getLeaderboard: (templateId: string, disableCache: boolean, filters: LoyaltyFilters) => Promise<PaginationModel>;
|
|
13
16
|
getLeaderboardForGame: (gameId: string, disableCache: boolean, filters: LoyaltyFilters) => Promise<PaginationModel>;
|
|
17
|
+
getUserRankings: (userId: string, filters: RankingsFilters, disableCache: boolean) => Promise<FootballPaginationModel>;
|
|
14
18
|
}
|
|
@@ -29,4 +29,5 @@ export default class PredictorHttps {
|
|
|
29
29
|
getGamePredictions: (gameId: string, disableCache: boolean, filters?: PredictionsFilters) => Promise<PaginationModel>;
|
|
30
30
|
getUserGameEditions: (filters: GamesFilters, disableCache: boolean) => Promise<PaginationModel>;
|
|
31
31
|
getGameResults: (gameId: string, disableCache: boolean, filters?: GamesFilters) => Promise<PaginationModel>;
|
|
32
|
+
getMarketResultsForGame: (gameId: string, disableCache: boolean) => Promise<import("../Namespaces/MatchQuiz/Models/GameMarketsResults/GameMarketsResults").default>;
|
|
32
33
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { IdSchemaEnum } from "../../../Configurator/Enums/IdSchemaEnum";
|
|
2
1
|
import SDKConfigurationModel from "../../../Configurator/Models/SDKConfiguraitonModel";
|
|
2
|
+
import { IdSchemaType } from "../../../Configurator/Types/ConfiguratorTypes";
|
|
3
3
|
import TagsModel from "../Models/RequestBody/Context/TagsModel";
|
|
4
4
|
export default class ActivityService {
|
|
5
5
|
private idSchema;
|
|
@@ -13,5 +13,5 @@ export default class ActivityService {
|
|
|
13
13
|
* @param tags
|
|
14
14
|
* @returns Remapped tags from idSchema to native.
|
|
15
15
|
*/
|
|
16
|
-
remapTagsIds: (tags: TagsModel[], fromSchema:
|
|
16
|
+
remapTagsIds: (tags: TagsModel[], fromSchema: IdSchemaType, toSchema: IdSchemaType) => Promise<TagsModel[]>;
|
|
17
17
|
}
|
|
@@ -6,16 +6,23 @@ import LoyaltyFilters from "../Models/Filters/LoyaltyFilters";
|
|
|
6
6
|
import ClientBadges from "../Models/Badges/ClientBadges";
|
|
7
7
|
import TemplateModel from "../Models/Template/TemplateModel";
|
|
8
8
|
import { FeaturesConfigModels } from "../../../Global/Types/GlobalTypes";
|
|
9
|
+
import RankingsFilters from "../Models/Filters/RankingsFilters";
|
|
10
|
+
import FootballPaginationModel from "../../Football/Models/Pagination/FootballPaginationModel";
|
|
11
|
+
import ProfileHttps from "../../../Https/ProfileHttps";
|
|
12
|
+
import LocalStorage from "../../../Global/LocalStorage";
|
|
9
13
|
export default class LoyaltyFacade {
|
|
10
14
|
private config;
|
|
11
15
|
private clientHttps;
|
|
12
16
|
private loyaltyHttps;
|
|
13
17
|
private loyaltyService;
|
|
14
|
-
|
|
18
|
+
private profileFacade;
|
|
19
|
+
constructor(config: SDKConfigurationModel, clientHttps: ClientHttps, loyaltyHttps: LoyaltyHttps, profileHttps: ProfileHttps, localStorage: LocalStorage);
|
|
15
20
|
getConfig: () => Promise<FeaturesConfigModels>;
|
|
16
21
|
getClientBadges: () => Promise<ClientBadges>;
|
|
17
22
|
getTemplates: (disableCache?: boolean) => Promise<PaginationModel>;
|
|
18
23
|
getTemplateById: (templateId: string, disableCache?: boolean) => Promise<TemplateModel>;
|
|
19
24
|
getLeaderboard: (templateId: string, filters?: LoyaltyFilters, disableCache?: boolean) => Promise<PaginationModel>;
|
|
20
25
|
getLeaderboardForGame: (gameId: string, filters: LoyaltyFilters, disableCache?: boolean) => Promise<PaginationModel>;
|
|
26
|
+
getOwnRankings: (filters?: RankingsFilters, disableCache?: boolean) => Promise<FootballPaginationModel>;
|
|
27
|
+
getUserRankings: (userId: string, filters?: RankingsFilters, disableCache?: boolean) => Promise<FootballPaginationModel>;
|
|
21
28
|
}
|
|
@@ -4,10 +4,13 @@ import LoyaltyFilters from "./Models/Filters/LoyaltyFilters";
|
|
|
4
4
|
import ClientBadges from "./Models/Badges/ClientBadges";
|
|
5
5
|
import TemplateModel from "./Models/Template/TemplateModel";
|
|
6
6
|
import { FeaturesConfigModels } from "../../Global/Types/GlobalTypes";
|
|
7
|
+
import RankingsFilters from "./Models/Filters/RankingsFilters";
|
|
7
8
|
export default class Loyalty {
|
|
8
9
|
private clientHttps;
|
|
10
|
+
private profileHttps;
|
|
9
11
|
private loyaltyHttps;
|
|
10
12
|
private loyaltyFacade;
|
|
13
|
+
private localStorage;
|
|
11
14
|
constructor(config: SDKConfigurationModel);
|
|
12
15
|
getConfig: () => Promise<FeaturesConfigModels>;
|
|
13
16
|
getClientBadges: () => Promise<ClientBadges>;
|
|
@@ -15,4 +18,6 @@ export default class Loyalty {
|
|
|
15
18
|
getTemplateById: (templateId: string, disableCache?: boolean) => Promise<TemplateModel>;
|
|
16
19
|
getLeaderboard: (templateId: string, filters?: LoyaltyFilters, disableCache?: boolean) => Promise<PaginationModel>;
|
|
17
20
|
getLeaderboardForGame: (gameId: string, filters?: LoyaltyFilters, disableCache?: boolean) => Promise<PaginationModel>;
|
|
21
|
+
getOwnRankings: (filters?: RankingsFilters, disableCache?: boolean) => Promise<import("../Football/Models/Pagination/FootballPaginationModel").default>;
|
|
22
|
+
getUserRankings: (userId: string, filters?: RankingsFilters, disableCache?: boolean) => Promise<import("../Football/Models/Pagination/FootballPaginationModel").default>;
|
|
18
23
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { FiltersInterface } from "../../../../Global/Interfaces/GlobalInterfaces";
|
|
2
|
+
export default class LoyaltyFilters implements FiltersInterface {
|
|
3
|
+
limit?: number;
|
|
4
|
+
page?: number;
|
|
4
5
|
constructor(filters: any);
|
|
5
|
-
constructFiltersUrl
|
|
6
|
+
constructFiltersUrl(): string;
|
|
6
7
|
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { FiltersInterface } from "../../../../Global/Interfaces/GlobalInterfaces";
|
|
2
|
+
import { SortOrder } from "../../../../Global/Types/GlobalTypes";
|
|
3
|
+
import { RankingsType } from "../../Types/LoyaltyTypes";
|
|
4
|
+
import LoyaltyFilters from "./LoyaltyFilters";
|
|
5
|
+
export default class RankingsFilters extends LoyaltyFilters implements FiltersInterface {
|
|
6
|
+
sortOrder?: SortOrder;
|
|
7
|
+
type?: RankingsType;
|
|
8
|
+
typeIds?: string[];
|
|
9
|
+
constructor(filters: any);
|
|
10
|
+
constructFiltersUrl: () => string;
|
|
11
|
+
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import LoyaltyMeta from "../Meta/LoyaltyMeta";
|
|
2
|
-
import LeaderboardModel from "./LeaderboardModel";
|
|
3
1
|
export default class LeaderboardRemapper {
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
remapResponse: (response: any) => any;
|
|
3
|
+
private remapMeta;
|
|
4
|
+
private remapData;
|
|
6
5
|
}
|
|
@@ -3,6 +3,7 @@ import BadgesModel from "../Models/Badges/BadgesModel";
|
|
|
3
3
|
import ClientBadges from "../Models/Badges/ClientBadges";
|
|
4
4
|
import LeaderboardModel from "../Models/Leaderboard/LeaderboardModel";
|
|
5
5
|
import TemplateModel from "../Models/Template/TemplateModel";
|
|
6
|
+
import { FiltersType } from "../Types/LoyaltyTypes";
|
|
6
7
|
export default class LoyaltyService {
|
|
7
8
|
private idMappingService;
|
|
8
9
|
private profileNamespace;
|
|
@@ -10,5 +11,6 @@ export default class LoyaltyService {
|
|
|
10
11
|
remapTemplatesIds: (templates: TemplateModel[]) => Promise<TemplateModel[]>;
|
|
11
12
|
addProfileModel: (leaderboard: any[]) => Promise<LeaderboardModel[]>;
|
|
12
13
|
buildClientBadges: (badges: BadgesModel) => ClientBadges;
|
|
14
|
+
initFilters: (filters: any, type: FiltersType) => any;
|
|
13
15
|
private extractEnabledBadgesId;
|
|
14
16
|
}
|
|
@@ -7,12 +7,12 @@ import { FeaturesConfigModels } from "../../../Global/Types/GlobalTypes";
|
|
|
7
7
|
import GameModel from "../../TopX/Models/Games/GameModel";
|
|
8
8
|
import GamesFilters from "../../TopX/Models/Games/GamesFilters";
|
|
9
9
|
import GamesListModel from "../../TopX/Models/Games/GamesListModel";
|
|
10
|
+
import GameMarketsResults from "../Models/GameMarketsResults/GameMarketsResults";
|
|
10
11
|
export default class MatchQuizFacade {
|
|
11
12
|
private predictorHttps;
|
|
12
13
|
private predictorService;
|
|
13
14
|
private idMapping;
|
|
14
15
|
private clientHttps;
|
|
15
|
-
readonly invalidPredictionModelErrorMessage = "The prediction is invalid. Please check again have you passed appropriate prediction model. For more information please visit our offical documentation: \n https://docs.fansunitedmedia.com/sdks/js/match.quiz#gamerelatedoperations";
|
|
16
16
|
constructor(config: SDKConfigurationModel);
|
|
17
17
|
getConfig: () => Promise<FeaturesConfigModels>;
|
|
18
18
|
play: (matchQuizPrediction: PredictionRequestModel) => Promise<PredictionResponseModel>;
|
|
@@ -26,4 +26,5 @@ export default class MatchQuizFacade {
|
|
|
26
26
|
getMyGamePrediction: (gameId: string) => Promise<PredictionResponseModel>;
|
|
27
27
|
getUserGameEditions: (userId: string, filters?: GamesFilters, disableCache?: boolean) => Promise<PaginationModel>;
|
|
28
28
|
getUserGamePrediction: (userId: string, gameId: string, disableCache?: boolean) => Promise<PredictionResponseModel>;
|
|
29
|
+
getMarketsResultsForGame: (gameId: string, disableCache?: boolean) => Promise<GameMarketsResults>;
|
|
29
30
|
}
|
|
@@ -7,6 +7,7 @@ import { FeaturesConfigModels } from "../../Global/Types/GlobalTypes";
|
|
|
7
7
|
import GameModel from "../TopX/Models/Games/GameModel";
|
|
8
8
|
import GamesFilters from "../TopX/Models/Games/GamesFilters";
|
|
9
9
|
import GamesListModel from "../TopX/Models/Games/GamesListModel";
|
|
10
|
+
import GameMarketsResults from "./Models/GameMarketsResults/GameMarketsResults";
|
|
10
11
|
export default class MatchQuiz {
|
|
11
12
|
private matchQuizFacade;
|
|
12
13
|
constructor(config: SDKConfigurationModel);
|
|
@@ -22,4 +23,5 @@ export default class MatchQuiz {
|
|
|
22
23
|
getMyGamePrediction: (gameId: string) => Promise<PredictionResponseModel>;
|
|
23
24
|
getUserGameEditions: (userId: string, filters?: GamesFilters, disableCache?: boolean) => Promise<PaginationModel>;
|
|
24
25
|
getUserGamePrediction: (userId: string, gameId: string, disableCache?: boolean) => Promise<PredictionResponseModel>;
|
|
26
|
+
getMarketsResultsForGame: (gameId: string, disableCache?: boolean) => Promise<GameMarketsResults>;
|
|
25
27
|
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import MatchBasicModel from "../../../Football/Models/Match/MatchBasicModel";
|
|
2
|
+
import PlayerMarketResultModel from "../../../Football/Models/Player/PlayerMarketResultModel";
|
|
3
|
+
import { MarketEnum } from "../../../Predictor/Enums/MarketEnum";
|
|
4
|
+
export declare type MarketsResults = {
|
|
5
|
+
matchId: string;
|
|
6
|
+
market: MarketEnum;
|
|
7
|
+
result: string | string[] | boolean;
|
|
8
|
+
matchModel: MatchBasicModel;
|
|
9
|
+
playerModels?: PlayerMarketResultModel[];
|
|
10
|
+
};
|
|
11
|
+
export default class GameMarketsResults {
|
|
12
|
+
gameId: string;
|
|
13
|
+
results: MarketsResults[];
|
|
14
|
+
}
|
|
@@ -33,4 +33,5 @@ export declare enum MarketEnum {
|
|
|
33
33
|
export declare const MarketsOverGoals: MarketEnum[];
|
|
34
34
|
export declare const MarketsOverCorners: MarketEnum[];
|
|
35
35
|
export declare const playerMarkets: MarketEnum[];
|
|
36
|
+
export declare const endMarkMarkets: MarketEnum[];
|
|
36
37
|
export declare const playerMarketNobodyPrediction = MarketEnum.PLAYER_SCORE_FIRST_GOAL;
|
|
@@ -20,6 +20,7 @@ import { TypeGames } from "../../TopX/Types/TypeGames";
|
|
|
20
20
|
import GamesFilters from "../../TopX/Models/Games/GamesFilters";
|
|
21
21
|
import PaginationModel from "../../../Global/Models/Pagination/PaginationModel";
|
|
22
22
|
import { FeaturesConfigModels, FilterCase } from "../../../Global/Types/GlobalTypes";
|
|
23
|
+
import GameMarketsResults from "../../MatchQuiz/Models/GameMarketsResults/GameMarketsResults";
|
|
23
24
|
export default class PredictorService {
|
|
24
25
|
private footballHttps;
|
|
25
26
|
private idMapping;
|
|
@@ -90,5 +91,6 @@ export default class PredictorService {
|
|
|
90
91
|
*/
|
|
91
92
|
areIdsExceeded: (ids: string[]) => boolean;
|
|
92
93
|
initPredictionsFilters: (filters: PredictionsFilters, filtersFor: FilterCase, matchIds?: string[]) => PredictionsFilters;
|
|
94
|
+
completeGameMarketResults: (gameMarketResults: GameMarketsResults, gameType: TypeGames) => Promise<GameMarketsResults>;
|
|
93
95
|
private deleteUnexpectedProperties;
|
|
94
96
|
}
|
|
@@ -9,6 +9,7 @@ import PaginationModel from "../../../Global/Models/Pagination/PaginationModel";
|
|
|
9
9
|
import TopXPredictionRequestModel from "../Models/Prediction/TopXPredictionRequestModel";
|
|
10
10
|
import PredictionsFilters from "../../Predictor/Models/Predictions/PredictionsFilters";
|
|
11
11
|
import { FeaturesConfigModels } from "../../../Global/Types/GlobalTypes";
|
|
12
|
+
import GameMarketsResults from "../../MatchQuiz/Models/GameMarketsResults/GameMarketsResults";
|
|
12
13
|
export default class TopXFacade {
|
|
13
14
|
readonly idMapping: IdMappingService;
|
|
14
15
|
readonly predictorHttps: PredictorHttps;
|
|
@@ -27,4 +28,5 @@ export default class TopXFacade {
|
|
|
27
28
|
getMyGamePrediction: (gameId: string) => Promise<PredictionResponseModel>;
|
|
28
29
|
getUserGameEditions: (userId: string, filters?: GamesFilters, disableCache?: boolean) => Promise<PaginationModel>;
|
|
29
30
|
getUserGamePrediction: (userId: string, gameId: string, disableCache?: boolean) => Promise<PredictionResponseModel>;
|
|
31
|
+
getMarketsResultsForGame: (gameId: string, disableCache?: boolean) => Promise<GameMarketsResults>;
|
|
30
32
|
}
|
|
@@ -3,6 +3,7 @@ import GamesListModel from "./GamesListModel";
|
|
|
3
3
|
import GamesMatchQuizListModel from "../../../MatchQuiz/Models/Games/GamesMatchQuizListModel";
|
|
4
4
|
import GamesTopXListModel from "./GamesTopXListModel";
|
|
5
5
|
import PaginationModel from "../../../../Global/Models/Pagination/PaginationModel";
|
|
6
|
+
import GameMarketsResults from "../../../MatchQuiz/Models/GameMarketsResults/GameMarketsResults";
|
|
6
7
|
export default class GamesRemapper {
|
|
7
8
|
remapPaginatedGames: (paginatedGames: any) => PaginationModel;
|
|
8
9
|
remapGamesListResponse: (gamesList: any) => GamesListModel;
|
|
@@ -15,6 +16,11 @@ export default class GamesRemapper {
|
|
|
15
16
|
private remapMatchQuizFixturesResponse;
|
|
16
17
|
remapPaginatedGameResults: (gameResultsResponse: any) => PaginationModel;
|
|
17
18
|
remapGameResults: (gameResults: any) => GameModel;
|
|
19
|
+
remapGameMarketsResults: (gameMarketsResultsResponse: any) => GameMarketsResults;
|
|
20
|
+
private remapMarketsResults;
|
|
21
|
+
private remapMarketResult;
|
|
22
|
+
private deleteUnusefulField;
|
|
23
|
+
private isPlayerMarketWithNoResult;
|
|
18
24
|
private remapResults;
|
|
19
25
|
private remapTiebreaker;
|
|
20
26
|
}
|
|
@@ -6,6 +6,7 @@ import GamesListModel from "./Models/Games/GamesListModel";
|
|
|
6
6
|
import PaginationModel from "../../Global/Models/Pagination/PaginationModel";
|
|
7
7
|
import TopXPredictionRequestModel from "./Models/Prediction/TopXPredictionRequestModel";
|
|
8
8
|
import PredictionsFilters from "../Predictor/Models/Predictions/PredictionsFilters";
|
|
9
|
+
import GameMarketsResults from "../MatchQuiz/Models/GameMarketsResults/GameMarketsResults";
|
|
9
10
|
export default class TopX {
|
|
10
11
|
private topXFacade;
|
|
11
12
|
private idMapping;
|
|
@@ -22,4 +23,5 @@ export default class TopX {
|
|
|
22
23
|
getMyGamePrediction: (gameId: string) => Promise<PredictionResponseModel>;
|
|
23
24
|
getUserGameEditions: (userId: string, filters?: GamesFilters, disableCache?: boolean) => Promise<PaginationModel>;
|
|
24
25
|
getUserGamePrediction: (userId: string, gameId: string, disableCache?: boolean) => Promise<PredictionResponseModel>;
|
|
26
|
+
getMarketsResultsForGame: (gameId: string, disableCache?: boolean) => Promise<GameMarketsResults>;
|
|
25
27
|
}
|