@dynamic-labs/sdk-api-core 0.0.1125 → 0.1.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/sdk-api-core",
3
- "version": "0.0.1125",
3
+ "version": "0.1.0",
4
4
  "author": "Dynamic Labs",
5
5
  "license": "Apache-2.0",
6
6
  "publishConfig": {
@@ -44,7 +44,6 @@ require('../models/KycFieldType.cjs');
44
44
  var BusinessAccount = require('../models/BusinessAccount.cjs');
45
45
  var BusinessAccountDetail = require('../models/BusinessAccountDetail.cjs');
46
46
  var BusinessAccountMember = require('../models/BusinessAccountMember.cjs');
47
- var BusinessAccountSigner = require('../models/BusinessAccountSigner.cjs');
48
47
  require('../models/ChainEnum.cjs');
49
48
  var BusinessAccountList = require('../models/BusinessAccountList.cjs');
50
49
  require('../models/CaptchaProviderEnum.cjs');
@@ -5320,6 +5319,39 @@ class SDKApi extends runtime.BaseAPI {
5320
5319
  const response = await this.getUserPasskeysRaw(requestParameters, initOverrides);
5321
5320
  return await response.value();
5322
5321
  }
5322
+ /**
5323
+ * Returns the Composition environment-Layer content for the environment, read-only, for any signed-in user in the environment.
5324
+ * Get the environment-Layer\'s Rules
5325
+ */
5326
+ async getWaasEnvPolicyLayerRaw(requestParameters, initOverrides) {
5327
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
5328
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling getWaasEnvPolicyLayer.');
5329
+ }
5330
+ const queryParameters = {};
5331
+ const headerParameters = {};
5332
+ if (this.configuration && this.configuration.accessToken) {
5333
+ const token = this.configuration.accessToken;
5334
+ const tokenString = await token("bearerAuth", []);
5335
+ if (tokenString) {
5336
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
5337
+ }
5338
+ }
5339
+ const response = await this.request({
5340
+ path: `/sdk/{environmentId}/waas/env-policy-layer`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
5341
+ method: 'GET',
5342
+ headers: headerParameters,
5343
+ query: queryParameters,
5344
+ }, initOverrides);
5345
+ return new runtime.JSONApiResponse(response, (jsonValue) => WaasPolicyLayerResponse.WaasPolicyLayerResponseFromJSON(jsonValue));
5346
+ }
5347
+ /**
5348
+ * Returns the Composition environment-Layer content for the environment, read-only, for any signed-in user in the environment.
5349
+ * Get the environment-Layer\'s Rules
5350
+ */
5351
+ async getWaasEnvPolicyLayer(requestParameters, initOverrides) {
5352
+ const response = await this.getWaasEnvPolicyLayerRaw(requestParameters, initOverrides);
5353
+ return await response.value();
5354
+ }
5323
5355
  /**
5324
5356
  * Returns the Composition Layer content for the calling wallet\'s own active Signer, or (given shareSetId) another share set of the same wallet — e.g. a delegated share set — without mutating it. Only the wallet\'s own owner may target another share set.
5325
5357
  * Get a signer-Layer\'s Rules
@@ -8700,8 +8732,8 @@ class SDKApi extends runtime.BaseAPI {
8700
8732
  return await response.value();
8701
8733
  }
8702
8734
  /**
8703
- * **Stubbed** in this release. Caller must hold an active share on the wallet (only existing share-holders can reshare). Target user is resolved the same way as addMember. The pending signer row is persisted with `shareSetId=null`; the reshare ceremony that mints the share is a follow-up.
8704
- * SDK — add a signer to a wallet in a business account (stubbed)
8735
+ * Adds a signer to a business-account wallet by running a same-parties 2/2 -> 2/2 MPC reshare ceremony. The caller must hold an active share on the wallet (only existing share-holders can reshare). The target user is resolved the same way as addMember and, if absent, is created and added to the account. The response is `text/event-stream` (NOT JSON): clients consume it via EventSource and receive `room_created` and `ceremony_complete` events; the new signer share is delivered to the initiating client (iframe) via Sodot\'s relay and backed up to the client-keyshare service on the target\'s behalf.
8736
+ * SDK — add a signer to a wallet in a business account
8705
8737
  */
8706
8738
  async sdkAddBusinessAccountSignerRaw(requestParameters, initOverrides) {
8707
8739
  if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
@@ -8733,11 +8765,11 @@ class SDKApi extends runtime.BaseAPI {
8733
8765
  query: queryParameters,
8734
8766
  body: AddBusinessAccountSignerSdkRequest.AddBusinessAccountSignerSdkRequestToJSON(requestParameters.addBusinessAccountSignerSdkRequest),
8735
8767
  }, initOverrides);
8736
- return new runtime.JSONApiResponse(response, (jsonValue) => BusinessAccountSigner.BusinessAccountSignerFromJSON(jsonValue));
8768
+ return new runtime.TextApiResponse(response);
8737
8769
  }
8738
8770
  /**
8739
- * **Stubbed** in this release. Caller must hold an active share on the wallet (only existing share-holders can reshare). Target user is resolved the same way as addMember. The pending signer row is persisted with `shareSetId=null`; the reshare ceremony that mints the share is a follow-up.
8740
- * SDK — add a signer to a wallet in a business account (stubbed)
8771
+ * Adds a signer to a business-account wallet by running a same-parties 2/2 -> 2/2 MPC reshare ceremony. The caller must hold an active share on the wallet (only existing share-holders can reshare). The target user is resolved the same way as addMember and, if absent, is created and added to the account. The response is `text/event-stream` (NOT JSON): clients consume it via EventSource and receive `room_created` and `ceremony_complete` events; the new signer share is delivered to the initiating client (iframe) via Sodot\'s relay and backed up to the client-keyshare service on the target\'s behalf.
8772
+ * SDK — add a signer to a wallet in a business account
8741
8773
  */
8742
8774
  async sdkAddBusinessAccountSigner(requestParameters, initOverrides) {
8743
8775
  const response = await this.sdkAddBusinessAccountSignerRaw(requestParameters, initOverrides);
@@ -11461,6 +11493,29 @@ class SDKApi extends runtime.BaseAPI {
11461
11493
  async verifyUnlinkOptions(requestParameters, initOverrides) {
11462
11494
  await this.verifyUnlinkOptionsRaw(requestParameters, initOverrides);
11463
11495
  }
11496
+ /**
11497
+ * Options call for this endpoint
11498
+ */
11499
+ async waasEnvPolicyLayerOptionsRaw(requestParameters, initOverrides) {
11500
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
11501
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling waasEnvPolicyLayerOptions.');
11502
+ }
11503
+ const queryParameters = {};
11504
+ const headerParameters = {};
11505
+ const response = await this.request({
11506
+ path: `/sdk/{environmentId}/waas/env-policy-layer`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))),
11507
+ method: 'OPTIONS',
11508
+ headers: headerParameters,
11509
+ query: queryParameters,
11510
+ }, initOverrides);
11511
+ return new runtime.VoidApiResponse(response);
11512
+ }
11513
+ /**
11514
+ * Options call for this endpoint
11515
+ */
11516
+ async waasEnvPolicyLayerOptions(requestParameters, initOverrides) {
11517
+ await this.waasEnvPolicyLayerOptionsRaw(requestParameters, initOverrides);
11518
+ }
11464
11519
  /**
11465
11520
  * Options call for this endpoint
11466
11521
  */