@rtsdk/topia 0.17.7 → 0.17.9

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.d.ts CHANGED
@@ -117,9 +117,11 @@ type ResponseType$1 = {
117
117
  *
118
118
  * @example
119
119
  * ```ts
120
- * const scene = await new Scene(topia, "sceneId", {
120
+ * import { Scene } from "utils/topiaInit.ts";
121
+ *
122
+ * const scene = await Scene.get(exampleSceneId, {
121
123
  * attributes: { name: "My Scene" },
122
- * credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }
124
+ * credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", visitorId: 1, urlSlug: "exampleUrlSlug" }
123
125
  * });
124
126
  * ```
125
127
  */
@@ -129,6 +131,8 @@ declare class Scene extends SDKController implements SceneInterface {
129
131
  /**
130
132
  * Retrieves scene details and assigns response data to the instance.
131
133
  *
134
+ * @keywords get, fetch, retrieve, load, details, info, information, scene
135
+ *
132
136
  * @example
133
137
  * ```ts
134
138
  * await scene.fetchSceneById();
@@ -143,9 +147,10 @@ declare class Scene extends SDKController implements SceneInterface {
143
147
  *
144
148
  * @example
145
149
  * ```ts
146
- * const droppedAsset = await new DroppedAsset(topia, "1giFZb0sQ3X27L7uGyQX", "example", {
147
- * attributes: { text: "My Dropped Asset" },
148
- * credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }
150
+ * import { DroppedAsset } from "utils/topiaInit.ts";
151
+ *
152
+ * const droppedAsset = await DroppedAsset.get(exampleDroppedAssetId, exampleUrlSlug, {
153
+ * credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", visitorId: 1, urlSlug: "exampleUrlSlug" }
149
154
  * });
150
155
  * ```
151
156
  */
@@ -165,6 +170,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
165
170
  /**
166
171
  * Retrieves dropped asset details and assigns response data to the instance.
167
172
  *
173
+ * @keywords get, fetch, retrieve, load, details, info, information
174
+ *
168
175
  * @example
169
176
  * ```ts
170
177
  * await droppedAsset.fetchDroppedAssetById();
@@ -175,6 +182,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
175
182
  /**
176
183
  * Updates dropped asset details and assigns the response data to the instance. Requires Public Key to have the `canUpdateDroppedAssets` permission.
177
184
  *
185
+ * @keywords update, modify, change, edit, alter, transform
186
+ *
178
187
  * @example
179
188
  * ```ts
180
189
  * const payload = {
@@ -206,6 +215,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
206
215
  /**
207
216
  * Deletes the dropped asset (removes it from the world).
208
217
  *
218
+ * @keywords remove, delete, erase, destroy, eliminate
219
+ *
209
220
  * @example
210
221
  * ```ts
211
222
  * await droppedAsset.deleteDroppedAsset();
@@ -215,6 +226,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
215
226
  /**
216
227
  * Retrieves the data object for a dropped asset.
217
228
  *
229
+ * @keywords get, fetch, retrieve, load, data, object, state
230
+ *
218
231
  * @category Data Objects
219
232
  *
220
233
  * @example
@@ -231,6 +244,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
231
244
  * @remarks
232
245
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
233
246
  *
247
+ * @keywords set, assign, store, save, data, object, state
248
+ *
234
249
  * @category Data Objects
235
250
  *
236
251
  * @example
@@ -263,6 +278,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
263
278
  * @remarks
264
279
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
265
280
  *
281
+ * @keywords update, modify, change, edit, alter, data, object, state
282
+ *
266
283
  * @category Data Objects
267
284
  *
268
285
  * @example
@@ -292,6 +309,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
292
309
  * @remarks
293
310
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
294
311
  *
312
+ * @keywords increment, increase, add, count, data, object, state
313
+ *
295
314
  * @category Data Objects
296
315
  *
297
316
  * @example
@@ -313,6 +332,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
313
332
  /**
314
333
  * Updates broadcast options for a dropped asset.
315
334
  *
335
+ * @keywords broadcast, dropped asset settings
336
+ *
316
337
  * @example
317
338
  * ```ts
318
339
  * await droppedAsset.updateBroadcast({
@@ -328,6 +349,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
328
349
  /**
329
350
  * Updates click options for a dropped asset.
330
351
  *
352
+ * @keywords click, link, interaction, url, dropped asset settings
353
+ *
331
354
  * @example
332
355
  * ```ts
333
356
  * await droppedAsset.updateClickType({
@@ -350,6 +373,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
350
373
  /**
351
374
  * Adds an array of links to an asset. Maximum is 20 links.
352
375
  *
376
+ * @keywords links, multiple, clickable, urls, hyperlinks, dropped asset settings
377
+ *
353
378
  * @example
354
379
  * ```ts
355
380
  * await droppedAsset.setClickableLinkMulti({
@@ -379,6 +404,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
379
404
  * @remarks
380
405
  * Pass in an 'existingLinkId' to edit an existing link.
381
406
  *
407
+ * @keywords links, multiple, clickable, urls, dropped asset settings
408
+ *
382
409
  * @example
383
410
  * ```ts
384
411
  * await droppedAsset.updateClickableLinkMulti({
@@ -396,6 +423,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
396
423
  /**
397
424
  * Removes a clickable link from a dropped asset.
398
425
  *
426
+ * @keywords remove, delete, link, clickable, url, erase, dropped asset settings
427
+ *
399
428
  * @example
400
429
  * ```ts
401
430
  * await droppedAsset.removeClickableLink({ linkId: "link-id" });
@@ -407,6 +436,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
407
436
  /**
408
437
  * Updates text and style of a dropped asset.
409
438
  *
439
+ * @keywords text, style, dropped asset settings
440
+ *
410
441
  * @example
411
442
  * ```ts
412
443
  * const style = {
@@ -425,6 +456,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
425
456
  /**
426
457
  * Updates media options for a dropped asset.
427
458
  *
459
+ * @keywords media, video, audio, dropped asset settings
460
+ *
428
461
  * @example
429
462
  * ```ts
430
463
  * await droppedAsset.updateMediaType({
@@ -445,6 +478,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
445
478
  /**
446
479
  * Updates mute zone options for a dropped asset.
447
480
  *
481
+ * @keywords mute, zone, dropped asset settings
482
+ *
448
483
  * @example
449
484
  * ```ts
450
485
  * await droppedAsset.updateMuteZone(true);
@@ -456,6 +491,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
456
491
  /**
457
492
  * Updates landmark zone options for a dropped asset.
458
493
  *
494
+ * @keywords landmark, zone, dropped asset settings
495
+ *
459
496
  * @example
460
497
  * ```ts
461
498
  * await droppedAsset.updateLandmarkZone({
@@ -475,6 +512,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
475
512
  /**
476
513
  * Updates webhook zone options for a dropped asset.
477
514
  *
515
+ * @keywords webhook, zone, dropped asset settings
516
+ *
478
517
  * @example
479
518
  * ```ts
480
519
  * await droppedAsset.updateWebhookZone(true);
@@ -486,6 +525,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
486
525
  /**
487
526
  * Moves a dropped asset to specified coordinates.
488
527
  *
528
+ * @keywords position, dropped asset settings
529
+ *
489
530
  * @example
490
531
  * ```ts
491
532
  * await droppedAsset.updatePosition(100, 200, 100);
@@ -497,6 +538,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
497
538
  /**
498
539
  * Updates private zone options for a dropped asset.
499
540
  *
541
+ * @keywords private, zone, dropped asset settings
542
+ *
500
543
  * @example
501
544
  * ```ts
502
545
  * await droppedAsset.updatePrivateZone({
@@ -512,6 +555,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
512
555
  /**
513
556
  * Updates the size of a dropped asset.
514
557
  *
558
+ * @keywords size, scale, dropped asset settings
559
+ *
515
560
  * @example
516
561
  * ```ts
517
562
  * await droppedAsset.assetScale(.5);
@@ -523,6 +568,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
523
568
  /**
524
569
  * Flip an dropped asset.
525
570
  *
571
+ * @keywords flip, layout, dropped asset settings
572
+ *
526
573
  * @example
527
574
  * ```ts
528
575
  * await droppedAsset.flip(.5);
@@ -534,6 +581,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
534
581
  /**
535
582
  * Change or remove media embedded in a dropped asset.
536
583
  *
584
+ * @keywords media, update, dropped asset settings
585
+ *
537
586
  * @example
538
587
  * ```ts
539
588
  * await droppedAsset.updateUploadedMediaSelected("LVWyxwNxI96eLjnXWwYO");
@@ -545,6 +594,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
545
594
  /**
546
595
  * Change or remove top and bottom layers of a dropped asset.
547
596
  *
597
+ * @keywords layers, images, urls, dropped asset settings
598
+ *
548
599
  * @example
549
600
  * ```ts
550
601
  * await droppedAsset.updateWebImageLayers("","https://www.shutterstock.com/image-vector/colorful-illustration-test-word-260nw-1438324490.jpg");
@@ -556,6 +607,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
556
607
  /**
557
608
  * Add a webhook to a dropped asset
558
609
  *
610
+ * @keywords webhook, dropped asset settings
611
+ *
559
612
  * @example
560
613
  * ```ts
561
614
  * await droppedAsset.addWebhook({
@@ -584,6 +637,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
584
637
  /**
585
638
  * Set the interactive settings on a dropped asset
586
639
  *
640
+ * @keywords interactive, dropped asset settings
641
+ *
587
642
  * @example
588
643
  * ```ts
589
644
  * await droppedAsset.setInteractiveSettings({
@@ -599,6 +654,8 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
599
654
  /**
600
655
  * Retrieve analytics for a dropped asset by day, week, month, quarter, or year
601
656
  *
657
+ * @keywords get, fetch, retrieve, load, analytics
658
+ *
602
659
  * @example
603
660
  * ```ts
604
661
  * const analytics = await droppedAsset.fetchDroppedAssetAnalytics({
@@ -622,9 +679,11 @@ declare class DroppedAsset extends Asset implements DroppedAssetInterface {
622
679
  *
623
680
  * @example
624
681
  * ```ts
625
- * const world = await new World(topia, "exampleWorld", {
682
+ * import { World } from "utils/topiaInit.ts";
683
+ *
684
+ * const world = await World.create(exampleUrlSlug, {
626
685
  * attributes: { name: "Example World" },
627
- * credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }
686
+ * credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", visitorId: 1, urlSlug: "exampleUrlSlug" }
628
687
  * });
629
688
  * ```
630
689
  */
@@ -642,6 +701,8 @@ declare class World extends SDKController implements WorldInterface {
642
701
  /**
643
702
  * Retrieves details of a world.
644
703
  *
704
+ * @keywords get, fetch, retrieve, details, info, information, world
705
+ *
645
706
  * @example
646
707
  * ```ts
647
708
  * await world.fetchDetails();
@@ -652,6 +713,8 @@ declare class World extends SDKController implements WorldInterface {
652
713
  /**
653
714
  * Update details of a world.
654
715
  *
716
+ * @keywords update, modify, change, edit, world, settings, details
717
+ *
655
718
  * @example
656
719
  * ```ts
657
720
  * await world.updateDetails({
@@ -676,6 +739,8 @@ declare class World extends SDKController implements WorldInterface {
676
739
  /**
677
740
  * Set close world settings
678
741
  *
742
+ * @keywords update, modify, change, edit, world, settings, details, close, closed
743
+ *
679
744
  * @example
680
745
  * ```ts
681
746
  * await world.updateCloseWorldSettings({
@@ -703,6 +768,8 @@ declare class World extends SDKController implements WorldInterface {
703
768
  /**
704
769
  * Retrieve all assets dropped in a world.
705
770
  *
771
+ * @keywords get, fetch, retrieve, list, current, dropped assets
772
+ *
706
773
  * @category Dropped Assets
707
774
  *
708
775
  * @example
@@ -715,6 +782,8 @@ declare class World extends SDKController implements WorldInterface {
715
782
  /**
716
783
  * Retrieve all assets dropped in a world matching uniqueName.
717
784
  *
785
+ * @keywords get, fetch, retrieve, list, current, dropped assets, uniqueName
786
+ *
718
787
  * @category Dropped Assets
719
788
  *
720
789
  * @example
@@ -732,6 +801,8 @@ declare class World extends SDKController implements WorldInterface {
732
801
  /**
733
802
  * Retrieve all assets dropped in a world matching sceneDropId.
734
803
  *
804
+ * @keywords get, fetch, retrieve, list, current, dropped assets, sceneDropId
805
+ *
735
806
  * @category Dropped Assets
736
807
  *
737
808
  * @example
@@ -751,6 +822,8 @@ declare class World extends SDKController implements WorldInterface {
751
822
  /**
752
823
  * Update multiple custom text dropped assets with a single style while preserving text for specified dropped assets only.
753
824
  *
825
+ * @keywords update, modify, change, edit, dropped assets, custom text, style, text
826
+ *
754
827
  * @category Dropped Assets
755
828
  *
756
829
  * @example
@@ -773,6 +846,8 @@ declare class World extends SDKController implements WorldInterface {
773
846
  /**
774
847
  * Retrieve all landmark zone assets dropped in a world.
775
848
  *
849
+ * @keywords get, fetch, retrieve, list, landmark, zones, dropped assets
850
+ *
776
851
  * @category Dropped Assets
777
852
  *
778
853
  * @example
@@ -802,6 +877,8 @@ declare class World extends SDKController implements WorldInterface {
802
877
  /**
803
878
  * Fetch a list of all scene drop ids and dropped assets in a world
804
879
  *
880
+ * @keywords get, fetch, retrieve, list, scenes
881
+ *
805
882
  * @category Scenes
806
883
  *
807
884
  * @example
@@ -832,6 +909,8 @@ declare class World extends SDKController implements WorldInterface {
832
909
  /**
833
910
  * Drops a scene in a world and returns sceneDropId.
834
911
  *
912
+ * @keywords drop, add, place, scene
913
+ *
835
914
  * @category Scenes
836
915
  *
837
916
  * @example
@@ -861,6 +940,8 @@ declare class World extends SDKController implements WorldInterface {
861
940
  /**
862
941
  * Replace the current scene of a world.
863
942
  *
943
+ * @keywords replace, change, scene
944
+ *
864
945
  * @category Scenes
865
946
  *
866
947
  * @example
@@ -882,6 +963,8 @@ declare class World extends SDKController implements WorldInterface {
882
963
  /**
883
964
  * Get all particles available
884
965
  *
966
+ * @keywords get, fetch, retrieve, list, particles
967
+ *
885
968
  * @category Particles
886
969
  *
887
970
  * @example
@@ -895,6 +978,8 @@ declare class World extends SDKController implements WorldInterface {
895
978
  /**
896
979
  * Trigger a particle effect at a position in the world
897
980
  *
981
+ * @keywords trigger, start, play, particle, effect
982
+ *
898
983
  * @category Particles
899
984
  *
900
985
  * @example
@@ -916,6 +1001,8 @@ declare class World extends SDKController implements WorldInterface {
916
1001
  * Add an activity to a world
917
1002
  * excludeFromNotification is an array of visitorIds to exclude from the notification
918
1003
  *
1004
+ * @keywords start, trigger, activity
1005
+ *
919
1006
  * @example
920
1007
  * ```ts
921
1008
  * await world.triggerActivity({ type: "GAME_ON", assetId: "abc123" });
@@ -931,6 +1018,8 @@ declare class World extends SDKController implements WorldInterface {
931
1018
  /**
932
1019
  * Display a message via a toast to all visitors currently in a world.
933
1020
  *
1021
+ * @keywords send, display, show, toast, message, notification
1022
+ *
934
1023
  * @example
935
1024
  * ```ts
936
1025
  * await world.fireToast({
@@ -946,6 +1035,8 @@ declare class World extends SDKController implements WorldInterface {
946
1035
  /**
947
1036
  * Retrieves the data object for a world. Must have valid interactive credentials from a visitor in the world.
948
1037
  *
1038
+ * @keywords get, fetch, retrieve, load, data, object, state
1039
+ *
949
1040
  * @category Data Objects
950
1041
  *
951
1042
  * @example
@@ -961,6 +1052,8 @@ declare class World extends SDKController implements WorldInterface {
961
1052
  * @remarks
962
1053
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
963
1054
  *
1055
+ * @keywords set, assign, store, save, data, object, state
1056
+ *
964
1057
  * @category Data Objects
965
1058
  *
966
1059
  * @example
@@ -992,6 +1085,8 @@ declare class World extends SDKController implements WorldInterface {
992
1085
  * @remarks
993
1086
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
994
1087
  *
1088
+ * @keywords update, modify, change, edit, alter, data, object, state
1089
+ *
995
1090
  * @category Data Objects
996
1091
  *
997
1092
  * @example
@@ -1020,6 +1115,8 @@ declare class World extends SDKController implements WorldInterface {
1020
1115
  * @remarks
1021
1116
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
1022
1117
  *
1118
+ * @keywords increment, increase, add, count, data, object, state
1119
+ *
1023
1120
  * @category Data Objects
1024
1121
  *
1025
1122
  * @example
@@ -1041,6 +1138,8 @@ declare class World extends SDKController implements WorldInterface {
1041
1138
  /**
1042
1139
  * Retrieve all webhooks in a world.
1043
1140
  *
1141
+ * @keywords get, fetch, retrieve, list, current, webhooks
1142
+ *
1044
1143
  * @category Webhooks
1045
1144
  *
1046
1145
  * @example
@@ -1053,6 +1152,8 @@ declare class World extends SDKController implements WorldInterface {
1053
1152
  /**
1054
1153
  * Retrieve world analytics by day, week, month, quarter, or year
1055
1154
  *
1155
+ * @keywords get, fetch, retrieve, analytics, stats, statistics, data, metrics
1156
+ *
1056
1157
  * @category Analytics
1057
1158
  *
1058
1159
  * @example
@@ -1076,9 +1177,11 @@ declare class World extends SDKController implements WorldInterface {
1076
1177
  *
1077
1178
  * @example
1078
1179
  * ```ts
1079
- * const user = await new User(topia, {
1080
- * profileId: 1,
1081
- * credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }
1180
+ * import { User } from "utils/topiaInit.ts";
1181
+ *
1182
+ * const user = await User.create({
1183
+ * profileId: "exampleProfileId",
1184
+ * credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", profileId: "exampleProfileId", visitorId: 1, urlSlug: "exampleUrlSlug" }
1082
1185
  * });
1083
1186
  * ```
1084
1187
  */
@@ -1104,6 +1207,8 @@ declare class User extends SDKController implements UserInterface {
1104
1207
  /**
1105
1208
  * Returns all avatars owned by User
1106
1209
  *
1210
+ * @keywords get, fetch, retrieve, list, avatars, characters
1211
+ *
1107
1212
  * @category Avatars
1108
1213
  *
1109
1214
  * @example
@@ -1117,6 +1222,8 @@ declare class User extends SDKController implements UserInterface {
1117
1222
  /**
1118
1223
  * Add a new avatar
1119
1224
  *
1225
+ * @keywords add, create, upload, avatar, character
1226
+ *
1120
1227
  * @category Avatars
1121
1228
  *
1122
1229
  * @example
@@ -1189,6 +1296,8 @@ declare class User extends SDKController implements UserInterface {
1189
1296
  /**
1190
1297
  * Update avatar and sprite sheet records and upload files to existing sprite sheet and avatar storage buckets
1191
1298
  *
1299
+ * @keywords update, modify, change, edit, avatar, character
1300
+ *
1192
1301
  * @category Avatars
1193
1302
  *
1194
1303
  * @example
@@ -1261,6 +1370,8 @@ declare class User extends SDKController implements UserInterface {
1261
1370
  /**
1262
1371
  * Update avatar and sprite sheet records and upload files to existing sprite sheet and avatar storage buckets
1263
1372
  *
1373
+ * @keywords delete, remove, erase, destroy, eliminate, avatar
1374
+ *
1264
1375
  * @category Avatars
1265
1376
  *
1266
1377
  * @example
@@ -1272,6 +1383,8 @@ declare class User extends SDKController implements UserInterface {
1272
1383
  /**
1273
1384
  * Returns all assets owned by User when an email address is provided.
1274
1385
  *
1386
+ * @keywords get, fetch, retrieve, list, user assets, objects
1387
+ *
1275
1388
  * @category Assets
1276
1389
  *
1277
1390
  * @example
@@ -1284,6 +1397,8 @@ declare class User extends SDKController implements UserInterface {
1284
1397
  /**
1285
1398
  * Returns all platform assets.
1286
1399
  *
1400
+ * @keywords get, fetch, retrieve, list, platform assets, objects
1401
+ *
1287
1402
  * @category Assets
1288
1403
  *
1289
1404
  * @example
@@ -1297,6 +1412,8 @@ declare class User extends SDKController implements UserInterface {
1297
1412
  /**
1298
1413
  * Returns all scenes owned by User.
1299
1414
  *
1415
+ * @keywords get, fetch, retrieve, list, user scenes
1416
+ *
1300
1417
  * @category Scenes
1301
1418
  *
1302
1419
  * @example
@@ -1309,6 +1426,8 @@ declare class User extends SDKController implements UserInterface {
1309
1426
  /**
1310
1427
  * Retrieves all worlds owned by user with matching API Key, creates a new World object for each, and creates new map of Worlds accessible via user.worlds.
1311
1428
  *
1429
+ * @keywords get, fetch, retrieve, list, user worlds
1430
+ *
1312
1431
  * @category Worlds
1313
1432
  *
1314
1433
  * @example
@@ -1326,6 +1445,8 @@ declare class User extends SDKController implements UserInterface {
1326
1445
  /**
1327
1446
  * Retrieves all worlds a user with matching API Key is an admin in, creates a new World object for each, and creates new map of Worlds accessible via user.adminWorlds.
1328
1447
  *
1448
+ * @keywords get, fetch, retrieve, list, admin worlds, user worlds
1449
+ *
1329
1450
  * @category Worlds
1330
1451
  *
1331
1452
  * @example
@@ -1338,6 +1459,8 @@ declare class User extends SDKController implements UserInterface {
1338
1459
  /**
1339
1460
  * Retrieves ids of all dropped assets in all worlds with a matching interactivePublicKey.
1340
1461
  *
1462
+ * @keywords get, fetch, retrieve, list, interactive worlds, public key
1463
+ *
1341
1464
  * @category Dropped Assets
1342
1465
  *
1343
1466
  * @example
@@ -1352,6 +1475,8 @@ declare class User extends SDKController implements UserInterface {
1352
1475
  /**
1353
1476
  * Send an email
1354
1477
  *
1478
+ * @keywords send, email, message, notify
1479
+ *
1355
1480
  * @example
1356
1481
  * ```ts
1357
1482
  * const html = `<p><b>Hello World!</b></p><p>This email is being sent from via SDK.</p>`
@@ -1368,6 +1493,8 @@ declare class User extends SDKController implements UserInterface {
1368
1493
  /**
1369
1494
  * Get expressions
1370
1495
  *
1496
+ * @keywords get, fetch, retrieve, list, expressions, emotes
1497
+ *
1371
1498
  * @category Expressions
1372
1499
  *
1373
1500
  * @example
@@ -1384,6 +1511,8 @@ declare class User extends SDKController implements UserInterface {
1384
1511
  /**
1385
1512
  * Retrieves the data object for a user.
1386
1513
  *
1514
+ * @keywords get, fetch, retrieve, load, data, object, state
1515
+ *
1387
1516
  * @category Data Objects
1388
1517
  *
1389
1518
  * @example
@@ -1397,6 +1526,8 @@ declare class User extends SDKController implements UserInterface {
1397
1526
  /**
1398
1527
  * Sets the data object for a user.
1399
1528
  *
1529
+ * @keywords set, assign, store, save, data, object, state
1530
+ *
1400
1531
  * @remarks
1401
1532
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
1402
1533
  *
@@ -1429,6 +1560,8 @@ declare class User extends SDKController implements UserInterface {
1429
1560
  /**
1430
1561
  * Updates the data object for a user.
1431
1562
  *
1563
+ * @keywords update, modify, change, edit, alter, data, object, state
1564
+ *
1432
1565
  * @remarks
1433
1566
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
1434
1567
  *
@@ -1459,6 +1592,8 @@ declare class User extends SDKController implements UserInterface {
1459
1592
  /**
1460
1593
  * Increments a specific value in the data object for a user by the amount specified. Must have valid interactive credentials from a visitor in the world.
1461
1594
  *
1595
+ * @keywords increment, increase, add, count, data, object, state
1596
+ *
1462
1597
  * @remarks
1463
1598
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
1464
1599
  *
@@ -1487,7 +1622,9 @@ declare class User extends SDKController implements UserInterface {
1487
1622
  *
1488
1623
  * @example
1489
1624
  * ```ts
1490
- * const visitor = await new Visitor(topia, id, urlSlug, { attributes: { moveTo: { x: 0, y: 0 } }, credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" } });
1625
+ * import { Visitor } from "utils/topiaInit.ts";
1626
+ *
1627
+ * const visitor = await Visitor.get(visitorId, urlSlug, { attributes: { moveTo: { x: 0, y: 0 } }, credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", profileId: "exampleProfileId", visitorId: 1, urlSlug: "exampleUrlSlug" } });
1491
1628
  * ```
1492
1629
  */
1493
1630
  declare class Visitor extends User implements VisitorInterface {
@@ -1498,6 +1635,8 @@ declare class Visitor extends User implements VisitorInterface {
1498
1635
  /**
1499
1636
  * Get a single visitor from a world
1500
1637
  *
1638
+ * @keywords get, fetch, retrieve, load, visitor, details
1639
+ *
1501
1640
  * @example
1502
1641
  * ```ts
1503
1642
  * await visitor.fetchVisitor();
@@ -1510,6 +1649,8 @@ declare class Visitor extends User implements VisitorInterface {
1510
1649
  /**
1511
1650
  * Teleport or walk a visitor currently in a world to a single set of coordinates.
1512
1651
  *
1652
+ * @keywords move, teleport, walk, position, coordinate, location, place
1653
+ *
1513
1654
  * @example
1514
1655
  * ```ts
1515
1656
  * await visitor.moveVisitor({
@@ -1526,6 +1667,8 @@ declare class Visitor extends User implements VisitorInterface {
1526
1667
  /**
1527
1668
  * Display a message via a toast to a visitor currently in a world.
1528
1669
  *
1670
+ * @keywords toast, message, notification, alert, display, show, popup
1671
+ *
1529
1672
  * @example
1530
1673
  * ```ts
1531
1674
  * await visitor.fireToast({
@@ -1541,6 +1684,8 @@ declare class Visitor extends User implements VisitorInterface {
1541
1684
  /**
1542
1685
  * Open an iframe in a drawer or modal for a visitor currently in a world.
1543
1686
  *
1687
+ * @keywords open, iframe, drawer, modal, link, url, website, web page
1688
+ *
1544
1689
  * @category iframes
1545
1690
  *
1546
1691
  * @example
@@ -1559,6 +1704,8 @@ declare class Visitor extends User implements VisitorInterface {
1559
1704
  /**
1560
1705
  * Reload an iframe for a visitor currently in a world.
1561
1706
  *
1707
+ * @keywords reload, iframe, drawer, modal, link, url, website, web page
1708
+ *
1562
1709
  * @category iframes
1563
1710
  *
1564
1711
  * @example
@@ -1572,6 +1719,8 @@ declare class Visitor extends User implements VisitorInterface {
1572
1719
  /**
1573
1720
  * Close an iframe for a visitor currently in a world.
1574
1721
  *
1722
+ * @keywords close, iframe, drawer, modal
1723
+ *
1575
1724
  * @category iframes
1576
1725
  *
1577
1726
  * @example
@@ -1585,6 +1734,8 @@ declare class Visitor extends User implements VisitorInterface {
1585
1734
  /**
1586
1735
  * Mute and turn video off for a visitor currently in a world.
1587
1736
  *
1737
+ * @keywords mute, video, av, turn off, disable
1738
+ *
1588
1739
  * @example
1589
1740
  * ```ts
1590
1741
  * await visitor.turnAVOff();
@@ -1596,6 +1747,8 @@ declare class Visitor extends User implements VisitorInterface {
1596
1747
  /**
1597
1748
  * Get expressions
1598
1749
  *
1750
+ * @keywords get, fetch, retrieve, list, expressions, emotes
1751
+ *
1599
1752
  * @category Expressions
1600
1753
  *
1601
1754
  * @example
@@ -1611,6 +1764,8 @@ declare class Visitor extends User implements VisitorInterface {
1611
1764
  /**
1612
1765
  * Grant expression to a visitor by id or name.
1613
1766
  *
1767
+ * @keywords grant, give, add, expression, emote
1768
+ *
1614
1769
  * @category Expressions
1615
1770
  *
1616
1771
  * @example
@@ -1628,6 +1783,8 @@ declare class Visitor extends User implements VisitorInterface {
1628
1783
  /**
1629
1784
  * Get all particles available
1630
1785
  *
1786
+ * @keywords get, fetch, retrieve, list, particles, effects
1787
+ *
1631
1788
  * @category Particle Effects
1632
1789
  *
1633
1790
  * @example
@@ -1641,6 +1798,8 @@ declare class Visitor extends User implements VisitorInterface {
1641
1798
  /**
1642
1799
  * Trigger a particle effect on a visitor
1643
1800
  *
1801
+ * @keywords trigger, particle, effect, spawn, start, play
1802
+ *
1644
1803
  * @category Particle Effects
1645
1804
  *
1646
1805
  * @example
@@ -1658,6 +1817,8 @@ declare class Visitor extends User implements VisitorInterface {
1658
1817
  /**
1659
1818
  * Retrieves the data object for a visitor.
1660
1819
  *
1820
+ * @keywords get, fetch, retrieve, load, data, object, state
1821
+ *
1661
1822
  * @category Data Objects
1662
1823
  *
1663
1824
  * @example
@@ -1671,6 +1832,8 @@ declare class Visitor extends User implements VisitorInterface {
1671
1832
  /**
1672
1833
  * Sets the data object for a visitor.
1673
1834
  *
1835
+ * @keywords set, assign, store, save, data, object, state
1836
+ *
1674
1837
  * @remarks
1675
1838
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
1676
1839
  *
@@ -1706,6 +1869,8 @@ declare class Visitor extends User implements VisitorInterface {
1706
1869
  * @remarks
1707
1870
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
1708
1871
  *
1872
+ * @keywords update, modify, change, edit, alter, data, object, state
1873
+ *
1709
1874
  * @category Data Objects
1710
1875
  *
1711
1876
  * @example
@@ -1736,6 +1901,8 @@ declare class Visitor extends User implements VisitorInterface {
1736
1901
  * @remarks
1737
1902
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
1738
1903
  *
1904
+ * @keywords increment, increase, add, count, data, object, state
1905
+ *
1739
1906
  * @category Data Objects
1740
1907
  *
1741
1908
  * @example
@@ -1757,6 +1924,8 @@ declare class Visitor extends User implements VisitorInterface {
1757
1924
  /**
1758
1925
  * Update analytics for a given public key. Must have valid interactive credentials from a visitor in the world.
1759
1926
  *
1927
+ * @keywords update, modify, change, edit, analytics, analytic, stats, statistics, data
1928
+ *
1760
1929
  * @example
1761
1930
  * ```ts
1762
1931
  * await visitor.updatePublicKeyAnalytics([{ analyticName: "joins", profileId, uniqueKey: profileId, urlSlug }]);
@@ -1766,6 +1935,8 @@ declare class Visitor extends User implements VisitorInterface {
1766
1935
  /**
1767
1936
  * Setup signal to visitor
1768
1937
  *
1938
+ * @keywords signal, webrtc, answer, connect, p2p
1939
+ *
1769
1940
  * @example
1770
1941
  * ```ts
1771
1942
  * await visitor.sendSignalToVisitor(iceServers);
@@ -2421,9 +2592,11 @@ declare abstract class SDKController implements SDKInterface {
2421
2592
  *
2422
2593
  * @example
2423
2594
  * ```ts
2424
- * const asset = await new Asset(topia, "id", {
2595
+ * import { Asset } from "utils/topiaInit.ts";
2596
+ *
2597
+ * const asset = await Asset.create(assetId, {
2425
2598
  * attributes: { assetName: "My Asset", isPublic: false },
2426
- * credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }
2599
+ * credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", visitorId: 1, urlSlug: "exampleUrlSlug" }
2427
2600
  * });
2428
2601
  * ```
2429
2602
  */
@@ -2433,6 +2606,8 @@ declare class Asset extends SDKController implements AssetInterface {
2433
2606
  /**
2434
2607
  * Retrieves platform asset details and assigns response data to the instance.
2435
2608
  *
2609
+ * @keywords get, fetch, retrieve, load, details, info, information
2610
+ *
2436
2611
  * @example
2437
2612
  * ```ts
2438
2613
  * await asset.fetchAssetById();
@@ -2445,6 +2620,8 @@ declare class Asset extends SDKController implements AssetInterface {
2445
2620
  /**
2446
2621
  * Updates platform asset details.
2447
2622
  *
2623
+ * @keywords update, modify, change, edit, alter, transform
2624
+ *
2448
2625
  * @example
2449
2626
  * ```ts
2450
2627
  * await asset.updateAsset({
@@ -2475,8 +2652,10 @@ declare class Asset extends SDKController implements AssetInterface {
2475
2652
  *
2476
2653
  * @example
2477
2654
  * ```ts
2478
- * const ecosystem =await new Ecosystem(topia, {
2479
- * credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }
2655
+ * import { Ecosystem } from "utils/topiaInit.ts";
2656
+ *
2657
+ * const ecosystem = await Ecosystem.create({
2658
+ * credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", visitorId: 1, urlSlug: "exampleUrlSlug" }
2480
2659
  * });
2481
2660
  * ```
2482
2661
  */
@@ -2486,6 +2665,8 @@ declare class Ecosystem extends SDKController {
2486
2665
  /**
2487
2666
  * Retrieves the data object for a Topia ecosystem. Requires canUpdateEcosystemDataObjects permission to be set to true for the public key.
2488
2667
  *
2668
+ * @keywords get, fetch, retrieve, load, data, object, state
2669
+ *
2489
2670
  * @category Data Objects
2490
2671
  *
2491
2672
  * @example
@@ -2504,6 +2685,8 @@ declare class Ecosystem extends SDKController {
2504
2685
  *
2505
2686
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
2506
2687
  *
2688
+ * @keywords set, assign, store, save, data, object, state
2689
+ *
2507
2690
  * @category Data Objects
2508
2691
  *
2509
2692
  * @example
@@ -2534,6 +2717,8 @@ declare class Ecosystem extends SDKController {
2534
2717
  *
2535
2718
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
2536
2719
  *
2720
+ * @keywords update, modify, change, edit, alter, data, object, state
2721
+ *
2537
2722
  * @category Data Objects
2538
2723
  *
2539
2724
  * @example
@@ -2570,6 +2755,8 @@ declare class Ecosystem extends SDKController {
2570
2755
  *
2571
2756
  * Optionally, a lock can be provided with this request to ensure only one update happens at a time between all updates that share the same lock id
2572
2757
  *
2758
+ * @keywords increment, increase, add, count, data, object, state
2759
+ *
2573
2760
  * @category Data Objects
2574
2761
  *
2575
2762
  * @example
@@ -2599,7 +2786,7 @@ declare class Ecosystem extends SDKController {
2599
2786
  * @example
2600
2787
  * ```ts
2601
2788
  * const webRTC = await new WebRTCConnector(topia, {
2602
- * credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }
2789
+ * credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", profileId: "exampleProfileId", visitorId: 1, urlSlug: "exampleUrlSlug" }
2603
2790
  * });
2604
2791
  * ```
2605
2792
  */
@@ -2626,9 +2813,11 @@ declare class WebRTCConnector extends SDKController implements WebRTCConnectorIn
2626
2813
  *
2627
2814
  * @example
2628
2815
  * ```ts
2629
- * const activity = await new WorldActivity(topia, "exampleWorld", {
2816
+ * import { WorldActivity } from "utils/topiaInit.ts";
2817
+ *
2818
+ * const activity = await WorldActivity.create(urlSlug, {
2630
2819
  * attributes: { name: "Example World" },
2631
- * credentials: { interactiveNonce: "exampleNonce", assetId: "droppedAssetId", visitorId: 1, urlSlug: "exampleWorld" }
2820
+ * credentials: { interactivePublicKey: "examplePublicKey", interactiveNonce: "exampleNonce", assetId: "exampleDroppedAssetId", visitorId: 1, urlSlug: "exampleUrlSlug" }
2632
2821
  * });
2633
2822
  * ```
2634
2823
  */
@@ -2643,6 +2832,8 @@ declare class WorldActivity extends SDKController {
2643
2832
  /**
2644
2833
  * Retrieve all visitors currently in a world.
2645
2834
  *
2835
+ * @keywords get, fetch, retrieve, list, current, visitors, users, players
2836
+ *
2646
2837
  * @category Visitors
2647
2838
  *
2648
2839
  * @example
@@ -2658,6 +2849,8 @@ declare class WorldActivity extends SDKController {
2658
2849
  /**
2659
2850
  * Retrieve all visitors currently in a Landmark Zone.
2660
2851
  *
2852
+ * @keywords get, fetch, retrieve, list, zone, area, landmark, visitors, users
2853
+ *
2661
2854
  * @category Visitors
2662
2855
  *
2663
2856
  * @example
@@ -2680,6 +2873,8 @@ declare class WorldActivity extends SDKController {
2680
2873
  * Optionally refetch visitors, teleport or walk visitors to new location,
2681
2874
  * and scatter visitors by any number so that they don't all move to the exact same location.
2682
2875
  *
2876
+ * @keywords move, teleport, position, coordinate, visitors, users, relocate
2877
+ *
2683
2878
  * @category Visitors
2684
2879
  *
2685
2880
  * @example
@@ -2700,6 +2895,8 @@ declare class WorldActivity extends SDKController {
2700
2895
  /**
2701
2896
  * Teleport or walk a list of visitors currently in a world to various coordinates.
2702
2897
  *
2898
+ * @keywords move, teleport, position, coordinate, visitor, user, relocate
2899
+ *
2703
2900
  * @category Visitors
2704
2901
  *
2705
2902
  * @example
@@ -2727,109 +2924,270 @@ declare class WorldActivity extends SDKController {
2727
2924
  }
2728
2925
 
2729
2926
  /**
2927
+ * Factory for creating Asset instances. Use this factory to create or upload assets in the Topia platform.
2928
+ *
2929
+ * @remarks
2930
+ * This factory should be instantiated once per application and reused across your codebase.
2931
+ *
2932
+ * @keywords asset, factory, create, upload, instantiate, topia
2933
+ *
2730
2934
  * @example
2731
2935
  * ```ts
2732
- * const Asset = new AssetFactory(myTopiaInstance);
2936
+ * // In your initialization file (e.g., utils/topiaInit.ts)
2937
+ * import { Topia, AssetFactory } from "@rtsdk/topia";
2938
+ * const topia = new Topia({ config });
2939
+ * export const Asset = new AssetFactory(topia);
2733
2940
  * ```
2734
2941
  */
2735
2942
  declare class AssetFactory extends SDKController {
2736
2943
  constructor(topia: Topia);
2737
2944
  /**
2738
- * Instantiate a new instance of Asset class.
2945
+ * Instantiate a new instance of Asset class with the specified asset ID.
2946
+ *
2947
+ * @remarks
2948
+ * This method creates a new Asset controller instance that can be used to interact with an existing asset.
2949
+ * It does not create a new asset in the database.
2950
+ *
2951
+ * @keywords create, instantiate, asset, initialize, get, instance
2739
2952
  *
2740
2953
  * @example
2741
- * ```
2742
- * const assetInstance = await Asset.create(id, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
2954
+ * ```ts
2955
+ * // Import the pre-initialized factory from your app's initialization file
2956
+ * import { Asset } from "utils/topiaInit.ts";
2957
+ *
2958
+ * // Create an Asset instance with credentials
2959
+ * const assetInstance = await Asset.create(assetId, {
2960
+ * credentials: {
2961
+ * interactiveNonce,
2962
+ * interactivePublicKey,
2963
+ * assetId,
2964
+ * urlSlug,
2965
+ * visitorId
2966
+ * }
2967
+ * });
2968
+ *
2969
+ * // Use the instance to interact with the asset
2970
+ * await assetInstance.fetchAssetById();
2743
2971
  * ```
2744
2972
  *
2745
2973
  * @returns {Asset} Returns a new Asset object with the asset id.
2746
2974
  */
2747
2975
  create(id: string, options?: AssetOptionalInterface): Asset;
2748
2976
  /**
2749
- * Upload a new Asset and return a new instance of Asset class.
2977
+ * Upload a new Asset to the Topia platform and return a new instance of Asset class.
2978
+ *
2979
+ * @remarks
2980
+ * This method both creates a new asset in the database and returns an Asset controller instance.
2981
+ * A valid API key with appropriate permissions is required.
2982
+ *
2983
+ * @keywords upload, create, new, asset, add, store
2750
2984
  *
2751
2985
  * @example
2752
- * ```
2986
+ * ```ts
2987
+ * // Import the pre-initialized factory from your app's initialization file
2988
+ * import { Asset } from "utils/topiaInit.ts";
2989
+ *
2990
+ * // Prepare the asset payload
2753
2991
  * const assetPayload = {
2754
- * assetName: "exampleAssetName"
2755
- * bottomLayerURL: "https://example.bottomLayerURL"
2992
+ * assetName: "My Decorative Asset",
2993
+ * bottomLayerURL: "https://example.com/bottom-layer.png",
2756
2994
  * creatorTags: { "decorations": true },
2757
2995
  * tagJson: "[{"label":"decorations","value":"decorations"}]",
2758
2996
  * isPublic: true,
2759
- * topLayerURL: "https://example.topLayerURL"
2760
- * }
2997
+ * topLayerURL: "https://example.com/top-layer.png"
2998
+ * };
2999
+ *
3000
+ * // Upload the asset using your API key
2761
3001
  * const asset = await Asset.upload(assetPayload, apiKey);
3002
+ *
3003
+ * // Access the new asset's properties
3004
+ * console.log(asset.id);
2762
3005
  * ```
2763
3006
  *
2764
- * @returns {AssetType} Returns a new Asset object with the asset details.
3007
+ * @returns {Asset} Returns a new Asset object with the asset details.
2765
3008
  */
2766
3009
  upload(assetPayload: AssetType, apiKey: string): Promise<Asset>;
2767
3010
  }
2768
3011
 
2769
3012
  /**
3013
+ * Factory for creating and retrieving DroppedAsset instances. Use this factory to work with assets that have been placed in a Topia world.
3014
+ *
3015
+ * @remarks
3016
+ * This factory should be instantiated once per application and reused across your codebase.
3017
+ *
3018
+ * @keywords dropped asset, factory, create, get, retrieve, instantiate, topia
3019
+ *
2770
3020
  * @example
2771
3021
  * ```ts
2772
- * const DroppedAsset = new DroppedAssetFactory(myTopiaInstance);
3022
+ * // In your initialization file (e.g., utils/topiaInit.ts)
3023
+ * import { Topia, DroppedAssetFactory } from "@rtsdk/topia";
3024
+ * const topia = new Topia({ config });
3025
+ * export const DroppedAsset = new DroppedAssetFactory(topia);
2773
3026
  * ```
2774
3027
  */
2775
3028
  declare class DroppedAssetFactory extends SDKController {
2776
3029
  constructor(topia: Topia);
2777
3030
  /**
2778
- * Instantiate a new instance of DroppedAsset class.
3031
+ * Instantiate a new instance of DroppedAsset class for an existing dropped asset in a world.
3032
+ *
3033
+ * @remarks
3034
+ * This method creates a controller instance for an existing dropped asset but does not fetch its properties.
3035
+ * Use this when you need a lightweight instance and will fetch properties separately if needed or when you already have the properties.
3036
+ *
3037
+ * @keywords create, instantiate, dropped asset, initialize, instance
2779
3038
  *
2780
3039
  * @example
2781
- * ```
2782
- * const droppedAssetInstance = await DroppedAsset.create(assetId, urlSlug, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
3040
+ * ```ts
3041
+ * // Import the pre-initialized factory from your app's initialization file
3042
+ * import { DroppedAsset } from "utils/topiaInit.ts";
3043
+ *
3044
+ * // Create a DroppedAsset instance with credentials
3045
+ * const droppedAssetInstance = DroppedAsset.create(
3046
+ * assetId,
3047
+ * urlSlug,
3048
+ * {
3049
+ * credentials: {
3050
+ * interactiveNonce,
3051
+ * interactivePublicKey,
3052
+ * assetId,
3053
+ * urlSlug,
3054
+ * visitorId
3055
+ * }
3056
+ * }
3057
+ * );
3058
+ *
3059
+ * // Later fetch its properties if needed
3060
+ * await droppedAssetInstance.fetchDroppedAssetById();
2783
3061
  * ```
2784
3062
  *
2785
- * @returns {DroppedAsset} Returns a new DroppedAsset object.
3063
+ * @returns {DroppedAsset} Returns a new DroppedAsset object without fetching its properties.
2786
3064
  */
2787
3065
  create(id: string, urlSlug: string, options?: DroppedAssetOptionalInterface): DroppedAsset;
2788
3066
  /**
2789
- * Instantiate a new instance of DroppedAsset class and retrieve all properties.
3067
+ * Instantiate a new instance of DroppedAsset class and automatically fetch all its properties.
3068
+ *
3069
+ * @remarks
3070
+ * This method creates a controller instance and immediately fetches all properties of the dropped asset.
3071
+ * It's a convenience method that combines creating an instance and calling fetchDroppedAssetById().
3072
+ *
3073
+ * @keywords get, fetch, retrieve, dropped asset, load, instance
2790
3074
  *
2791
3075
  * @example
2792
- * ```
2793
- * const droppedAssetInstance = await DroppedAsset.get(assetId, urlSlug, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
3076
+ * ```ts
3077
+ * // Import the pre-initialized factory from your app's initialization file
3078
+ * import { DroppedAsset } from "utils/topiaInit.ts";
3079
+ *
3080
+ * // Get a fully populated DroppedAsset instance
3081
+ * const droppedAssetInstance = await DroppedAsset.get(
3082
+ * assetId,
3083
+ * urlSlug,
3084
+ * {
3085
+ * credentials: {
3086
+ * interactiveNonce,
3087
+ * interactivePublicKey,
3088
+ * assetId,
3089
+ * urlSlug,
3090
+ * visitorId
3091
+ * }
3092
+ * }
3093
+ * );
3094
+ *
3095
+ * // The properties are already loaded, so you can use them immediately
3096
+ * console.log(droppedAssetInstance.position);
2794
3097
  * ```
2795
3098
  *
2796
- * @returns {Promise<DroppedAsset>} Returns a new DroppedAsset object with all properties.
3099
+ * @returns {Promise<DroppedAsset>} Returns a new DroppedAsset object with all properties already fetched.
2797
3100
  */
2798
3101
  get(id: string, urlSlug: string, options?: DroppedAssetOptionalInterface): Promise<DroppedAsset>;
2799
3102
  /**
2800
- * Searches dropped assets within a world by a provide `uniqueName`. If a single match is found, a new instance of DroppedAsset class is returned all properties.
3103
+ * Searches for and retrieves a dropped asset by its unique name within a world.
2801
3104
  *
2802
3105
  * @remarks
2803
- * This method leverages the handleGetDroppedAssetByUniqueName endpoint in the Public API and assumes there is exactly one dropped asset with matching uniqueName for the given urlSlug.
3106
+ * 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 ID.
3108
+ *
3109
+ * @keywords find, search, unique name, retrieve, locate, lookup, dropped asset
2804
3110
  *
2805
3111
  * @example
2806
- * ```
2807
- * const droppedAssetInstance = await DroppedAsset.getWithUniqueName("exampleUniqueName", urlSlug, interactiveSecret, credentials);
3112
+ * ```ts
3113
+ * // Import the pre-initialized factory from your app's initialization file
3114
+ * import { DroppedAsset } from "utils/topiaInit.ts";
3115
+ *
3116
+ * // Find and retrieve a dropped asset by its unique name
3117
+ * const droppedAssetInstance = await DroppedAsset.getWithUniqueName(
3118
+ * "banner-sign-northeast",
3119
+ * "my-world-slug",
3120
+ * "your-interactive-secret",
3121
+ * {
3122
+ * apiKey: "your-api-key",
3123
+ * interactivePublicKey: "your-public-key",
3124
+ * // other credentials...
3125
+ * }
3126
+ * );
3127
+ *
3128
+ * // The properties are already loaded, so you can use them immediately
3129
+ * console.log(droppedAssetInstance.position);
2808
3130
  * ```
2809
3131
  *
2810
- * @returns {Promise<DroppedAsset>} Returns a new DroppedAsset object with all properties.
3132
+ * @returns {Promise<DroppedAsset>} Returns a new DroppedAsset object with all properties already fetched.
2811
3133
  */
2812
3134
  getWithUniqueName(uniqueName: string, urlSlug: string, interactiveSecret: string, credentials: InteractiveCredentials): Promise<DroppedAsset>;
2813
3135
  /**
2814
3136
  * Drops an asset in a world and returns a new instance of DroppedAsset class with all properties.
2815
3137
  *
3138
+ * @remarks
3139
+ * This method places an existing Asset into a world at specified coordinates, effectively "dropping" it into the environment.
3140
+ * You can customize various properties of the dropped asset during placement, such as scale, position, interactive settings, and visual layers.
3141
+ *
3142
+ * @keywords drop, place, add, create, position, asset, deploy
3143
+ *
2816
3144
  * @example
2817
- * ```
2818
- * const assetInstance = await Asset.create(id, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
2819
- * const droppedAssetInstance = await DroppedAsset.get(assetInstance, {
2820
- assetScale: 1.5,
2821
- flipped: true,
2822
- layer0: "",
2823
- layer1: "https://pathtoimage.png",
2824
- interactivePublicKey,
2825
- isInteractive: true,
2826
- position: { x: 0, y: 0 },
2827
- uniqueName: "exampleUniqueName",
2828
- urlSlug,
2829
- });
3145
+ * ```ts
3146
+ * // Import the pre-initialized factories from your app's initialization file
3147
+ * import { Asset, DroppedAsset } from "utils/topiaInit.ts";
3148
+ *
3149
+ * // First get an asset instance
3150
+ * const assetInstance = Asset.create("asset-id-123", {
3151
+ * credentials: {
3152
+ * interactiveNonce,
3153
+ * interactivePublicKey,
3154
+ * assetId,
3155
+ * urlSlug,
3156
+ * visitorId
3157
+ * }
3158
+ * });
3159
+ *
3160
+ * // Then drop (place) the asset in a world
3161
+ * const droppedAssetInstance = await DroppedAsset.drop(
3162
+ * assetInstance,
3163
+ * {
3164
+ * // Basic positioning and appearance
3165
+ * position: { x: 250, y: 350 },
3166
+ * assetScale: 1.5,
3167
+ * flipped: true,
3168
+ * uniqueName: "welcome-sign",
3169
+ * urlSlug: "my-world-slug",
3170
+ *
3171
+ * // For web images (optional)
3172
+ * layer0: "https://example.com/background.png",
3173
+ * layer1: "https://example.com/foreground.png",
3174
+ *
3175
+ * // For interactive assets (optional)
3176
+ * interactivePublicKey: "your-public-key",
3177
+ * isInteractive: true,
3178
+ *
3179
+ * // For clickable assets (optional)
3180
+ * clickType: "link",
3181
+ * clickableLink: "https://example.com",
3182
+ * clickableLinkTitle: "Visit Example"
3183
+ * }
3184
+ * );
3185
+ *
3186
+ * // The dropped asset is ready to use
3187
+ * console.log(droppedAssetInstance.id);
2830
3188
  * ```
2831
3189
  *
2832
- * @returns {Promise<DroppedAsset>} Returns a new DroppedAsset object with all properties.
3190
+ * @returns {Promise<DroppedAsset>} Returns a new DroppedAsset object representing the placed asset in the world.
2833
3191
  */
2834
3192
  drop(asset: Asset, { assetScale, clickType, clickableDisplayTextDescription, clickableDisplayTextHeadline, clickableLink, clickableLinkTitle, flipped, interactivePublicKey, isInteractive, isForceLinkInIframe, isOpenLinkInDrawer, isTextTopLayer, layer0, layer1, position: { x, y }, sceneDropId, text, textColor, textFontFamily, textSize, textWeight, textWidth, uniqueName, urlSlug, yOrderAdjust, }: {
2835
3193
  assetScale?: number;
@@ -2864,45 +3222,113 @@ declare class DroppedAssetFactory extends SDKController {
2864
3222
  }
2865
3223
 
2866
3224
  /**
3225
+ * Factory for creating Ecosystem instances. Use this factory to work with ecosystem-wide data and operations.
3226
+ *
3227
+ * @remarks
3228
+ * This factory should be instantiated once per application and reused across your codebase.
3229
+ * The Ecosystem controller provides methods to interact with data shared across multiple worlds.
3230
+ *
3231
+ * @keywords ecosystem, factory, create, multi-world, global, shared data, platform
3232
+ *
2867
3233
  * @example
2868
3234
  * ```ts
2869
- * const Ecosystem = new EcosystemFactory(myTopiaInstance);
3235
+ * // In your initialization file (e.g., utils/topiaInit.ts)
3236
+ * import { Topia, EcosystemFactory } from "@rtsdk/topia";
3237
+ * const topia = new Topia({ config });
3238
+ * export const Ecosystem = new EcosystemFactory(topia);
2870
3239
  * ```
2871
3240
  */
2872
3241
  declare class EcosystemFactory {
2873
3242
  topia: Topia;
2874
3243
  constructor(topia: Topia);
2875
3244
  /**
2876
- * Instantiate a new instance of Ecosystem class.
3245
+ * Instantiate a new instance of Ecosystem class for interacting with ecosystem-wide data.
3246
+ *
3247
+ * @remarks
3248
+ * This method creates a controller instance for accessing and managing data that spans multiple worlds.
3249
+ * Use this for cross-world data sharing, global data objects, and ecosystem-wide operations.
3250
+ *
3251
+ * @keywords create, instantiate, ecosystem, initialize, global, shared data, platform
2877
3252
  *
2878
3253
  * @example
2879
- * ```
2880
- * const ecosystemInstance = await Ecosystem.create({ credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId }});
3254
+ * ```ts
3255
+ * // Import the pre-initialized factory from your app's initialization file
3256
+ * import { Ecosystem } from "utils/topiaInit.ts";
3257
+ *
3258
+ * // Create an Ecosystem instance with credentials
3259
+ * const ecosystemInstance = Ecosystem.create({
3260
+ * credentials: {
3261
+ * interactiveNonce,
3262
+ * interactivePublicKey,
3263
+ * assetId,
3264
+ * urlSlug,
3265
+ * visitorId
3266
+ * }
3267
+ * });
3268
+ *
3269
+ * // Work with ecosystem-wide data objects
3270
+ * await ecosystemInstance.fetchDataObject("global-leaderboard");
3271
+ * await ecosystemInstance.setDataObject("global-leaderboard", { scores: [...] });
2881
3272
  * ```
2882
3273
  *
2883
- * @returns {Ecosystem} Returns a new Ecosystem object.
3274
+ * @returns {Ecosystem} Returns a new Ecosystem object for interacting with ecosystem-wide data.
2884
3275
  */
2885
3276
  create(options?: EcosystemOptionalInterface): Ecosystem;
2886
3277
  }
2887
3278
 
2888
3279
  /**
3280
+ * Factory for creating Scene instances. Use this factory to work with scenes in the Topia platform.
3281
+ *
3282
+ * @remarks
3283
+ * This factory should be instantiated once per application and reused across your codebase.
3284
+ * Scenes represent the template or blueprint for a world's design and layout.
3285
+ *
3286
+ * @keywords scene, factory, create, template, blueprint, layout, design
3287
+ *
2889
3288
  * @example
2890
3289
  * ```ts
2891
- * const Scene = new SceneFactory(myTopiaInstance);
3290
+ * // In your initialization file (e.g., utils/topiaInit.ts)
3291
+ * import { Topia, SceneFactory } from "@rtsdk/topia";
3292
+ * const topia = new Topia({ config });
3293
+ * export const Scene = new SceneFactory(topia);
2892
3294
  * ```
2893
3295
  */
2894
3296
  declare class SceneFactory {
2895
3297
  topia: Topia;
2896
3298
  constructor(topia: Topia);
2897
3299
  /**
2898
- * Instantiate a new instance of Scene class.
3300
+ * Instantiate a new instance of Scene class for an existing scene in the platform.
3301
+ *
3302
+ * @remarks
3303
+ * 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 ID.
3305
+ *
3306
+ * @keywords create, instantiate, scene, initialize, instance, template
2899
3307
  *
2900
3308
  * @example
2901
- * ```
2902
- * const sceneInstance = await Scene.create(id, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
3309
+ * ```ts
3310
+ * // Import the pre-initialized factory from your app's initialization file
3311
+ * import { Scene } from "utils/topiaInit.ts";
3312
+ *
3313
+ * // Create a Scene instance with credentials
3314
+ * const sceneInstance = Scene.create(
3315
+ * "scene-id-123",
3316
+ * {
3317
+ * credentials: {
3318
+ * interactiveNonce,
3319
+ * interactivePublicKey,
3320
+ * assetId,
3321
+ * urlSlug,
3322
+ * visitorId
3323
+ * }
3324
+ * }
3325
+ * );
3326
+ *
3327
+ * // Fetch scene details if needed
3328
+ * await sceneInstance.fetchSceneById();
2903
3329
  * ```
2904
3330
  *
2905
- * @returns {Scene} Returns a new Scene object.
3331
+ * @returns {Scene} Returns a new Scene object for interacting with the specified scene.
2906
3332
  */
2907
3333
  create(id: string, options?: SceneOptionalInterface): Scene;
2908
3334
  /**
@@ -2919,132 +3345,363 @@ declare class SceneFactory {
2919
3345
  }
2920
3346
 
2921
3347
  /**
3348
+ * Factory for creating User instances. Use this factory to work with user data in the Topia platform.
3349
+ *
3350
+ * @remarks
3351
+ * This factory should be instantiated once per application and reused across your codebase.
3352
+ * The User controller allows you to interact with user-specific information and operations.
3353
+ *
3354
+ * @keywords user, factory, create, account, profile, member, visitor
3355
+ *
2922
3356
  * @example
2923
3357
  * ```ts
2924
- * const User = new UserFactory(myTopiaInstance);
3358
+ * // In your initialization file (e.g., utils/topiaInit.ts)
3359
+ * import { Topia, UserFactory } from "@rtsdk/topia";
3360
+ * const topia = new Topia({ config });
3361
+ * export const User = new UserFactory(topia);
2925
3362
  * ```
2926
3363
  */
2927
3364
  declare class UserFactory {
2928
3365
  topia: Topia;
2929
3366
  constructor(topia: Topia);
2930
3367
  /**
2931
- * Instantiate a new instance of User class.
3368
+ * Instantiate a new instance of User class for working with user data.
3369
+ *
3370
+ * @remarks
3371
+ * This method creates a controller instance for interacting with user-specific operations.
3372
+ * The User controller doesn't require an ID since it represents the currently authenticated user.
3373
+ *
3374
+ * @keywords create, instantiate, user, initialize, account, profile, member
2932
3375
  *
2933
3376
  * @example
2934
- * ```
2935
- * const userInstance = await User.create({ credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
3377
+ * ```ts
3378
+ * // Import the pre-initialized factory from your app's initialization file
3379
+ * import { User } from "utils/topiaInit.ts";
3380
+ *
3381
+ * // Create a User instance with credentials
3382
+ * const userInstance = User.create({
3383
+ * credentials: {
3384
+ * interactiveNonce,
3385
+ * interactivePublicKey,
3386
+ * assetId,
3387
+ * urlSlug,
3388
+ * visitorId
3389
+ * }
3390
+ * });
3391
+ *
3392
+ * // Use methods on the user instance
3393
+ * await userInstance.checkInteractiveCredentials();
3394
+ * const avatars = await userInstance.fetchAvatars();
2936
3395
  * ```
2937
3396
  *
2938
- * @returns {User} Returns a new User object.
3397
+ * @returns {User} Returns a new User object for interacting with user data.
2939
3398
  */
2940
3399
  create(options?: UserOptionalInterface): User;
2941
3400
  }
2942
3401
 
2943
3402
  /**
3403
+ * Factory for creating Visitor instances. Use this factory to work with visitors in Topia worlds.
3404
+ *
3405
+ * @remarks
3406
+ * This factory should be instantiated once per application and reused across your codebase.
3407
+ * The Visitor controller represents a specific visitor/avatar instance in a world.
3408
+ *
3409
+ * @keywords visitor, factory, create, get, avatar, user, participant
3410
+ *
2944
3411
  * @example
2945
3412
  * ```ts
2946
- * const Visitor = new VisitorFactory(myTopiaInstance);
3413
+ * // In your initialization file (e.g., utils/topiaInit.ts)
3414
+ * import { Topia, VisitorFactory } from "@rtsdk/topia";
3415
+ * const topia = new Topia({ config });
3416
+ * export const Visitor = new VisitorFactory(topia);
2947
3417
  * ```
2948
3418
  */
2949
3419
  declare class VisitorFactory {
2950
3420
  topia: Topia;
2951
3421
  constructor(topia: Topia);
2952
3422
  /**
2953
- * Instantiate a new instance of Visitor class.
3423
+ * Instantiate a new instance of Visitor class for an existing visitor in a world.
3424
+ *
3425
+ * @remarks
3426
+ * This method creates a controller instance for a visitor but does not fetch its properties.
3427
+ * Use this when you need a lightweight instance and will fetch properties separately or when you already have the properties.
3428
+ *
3429
+ * @keywords create, instantiate, visitor, initialize, avatar, instance
2954
3430
  *
2955
3431
  * @example
2956
- * ```
2957
- * const visitorInstance = await Visitor.create(id, urlSlug, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
3432
+ * ```ts
3433
+ * // Import the pre-initialized factory from your app's initialization file
3434
+ * import { Visitor } from "utils/topiaInit.ts";
3435
+ *
3436
+ * // Create a Visitor instance with credentials
3437
+ * const visitorInstance = Visitor.create(
3438
+ * 12345, // visitor ID
3439
+ * "my-world-slug",
3440
+ * {
3441
+ * credentials: {
3442
+ * interactiveNonce,
3443
+ * interactivePublicKey,
3444
+ * assetId,
3445
+ * urlSlug,
3446
+ * visitorId
3447
+ * }
3448
+ * }
3449
+ * );
3450
+ *
3451
+ * // Later fetch visitor properties if needed
3452
+ * await visitorInstance.fetchVisitor();
2958
3453
  * ```
2959
3454
  *
2960
- * @returns {Visitor} Returns a new Visitor object.
3455
+ * @returns {Visitor} Returns a new Visitor object without fetching its properties.
2961
3456
  */
2962
3457
  create(id: number, urlSlug: string, options?: VisitorOptionalInterface): Visitor;
2963
3458
  /**
2964
- * Instantiate a new instance of Visitor class and retrieve all properties.
3459
+ * Instantiate a new instance of Visitor class and automatically fetch all its properties.
3460
+ *
3461
+ * @remarks
3462
+ * This method creates a controller instance and immediately fetches all properties of the visitor.
3463
+ * It's a convenience method that combines creating an instance and calling fetchVisitor().
3464
+ *
3465
+ * @keywords get, fetch, retrieve, visitor, load, avatar, instance
2965
3466
  *
2966
3467
  * @example
2967
- * ```
2968
- * const visitorInstance = await Visitor.get(id, urlSlug, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
3468
+ * ```ts
3469
+ * // Import the pre-initialized factory from your app's initialization file
3470
+ * import { Visitor } from "utils/topiaInit.ts";
3471
+ *
3472
+ * // Get a fully populated Visitor instance
3473
+ * const visitorInstance = await Visitor.get(
3474
+ * 12345, // visitor ID
3475
+ * "my-world-slug",
3476
+ * {
3477
+ * credentials: {
3478
+ * interactiveNonce,
3479
+ * interactivePublicKey,
3480
+ * assetId,
3481
+ * urlSlug,
3482
+ * visitorId
3483
+ * }
3484
+ * }
3485
+ * );
3486
+ *
3487
+ * // The properties are already loaded, so you can use them immediately
3488
+ * console.log(visitorInstance.username);
3489
+ * console.log(visitorInstance.position);
2969
3490
  * ```
2970
3491
  *
2971
- * @returns {Promise<Visitor>} Returns a new Visitor object with all properties.
3492
+ * @returns {Promise<Visitor>} Returns a new Visitor object with all properties already fetched.
2972
3493
  */
2973
3494
  get(id: number, urlSlug: string, options?: VisitorOptionalInterface): Promise<Visitor>;
2974
3495
  }
2975
3496
 
2976
3497
  /**
3498
+ * Factory for creating WebRTCConnector instances. Use this factory to establish WebRTC connections for audio/video in Topia worlds.
3499
+ *
3500
+ * @remarks
3501
+ * This factory should be instantiated once per application and reused across your codebase.
3502
+ * The WebRTCConnector provides methods to set up and manage real-time audio/video communication.
3503
+ *
3504
+ * @keywords webrtc, factory, create, audio, video, communication, real-time, conference
3505
+ *
2977
3506
  * @example
2978
3507
  * ```ts
2979
- * const WebRTCConnector = new WebRTCConnectorFactory(myTopiaInstance);
3508
+ * // In your initialization file (e.g., utils/topiaInit.ts)
3509
+ * import { Topia, WebRTCConnectorFactory } from "@rtsdk/topia";
3510
+ * const topia = new Topia({ config });
3511
+ * export const WebRTCConnector = new WebRTCConnectorFactory(topia);
2980
3512
  * ```
2981
3513
  */
2982
3514
  declare class WebRTCConnectorFactory {
2983
3515
  topia: Topia;
2984
3516
  constructor(topia: Topia);
2985
3517
  /**
2986
- * Instantiate a new instance of WebRTCConnector class.
3518
+ * Instantiate a new instance of WebRTCConnector class for managing audio/video communication.
3519
+ *
3520
+ * @remarks
3521
+ * This method creates a controller instance for establishing and managing WebRTC connections.
3522
+ * Use this for implementing real-time audio/video communication features in Topia worlds.
3523
+ *
3524
+ * @keywords create, instantiate, webrtc, initialize, audio, video, communication, stream
2987
3525
  *
2988
3526
  * @example
2989
- * ```
2990
- * const webRTCInstance = await WebRTCConnector.create({ credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId }, twilioConfig: {} });
3527
+ * ```ts
3528
+ * // Import the pre-initialized factory from your app's initialization file
3529
+ * import { WebRTCConnector } from "utils/topiaInit.ts";
3530
+ *
3531
+ * // Create a WebRTCConnector instance with credentials and configuration
3532
+ * const webRTCInstance = WebRTCConnector.create(
3533
+ * "my-world-slug",
3534
+ * {
3535
+ * credentials: {
3536
+ * interactiveNonce,
3537
+ * interactivePublicKey,
3538
+ * assetId,
3539
+ * urlSlug,
3540
+ * visitorId
3541
+ * },
3542
+ * twilioConfig: {
3543
+ * // Twilio configuration options
3544
+ * }
3545
+ * }
3546
+ * );
3547
+ *
3548
+ * // Use the instance to establish connections
3549
+ * await webRTCInstance.connect();
2991
3550
  * ```
2992
3551
  *
2993
- * @returns {WebRTCConnector} Returns a new WebRTCConnector object.
3552
+ * @returns {WebRTCConnector} Returns a new WebRTCConnector object for managing audio/video communication.
2994
3553
  */
2995
3554
  create(urlSlug: string, options?: WebRTCConnectorOptionalInterface): WebRTCConnector;
2996
3555
  }
2997
3556
 
2998
3557
  /**
3558
+ * Factory for creating WorldActivity instances. Use this factory to monitor and manage visitor activity in Topia worlds.
3559
+ *
3560
+ * @remarks
3561
+ * This factory should be instantiated once per application and reused across your codebase.
3562
+ * The WorldActivity controller provides methods to interact with real-time visitor activities and movements.
3563
+ *
3564
+ * @keywords world activity, factory, create, visitors, movement, tracking, presence, real-time
3565
+ *
2999
3566
  * @example
3000
3567
  * ```ts
3001
- * const WorldActivity = new WorldActivityFactory(myTopiaInstance);
3568
+ * // In your initialization file (e.g., utils/topiaInit.ts)
3569
+ * import { Topia, WorldActivityFactory } from "@rtsdk/topia";
3570
+ * const topia = new Topia({ config });
3571
+ * export const WorldActivity = new WorldActivityFactory(topia);
3002
3572
  * ```
3003
3573
  */
3004
3574
  declare class WorldActivityFactory {
3005
3575
  topia: Topia;
3006
3576
  constructor(topia: Topia);
3007
3577
  /**
3008
- * Instantiate a new instance of WorldActivity class.
3578
+ * Instantiate a new instance of WorldActivity class for monitoring visitor activity in a specific world.
3579
+ *
3580
+ * @remarks
3581
+ * This method creates a controller instance for tracking and managing visitor activity in a world.
3582
+ * Use this to fetch current visitors, move visitors, or monitor specific zones within a world.
3583
+ *
3584
+ * @keywords create, instantiate, world activity, initialize, visitors, tracking, presence
3009
3585
  *
3010
3586
  * @example
3011
- * ```
3012
- * const worldActivityInstance = await WorldActivity.create(urlSlug, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
3587
+ * ```ts
3588
+ * // Import the pre-initialized factory from your app's initialization file
3589
+ * import { WorldActivity } from "utils/topiaInit.ts";
3590
+ *
3591
+ * // Create a WorldActivity instance with credentials
3592
+ * const worldActivityInstance = WorldActivity.create(
3593
+ * "my-world-slug",
3594
+ * {
3595
+ * credentials: {
3596
+ * interactiveNonce,
3597
+ * interactivePublicKey,
3598
+ * assetId,
3599
+ * urlSlug,
3600
+ * visitorId
3601
+ * }
3602
+ * }
3603
+ * );
3604
+ *
3605
+ * // Get current visitors in the world
3606
+ * const visitors = await worldActivityInstance.currentVisitors();
3607
+ * console.log(`There are ${visitors.length} visitors in the world`);
3608
+ *
3609
+ * // Check visitors in a specific zone
3610
+ * const zoneVisitors = await worldActivityInstance.fetchVisitorsInZone("stage-area");
3013
3611
  * ```
3014
3612
  *
3015
- * @returns {WorldActivity} Returns a new WorldActivity object.
3613
+ * @returns {WorldActivity} Returns a new WorldActivity object for tracking and managing visitor activity.
3016
3614
  */
3017
3615
  create(urlSlug: string, options?: WorldOptionalInterface): WorldActivity;
3018
3616
  }
3019
3617
 
3020
3618
  /**
3619
+ * Factory for creating World instances. Use this factory to interact with Topia worlds.
3620
+ *
3621
+ * @remarks
3622
+ * This factory should be instantiated once per application and reused across your codebase.
3623
+ * The World controller provides methods to manage world settings, retrieve world details, and perform world-level operations.
3624
+ *
3625
+ * @keywords world, factory, create, virtual space, environment, room, topia
3626
+ *
3021
3627
  * @example
3022
3628
  * ```ts
3023
- * const World = new WorldFactory(myTopiaInstance);
3629
+ * // In your initialization file (e.g., utils/topiaInit.ts)
3630
+ * import { Topia, WorldFactory } from "@rtsdk/topia";
3631
+ * const topia = new Topia({ config });
3632
+ * export const World = new WorldFactory(topia);
3024
3633
  * ```
3025
3634
  */
3026
3635
  declare class WorldFactory extends SDKController {
3027
3636
  constructor(topia: Topia);
3028
3637
  /**
3029
- * Instantiate a new instance of World class.
3638
+ * Instantiate a new instance of World class for interacting with a specific Topia world.
3639
+ *
3640
+ * @remarks
3641
+ * This method creates a controller instance for a world identified by its URL slug.
3642
+ * The world controller can be used to fetch details, update world settings, and perform other world-level operations.
3643
+ *
3644
+ * @keywords create, instantiate, world, initialize, virtual space, environment, room
3030
3645
  *
3031
3646
  * @example
3032
- * ```
3033
- * const worldInstance = await World.create(urlSlug, { credentials: { interactiveNonce, interactivePublicKey, assetId, urlSlug, visitorId } });
3647
+ * ```ts
3648
+ * // Import the pre-initialized factory from your app's initialization file
3649
+ * import { World } from "utils/topiaInit.ts";
3650
+ *
3651
+ * // Create a World instance with credentials
3652
+ * const worldInstance = World.create(
3653
+ * "my-world-slug",
3654
+ * {
3655
+ * credentials: {
3656
+ * interactiveNonce,
3657
+ * interactivePublicKey,
3658
+ * assetId,
3659
+ * urlSlug,
3660
+ * visitorId
3661
+ * }
3662
+ * }
3663
+ * );
3664
+ *
3665
+ * // Fetch world details
3666
+ * await worldInstance.fetchDetails();
3667
+ * console.log(worldInstance.name);
3034
3668
  * ```
3035
3669
  *
3036
- * @returns {World} Returns a new World object.
3670
+ * @returns {World} Returns a new World object for interacting with the specified world.
3037
3671
  */
3038
3672
  create(urlSlug: string, options?: WorldOptionalInterface): World;
3039
3673
  /**
3040
- * Deletes an array of Dropped Assets from within a world and returns success: true
3674
+ * Deletes multiple dropped assets from a world in a single operation.
3675
+ *
3676
+ * @remarks
3677
+ * This method provides a convenient way to delete multiple dropped assets at once rather than
3678
+ * deleting them one by one. Requires appropriate permissions via interactive credentials.
3679
+ *
3680
+ * @keywords delete, remove, dropped assets, multiple, batch, cleanup, world
3041
3681
  *
3042
3682
  * @example
3043
- * ```
3044
- * await World.deleteDroppedAssets(urlSlug, ["exampleDroppedAssetId1", "exampleDroppedAssetId2"], interactiveSecret, credentials);
3683
+ * ```ts
3684
+ * // Import the pre-initialized factory from your app's initialization file
3685
+ * import { World } from "utils/topiaInit.ts";
3686
+ *
3687
+ * // Delete multiple dropped assets from a world
3688
+ * const result = await World.deleteDroppedAssets(
3689
+ * "my-world-slug",
3690
+ * ["asset-id-123", "asset-id-456", "asset-id-789"],
3691
+ * "your-interactive-secret",
3692
+ * {
3693
+ * apiKey: "your-api-key",
3694
+ * interactivePublicKey: "your-public-key",
3695
+ * visitorId: 12345
3696
+ * }
3697
+ * );
3698
+ *
3699
+ * if (result.success) {
3700
+ * console.log("Assets successfully deleted");
3701
+ * }
3045
3702
  * ```
3046
3703
  *
3047
- * @returns {Promise<{ success: boolean }>} Returns `{ success: true }` or an error.
3704
+ * @returns {Promise<{ success: boolean }>} Returns `{ success: true }` if all assets were deleted successfully.
3048
3705
  */
3049
3706
  deleteDroppedAssets(urlSlug: string, droppedAssetIds: string[], interactiveSecret: string, credentials: {
3050
3707
  apiKey?: string;