@rtsdk/topia 0.17.9 → 0.18.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/dist/index.cjs +362 -9
- package/dist/index.d.ts +239 -34
- package/dist/index.js +362 -9
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -74,7 +74,7 @@ type DroppedAssetLinkType = {
|
|
|
74
74
|
linkSamlQueryParams?: string;
|
|
75
75
|
};
|
|
76
76
|
|
|
77
|
-
type InteractiveCredentials = {
|
|
77
|
+
type InteractiveCredentials$1 = {
|
|
78
78
|
apiKey?: string;
|
|
79
79
|
assetId?: string;
|
|
80
80
|
interactiveNonce?: string;
|
|
@@ -88,22 +88,22 @@ type InteractiveCredentials = {
|
|
|
88
88
|
|
|
89
89
|
type AssetOptions = {
|
|
90
90
|
attributes?: AssetInterface | undefined;
|
|
91
|
-
credentials?: InteractiveCredentials | undefined;
|
|
91
|
+
credentials?: InteractiveCredentials$1 | undefined;
|
|
92
92
|
};
|
|
93
93
|
type DroppedAssetOptions = {
|
|
94
94
|
attributes?: DroppedAssetInterface | undefined;
|
|
95
|
-
credentials?: InteractiveCredentials | undefined;
|
|
95
|
+
credentials?: InteractiveCredentials$1 | undefined;
|
|
96
96
|
};
|
|
97
97
|
type UserOptions = {
|
|
98
|
-
credentials?: InteractiveCredentials | undefined;
|
|
98
|
+
credentials?: InteractiveCredentials$1 | undefined;
|
|
99
99
|
};
|
|
100
100
|
type VisitorOptions = {
|
|
101
101
|
attributes?: VisitorInterface | undefined;
|
|
102
|
-
credentials?: InteractiveCredentials | undefined;
|
|
102
|
+
credentials?: InteractiveCredentials$1 | undefined;
|
|
103
103
|
};
|
|
104
104
|
type WorldOptions = {
|
|
105
105
|
attributes?: WorldDetailsInterface | undefined;
|
|
106
|
-
credentials?: InteractiveCredentials | undefined;
|
|
106
|
+
credentials?: InteractiveCredentials$1 | undefined;
|
|
107
107
|
};
|
|
108
108
|
|
|
109
109
|
type ResponseType$1 = {
|
|
@@ -1172,6 +1172,38 @@ declare class World extends SDKController implements WorldInterface {
|
|
|
1172
1172
|
}): Promise<void | ResponseType$1>;
|
|
1173
1173
|
}
|
|
1174
1174
|
|
|
1175
|
+
/**
|
|
1176
|
+
* Controller for a user's owned inventory item.
|
|
1177
|
+
*
|
|
1178
|
+
* @remarks
|
|
1179
|
+
* This class should be instantiated via UserInventoryItemFactory only.
|
|
1180
|
+
*
|
|
1181
|
+
* @property inventoryItemId - The root inventory item's id
|
|
1182
|
+
*/
|
|
1183
|
+
declare class UserInventoryItem extends InventoryItem implements UserInventoryItemInterface {
|
|
1184
|
+
userItemId: string;
|
|
1185
|
+
user_id: string;
|
|
1186
|
+
item_id: string;
|
|
1187
|
+
quantity: number;
|
|
1188
|
+
created_at?: Date;
|
|
1189
|
+
updated_at?: Date;
|
|
1190
|
+
metadata?: object | null;
|
|
1191
|
+
grant_source: string;
|
|
1192
|
+
type: string;
|
|
1193
|
+
constructor(topia: Topia, id: string, options?: UserInventoryItemOptionalInterface);
|
|
1194
|
+
/**
|
|
1195
|
+
* Fetches the user inventory item details from the platform and assigns them to this instance.
|
|
1196
|
+
*
|
|
1197
|
+
* @example
|
|
1198
|
+
* ```ts
|
|
1199
|
+
* await userInventoryItem.fetchUserInventoryItemById();
|
|
1200
|
+
* ```
|
|
1201
|
+
*
|
|
1202
|
+
* @returns {Promise<void>} Returns when the item has been fetched and assigned.
|
|
1203
|
+
*/
|
|
1204
|
+
fetchUserInventoryItemById(): Promise<void>;
|
|
1205
|
+
}
|
|
1206
|
+
|
|
1175
1207
|
/**
|
|
1176
1208
|
* Create an instance of User class with optional session credentials.
|
|
1177
1209
|
*
|
|
@@ -1615,6 +1647,53 @@ declare class User extends SDKController implements UserInterface {
|
|
|
1615
1647
|
releaseLock?: boolean;
|
|
1616
1648
|
};
|
|
1617
1649
|
}): Promise<void | ResponseType$1>;
|
|
1650
|
+
/**
|
|
1651
|
+
* Retrieves all inventory items owned by this visitor and app's key.
|
|
1652
|
+
*
|
|
1653
|
+
* @keywords get, fetch, retrieve, list, inventory, items, visitor
|
|
1654
|
+
*
|
|
1655
|
+
* @example
|
|
1656
|
+
* ```ts
|
|
1657
|
+
* const items = await visitor.fetchInventoryItems();
|
|
1658
|
+
* ```
|
|
1659
|
+
*
|
|
1660
|
+
* @returns {Promise<void>} Returns an array of InventoryItem objects.
|
|
1661
|
+
*/
|
|
1662
|
+
fetchInventoryItems(): Promise<void>;
|
|
1663
|
+
get inventoryItems(): UserInventoryItem[];
|
|
1664
|
+
}
|
|
1665
|
+
|
|
1666
|
+
/**
|
|
1667
|
+
* InventoryItem represents an item in a user's inventory.
|
|
1668
|
+
*
|
|
1669
|
+
* @remarks
|
|
1670
|
+
* This class should be instantiated via InventoryFactory only.
|
|
1671
|
+
*
|
|
1672
|
+
* @keywords inventory, item, asset, object
|
|
1673
|
+
*/
|
|
1674
|
+
declare class InventoryItem extends SDKController implements InventoryItemInterface {
|
|
1675
|
+
id: string;
|
|
1676
|
+
name?: string;
|
|
1677
|
+
description?: string;
|
|
1678
|
+
type?: string;
|
|
1679
|
+
created_at?: Date;
|
|
1680
|
+
updated_at?: Date;
|
|
1681
|
+
metadata?: object | null;
|
|
1682
|
+
image_path?: string;
|
|
1683
|
+
interactive_key_id?: string;
|
|
1684
|
+
status?: string;
|
|
1685
|
+
constructor(topia: Topia, id: string, options?: InventoryItemOptionalInterface);
|
|
1686
|
+
/**
|
|
1687
|
+
* Fetches the inventory item details from the platform and assigns them to this instance.
|
|
1688
|
+
*
|
|
1689
|
+
* @example
|
|
1690
|
+
* ```ts
|
|
1691
|
+
* await item.fetchInventoryItemById();
|
|
1692
|
+
* ```
|
|
1693
|
+
*
|
|
1694
|
+
* @returns {Promise<InventoryItem>} Returns when the item has been fetched and assigned.
|
|
1695
|
+
*/
|
|
1696
|
+
fetchInventoryItemById(): Promise<InventoryItem>;
|
|
1618
1697
|
}
|
|
1619
1698
|
|
|
1620
1699
|
/**
|
|
@@ -1628,6 +1707,7 @@ declare class User extends SDKController implements UserInterface {
|
|
|
1628
1707
|
* ```
|
|
1629
1708
|
*/
|
|
1630
1709
|
declare class Visitor extends User implements VisitorInterface {
|
|
1710
|
+
#private;
|
|
1631
1711
|
readonly id: number;
|
|
1632
1712
|
urlSlug: string;
|
|
1633
1713
|
user?: User;
|
|
@@ -1945,6 +2025,61 @@ declare class Visitor extends User implements VisitorInterface {
|
|
|
1945
2025
|
sendSignalToVisitor(signal: any): Promise<void | (ResponseType$1 & {
|
|
1946
2026
|
answerSignal: any;
|
|
1947
2027
|
})>;
|
|
2028
|
+
/**
|
|
2029
|
+
* Retrieves all inventory items owned by this visitor and app's key.
|
|
2030
|
+
*
|
|
2031
|
+
* @keywords get, fetch, retrieve, list, inventory, items, visitor
|
|
2032
|
+
*
|
|
2033
|
+
* @example
|
|
2034
|
+
* ```ts
|
|
2035
|
+
* const items = await visitor.fetchInventoryItems();
|
|
2036
|
+
* ```
|
|
2037
|
+
*
|
|
2038
|
+
* @returns {Promise<void>} Returns an array of InventoryItem objects.
|
|
2039
|
+
*/
|
|
2040
|
+
fetchInventoryItem(item: InventoryItem): Promise<UserInventoryItem>;
|
|
2041
|
+
/**
|
|
2042
|
+
* Retrieves all inventory items owned by this visitor and app's key.
|
|
2043
|
+
*
|
|
2044
|
+
* @keywords get, fetch, retrieve, list, inventory, items, visitor
|
|
2045
|
+
*
|
|
2046
|
+
* @example
|
|
2047
|
+
* ```ts
|
|
2048
|
+
* const items = await visitor.fetchInventoryItems();
|
|
2049
|
+
* ```
|
|
2050
|
+
*
|
|
2051
|
+
* @returns {Promise<void>} Returns an array of InventoryItem objects.
|
|
2052
|
+
*/
|
|
2053
|
+
fetchInventoryItems(): Promise<void>;
|
|
2054
|
+
get inventoryItems(): UserInventoryItem[];
|
|
2055
|
+
/**
|
|
2056
|
+
* Grants an inventory item to this visitor.
|
|
2057
|
+
*
|
|
2058
|
+
* @param itemId The ID of the inventory item to grant.
|
|
2059
|
+
* @param quantity The quantity to grant (default 1).
|
|
2060
|
+
*
|
|
2061
|
+
* @example
|
|
2062
|
+
* ```ts
|
|
2063
|
+
* await visitor.grantInventoryItem("item-id-123", 2);
|
|
2064
|
+
* ```
|
|
2065
|
+
*
|
|
2066
|
+
* @returns {Promise<UserInventoryItem>} Returns the updated inventory or a response object.
|
|
2067
|
+
*/
|
|
2068
|
+
grantInventoryItem(item: InventoryItem, quantity?: number): Promise<UserInventoryItem>;
|
|
2069
|
+
/**
|
|
2070
|
+
* Modifies the quantity of an inventory item in this visitor's inventory.
|
|
2071
|
+
*
|
|
2072
|
+
* @param itemId The ID of the inventory item to modify.
|
|
2073
|
+
* @param quantity The new quantity to set.
|
|
2074
|
+
*
|
|
2075
|
+
* @example
|
|
2076
|
+
* ```ts
|
|
2077
|
+
* await visitor.modifyInventoryItemQuantity("item-id-123", 5);
|
|
2078
|
+
* ```
|
|
2079
|
+
*
|
|
2080
|
+
* @returns {Promise<UserInventoryItem>} Returns the updated inventory or a response object.
|
|
2081
|
+
*/
|
|
2082
|
+
modifyInventoryItemQuantity(item: UserInventoryItem, quantity: number): Promise<UserInventoryItem>;
|
|
1948
2083
|
}
|
|
1949
2084
|
|
|
1950
2085
|
type VisitorType = {
|
|
@@ -1987,7 +2122,7 @@ declare enum WorldActivityType {
|
|
|
1987
2122
|
}
|
|
1988
2123
|
|
|
1989
2124
|
interface SDKInterface {
|
|
1990
|
-
credentials?: InteractiveCredentials;
|
|
2125
|
+
credentials?: InteractiveCredentials$1;
|
|
1991
2126
|
jwt?: string;
|
|
1992
2127
|
requestOptions: object;
|
|
1993
2128
|
topia: Topia;
|
|
@@ -2024,7 +2159,7 @@ interface AssetInterface extends SDKInterface {
|
|
|
2024
2159
|
}
|
|
2025
2160
|
type AssetOptionalInterface = {
|
|
2026
2161
|
attributes?: AssetInterface | object;
|
|
2027
|
-
credentials?: InteractiveCredentials;
|
|
2162
|
+
credentials?: InteractiveCredentials$1;
|
|
2028
2163
|
};
|
|
2029
2164
|
|
|
2030
2165
|
interface DroppedAssetInterface extends AssetInterface {
|
|
@@ -2146,7 +2281,7 @@ interface DroppedAssetOptionalInterface {
|
|
|
2146
2281
|
text?: string;
|
|
2147
2282
|
urlSlug?: string;
|
|
2148
2283
|
};
|
|
2149
|
-
credentials?: InteractiveCredentials | object;
|
|
2284
|
+
credentials?: InteractiveCredentials$1 | object;
|
|
2150
2285
|
}
|
|
2151
2286
|
interface UpdateBroadcastInterface {
|
|
2152
2287
|
assetBroadcast?: boolean;
|
|
@@ -2238,7 +2373,7 @@ interface EcosystemInterface {
|
|
|
2238
2373
|
incrementDataObjectValue(path: string, amount: number, options: object): Promise<void | ResponseType$1>;
|
|
2239
2374
|
}
|
|
2240
2375
|
interface EcosystemOptionalInterface {
|
|
2241
|
-
credentials?: InteractiveCredentials;
|
|
2376
|
+
credentials?: InteractiveCredentials$1;
|
|
2242
2377
|
}
|
|
2243
2378
|
|
|
2244
2379
|
interface SceneInterface {
|
|
@@ -2266,7 +2401,7 @@ interface SceneInterface {
|
|
|
2266
2401
|
}
|
|
2267
2402
|
type SceneOptionalInterface = {
|
|
2268
2403
|
attributes?: SceneInterface | object;
|
|
2269
|
-
credentials?: InteractiveCredentials;
|
|
2404
|
+
credentials?: InteractiveCredentials$1;
|
|
2270
2405
|
};
|
|
2271
2406
|
|
|
2272
2407
|
interface FireToastInterface {
|
|
@@ -2309,7 +2444,7 @@ interface UserInterface {
|
|
|
2309
2444
|
dataObject?: object | null;
|
|
2310
2445
|
}
|
|
2311
2446
|
interface UserOptionalInterface {
|
|
2312
|
-
credentials?: InteractiveCredentials;
|
|
2447
|
+
credentials?: InteractiveCredentials$1;
|
|
2313
2448
|
profileId?: string | null;
|
|
2314
2449
|
visitorId?: number | null;
|
|
2315
2450
|
urlSlug?: string;
|
|
@@ -2332,19 +2467,24 @@ interface VisitorInterface extends SDKInterface {
|
|
|
2332
2467
|
name?: string;
|
|
2333
2468
|
}): Promise<ResponseType$1>;
|
|
2334
2469
|
getAllParticles(): Promise<ResponseType$1>;
|
|
2470
|
+
fetchInventoryItems(): Promise<void>;
|
|
2471
|
+
inventoryItems: UserInventoryItem[];
|
|
2472
|
+
grantInventoryItem(item: InventoryItem, quantity: number): Promise<UserInventoryItem>;
|
|
2473
|
+
modifyInventoryItemQuantity(item: UserInventoryItem, quantity: number): Promise<UserInventoryItem>;
|
|
2474
|
+
fetchInventoryItem(item: InventoryItem): Promise<UserInventoryItem>;
|
|
2335
2475
|
triggerParticle({ id, name, duration, }: {
|
|
2336
2476
|
id?: string;
|
|
2337
2477
|
name?: string;
|
|
2338
2478
|
duration?: number;
|
|
2339
|
-
fetchDataObject(appPublicKey?: string, appJWT?: string, sharedAppPublicKey?: string, sharedAppJWT?: string): Promise<void | ResponseType$1>;
|
|
2340
|
-
setDataObject(dataObject: object | null | undefined, options: object): Promise<void | ResponseType$1>;
|
|
2341
|
-
updateDataObject(dataObject: object, options: object): Promise<void | ResponseType$1>;
|
|
2342
|
-
incrementDataObjectValue(path: string, amount: number, options: object): Promise<void | ResponseType$1>;
|
|
2343
|
-
updatePublicKeyAnalytics(analytics?: AnalyticType[]): Promise<void | ResponseType$1>;
|
|
2344
|
-
sendSignalToVisitor(signal: any): Promise<void | (ResponseType$1 & {
|
|
2345
|
-
answerSignal: any;
|
|
2346
|
-
})>;
|
|
2347
2479
|
}): Promise<ResponseType$1 | string>;
|
|
2480
|
+
fetchDataObject(appPublicKey?: string, appJWT?: string, sharedAppPublicKey?: string, sharedAppJWT?: string): Promise<void | ResponseType$1>;
|
|
2481
|
+
setDataObject(dataObject: object | null | undefined, options: object): Promise<void | ResponseType$1>;
|
|
2482
|
+
updateDataObject(dataObject: object, options: object): Promise<void | ResponseType$1>;
|
|
2483
|
+
incrementDataObjectValue(path: string, amount: number, options: object): Promise<void | ResponseType$1>;
|
|
2484
|
+
updatePublicKeyAnalytics(analytics?: AnalyticType[]): Promise<void | ResponseType$1>;
|
|
2485
|
+
sendSignalToVisitor(signal: any): Promise<void | (ResponseType$1 & {
|
|
2486
|
+
answerSignal: any;
|
|
2487
|
+
})>;
|
|
2348
2488
|
color?: string;
|
|
2349
2489
|
dataObject?: object | null | undefined;
|
|
2350
2490
|
displayName?: string;
|
|
@@ -2375,7 +2515,7 @@ interface VisitorInterface extends SDKInterface {
|
|
|
2375
2515
|
}
|
|
2376
2516
|
interface VisitorOptionalInterface {
|
|
2377
2517
|
attributes?: VisitorInterface | object;
|
|
2378
|
-
credentials?: InteractiveCredentials;
|
|
2518
|
+
credentials?: InteractiveCredentials$1;
|
|
2379
2519
|
}
|
|
2380
2520
|
interface MoveVisitorInterface {
|
|
2381
2521
|
shouldTeleportVisitor: boolean;
|
|
@@ -2408,12 +2548,12 @@ interface WebRTCConnectorInterface {
|
|
|
2408
2548
|
getTwilioConfig(): Promise<void | ResponseType$1>;
|
|
2409
2549
|
}
|
|
2410
2550
|
interface WebRTCConnectorOptionalInterface {
|
|
2411
|
-
credentials?: InteractiveCredentials;
|
|
2551
|
+
credentials?: InteractiveCredentials$1;
|
|
2412
2552
|
twilioConfig?: object;
|
|
2413
2553
|
}
|
|
2414
2554
|
|
|
2415
2555
|
interface WorldActivityOptionalInterface {
|
|
2416
|
-
credentials?: InteractiveCredentials;
|
|
2556
|
+
credentials?: InteractiveCredentials$1;
|
|
2417
2557
|
}
|
|
2418
2558
|
interface MoveAllVisitorsInterface {
|
|
2419
2559
|
shouldFetchVisitors?: boolean;
|
|
@@ -2503,12 +2643,62 @@ interface WorldInterface extends SDKInterface, WorldDetailsInterface {
|
|
|
2503
2643
|
}
|
|
2504
2644
|
interface WorldOptionalInterface {
|
|
2505
2645
|
attributes?: WorldDetailsInterface | object;
|
|
2506
|
-
credentials?: InteractiveCredentials;
|
|
2646
|
+
credentials?: InteractiveCredentials$1;
|
|
2507
2647
|
}
|
|
2508
2648
|
interface WorldWebhooksInterface {
|
|
2509
2649
|
webhooks: Array<WebhookInterface>;
|
|
2510
2650
|
}
|
|
2511
2651
|
|
|
2652
|
+
type InteractiveCredentials = {
|
|
2653
|
+
apiKey?: string;
|
|
2654
|
+
assetId?: string;
|
|
2655
|
+
interactiveNonce?: string;
|
|
2656
|
+
interactivePublicKey?: string;
|
|
2657
|
+
profileId?: string | null;
|
|
2658
|
+
urlSlug?: string;
|
|
2659
|
+
visitorId?: number;
|
|
2660
|
+
iframeId?: string;
|
|
2661
|
+
gameEngineId?: string;
|
|
2662
|
+
};
|
|
2663
|
+
|
|
2664
|
+
/**
|
|
2665
|
+
* Interface for an inventory item.
|
|
2666
|
+
*/
|
|
2667
|
+
interface InventoryItemInterface extends SDKInterface {
|
|
2668
|
+
id: string;
|
|
2669
|
+
name?: string;
|
|
2670
|
+
description?: string;
|
|
2671
|
+
type?: string;
|
|
2672
|
+
created_at?: Date;
|
|
2673
|
+
updated_at?: Date;
|
|
2674
|
+
metadata?: object | null;
|
|
2675
|
+
image_path?: string;
|
|
2676
|
+
interactive_key_id?: string;
|
|
2677
|
+
status?: string;
|
|
2678
|
+
}
|
|
2679
|
+
type InventoryItemOptionalInterface = {
|
|
2680
|
+
attributes?: InventoryItemInterface | object;
|
|
2681
|
+
credentials?: InteractiveCredentials;
|
|
2682
|
+
};
|
|
2683
|
+
|
|
2684
|
+
/**
|
|
2685
|
+
* Interface for a user-owned inventory item.
|
|
2686
|
+
*/
|
|
2687
|
+
interface UserInventoryItemInterface extends InventoryItemInterface {
|
|
2688
|
+
userItemId: string;
|
|
2689
|
+
user_id: string;
|
|
2690
|
+
item_id: string;
|
|
2691
|
+
quantity: number;
|
|
2692
|
+
created_at?: Date;
|
|
2693
|
+
updated_at?: Date;
|
|
2694
|
+
metadata?: object | null;
|
|
2695
|
+
grant_source: string;
|
|
2696
|
+
}
|
|
2697
|
+
type UserInventoryItemOptionalInterface = {
|
|
2698
|
+
attributes?: UserInventoryItemInterface | object;
|
|
2699
|
+
credentials?: InteractiveCredentials;
|
|
2700
|
+
};
|
|
2701
|
+
|
|
2512
2702
|
/**
|
|
2513
2703
|
* Create a single instance of Topia axios used for all calls to the public API in all classes
|
|
2514
2704
|
*
|
|
@@ -2562,11 +2752,11 @@ declare class Topia implements TopiaInterface {
|
|
|
2562
2752
|
* ```
|
|
2563
2753
|
*/
|
|
2564
2754
|
declare abstract class SDKController implements SDKInterface {
|
|
2565
|
-
credentials: InteractiveCredentials | undefined;
|
|
2755
|
+
credentials: InteractiveCredentials$1 | undefined;
|
|
2566
2756
|
jwt?: string;
|
|
2567
2757
|
requestOptions: object;
|
|
2568
2758
|
topia: Topia;
|
|
2569
|
-
constructor(topia: Topia, credentials?: InteractiveCredentials);
|
|
2759
|
+
constructor(topia: Topia, credentials?: InteractiveCredentials$1);
|
|
2570
2760
|
topiaPublicApi(): axios.AxiosInstance;
|
|
2571
2761
|
errorHandler({ error, message, params, sdkMethod, }: {
|
|
2572
2762
|
error?: Error | AxiosError | unknown;
|
|
@@ -2660,6 +2850,7 @@ declare class Asset extends SDKController implements AssetInterface {
|
|
|
2660
2850
|
* ```
|
|
2661
2851
|
*/
|
|
2662
2852
|
declare class Ecosystem extends SDKController {
|
|
2853
|
+
#private;
|
|
2663
2854
|
dataObject?: object | null | undefined;
|
|
2664
2855
|
constructor(topia: Topia, options?: EcosystemOptionalInterface);
|
|
2665
2856
|
/**
|
|
@@ -2778,6 +2969,20 @@ declare class Ecosystem extends SDKController {
|
|
|
2778
2969
|
releaseLock?: boolean;
|
|
2779
2970
|
};
|
|
2780
2971
|
}): Promise<void | ResponseType$1>;
|
|
2972
|
+
/**
|
|
2973
|
+
* Retrieves all inventory items for a given keyholder (app public key).
|
|
2974
|
+
*
|
|
2975
|
+
* @keywords get, fetch, retrieve, list, inventory, items, keyholder
|
|
2976
|
+
*
|
|
2977
|
+
* @example
|
|
2978
|
+
* ```ts
|
|
2979
|
+
* const items = await ecosystem.fetchInventoryItems("appPublicKey", "appJWT");
|
|
2980
|
+
* ```
|
|
2981
|
+
*
|
|
2982
|
+
* @returns {Promise<object[]>} Returns an array of InventoryItem objects.
|
|
2983
|
+
*/
|
|
2984
|
+
fetchInventoryItems(): Promise<void>;
|
|
2985
|
+
get inventoryItems(): InventoryItem[];
|
|
2781
2986
|
}
|
|
2782
2987
|
|
|
2783
2988
|
/**
|
|
@@ -2942,7 +3147,7 @@ declare class WorldActivity extends SDKController {
|
|
|
2942
3147
|
declare class AssetFactory extends SDKController {
|
|
2943
3148
|
constructor(topia: Topia);
|
|
2944
3149
|
/**
|
|
2945
|
-
* Instantiate a new instance of Asset class with the specified asset
|
|
3150
|
+
* Instantiate a new instance of Asset class with the specified asset id.
|
|
2946
3151
|
*
|
|
2947
3152
|
* @remarks
|
|
2948
3153
|
* This method creates a new Asset controller instance that can be used to interact with an existing asset.
|
|
@@ -3104,7 +3309,7 @@ declare class DroppedAssetFactory extends SDKController {
|
|
|
3104
3309
|
*
|
|
3105
3310
|
* @remarks
|
|
3106
3311
|
* This method leverages the handleGetDroppedAssetByUniqueName endpoint in the Public API and assumes there is exactly one dropped asset with the matching uniqueName for the given urlSlug.
|
|
3107
|
-
* Use this when you need to find a dropped asset by its uniqueName rather than its
|
|
3312
|
+
* Use this when you need to find a dropped asset by its uniqueName rather than its id.
|
|
3108
3313
|
*
|
|
3109
3314
|
* @keywords find, search, unique name, retrieve, locate, lookup, dropped asset
|
|
3110
3315
|
*
|
|
@@ -3131,7 +3336,7 @@ declare class DroppedAssetFactory extends SDKController {
|
|
|
3131
3336
|
*
|
|
3132
3337
|
* @returns {Promise<DroppedAsset>} Returns a new DroppedAsset object with all properties already fetched.
|
|
3133
3338
|
*/
|
|
3134
|
-
getWithUniqueName(uniqueName: string, urlSlug: string, interactiveSecret: string, credentials: InteractiveCredentials): Promise<DroppedAsset>;
|
|
3339
|
+
getWithUniqueName(uniqueName: string, urlSlug: string, interactiveSecret: string, credentials: InteractiveCredentials$1): Promise<DroppedAsset>;
|
|
3135
3340
|
/**
|
|
3136
3341
|
* Drops an asset in a world and returns a new instance of DroppedAsset class with all properties.
|
|
3137
3342
|
*
|
|
@@ -3301,7 +3506,7 @@ declare class SceneFactory {
|
|
|
3301
3506
|
*
|
|
3302
3507
|
* @remarks
|
|
3303
3508
|
* This method creates a controller instance for working with a scene but does not fetch its properties.
|
|
3304
|
-
* Use this when you need to interact with a specific scene by its
|
|
3509
|
+
* Use this when you need to interact with a specific scene by its id.
|
|
3305
3510
|
*
|
|
3306
3511
|
* @keywords create, instantiate, scene, initialize, instance, template
|
|
3307
3512
|
*
|
|
@@ -3369,7 +3574,7 @@ declare class UserFactory {
|
|
|
3369
3574
|
*
|
|
3370
3575
|
* @remarks
|
|
3371
3576
|
* This method creates a controller instance for interacting with user-specific operations.
|
|
3372
|
-
* The User controller doesn't require an
|
|
3577
|
+
* The User controller doesn't require an id since it represents the currently authenticated user.
|
|
3373
3578
|
*
|
|
3374
3579
|
* @keywords create, instantiate, user, initialize, account, profile, member
|
|
3375
3580
|
*
|
|
@@ -3435,7 +3640,7 @@ declare class VisitorFactory {
|
|
|
3435
3640
|
*
|
|
3436
3641
|
* // Create a Visitor instance with credentials
|
|
3437
3642
|
* const visitorInstance = Visitor.create(
|
|
3438
|
-
* 12345, // visitor
|
|
3643
|
+
* 12345, // visitor id
|
|
3439
3644
|
* "my-world-slug",
|
|
3440
3645
|
* {
|
|
3441
3646
|
* credentials: {
|
|
@@ -3471,7 +3676,7 @@ declare class VisitorFactory {
|
|
|
3471
3676
|
*
|
|
3472
3677
|
* // Get a fully populated Visitor instance
|
|
3473
3678
|
* const visitorInstance = await Visitor.get(
|
|
3474
|
-
* 12345, // visitor
|
|
3679
|
+
* 12345, // visitor id
|
|
3475
3680
|
* "my-world-slug",
|
|
3476
3681
|
* {
|
|
3477
3682
|
* credentials: {
|
|
@@ -3713,4 +3918,4 @@ declare class WorldFactory extends SDKController {
|
|
|
3713
3918
|
}>;
|
|
3714
3919
|
}
|
|
3715
3920
|
|
|
3716
|
-
export { AnalyticType, AnimationMetaType, Asset, AssetFactory, AssetInterface, AssetOptionalInterface, AssetOptions, AssetType, DroppedAsset, DroppedAssetClickType, DroppedAssetFactory, DroppedAssetInterface, DroppedAssetLinkType, DroppedAssetMediaType, DroppedAssetMediaVolumeRadius, DroppedAssetOptionalInterface, DroppedAssetOptions, Ecosystem, EcosystemFactory, EcosystemInterface, EcosystemOptionalInterface, FireToastInterface, FrameType, InteractiveCredentials, MoveAllVisitorsInterface, MoveVisitorInterface, OpenIframeInterface, RemoveClickableLinkInterface, ResponseType$1 as ResponseType, SDKController, SDKInterface, Scene, SceneFactory, SceneInterface, SceneOptionalInterface, SetClickableLinkMultiInterface, Topia, TopiaInterface, UpdateBroadcastInterface, UpdateClickTypeInterface, UpdateClickableLinkMultiInterface, UpdateDroppedAssetInterface, UpdateMediaTypeInterface, UpdatePrivateZoneInterface, User, UserFactory, UserInterface, UserOptionalInterface, UserOptions, Visitor, VisitorFactory, VisitorInterface, VisitorOptionalInterface, VisitorOptions, VisitorType, VisitorsToMoveArrayType, VisitorsToMoveType, WebRTCConnector, WebRTCConnectorFactory, WebRTCConnectorInterface, WebRTCConnectorOptionalInterface, WebhookInterface, World, WorldActivity, WorldActivityFactory, WorldActivityOptionalInterface, WorldActivityType, WorldDetailsInterface, WorldFactory, WorldInterface, WorldOptionalInterface, WorldOptions, WorldWebhooksInterface };
|
|
3921
|
+
export { AnalyticType, AnimationMetaType, Asset, AssetFactory, AssetInterface, AssetOptionalInterface, AssetOptions, AssetType, DroppedAsset, DroppedAssetClickType, DroppedAssetFactory, DroppedAssetInterface, DroppedAssetLinkType, DroppedAssetMediaType, DroppedAssetMediaVolumeRadius, DroppedAssetOptionalInterface, DroppedAssetOptions, Ecosystem, EcosystemFactory, EcosystemInterface, EcosystemOptionalInterface, FireToastInterface, FrameType, InteractiveCredentials$1 as InteractiveCredentials, InventoryItemInterface, InventoryItemOptionalInterface, MoveAllVisitorsInterface, MoveVisitorInterface, OpenIframeInterface, RemoveClickableLinkInterface, ResponseType$1 as ResponseType, SDKController, SDKInterface, Scene, SceneFactory, SceneInterface, SceneOptionalInterface, SetClickableLinkMultiInterface, Topia, TopiaInterface, UpdateBroadcastInterface, UpdateClickTypeInterface, UpdateClickableLinkMultiInterface, UpdateDroppedAssetInterface, UpdateMediaTypeInterface, UpdatePrivateZoneInterface, User, UserFactory, UserInterface, UserInventoryItemInterface, UserInventoryItemOptionalInterface, UserOptionalInterface, UserOptions, Visitor, VisitorFactory, VisitorInterface, VisitorOptionalInterface, VisitorOptions, VisitorType, VisitorsToMoveArrayType, VisitorsToMoveType, WebRTCConnector, WebRTCConnectorFactory, WebRTCConnectorInterface, WebRTCConnectorOptionalInterface, WebhookInterface, World, WorldActivity, WorldActivityFactory, WorldActivityOptionalInterface, WorldActivityType, WorldDetailsInterface, WorldFactory, WorldInterface, WorldOptionalInterface, WorldOptions, WorldWebhooksInterface };
|