@smartico/public-api 0.0.349 → 0.0.351
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/ClassId.d.ts +6 -0
- package/dist/SmarticoLib/index.d.ts +4 -0
- package/dist/WSAPI/WSAPI.d.ts +3 -4
- package/dist/index.js +11 -4
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +11 -4
- package/dist/index.modern.mjs.map +1 -1
- package/docs/api/classes/WSAPI.md +3 -4
- package/package.json +1 -1
- package/src/ActivityLog/GetActivityLogResponse.ts +2 -0
- package/src/Base/ClassId.ts +7 -0
- package/src/SmarticoLib/index.ts +4 -0
- package/src/WSAPI/WSAPI.ts +3 -4
|
@@ -7,12 +7,11 @@
|
|
|
7
7
|
▸ **getUserProfile**(): [`TUserProfile`](../interfaces/TUserProfile.md)
|
|
8
8
|
|
|
9
9
|
Returns information about current user
|
|
10
|
-
|
|
10
|
+
Pay attention that this method is synchronous and returns the user profile object immediately, not a promise.
|
|
11
11
|
**Example**:
|
|
12
12
|
```
|
|
13
|
-
_smartico.api.getUserProfile
|
|
14
|
-
|
|
15
|
-
});
|
|
13
|
+
var p = _smartico.api.getUserProfile);
|
|
14
|
+
console.log(p);
|
|
16
15
|
```
|
|
17
16
|
**Visitor mode: not supported**
|
|
18
17
|
|
package/package.json
CHANGED
|
@@ -20,6 +20,8 @@ export const ActivityLogTransform = (items: ActivityLogEntry[]): TActivityLog[]
|
|
|
20
20
|
source_type_id: item.source_type_id,
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
+
item.type = item.type ?? UserBalanceType.Points;
|
|
24
|
+
|
|
23
25
|
if (item.type === UserBalanceType.Diamonds || item.type === UserBalanceType.Gems) {
|
|
24
26
|
itemTransformed.type = item.type;
|
|
25
27
|
itemTransformed.amount = item.amount;
|
package/src/Base/ClassId.ts
CHANGED
|
@@ -102,6 +102,13 @@ export enum ClassId {
|
|
|
102
102
|
GET_POINT_HISTORY_REQUEST = 545,
|
|
103
103
|
GET_POINT_HISTORY_RESPONSE = 546,
|
|
104
104
|
|
|
105
|
+
GET_AVATARS_LIST_REQUEST = 560,
|
|
106
|
+
GET_AVATARS_LIST_RESPONSE = 561,
|
|
107
|
+
GET_AVATARS_CUSTOMIZED_REQUEST = 562,
|
|
108
|
+
GET_AVATARS_CUSTOMIZED_RESPONSE = 563,
|
|
109
|
+
GET_AVATAR_PROMPTS_REQUEST = 564,
|
|
110
|
+
GET_AVATAR_PROMPTS_RESPONSE = 565,
|
|
111
|
+
|
|
105
112
|
/*
|
|
106
113
|
!Important, if adding new messages that are 'acting' on behalf of the client,
|
|
107
114
|
you need to include them in the CLASS_ID_IGNORE_FOR_SIMULATION
|
package/src/SmarticoLib/index.ts
CHANGED
|
@@ -188,6 +188,10 @@ declare enum ClassId {
|
|
|
188
188
|
ACHIEVEMENT_CLAIM_PRIZE_RESPONSE = 540,
|
|
189
189
|
ACH_SHOP_ITEM_HISTORY_REQUEST = 541,
|
|
190
190
|
ACH_SHOP_ITEM_HISTORY_RESPONSE = 542,
|
|
191
|
+
GET_AVATARS_LIST_REQUEST = 560,
|
|
192
|
+
GET_AVATARS_LIST_RESPONSE = 561,
|
|
193
|
+
GET_AVATAR_PROMPTS_REQUEST = 564,
|
|
194
|
+
GET_AVATAR_PROMPTS_RESPONSE = 565,
|
|
191
195
|
GET_BONUSES_REQUEST = 600,
|
|
192
196
|
GET_BONUSES_RESPONSE = 601,
|
|
193
197
|
CLAIM_BONUS_REQUEST = 602,
|
package/src/WSAPI/WSAPI.ts
CHANGED
|
@@ -164,12 +164,11 @@ export class WSAPI {
|
|
|
164
164
|
}
|
|
165
165
|
|
|
166
166
|
/** Returns information about current user
|
|
167
|
-
*
|
|
167
|
+
* Pay attention that this method is synchronous and returns the user profile object immediately, not a promise.
|
|
168
168
|
* **Example**:
|
|
169
169
|
* ```
|
|
170
|
-
* _smartico.api.getUserProfile
|
|
171
|
-
*
|
|
172
|
-
* });
|
|
170
|
+
* var p = _smartico.api.getUserProfile);
|
|
171
|
+
* console.log(p);
|
|
173
172
|
* ```
|
|
174
173
|
* **Visitor mode: not supported**
|
|
175
174
|
* */
|