@smartico/public-api 0.0.401 → 0.0.402
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/ActivityLog/ActivityLogEntry.d.ts +2 -0
- package/dist/Avatars/AvatarCustomized.d.ts +2 -2
- package/dist/GamePick/GamePickTypes.d.ts +6 -6
- package/dist/WSAPI/WSAPIAvatars.d.ts +1 -1
- package/dist/WSAPI/WSAPITypes.d.ts +7 -4
- package/dist/index.d.ts +1 -0
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +2 -2
- package/dist/index.modern.mjs.map +1 -1
- package/docs/api/classes/WSAPIAvatars.md +1 -1
- package/docs/api/interfaces/AvatarCustomized.md +2 -2
- package/docs/api/interfaces/GamePickEvent.md +4 -4
- package/docs/api/interfaces/GamePickUserInfo.md +2 -2
- package/docs/api/interfaces/GemsDiamondsLog.md +2 -0
- package/docs/api/interfaces/PointsLog.md +2 -0
- package/docs/api/interfaces/TAvatarCustomized.md +2 -2
- package/docs/api/interfaces/TInboxMessage.md +2 -1
- package/docs/api/interfaces/TMissionOrBadge.md +3 -1
- package/package.json +1 -1
- package/src/ActivityLog/ActivityLogEntry.ts +2 -0
- package/src/Avatars/AvatarCustomized.ts +2 -2
- package/src/GamePick/GamePickTypes.ts +6 -6
- package/src/Missions/UserAchievement.ts +2 -2
- package/src/Store/StoreItem.ts +1 -1
- package/src/WSAPI/WSAPIAvatars.ts +1 -1
- package/src/WSAPI/WSAPITypes.ts +7 -4
- package/src/index.ts +20 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { PointChangeSourceType } from './PointChangeSourceType';
|
|
2
2
|
import { UserBalanceType } from './UserBalanceType';
|
|
3
3
|
export interface PointsLog {
|
|
4
|
+
/** Epoch timestamp in SECONDS (not ms — unlike most SDK timestamps). */
|
|
4
5
|
create_date: number;
|
|
5
6
|
user_ext_id: string;
|
|
6
7
|
crm_brand_id: number;
|
|
@@ -10,6 +11,7 @@ export interface PointsLog {
|
|
|
10
11
|
source_type_id: PointChangeSourceType;
|
|
11
12
|
}
|
|
12
13
|
export interface GemsDiamondsLog {
|
|
14
|
+
/** Epoch timestamp in SECONDS (not ms — unlike most SDK timestamps). */
|
|
13
15
|
create_date: number;
|
|
14
16
|
user_ext_id: string;
|
|
15
17
|
crm_brand_id: number;
|
|
@@ -3,6 +3,6 @@ export interface AvatarCustomized {
|
|
|
3
3
|
avatar_real_id: number;
|
|
4
4
|
/** CDN URL of the AI-customized avatar image */
|
|
5
5
|
url: string;
|
|
6
|
-
/**
|
|
7
|
-
dt_created:
|
|
6
|
+
/** Unix-ms timestamp when the customization was created. */
|
|
7
|
+
dt_created: number;
|
|
8
8
|
}
|
|
@@ -201,10 +201,10 @@ export interface GamePickEventMeta extends QuizEventMeta {
|
|
|
201
201
|
export interface GamePickEvent {
|
|
202
202
|
/** Unique identifier of the event */
|
|
203
203
|
gp_event_id: number;
|
|
204
|
-
/**
|
|
205
|
-
event_resolution_date:
|
|
206
|
-
/**
|
|
207
|
-
match_date:
|
|
204
|
+
/** ISO 8601 date-time string when the event was resolved; null until resolved. */
|
|
205
|
+
event_resolution_date: string;
|
|
206
|
+
/** ISO 8601 date-time string of the match/event start time. */
|
|
207
|
+
match_date: string;
|
|
208
208
|
/** Market type defining the prediction format (e.g. two-team score, quiz question, custom) */
|
|
209
209
|
market_type_id: SAWGPMarketType;
|
|
210
210
|
/** Event metadata containing team names, images, sport type, and question details */
|
|
@@ -406,8 +406,8 @@ export interface GamePickUserInfo {
|
|
|
406
406
|
part_wins_count?: number;
|
|
407
407
|
/** User's total score */
|
|
408
408
|
resolution_score?: number;
|
|
409
|
-
/**
|
|
410
|
-
last_wallet_sync_time?:
|
|
409
|
+
/** ISO 8601 date-time string of the last time the user's balance was synced from the Smartico platform. */
|
|
410
|
+
last_wallet_sync_time?: string;
|
|
411
411
|
/** User's current points balance */
|
|
412
412
|
ach_points_balance?: number;
|
|
413
413
|
/** User's current gems balance */
|
|
@@ -123,7 +123,7 @@ export declare class WSAPIAvatars extends WSAPIMiniGames {
|
|
|
123
123
|
*
|
|
124
124
|
* // Newest-first within each base.
|
|
125
125
|
* for (const list of byBase.values()) {
|
|
126
|
-
* list.sort((a, b) => b.dt_created
|
|
126
|
+
* list.sort((a, b) => b.dt_created - a.dt_created);
|
|
127
127
|
* }
|
|
128
128
|
*
|
|
129
129
|
* console.log('[smartico] AI variants by base avatar — render as a carousel under each base');
|
|
@@ -832,7 +832,9 @@ export interface TMissionOrBadge {
|
|
|
832
832
|
requires_prize_claim?: boolean;
|
|
833
833
|
/** The date/timestamp indicating when the prize was claimed by the user */
|
|
834
834
|
prize_claimed_date_ts?: number;
|
|
835
|
-
/**
|
|
835
|
+
/** Date-time the mission/badge was completed, as a `"dd/MM/yyyy HH:mm:ss"` string
|
|
836
|
+
* (server local — NOT ISO-8601, so `new Date(complete_date)` will not parse it).
|
|
837
|
+
* Prefer the epoch-ms `complete_date_ts` for date math. */
|
|
836
838
|
complete_date?: string;
|
|
837
839
|
/** Time of mission/badge being completed, this property shows the epoch time in UTC */
|
|
838
840
|
complete_date_ts?: number;
|
|
@@ -974,7 +976,8 @@ export interface TInboxMessage {
|
|
|
974
976
|
/** Unique identifier of the message. Pass to `getInboxMessageBody`
|
|
975
977
|
* and the mark / favorite / delete mutations. */
|
|
976
978
|
message_guid: string;
|
|
977
|
-
/** Date
|
|
979
|
+
/** Date-time the message was sent, as a `"dd/MM/yyyy HH:mm:ss"` string
|
|
980
|
+
* (server local — NOT ISO-8601, so `new Date(sent_date)` will not parse it). */
|
|
978
981
|
sent_date: string;
|
|
979
982
|
/** `true` when the message has been marked read. */
|
|
980
983
|
read: boolean;
|
|
@@ -1688,8 +1691,8 @@ export interface TAvatarCustomized {
|
|
|
1688
1691
|
avatar_real_id: number;
|
|
1689
1692
|
/** Absolute CDN URL of the AI-generated image. Can be passed as `avatar_url` to `setAvatar()`. */
|
|
1690
1693
|
url: string;
|
|
1691
|
-
/**
|
|
1692
|
-
dt_created:
|
|
1694
|
+
/** Unix-ms timestamp of when the variant was generated. */
|
|
1695
|
+
dt_created: number;
|
|
1693
1696
|
}
|
|
1694
1697
|
/**
|
|
1695
1698
|
* One AI style prompt for avatar customization. Returned by `getAvatarPrompts()`.
|
package/dist/index.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ export * from './SmarticoAPI';
|
|
|
4
4
|
export * from './WSAPI/WSAPI';
|
|
5
5
|
export * from './SmarticoGlobal';
|
|
6
6
|
export * from './CookieStore';
|
|
7
|
+
export type { TAchCategory, TActivityLog, TAvatarCustomized, TAvatarDefinition, TAvatarPrompt, TBonus, TBuyStoreItemResult, TClaimBonusResult, TClan, TClanInfo, TClanJoinResult, TClanTournamentPlayers, TClans, TGetTranslations, TInboxMessage, TInboxMessageBody, TLevel, TLevelCurrent, TMiniGamePlayBatchResult, TMiniGamePlayResult, TMiniGamePrize, TMiniGameTemplate, TMissionClaimRewardResult, TMissionOptInResult, TMissionOrBadge, TMissionOrBadgeTask, TRaffle, TRaffleDraw, TRaffleDrawRun, TRaffleOptinResponse, TRafflePrize, TRafflePrizeWinner, TRaffleTicket, TSawHistory, TSegmentCheckResult, TSetAvatarResult, TStoreCategory, TStoreItem, TTournament, TTournamentDetailed, TTournamentRegistrationResult, TUICustomSection, TUserProfile, TransformedRaffleClaimPrizeResponse, InboxMarkMessageAction, LeaderBoardDetailsT, LeaderBoardUserT, LeaderBoardsRewardsT, UserLevelExtraCountersT, } from './WSAPI/WSAPITypes';
|
|
7
8
|
export * from './Analytics';
|
|
8
9
|
export * from './Core';
|
|
9
10
|
export * from './UserProfile';
|
package/dist/index.js
CHANGED
|
@@ -1064,7 +1064,7 @@ var StoreItemTransform = function StoreItemTransform(items) {
|
|
|
1064
1064
|
id: r.id,
|
|
1065
1065
|
name: r.itemPublicMeta.name,
|
|
1066
1066
|
purchase_type: mapPurchaseType$1(r.itemPublicMeta.purchase_type),
|
|
1067
|
-
price: r.itemPublicMeta.price,
|
|
1067
|
+
price: Number(r.itemPublicMeta.price),
|
|
1068
1068
|
image: r.itemPublicMeta.image_url,
|
|
1069
1069
|
description: r.itemPublicMeta.description,
|
|
1070
1070
|
ribbon: r.itemPublicMeta.label_tag === 'custom' ? r.itemPublicMeta.custom_label_tag : r.itemPublicMeta.label_tag,
|
|
@@ -7915,7 +7915,7 @@ var WSAPIAvatars = /*#__PURE__*/function (_WSAPIMiniGames) {
|
|
|
7915
7915
|
*
|
|
7916
7916
|
* // Newest-first within each base.
|
|
7917
7917
|
* for (const list of byBase.values()) {
|
|
7918
|
-
* list.sort((a, b) => b.dt_created
|
|
7918
|
+
* list.sort((a, b) => b.dt_created - a.dt_created);
|
|
7919
7919
|
* }
|
|
7920
7920
|
*
|
|
7921
7921
|
* console.log('[smartico] AI variants by base avatar — render as a carousel under each base');
|