@smartico/public-api 0.0.331 → 0.0.333
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/dist/Base/AchRelatedGame.d.ts +1 -0
- package/dist/Jackpots/GetJackpotEligibleGamesResponse.d.ts +2 -0
- package/dist/MiniGames/SAWGameType.d.ts +2 -2
- package/dist/SmarticoLib/index.d.ts +6 -0
- package/dist/WSAPI/WSAPITypes.d.ts +6 -0
- package/dist/index.js +12 -9
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +12 -9
- package/dist/index.modern.mjs.map +1 -1
- package/docs/enums/SAWGameType.md +6 -0
- package/docs/enums/SAWGameTypeName.md +6 -0
- package/docs/interfaces/AchRelatedGame-1.md +1 -0
- package/docs/interfaces/AchRelatedGame.md +1 -0
- package/docs/interfaces/JackpotEligibleGame.md +8 -0
- package/docs/interfaces/TUserProfile.md +16 -0
- package/package.json +1 -1
- package/src/Base/AchRelatedGame.ts +1 -0
- package/src/Jackpots/GetJackpotEligibleGamesResponse.ts +4 -1
- package/src/MiniGames/SAWGameType.ts +3 -3
- package/src/Missions/UserAchievement.ts +3 -2
- package/src/SmarticoLib/index.ts +7 -0
- package/src/Tournaments/GetTournamentInfoResponse.ts +2 -1
- package/src/WSAPI/WSAPITypes.ts +6 -0
|
@@ -27,3 +27,4 @@ Game public meta information
|
|
|
27
27
|
| `game_categories` | `string`[] | The list of categories of the game |
|
|
28
28
|
| `game_provider` | `string` | The name of the game provider |
|
|
29
29
|
| `mobile_spec_link` | `string` | The URL to the mobile game |
|
|
30
|
+
| `priority?` | `number` | The priority of the game |
|
|
@@ -95,3 +95,19 @@ ___
|
|
|
95
95
|
• `Optional` **core\_inbox\_unread\_count**: `number`
|
|
96
96
|
|
|
97
97
|
THe number of unread inbox messages
|
|
98
|
+
|
|
99
|
+
___
|
|
100
|
+
|
|
101
|
+
### core\_recommended\_deposit\_amount
|
|
102
|
+
|
|
103
|
+
• `Optional` **core\_recommended\_deposit\_amount**: `number`
|
|
104
|
+
|
|
105
|
+
The recommended deposit amount for the user
|
|
106
|
+
|
|
107
|
+
___
|
|
108
|
+
|
|
109
|
+
### core\_recommended\_casino\_bet\_amount
|
|
110
|
+
|
|
111
|
+
• `Optional` **core\_recommended\_casino\_bet\_amount**: `number`
|
|
112
|
+
|
|
113
|
+
The recommended casino bet amount for the user
|
package/package.json
CHANGED
|
@@ -28,13 +28,15 @@ export interface JackpotEligibleGame {
|
|
|
28
28
|
game_provider: string;
|
|
29
29
|
/** The link to the mobile game */
|
|
30
30
|
mobile_spec_link: string;
|
|
31
|
+
/** The priority of the game */
|
|
32
|
+
priority: number;
|
|
31
33
|
}
|
|
32
34
|
|
|
33
35
|
/**
|
|
34
36
|
* @ignore
|
|
35
37
|
*/
|
|
36
38
|
export const GetJackpotEligibleGamesResponseTransform = ({ eligible_games } : { eligible_games: AchRelatedGame[]}): TGetJackpotEligibleGamesResponse => {
|
|
37
|
-
const games = eligible_games.map((game: AchRelatedGame) => ({
|
|
39
|
+
const games = eligible_games.map((game: AchRelatedGame, i: number) => ({
|
|
38
40
|
game_id: game.ach_game_id,
|
|
39
41
|
ext_game_id: game.ext_game_id,
|
|
40
42
|
name: game.game_public_meta.name,
|
|
@@ -44,6 +46,7 @@ export const GetJackpotEligibleGamesResponseTransform = ({ eligible_games } : {
|
|
|
44
46
|
game_categories: game.game_public_meta.game_categories,
|
|
45
47
|
game_provider: game.game_public_meta.game_provider,
|
|
46
48
|
mobile_spec_link: game.game_public_meta.mobile_spec_link,
|
|
49
|
+
priority: i + 1,
|
|
47
50
|
}));
|
|
48
51
|
|
|
49
52
|
return { eligible_games: games };
|
|
@@ -10,7 +10,7 @@ export enum SAWGameType {
|
|
|
10
10
|
TreasureHunt = 9,
|
|
11
11
|
Voyager = 10,
|
|
12
12
|
Plinko = 11,
|
|
13
|
-
|
|
13
|
+
CoinFlip = 12,
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
export enum SAWGameTypeName {
|
|
@@ -25,7 +25,7 @@ export enum SAWGameTypeName {
|
|
|
25
25
|
TreasureHunt = 'treasure_hunt',
|
|
26
26
|
Voyager = 'voyager',
|
|
27
27
|
Plinko = 'plinko',
|
|
28
|
-
|
|
28
|
+
CoinFlip = 'coin_flip',
|
|
29
29
|
Unknown = 'unknown',
|
|
30
30
|
}
|
|
31
31
|
|
|
@@ -44,7 +44,7 @@ export const SAWGameTypeNamed = (type: SAWGameType): SAWGameTypeName => {
|
|
|
44
44
|
[SAWGameType.TreasureHunt]: SAWGameTypeName.TreasureHunt,
|
|
45
45
|
[SAWGameType.Voyager]: SAWGameTypeName.Voyager,
|
|
46
46
|
[SAWGameType.Plinko]: SAWGameTypeName.Plinko,
|
|
47
|
-
[SAWGameType
|
|
47
|
+
[SAWGameType.CoinFlip]: SAWGameTypeName.CoinFlip,
|
|
48
48
|
}[type] || SAWGameTypeName.Unknown
|
|
49
49
|
);
|
|
50
50
|
};
|
|
@@ -128,7 +128,7 @@ export const UserAchievementTransform = (items: UserAchievement[]): TMissionOrBa
|
|
|
128
128
|
stage_image: t.task_public_meta.stage_image,
|
|
129
129
|
})
|
|
130
130
|
}),
|
|
131
|
-
related_games: (r.related_games || []).map((g) => ({
|
|
131
|
+
related_games: (r.related_games || []).map((g, i) => ({
|
|
132
132
|
ext_game_id: g.ext_game_id,
|
|
133
133
|
game_public_meta: {
|
|
134
134
|
name: g.game_public_meta.name,
|
|
@@ -137,7 +137,8 @@ export const UserAchievementTransform = (items: UserAchievement[]): TMissionOrBa
|
|
|
137
137
|
enabled: g.game_public_meta.enabled,
|
|
138
138
|
game_categories: g.game_public_meta.game_categories,
|
|
139
139
|
game_provider: g.game_public_meta.game_provider,
|
|
140
|
-
mobile_spec_link: g.game_public_meta.mobile_spec_link
|
|
140
|
+
mobile_spec_link: g.game_public_meta.mobile_spec_link,
|
|
141
|
+
priority: i + 1,
|
|
141
142
|
},
|
|
142
143
|
})),
|
|
143
144
|
category_ids: r.ach_categories ?? [],
|
package/src/SmarticoLib/index.ts
CHANGED
|
@@ -116,6 +116,8 @@ export interface PublicProperties {
|
|
|
116
116
|
core_inbox_unread_count?: number;
|
|
117
117
|
is_visitor?: boolean;
|
|
118
118
|
core_registration_date?: number;
|
|
119
|
+
core_recommended_deposit_amount?: number;
|
|
120
|
+
core_recommended_casino_bet_amount?: number;
|
|
119
121
|
}
|
|
120
122
|
declare enum ClassId {
|
|
121
123
|
PING = 1,
|
|
@@ -837,7 +839,12 @@ export interface TUserProfile {
|
|
|
837
839
|
public_username?: string;
|
|
838
840
|
/** THe number of unread inbox messages */
|
|
839
841
|
core_inbox_unread_count?: number;
|
|
842
|
+
/** The recommended deposit amount for the user */
|
|
843
|
+
core_recommended_deposit_amount?: number;
|
|
844
|
+
/** The recommended casino bet amount for the user */
|
|
845
|
+
core_recommended_casino_bet_amount?: number;
|
|
840
846
|
}
|
|
847
|
+
|
|
841
848
|
/**
|
|
842
849
|
* TLevel describes the information of each level defined in the system
|
|
843
850
|
* There is no order of the levels, but it can be calculated using required_points property
|
|
@@ -25,7 +25,7 @@ export interface GetTournamentInfoResponse extends ProtocolResponse {
|
|
|
25
25
|
export const tournamentInfoItemTransform = (t: GetTournamentInfoResponse): TTournamentDetailed => {
|
|
26
26
|
const response: TTournamentDetailed = {
|
|
27
27
|
...TournamentItemsTransform([t.tournamentInfo.tournamentLobbyInfo])[0],
|
|
28
|
-
related_games: (t.tournamentInfo.tournamentLobbyInfo.related_games || []).map((g) => ({
|
|
28
|
+
related_games: (t.tournamentInfo.tournamentLobbyInfo.related_games || []).map((g, i) => ({
|
|
29
29
|
ext_game_id: g.ext_game_id,
|
|
30
30
|
game_public_meta: {
|
|
31
31
|
name: g.game_public_meta.name,
|
|
@@ -35,6 +35,7 @@ export const tournamentInfoItemTransform = (t: GetTournamentInfoResponse): TTour
|
|
|
35
35
|
game_categories: g.game_public_meta.game_categories,
|
|
36
36
|
game_provider: g.game_public_meta.game_provider,
|
|
37
37
|
mobile_spec_link: g.game_public_meta.mobile_spec_link,
|
|
38
|
+
priority: i + 1,
|
|
38
39
|
},
|
|
39
40
|
})),
|
|
40
41
|
players: t.tournamentInfo.players.map((p) => TournamentUtils.getPlayerTransformed(p)),
|
package/src/WSAPI/WSAPITypes.ts
CHANGED
|
@@ -228,6 +228,10 @@ export interface TUserProfile {
|
|
|
228
228
|
public_username?: string;
|
|
229
229
|
/** THe number of unread inbox messages */
|
|
230
230
|
core_inbox_unread_count?: number;
|
|
231
|
+
/** The recommended deposit amount for the user */
|
|
232
|
+
core_recommended_deposit_amount?: number;
|
|
233
|
+
/** The recommended casino bet amount for the user */
|
|
234
|
+
core_recommended_casino_bet_amount?: number;
|
|
231
235
|
}
|
|
232
236
|
|
|
233
237
|
/**
|
|
@@ -708,6 +712,8 @@ export interface AchRelatedGame {
|
|
|
708
712
|
game_provider: string;
|
|
709
713
|
/** The URL to the mobile game */
|
|
710
714
|
mobile_spec_link: string;
|
|
715
|
+
/** The priority of the game */
|
|
716
|
+
priority?: number;
|
|
711
717
|
};
|
|
712
718
|
}
|
|
713
719
|
|