@smartico/public-api 0.0.427 → 0.0.429

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smartico/public-api",
3
- "version": "0.0.427",
3
+ "version": "0.0.429",
4
4
  "description": "Smartico public API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -192,6 +192,7 @@ interface Tracker {
192
192
  getLabelSetting: (key: PublicLabelSettings) => any;
193
193
  triggerExternalCallBack: (callBackKey: string, payload: any) => void;
194
194
  getExtUserId: () => string;
195
+ getHash?: () => string;
195
196
  }
196
197
  interface IOptions {
197
198
  logger?: ILogger;
@@ -1499,6 +1500,11 @@ class SmarticoAPI {
1499
1500
  lang: this.tracker.userPublicProps?.core_user_language,
1500
1501
  });
1501
1502
 
1503
+ const user_hash = this.tracker.getHash?.();
1504
+ if (user_hash) {
1505
+ params.user_hash = user_hash;
1506
+ }
1507
+
1502
1508
  return params;
1503
1509
  }
1504
1510
 
@@ -54,7 +54,7 @@ export const StoreItemPurchasedTransform = (items: StoreItemPurchased[]): TStore
54
54
  purchased_today: purchasedToday,
55
55
  purchased_this_week: purchasedThisWeek,
56
56
  purchased_this_month: purchasedThisMonth,
57
- custom_data: r.itemPublicMeta.custom_data,
57
+ custom_data: IntUtils.JsonOrText(r.itemPublicMeta.custom_data),
58
58
  show_timer: r.itemPublicMeta.show_timer,
59
59
  related_games: (r.relatedGames?.filter((g) => g.game_public_meta.enabled) || []).map((g, i) => ({
60
60
  ext_game_id: g.ext_game_id,
@@ -1,4 +0,0 @@
1
- import { UserBalanceType } from './UserBalanceType';
2
- import { TActivityLogEntry } from '../WSAPI/WSAPITypes';
3
- export declare const mapActivityLogHistory: (logHistory: unknown[]) => TActivityLogEntry[];
4
- export declare const resolveWalletDisplayType: (entry: TActivityLogEntry) => UserBalanceType;
@@ -1,40 +0,0 @@
1
- export declare enum QuizAnswersValueType {
2
- HomeTeam = "1",
3
- AwayTeam = "2",
4
- Draw = "x",
5
- HomeTeamHomeTeam = "1/1",
6
- HomeTeamDraw = "1/x",
7
- HomeTeamAwayTeam = "1/2",
8
- DrawHomeTeam = "x/1",
9
- DrawDraw = "x/x",
10
- DrawAwayTeam = "x/2",
11
- AwayTeamHomeTeam = "2/1",
12
- AwayTeamDraw = "2/x",
13
- AwayTeamAwayTeam = "2/2",
14
- Yes = "yes",
15
- No = "no",
16
- Odd = "odd",
17
- Even = "even",
18
- HomeOdd = "1/odd",
19
- HomeEven = "1/even",
20
- AwayOdd = "2/odd",
21
- AwayEven = "2/even"
22
- }
23
- export declare const quizAnswerHomeTeamReplacementText = "{quiz_home_team}";
24
- export declare const quizAnswerAwayTeamReplacementText = "{quiz_away_team}";
25
- export declare const quizDrawReplacementText = "{quiz_draw}";
26
- export declare const quizYesReplacementText = "{yes}";
27
- export declare const quizNoReplacementText = "{no}";
28
- export declare const quizOddReplacementText = "{odd}";
29
- export declare const quizEvenReplacementText = "{even}";
30
- export declare const quizOrReplacementText = "{or}";
31
- export declare const quizNoGoalsReplacementText = "{quiz_no_goals}";
32
- export declare const quizAnswersTrKeys: {
33
- "{quiz_draw}": string;
34
- "{yes}": string;
35
- "{no}": string;
36
- "{odd}": string;
37
- "{even}": string;
38
- "{or}": string;
39
- "{quiz_no_goals}": string;
40
- };
@@ -1,14 +0,0 @@
1
- import { QuizAnswersValueType } from './MarketsAnswers';
2
- import { SAWGPMarketType } from './MarketsType';
3
- export declare const marketsInfo: {
4
- type: SAWGPMarketType;
5
- name: string;
6
- question: {
7
- text: string;
8
- trKey: string;
9
- };
10
- answers: {
11
- text: string;
12
- value: QuizAnswersValueType;
13
- }[];
14
- }[];
@@ -1,6 +0,0 @@
1
- import { SAWGPMarketType } from './MarketsType';
2
- export declare const QuizMarketPerSport: {
3
- 2: SAWGPMarketType[];
4
- 1: SAWGPMarketType[];
5
- 5: SAWGPMarketType[];
6
- };
@@ -1,28 +0,0 @@
1
- export declare enum SAWGPMarketType {
2
- TwoTeamsWithScore = 1,
3
- RedCard = 2,
4
- OneXTwo = 3,
5
- OneXTwoHalftime = 4,
6
- FirstGoal = 6,
7
- DoubleChance = 7,
8
- OverUnder2_5 = 8,
9
- OverUnder1_5Halftime = 9,
10
- OverUnder1_5__2ndHalf = 10,
11
- TotalCorners8_5 = 11,
12
- TotalCorners9_5 = 12,
13
- Corners1x2 = 13,
14
- One_Two = 14,
15
- Overtime = 15,
16
- OddEven = 16,
17
- OddEvenHomeAway = 17,
18
- FirstSet = 18,
19
- SecondSet = 19,
20
- ThirdSet = 20,
21
- FourthSet = 21,
22
- FifthSet = 22,
23
- PlayerOneWinsOneSet = 23,
24
- PlayerTwoWinsOneSet = 24,
25
- LastGoal = 25,
26
- CustomSport = 26,
27
- CustomNonSport = 27
28
- }
@@ -1,28 +0,0 @@
1
- type TeamType = 'Home' | 'Away';
2
- type CardType = 'Yellow' | 'Red' | 'YellowRed';
3
- type TimeType = 'FT' | '1st Half' | '2nd Half';
4
- export type OverHalfFullTimeScoreType = {
5
- home: number;
6
- away: number;
7
- };
8
- export type CardScoreType = {
9
- time: 'string';
10
- type: CardType;
11
- player: string;
12
- };
13
- export type CornerScoreType = {
14
- team: TeamType;
15
- timeType: TimeType;
16
- totalCount: number;
17
- };
18
- export type GoalScoreType = {
19
- team: TeamType;
20
- time: string;
21
- player: string;
22
- matchScore: OverHalfFullTimeScoreType;
23
- };
24
- export type SetsScoreType = {
25
- set: number;
26
- setScore: OverHalfFullTimeScoreType;
27
- };
28
- export {};
@@ -1,6 +0,0 @@
1
- export declare enum QuizSportType {
2
- Soccer = 1,
3
- Basketball = 2,
4
- Tennis = 5
5
- }
6
- export declare const quizSupportedSports: QuizSportType[];
@@ -1,6 +0,0 @@
1
- export * from './SportTypes';
2
- export * from './MarketsType';
3
- export * from './ScoreResultTypes';
4
- export * from './MarketsInfo';
5
- export * from './MarketsPerSport';
6
- export * from './MarketsAnswers';