connected-spaces-platform.web 4.22.1 → 4.23.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.
@@ -1730,6 +1730,14 @@ function csp_systems_ProductInfoResultFactory(
1730
1730
  ProxyClassFactories["csp_systems_ProductInfoResult"] =
1731
1731
  csp_systems_ProductInfoResultFactory;
1732
1732
 
1733
+ function csp_systems_ProductInfoCollectionResultFactory(
1734
+ nativePointer: NativePointer,
1735
+ ): NativeClassWrapper {
1736
+ return new Systems.ProductInfoCollectionResult(nativePointer);
1737
+ }
1738
+ ProxyClassFactories["csp_systems_ProductInfoCollectionResult"] =
1739
+ csp_systems_ProductInfoCollectionResultFactory;
1740
+
1733
1741
  function csp_systems_CheckoutInfoResultFactory(
1734
1742
  nativePointer: NativePointer,
1735
1743
  ): NativeClassWrapper {
@@ -2313,6 +2321,18 @@ function csp_common_Array_csp_systems_CartLineFactory(
2313
2321
  ProxyClassFactories["csp_common_Array_csp_systems_CartLine"] =
2314
2322
  csp_common_Array_csp_systems_CartLineFactory;
2315
2323
 
2324
+ function csp_common_Array_csp_systems_ProductInfoFactory(
2325
+ nativePointer: NativePointer,
2326
+ ): NativeClassWrapper {
2327
+ return new Common.Array<Systems.ProductInfo>(
2328
+ nativePointer,
2329
+ csp_systems_ProductInfoFactory,
2330
+ "csp_systems_ProductInfo",
2331
+ );
2332
+ }
2333
+ ProxyClassFactories["csp_common_Array_csp_systems_ProductInfo"] =
2334
+ csp_common_Array_csp_systems_ProductInfoFactory;
2335
+
2316
2336
  function csp_common_Array_csp_systems_TicketedEventFactory(
2317
2337
  nativePointer: NativePointer,
2318
2338
  ): NativeClassWrapper {
@@ -41957,6 +41977,71 @@ export namespace Systems {
41957
41977
  }
41958
41978
  }
41959
41979
 
41980
+ export namespace Systems {
41981
+ /**
41982
+ @ingroup ECommerce System
41983
+ * @description Data class used to contain information when attempting to get Arrays of Product Info.
41984
+ */
41985
+ export class ProductInfoCollectionResult
41986
+ extends Systems.ResultBase
41987
+ implements INativeResource
41988
+ {
41989
+ /** @internal */
41990
+ constructor(pointer: NativePointer) {
41991
+ super(pointer);
41992
+ }
41993
+
41994
+ static fromResultBase(
41995
+ baseInstance: Systems.ResultBase,
41996
+ ): Systems.ProductInfoCollectionResult {
41997
+ const nativeClassWrapper = baseInstance as unknown as NativeClassWrapper;
41998
+ return new Systems.ProductInfoCollectionResult(
41999
+ new NativePointer(
42000
+ nativeClassWrapper.pointer,
42001
+ nativeClassWrapper.ownsPointer,
42002
+ ),
42003
+ );
42004
+ }
42005
+
42006
+ /**
42007
+ * @description Retrieves the Product Info Array being stored.
42008
+ * @return Reference to the productinfos
42009
+ */
42010
+
42011
+ getProducts(): Common.Array<Systems.ProductInfo> {
42012
+ var _ret = Module._malloc(8);
42013
+
42014
+ Module.ccall(
42015
+ "csp_systems_ProductInfoCollectionResult_GetProductsC_ArrayRC",
42016
+ "void",
42017
+ ["number", "number"],
42018
+ [_ret, this.pointer],
42019
+ );
42020
+ var _nPtr = new Common.Array<Systems.ProductInfo>(
42021
+ getNativePointer(_ret),
42022
+ csp_systems_ProductInfoFactory,
42023
+ "csp_systems_ProductInfo",
42024
+ );
42025
+ Module._free(_ret);
42026
+
42027
+ return _nPtr;
42028
+ }
42029
+
42030
+ delete(): void {
42031
+ if (this.ownsPointer && !this.disposed) {
42032
+ Module.ccall(
42033
+ "csp_systems_ProductInfoCollectionResult_Dtor",
42034
+ "void",
42035
+ ["number"],
42036
+ [this.pointer],
42037
+ );
42038
+
42039
+ this.disposed = true;
42040
+ }
42041
+ }
42042
+ }
42043
+ }
42044
+
41960
42045
  export namespace Systems {
41961
42046
  /**
41962
42047
  @ingroup ECommerce System
@@ -42255,6 +42340,51 @@ export namespace Systems {
42255
42340
  return _promise;
42256
42341
  }
42257
42342
 
42343
+ /**
42344
+ * @description Get product information from a shopify store within a space, by providing an array of VariantIds
42345
+ * @param spaceId - Space id of product
42346
+ * @param variantIds - Variant ids to search for
42347
+ * @param callback - Callback containing collection of product info when asynchronous task finishes
42348
+ */
42349
+
42350
+ async getProductInfoCollectionByVariantIds(
42351
+ spaceId: string,
42352
+ variantIds: Common.Array<string>,
42353
+ ): Promise<Systems.ProductInfoCollectionResult> {
42354
+ var _resolve;
42355
+
42356
+ var _promise = new Promise<Systems.ProductInfoCollectionResult>((_r) => {
42357
+ _resolve = _r;
42358
+ });
42359
+
42360
+ var _callbackPtr: number;
42361
+ var _callback = (_stateObject__: number, result) => {
42362
+ var _resultPtr = getNativePointer(result);
42363
+ var _resultInstance = new Systems.ProductInfoCollectionResult(
42364
+ _resultPtr,
42365
+ );
42366
+
42367
+ if (_resultInstance.getResultCode() == Systems.EResultCode.InProgress) {
42368
+ return;
42369
+ }
42370
+
42371
+ _resolve(_resultInstance);
42372
+
42373
+ Module.removeFunction(_callbackPtr);
42374
+ };
42375
+
42376
+ _callbackPtr = Module.addFunction(_callback, "vii");
42377
+
42378
+ Module.ccall(
42379
+ "csp_systems_ECommerceSystem_GetProductInfoCollectionByVariantIds_void_StringRC_ArrayRC_ProductInfoCollectionResultCallback",
42380
+ "void",
42381
+ ["number", "string", "number", "number", "number"],
42382
+ [this.pointer, spaceId, variantIds.pointer, _callbackPtr, 0],
42383
+ );
42384
+
42385
+ return _promise;
42386
+ }
42387
+
42258
42388
  /**
42259
42389
  * @description Get checkout information from a shopify store within a space
42260
42390
  * @param spaceId - Space id of the cart
@@ -45992,16 +46122,40 @@ export namespace Systems {
45992
46122
  }
45993
46123
 
45994
46124
  /**
45995
- * @description Send exit current space event to EventSystem.
46125
+ * @description Exits the space and deregisters from the space scope.
45996
46126
  */
45997
46127
 
45998
- exitSpace(): void {
46128
+ async exitSpace(): Promise<Systems.NullResult> {
46129
+ var _resolve;
46130
+
46131
+ var _promise = new Promise<Systems.NullResult>((_r) => {
46132
+ _resolve = _r;
46133
+ });
46134
+
46135
+ var _callbackPtr: number;
46136
+ var _callback = (_stateObject__: number, result) => {
46137
+ var _resultPtr = getNativePointer(result);
46138
+ var _resultInstance = new Systems.NullResult(_resultPtr);
46139
+
46140
+ if (_resultInstance.getResultCode() == Systems.EResultCode.InProgress) {
46141
+ return;
46142
+ }
46143
+
46144
+ _resolve(_resultInstance);
46145
+
46146
+ Module.removeFunction(_callbackPtr);
46147
+ };
46148
+
46149
+ _callbackPtr = Module.addFunction(_callback, "vii");
46150
+
45999
46151
  Module.ccall(
46000
- "csp_systems_SpaceSystem_ExitSpace_void",
46152
+ "csp_systems_SpaceSystem_ExitSpace_void_NullResultCallback",
46001
46153
  "void",
46002
- ["number"],
46003
- [this.pointer],
46154
+ ["number", "number", "number"],
46155
+ [this.pointer, _callbackPtr, 0],
46004
46156
  );
46157
+
46158
+ return _promise;
46005
46159
  }
46006
46160
 
46007
46161
  /**
@@ -46331,7 +46485,8 @@ export namespace Systems {
46331
46485
  * @description Retrieves basic space details for the spaces with the given attributes available to the logged in user.
46332
46486
  * Results pagination is supported through the use of ResultsSkip and ResultsMax.
46333
46487
  * @param isDiscoverable - `true` or `false` to filter by IsDiscoverable attribute value.
46334
- * @param isDiscoverable - `true` or `false` to filter by RequiresInvite attribute value.
46488
+ * @param isArchived - `true` or `false` to filter by IsArchived attribute value.
46489
+ * @param requiresInvite - `true` or `false` to filter by RequiresInvite attribute value.
46335
46490
  * @param resultsSkip - Number of result entries that will be skipped from the result. for no skip pass nullptr.
46336
46491
  * @param resultsMax - Maximum number of result entries to be retrieved. for all available result entries pass
46337
46492
  * nullptr.
@@ -46340,6 +46495,7 @@ export namespace Systems {
46340
46495
 
46341
46496
  async getSpacesByAttributes(
46342
46497
  isDiscoverable: boolean | null,
46498
+ isArchived: boolean | null,
46343
46499
  requiresInvite: boolean | null,
46344
46500
  resultsSkip: number | null,
46345
46501
  resultsMax: number | null,
@@ -46372,6 +46528,12 @@ export namespace Systems {
46372
46528
  Module.setValue(isDiscoverablePointer, isDiscoverable ? 1 : 0, "i32");
46373
46529
  }
46374
46530
 
46531
+ var isArchivedPointer = 0;
46532
+ if (isArchived != null) {
46533
+ isArchivedPointer = Module._malloc(4);
46534
+ Module.setValue(isArchivedPointer, isArchived ? 1 : 0, "i32");
46535
+ }
46536
+
46375
46537
  var requiresInvitePointer = 0;
46376
46538
  if (requiresInvite != null) {
46377
46539
  requiresInvitePointer = Module._malloc(4);
@@ -46391,12 +46553,13 @@ export namespace Systems {
46391
46553
  }
46392
46554
 
46393
46555
  Module.ccall(
46394
- "csp_systems_SpaceSystem_GetSpacesByAttributes_void_boolRC_boolRC_intRC_intRC_BasicSpacesResultCallback",
46556
+ "csp_systems_SpaceSystem_GetSpacesByAttributes_void_boolRC_boolRC_boolRC_intRC_intRC_BasicSpacesResultCallback",
46395
46557
  "void",
46396
46558
  [
46397
46559
  "number",
46398
46560
  "boolean",
46399
46561
  "boolean",
46562
+ "boolean",
46400
46563
  "number",
46401
46564
  "number",
46402
46565
  "number",
@@ -46405,6 +46568,7 @@ export namespace Systems {
46405
46568
  [
46406
46569
  this.pointer,
46407
46570
  isDiscoverablePointer,
46571
+ isArchivedPointer,
46408
46572
  requiresInvitePointer,
46409
46573
  resultsSkipPointer,
46410
46574
  resultsMaxPointer,
@@ -46416,6 +46580,9 @@ export namespace Systems {
46416
46580
  if (isDiscoverablePointer) {
46417
46581
  Module._free(isDiscoverablePointer);
46418
46582
  }
46583
+ if (isArchivedPointer) {
46584
+ Module._free(isArchivedPointer);
46585
+ }
46419
46586
  if (requiresInvitePointer) {
46420
46587
  Module._free(requiresInvitePointer);
46421
46588
  }
@@ -49314,7 +49481,7 @@ export namespace Systems {
49314
49481
  * @param callback - Callback when asynchronous task finishes
49315
49482
  */
49316
49483
 
49317
- async refreshSession(
49484
+ async loginWithRefreshToken(
49318
49485
  userId: string,
49319
49486
  refreshToken: string,
49320
49487
  ): Promise<Systems.LoginStateResult> {
@@ -49341,7 +49508,7 @@ export namespace Systems {
49341
49508
  _callbackPtr = Module.addFunction(_callback, "vii");
49342
49509
 
49343
49510
  Module.ccall(
49344
- "csp_systems_UserSystem_RefreshSession_void_StringRC_StringRC_LoginStateResultCallback",
49511
+ "csp_systems_UserSystem_LoginWithRefreshToken_void_StringRC_StringRC_LoginStateResultCallback",
49345
49512
  "void",
49346
49513
  ["number", "string", "string", "number", "number"],
49347
49514
  [this.pointer, userId, refreshToken, _callbackPtr, 0],
@@ -49545,49 +49712,6 @@ export namespace Systems {
49545
49712
  return _promise;
49546
49713
  }
49547
49714
 
49548
- /**
49549
- * @description Log in to Magnopus Connected Services using the given one-time password/key.
49550
- * @param userId - The user id
49551
- * @param key - The one-time key to exchange
49552
- * @param callback - Callback to call when a response is received
49553
- */
49554
-
49555
- async exchangeKey(
49556
- userId: string,
49557
- key: string,
49558
- ): Promise<Systems.LoginStateResult> {
49559
- var _resolve;
49560
-
49561
- var _promise = new Promise<Systems.LoginStateResult>((_r) => {
49562
- _resolve = _r;
49563
- });
49564
-
49565
- var _callbackPtr: number;
49566
- var _callback = (_stateObject__: number, result) => {
49567
- var _resultPtr = getNativePointer(result);
49568
- var _resultInstance = new Systems.LoginStateResult(_resultPtr);
49569
-
49570
- if (_resultInstance.getResultCode() == Systems.EResultCode.InProgress) {
49571
- return;
49572
- }
49573
-
49574
- _resolve(_resultInstance);
49575
-
49576
- Module.removeFunction(_callbackPtr);
49577
- };
49578
-
49579
- _callbackPtr = Module.addFunction(_callback, "vii");
49580
-
49581
- Module.ccall(
49582
- "csp_systems_UserSystem_ExchangeKey_void_StringRC_StringRC_LoginStateResultCallback",
49583
- "void",
49584
- ["number", "string", "string", "number", "number"],
49585
- [this.pointer, userId, key, _callbackPtr, 0],
49586
- );
49587
-
49588
- return _promise;
49589
- }
49590
-
49591
49715
  /**
49592
49716
  * @description Logout from Magnopus Connected Services.
49593
49717
  * @param callback - Callback to call when a response is received
@@ -50537,6 +50661,24 @@ export namespace Common {
50537
50661
  return _inst;
50538
50662
  }
50539
50663
 
50664
+ static ofcsp_systems_ProductInfo(): Array<Systems.ProductInfo> {
50665
+ var _ret = Module._malloc(8);
50666
+ Module.ccall(
50667
+ "csp_common_Array_Ctor_csp_systems_ProductInfo",
50668
+ "void",
50669
+ ["number"],
50670
+ [_ret],
50671
+ );
50672
+ var _inst = new Array<Systems.ProductInfo>(
50673
+ getNativePointer(_ret),
50674
+ csp_systems_ProductInfoFactory,
50675
+ "csp_systems_ProductInfo",
50676
+ );
50677
+ Module._free(_ret);
50678
+
50679
+ return _inst;
50680
+ }
50681
+
50540
50682
  static ofcsp_systems_TicketedEvent(): Array<Systems.TicketedEvent> {
50541
50683
  var _ret = Module._malloc(8);
50542
50684
  Module.ccall(
@@ -51183,6 +51325,26 @@ export namespace Common {
51183
51325
  return _inst;
51184
51326
  }
51185
51327
 
51328
+ static ofcsp_systems_ProductInfo_number(
51329
+ size: number,
51330
+ ): Array<Systems.ProductInfo> {
51331
+ var _ret = Module._malloc(8);
51332
+ Module.ccall(
51333
+ "csp_common_Array_Conv_size_tC_csp_systems_ProductInfo",
51334
+ "void",
51335
+ ["number", "number"],
51336
+ [_ret, size],
51337
+ );
51338
+ var _inst = new Array<Systems.ProductInfo>(
51339
+ getNativePointer(_ret),
51340
+ csp_systems_ProductInfoFactory,
51341
+ "csp_systems_ProductInfo",
51342
+ );
51343
+ Module._free(_ret);
51344
+
51345
+ return _inst;
51346
+ }
51347
+
51186
51348
  static ofcsp_systems_TicketedEvent_number(
51187
51349
  size: number,
51188
51350
  ): Array<Systems.TicketedEvent> {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "connected-spaces-platform.web",
3
3
  "displayName": "connected-spaces-platform.web",
4
- "version": "4.22.1+503",
4
+ "version": "4.23.0+504",
5
5
  "description": "This package provides the binaries required to interface with the Connected Spaces Platform API.",
6
6
  "license": "Apache-2.0",
7
7
  "dependencies": {