@dynamic-labs/sdk-api 0.152.0 → 0.153.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",
3
- "version": "0.152.0",
3
+ "version": "0.153.0",
4
4
  "author": "Dynamic Labs",
5
5
  "license": "Apache-2.0",
6
6
  "publishConfig": {
@@ -1137,6 +1137,73 @@ class SDKApi extends runtime.BaseAPI {
1137
1137
  async broadcastWaasTransactionOptions(requestParameters, initOverrides) {
1138
1138
  await this.broadcastWaasTransactionOptionsRaw(requestParameters, initOverrides);
1139
1139
  }
1140
+ /**
1141
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`, which co-signs inside caller-visible MPC rooms. The enclave is offline: the caller supplies the token accounts\' raw on-chain state (`accountState`, `destinationAccountState`), the cluster rent constant (`lamportsPerByte`) and a fresh `recentBlockhash`/`lastValidBlockHeight`. Confidential amounts are opaque on-chain — policy screens the operation, mint and addresses but cannot evaluate the transferred amount.
1142
+ * Build Token-2022 confidential-transfer transactions
1143
+ */
1144
+ async buildWaasConfidentialTransactionRaw(requestParameters, initOverrides) {
1145
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
1146
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling buildWaasConfidentialTransaction.');
1147
+ }
1148
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
1149
+ throw new runtime.RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling buildWaasConfidentialTransaction.');
1150
+ }
1151
+ if (requestParameters.waasSignConfidentialTransferRequest === null || requestParameters.waasSignConfidentialTransferRequest === undefined) {
1152
+ throw new runtime.RequiredError('waasSignConfidentialTransferRequest', 'Required parameter requestParameters.waasSignConfidentialTransferRequest was null or undefined when calling buildWaasConfidentialTransaction.');
1153
+ }
1154
+ const queryParameters = {};
1155
+ const headerParameters = {};
1156
+ headerParameters['Content-Type'] = 'application/json';
1157
+ if (this.configuration && this.configuration.accessToken) {
1158
+ const token = this.configuration.accessToken;
1159
+ const tokenString = await token("bearerAuth", []);
1160
+ if (tokenString) {
1161
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
1162
+ }
1163
+ }
1164
+ const response = await this.request({
1165
+ path: `/sdk/{environmentId}/waas/{walletId}/buildConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
1166
+ method: 'POST',
1167
+ headers: headerParameters,
1168
+ query: queryParameters,
1169
+ body: WaasSignConfidentialTransferRequest.WaasSignConfidentialTransferRequestToJSON(requestParameters.waasSignConfidentialTransferRequest),
1170
+ }, initOverrides);
1171
+ return new runtime.JSONApiResponse(response, (jsonValue) => WaasSignConfidentialTransferResponse.WaasSignConfidentialTransferResponseFromJSON(jsonValue));
1172
+ }
1173
+ /**
1174
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`, which co-signs inside caller-visible MPC rooms. The enclave is offline: the caller supplies the token accounts\' raw on-chain state (`accountState`, `destinationAccountState`), the cluster rent constant (`lamportsPerByte`) and a fresh `recentBlockhash`/`lastValidBlockHeight`. Confidential amounts are opaque on-chain — policy screens the operation, mint and addresses but cannot evaluate the transferred amount.
1175
+ * Build Token-2022 confidential-transfer transactions
1176
+ */
1177
+ async buildWaasConfidentialTransaction(requestParameters, initOverrides) {
1178
+ const response = await this.buildWaasConfidentialTransactionRaw(requestParameters, initOverrides);
1179
+ return await response.value();
1180
+ }
1181
+ /**
1182
+ * Options call for this endpoint
1183
+ */
1184
+ async buildWaasConfidentialTransactionOptionsRaw(requestParameters, initOverrides) {
1185
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
1186
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling buildWaasConfidentialTransactionOptions.');
1187
+ }
1188
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
1189
+ throw new runtime.RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling buildWaasConfidentialTransactionOptions.');
1190
+ }
1191
+ const queryParameters = {};
1192
+ const headerParameters = {};
1193
+ const response = await this.request({
1194
+ path: `/sdk/{environmentId}/waas/{walletId}/buildConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
1195
+ method: 'OPTIONS',
1196
+ headers: headerParameters,
1197
+ query: queryParameters,
1198
+ }, initOverrides);
1199
+ return new runtime.VoidApiResponse(response);
1200
+ }
1201
+ /**
1202
+ * Options call for this endpoint
1203
+ */
1204
+ async buildWaasConfidentialTransactionOptions(requestParameters, initOverrides) {
1205
+ await this.buildWaasConfidentialTransactionOptionsRaw(requestParameters, initOverrides);
1206
+ }
1140
1207
  /**
1141
1208
  * Deprecated: use POST /sdk/{environmentId}/flow/{flowId}/cancel instead. Cancels a pre-broadcast transaction. Only allowed before the transaction is broadcasted.
1142
1209
  * Cancel a checkout transaction
@@ -11840,6 +11907,73 @@ class SDKApi extends runtime.BaseAPI {
11840
11907
  async signMessageOptions(requestParameters, initOverrides) {
11841
11908
  await this.signMessageOptionsRaw(requestParameters, initOverrides);
11842
11909
  }
11910
+ /**
11911
+ * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
11912
+ * Co-sign enclave-built confidential-transfer transactions
11913
+ */
11914
+ async signWaasConfidentialTransactionRaw(requestParameters, initOverrides) {
11915
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
11916
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling signWaasConfidentialTransaction.');
11917
+ }
11918
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
11919
+ throw new runtime.RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling signWaasConfidentialTransaction.');
11920
+ }
11921
+ if (requestParameters.waasSignConfidentialTransactionsRequest === null || requestParameters.waasSignConfidentialTransactionsRequest === undefined) {
11922
+ throw new runtime.RequiredError('waasSignConfidentialTransactionsRequest', 'Required parameter requestParameters.waasSignConfidentialTransactionsRequest was null or undefined when calling signWaasConfidentialTransaction.');
11923
+ }
11924
+ const queryParameters = {};
11925
+ const headerParameters = {};
11926
+ headerParameters['Content-Type'] = 'application/json';
11927
+ if (this.configuration && this.configuration.accessToken) {
11928
+ const token = this.configuration.accessToken;
11929
+ const tokenString = await token("bearerAuth", []);
11930
+ if (tokenString) {
11931
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
11932
+ }
11933
+ }
11934
+ const response = await this.request({
11935
+ path: `/sdk/{environmentId}/waas/{walletId}/signConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
11936
+ method: 'POST',
11937
+ headers: headerParameters,
11938
+ query: queryParameters,
11939
+ body: WaasSignConfidentialTransactionsRequest.WaasSignConfidentialTransactionsRequestToJSON(requestParameters.waasSignConfidentialTransactionsRequest),
11940
+ }, initOverrides);
11941
+ return new runtime.JSONApiResponse(response, (jsonValue) => WaasSignConfidentialTransactionsResponse.WaasSignConfidentialTransactionsResponseFromJSON(jsonValue));
11942
+ }
11943
+ /**
11944
+ * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
11945
+ * Co-sign enclave-built confidential-transfer transactions
11946
+ */
11947
+ async signWaasConfidentialTransaction(requestParameters, initOverrides) {
11948
+ const response = await this.signWaasConfidentialTransactionRaw(requestParameters, initOverrides);
11949
+ return await response.value();
11950
+ }
11951
+ /**
11952
+ * Options call for this endpoint
11953
+ */
11954
+ async signWaasConfidentialTransactionOptionsRaw(requestParameters, initOverrides) {
11955
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
11956
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling signWaasConfidentialTransactionOptions.');
11957
+ }
11958
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
11959
+ throw new runtime.RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling signWaasConfidentialTransactionOptions.');
11960
+ }
11961
+ const queryParameters = {};
11962
+ const headerParameters = {};
11963
+ const response = await this.request({
11964
+ path: `/sdk/{environmentId}/waas/{walletId}/signConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
11965
+ method: 'OPTIONS',
11966
+ headers: headerParameters,
11967
+ query: queryParameters,
11968
+ }, initOverrides);
11969
+ return new runtime.VoidApiResponse(response);
11970
+ }
11971
+ /**
11972
+ * Options call for this endpoint
11973
+ */
11974
+ async signWaasConfidentialTransactionOptions(requestParameters, initOverrides) {
11975
+ await this.signWaasConfidentialTransactionOptionsRaw(requestParameters, initOverrides);
11976
+ }
11843
11977
  /**
11844
11978
  * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
11845
11979
  * Co-sign enclave-built confidential-transfer transactions
@@ -104,6 +104,15 @@ export interface BroadcastWaasTransactionOptionsRequest {
104
104
  environmentId: string;
105
105
  walletId: string;
106
106
  }
107
+ export interface BuildWaasConfidentialTransactionRequest {
108
+ environmentId: string;
109
+ walletId: string;
110
+ waasSignConfidentialTransferRequest: WaasSignConfidentialTransferRequest;
111
+ }
112
+ export interface BuildWaasConfidentialTransactionOptionsRequest {
113
+ environmentId: string;
114
+ walletId: string;
115
+ }
107
116
  export interface CancelCheckoutTransactionRequest {
108
117
  environmentId: string;
109
118
  transactionId: string;
@@ -1515,6 +1524,15 @@ export interface SignMessageOptionsRequest {
1515
1524
  environmentId: string;
1516
1525
  walletId: string;
1517
1526
  }
1527
+ export interface SignWaasConfidentialTransactionRequest {
1528
+ environmentId: string;
1529
+ walletId: string;
1530
+ waasSignConfidentialTransactionsRequest: WaasSignConfidentialTransactionsRequest;
1531
+ }
1532
+ export interface SignWaasConfidentialTransactionOptionsRequest {
1533
+ environmentId: string;
1534
+ walletId: string;
1535
+ }
1518
1536
  export interface SignWaasConfidentialTransactionsRequest {
1519
1537
  environmentId: string;
1520
1538
  walletId: string;
@@ -2030,6 +2048,24 @@ export declare class SDKApi extends runtime.BaseAPI {
2030
2048
  * Options call for this endpoint
2031
2049
  */
2032
2050
  broadcastWaasTransactionOptions(requestParameters: BroadcastWaasTransactionOptionsRequest, initOverrides?: RequestInit): Promise<void>;
2051
+ /**
2052
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`, which co-signs inside caller-visible MPC rooms. The enclave is offline: the caller supplies the token accounts\' raw on-chain state (`accountState`, `destinationAccountState`), the cluster rent constant (`lamportsPerByte`) and a fresh `recentBlockhash`/`lastValidBlockHeight`. Confidential amounts are opaque on-chain — policy screens the operation, mint and addresses but cannot evaluate the transferred amount.
2053
+ * Build Token-2022 confidential-transfer transactions
2054
+ */
2055
+ buildWaasConfidentialTransactionRaw(requestParameters: BuildWaasConfidentialTransactionRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<WaasSignConfidentialTransferResponse>>;
2056
+ /**
2057
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`, which co-signs inside caller-visible MPC rooms. The enclave is offline: the caller supplies the token accounts\' raw on-chain state (`accountState`, `destinationAccountState`), the cluster rent constant (`lamportsPerByte`) and a fresh `recentBlockhash`/`lastValidBlockHeight`. Confidential amounts are opaque on-chain — policy screens the operation, mint and addresses but cannot evaluate the transferred amount.
2058
+ * Build Token-2022 confidential-transfer transactions
2059
+ */
2060
+ buildWaasConfidentialTransaction(requestParameters: BuildWaasConfidentialTransactionRequest, initOverrides?: RequestInit): Promise<WaasSignConfidentialTransferResponse>;
2061
+ /**
2062
+ * Options call for this endpoint
2063
+ */
2064
+ buildWaasConfidentialTransactionOptionsRaw(requestParameters: BuildWaasConfidentialTransactionOptionsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<void>>;
2065
+ /**
2066
+ * Options call for this endpoint
2067
+ */
2068
+ buildWaasConfidentialTransactionOptions(requestParameters: BuildWaasConfidentialTransactionOptionsRequest, initOverrides?: RequestInit): Promise<void>;
2033
2069
  /**
2034
2070
  * Deprecated: use POST /sdk/{environmentId}/flow/{flowId}/cancel instead. Cancels a pre-broadcast transaction. Only allowed before the transaction is broadcasted.
2035
2071
  * Cancel a checkout transaction
@@ -5152,6 +5188,24 @@ export declare class SDKApi extends runtime.BaseAPI {
5152
5188
  * Options call for this endpoint
5153
5189
  */
5154
5190
  signMessageOptions(requestParameters: SignMessageOptionsRequest, initOverrides?: RequestInit): Promise<void>;
5191
+ /**
5192
+ * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
5193
+ * Co-sign enclave-built confidential-transfer transactions
5194
+ */
5195
+ signWaasConfidentialTransactionRaw(requestParameters: SignWaasConfidentialTransactionRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<WaasSignConfidentialTransactionsResponse>>;
5196
+ /**
5197
+ * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
5198
+ * Co-sign enclave-built confidential-transfer transactions
5199
+ */
5200
+ signWaasConfidentialTransaction(requestParameters: SignWaasConfidentialTransactionRequest, initOverrides?: RequestInit): Promise<WaasSignConfidentialTransactionsResponse>;
5201
+ /**
5202
+ * Options call for this endpoint
5203
+ */
5204
+ signWaasConfidentialTransactionOptionsRaw(requestParameters: SignWaasConfidentialTransactionOptionsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<void>>;
5205
+ /**
5206
+ * Options call for this endpoint
5207
+ */
5208
+ signWaasConfidentialTransactionOptions(requestParameters: SignWaasConfidentialTransactionOptionsRequest, initOverrides?: RequestInit): Promise<void>;
5155
5209
  /**
5156
5210
  * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
5157
5211
  * Co-sign enclave-built confidential-transfer transactions
@@ -1133,6 +1133,73 @@ class SDKApi extends BaseAPI {
1133
1133
  async broadcastWaasTransactionOptions(requestParameters, initOverrides) {
1134
1134
  await this.broadcastWaasTransactionOptionsRaw(requestParameters, initOverrides);
1135
1135
  }
1136
+ /**
1137
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`, which co-signs inside caller-visible MPC rooms. The enclave is offline: the caller supplies the token accounts\' raw on-chain state (`accountState`, `destinationAccountState`), the cluster rent constant (`lamportsPerByte`) and a fresh `recentBlockhash`/`lastValidBlockHeight`. Confidential amounts are opaque on-chain — policy screens the operation, mint and addresses but cannot evaluate the transferred amount.
1138
+ * Build Token-2022 confidential-transfer transactions
1139
+ */
1140
+ async buildWaasConfidentialTransactionRaw(requestParameters, initOverrides) {
1141
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
1142
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling buildWaasConfidentialTransaction.');
1143
+ }
1144
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
1145
+ throw new RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling buildWaasConfidentialTransaction.');
1146
+ }
1147
+ if (requestParameters.waasSignConfidentialTransferRequest === null || requestParameters.waasSignConfidentialTransferRequest === undefined) {
1148
+ throw new RequiredError('waasSignConfidentialTransferRequest', 'Required parameter requestParameters.waasSignConfidentialTransferRequest was null or undefined when calling buildWaasConfidentialTransaction.');
1149
+ }
1150
+ const queryParameters = {};
1151
+ const headerParameters = {};
1152
+ headerParameters['Content-Type'] = 'application/json';
1153
+ if (this.configuration && this.configuration.accessToken) {
1154
+ const token = this.configuration.accessToken;
1155
+ const tokenString = await token("bearerAuth", []);
1156
+ if (tokenString) {
1157
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
1158
+ }
1159
+ }
1160
+ const response = await this.request({
1161
+ path: `/sdk/{environmentId}/waas/{walletId}/buildConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
1162
+ method: 'POST',
1163
+ headers: headerParameters,
1164
+ query: queryParameters,
1165
+ body: WaasSignConfidentialTransferRequestToJSON(requestParameters.waasSignConfidentialTransferRequest),
1166
+ }, initOverrides);
1167
+ return new JSONApiResponse(response, (jsonValue) => WaasSignConfidentialTransferResponseFromJSON(jsonValue));
1168
+ }
1169
+ /**
1170
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`, which co-signs inside caller-visible MPC rooms. The enclave is offline: the caller supplies the token accounts\' raw on-chain state (`accountState`, `destinationAccountState`), the cluster rent constant (`lamportsPerByte`) and a fresh `recentBlockhash`/`lastValidBlockHeight`. Confidential amounts are opaque on-chain — policy screens the operation, mint and addresses but cannot evaluate the transferred amount.
1171
+ * Build Token-2022 confidential-transfer transactions
1172
+ */
1173
+ async buildWaasConfidentialTransaction(requestParameters, initOverrides) {
1174
+ const response = await this.buildWaasConfidentialTransactionRaw(requestParameters, initOverrides);
1175
+ return await response.value();
1176
+ }
1177
+ /**
1178
+ * Options call for this endpoint
1179
+ */
1180
+ async buildWaasConfidentialTransactionOptionsRaw(requestParameters, initOverrides) {
1181
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
1182
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling buildWaasConfidentialTransactionOptions.');
1183
+ }
1184
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
1185
+ throw new RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling buildWaasConfidentialTransactionOptions.');
1186
+ }
1187
+ const queryParameters = {};
1188
+ const headerParameters = {};
1189
+ const response = await this.request({
1190
+ path: `/sdk/{environmentId}/waas/{walletId}/buildConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
1191
+ method: 'OPTIONS',
1192
+ headers: headerParameters,
1193
+ query: queryParameters,
1194
+ }, initOverrides);
1195
+ return new VoidApiResponse(response);
1196
+ }
1197
+ /**
1198
+ * Options call for this endpoint
1199
+ */
1200
+ async buildWaasConfidentialTransactionOptions(requestParameters, initOverrides) {
1201
+ await this.buildWaasConfidentialTransactionOptionsRaw(requestParameters, initOverrides);
1202
+ }
1136
1203
  /**
1137
1204
  * Deprecated: use POST /sdk/{environmentId}/flow/{flowId}/cancel instead. Cancels a pre-broadcast transaction. Only allowed before the transaction is broadcasted.
1138
1205
  * Cancel a checkout transaction
@@ -11836,6 +11903,73 @@ class SDKApi extends BaseAPI {
11836
11903
  async signMessageOptions(requestParameters, initOverrides) {
11837
11904
  await this.signMessageOptionsRaw(requestParameters, initOverrides);
11838
11905
  }
11906
+ /**
11907
+ * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
11908
+ * Co-sign enclave-built confidential-transfer transactions
11909
+ */
11910
+ async signWaasConfidentialTransactionRaw(requestParameters, initOverrides) {
11911
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
11912
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling signWaasConfidentialTransaction.');
11913
+ }
11914
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
11915
+ throw new RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling signWaasConfidentialTransaction.');
11916
+ }
11917
+ if (requestParameters.waasSignConfidentialTransactionsRequest === null || requestParameters.waasSignConfidentialTransactionsRequest === undefined) {
11918
+ throw new RequiredError('waasSignConfidentialTransactionsRequest', 'Required parameter requestParameters.waasSignConfidentialTransactionsRequest was null or undefined when calling signWaasConfidentialTransaction.');
11919
+ }
11920
+ const queryParameters = {};
11921
+ const headerParameters = {};
11922
+ headerParameters['Content-Type'] = 'application/json';
11923
+ if (this.configuration && this.configuration.accessToken) {
11924
+ const token = this.configuration.accessToken;
11925
+ const tokenString = await token("bearerAuth", []);
11926
+ if (tokenString) {
11927
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
11928
+ }
11929
+ }
11930
+ const response = await this.request({
11931
+ path: `/sdk/{environmentId}/waas/{walletId}/signConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
11932
+ method: 'POST',
11933
+ headers: headerParameters,
11934
+ query: queryParameters,
11935
+ body: WaasSignConfidentialTransactionsRequestToJSON(requestParameters.waasSignConfidentialTransactionsRequest),
11936
+ }, initOverrides);
11937
+ return new JSONApiResponse(response, (jsonValue) => WaasSignConfidentialTransactionsResponseFromJSON(jsonValue));
11938
+ }
11939
+ /**
11940
+ * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
11941
+ * Co-sign enclave-built confidential-transfer transactions
11942
+ */
11943
+ async signWaasConfidentialTransaction(requestParameters, initOverrides) {
11944
+ const response = await this.signWaasConfidentialTransactionRaw(requestParameters, initOverrides);
11945
+ return await response.value();
11946
+ }
11947
+ /**
11948
+ * Options call for this endpoint
11949
+ */
11950
+ async signWaasConfidentialTransactionOptionsRaw(requestParameters, initOverrides) {
11951
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
11952
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling signWaasConfidentialTransactionOptions.');
11953
+ }
11954
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
11955
+ throw new RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling signWaasConfidentialTransactionOptions.');
11956
+ }
11957
+ const queryParameters = {};
11958
+ const headerParameters = {};
11959
+ const response = await this.request({
11960
+ path: `/sdk/{environmentId}/waas/{walletId}/signConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
11961
+ method: 'OPTIONS',
11962
+ headers: headerParameters,
11963
+ query: queryParameters,
11964
+ }, initOverrides);
11965
+ return new VoidApiResponse(response);
11966
+ }
11967
+ /**
11968
+ * Options call for this endpoint
11969
+ */
11970
+ async signWaasConfidentialTransactionOptions(requestParameters, initOverrides) {
11971
+ await this.signWaasConfidentialTransactionOptionsRaw(requestParameters, initOverrides);
11972
+ }
11839
11973
  /**
11840
11974
  * Second half of the confidential-transfer flow. Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag — rejecting tampered, extra or expired transactions — and joins the room to co-sign. MFA step-up is enforced once for the whole operation. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
11841
11975
  * Co-sign enclave-built confidential-transfer transactions
@@ -352,6 +352,43 @@ class ServerApi extends runtime.BaseAPI {
352
352
  const response = await this.backupKeySharesToLocationsServerRaw(requestParameters, initOverrides);
353
353
  return await response.value();
354
354
  }
355
+ /**
356
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`. The caller supplies on-chain account state, the rent constant and a fresh blockhash; the enclave is offline and cannot reach Solana RPC.
357
+ * Server — build Token-2022 confidential-transfer transactions
358
+ */
359
+ async buildWaasConfidentialTransactionServerRaw(requestParameters, initOverrides) {
360
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
361
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling buildWaasConfidentialTransactionServer.');
362
+ }
363
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
364
+ throw new runtime.RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling buildWaasConfidentialTransactionServer.');
365
+ }
366
+ if (requestParameters.waasSignConfidentialTransferRequest === null || requestParameters.waasSignConfidentialTransferRequest === undefined) {
367
+ throw new runtime.RequiredError('waasSignConfidentialTransferRequest', 'Required parameter requestParameters.waasSignConfidentialTransferRequest was null or undefined when calling buildWaasConfidentialTransactionServer.');
368
+ }
369
+ const queryParameters = {};
370
+ const headerParameters = {};
371
+ headerParameters['Content-Type'] = 'application/json';
372
+ if (requestParameters.xDynServerSigningProof !== undefined && requestParameters.xDynServerSigningProof !== null) {
373
+ headerParameters['x-dyn-server-signing-proof'] = String(requestParameters.xDynServerSigningProof);
374
+ }
375
+ const response = await this.request({
376
+ path: `/server/{environmentId}/waas/{walletId}/buildConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
377
+ method: 'POST',
378
+ headers: headerParameters,
379
+ query: queryParameters,
380
+ body: WaasSignConfidentialTransferRequest.WaasSignConfidentialTransferRequestToJSON(requestParameters.waasSignConfidentialTransferRequest),
381
+ }, initOverrides);
382
+ return new runtime.JSONApiResponse(response, (jsonValue) => WaasSignConfidentialTransferResponse.WaasSignConfidentialTransferResponseFromJSON(jsonValue));
383
+ }
384
+ /**
385
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`. The caller supplies on-chain account state, the rent constant and a fresh blockhash; the enclave is offline and cannot reach Solana RPC.
386
+ * Server — build Token-2022 confidential-transfer transactions
387
+ */
388
+ async buildWaasConfidentialTransactionServer(requestParameters, initOverrides) {
389
+ const response = await this.buildWaasConfidentialTransactionServerRaw(requestParameters, initOverrides);
390
+ return await response.value();
391
+ }
355
392
  /**
356
393
  * Cancels a flow that is still initiated, meaning no source has been attached yet. Returns 400 if flowId is not a valid UUID and 409 flow_invalid_transition if the flow is in any other state. Requires an environment API token with the flow.write scope.
357
394
  * Cancel a flow
@@ -1406,6 +1443,43 @@ class ServerApi extends runtime.BaseAPI {
1406
1443
  const response = await this.signMessageServerRaw(requestParameters, initOverrides);
1407
1444
  return await response.value();
1408
1445
  }
1446
+ /**
1447
+ * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
1448
+ * Server — co-sign enclave-built confidential-transfer transactions
1449
+ */
1450
+ async signWaasConfidentialTransactionServerRaw(requestParameters, initOverrides) {
1451
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
1452
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling signWaasConfidentialTransactionServer.');
1453
+ }
1454
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
1455
+ throw new runtime.RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling signWaasConfidentialTransactionServer.');
1456
+ }
1457
+ if (requestParameters.waasSignConfidentialTransactionsRequest === null || requestParameters.waasSignConfidentialTransactionsRequest === undefined) {
1458
+ throw new runtime.RequiredError('waasSignConfidentialTransactionsRequest', 'Required parameter requestParameters.waasSignConfidentialTransactionsRequest was null or undefined when calling signWaasConfidentialTransactionServer.');
1459
+ }
1460
+ const queryParameters = {};
1461
+ const headerParameters = {};
1462
+ headerParameters['Content-Type'] = 'application/json';
1463
+ if (requestParameters.xDynServerSigningProof !== undefined && requestParameters.xDynServerSigningProof !== null) {
1464
+ headerParameters['x-dyn-server-signing-proof'] = String(requestParameters.xDynServerSigningProof);
1465
+ }
1466
+ const response = await this.request({
1467
+ path: `/server/{environmentId}/waas/{walletId}/signConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
1468
+ method: 'POST',
1469
+ headers: headerParameters,
1470
+ query: queryParameters,
1471
+ body: WaasSignConfidentialTransactionsRequest.WaasSignConfidentialTransactionsRequestToJSON(requestParameters.waasSignConfidentialTransactionsRequest),
1472
+ }, initOverrides);
1473
+ return new runtime.JSONApiResponse(response, (jsonValue) => WaasSignConfidentialTransactionsResponse.WaasSignConfidentialTransactionsResponseFromJSON(jsonValue));
1474
+ }
1475
+ /**
1476
+ * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
1477
+ * Server — co-sign enclave-built confidential-transfer transactions
1478
+ */
1479
+ async signWaasConfidentialTransactionServer(requestParameters, initOverrides) {
1480
+ const response = await this.signWaasConfidentialTransactionServerRaw(requestParameters, initOverrides);
1481
+ return await response.value();
1482
+ }
1409
1483
  /**
1410
1484
  * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
1411
1485
  * Server — co-sign enclave-built confidential-transfer transactions
@@ -23,6 +23,12 @@ export interface BackupKeySharesToLocationsServerRequest {
23
23
  backupKeySharesToLocationsRequest: BackupKeySharesToLocationsRequest;
24
24
  xDynServerSigningProof?: string;
25
25
  }
26
+ export interface BuildWaasConfidentialTransactionServerRequest {
27
+ environmentId: string;
28
+ walletId: string;
29
+ waasSignConfidentialTransferRequest: WaasSignConfidentialTransferRequest;
30
+ xDynServerSigningProof?: string;
31
+ }
26
32
  export interface CancelFlowServerRequest {
27
33
  environmentId: string;
28
34
  flowId: string;
@@ -190,6 +196,12 @@ export interface SignMessageServerRequest {
190
196
  signMessageWithWaasRequest: SignMessageWithWaasRequest;
191
197
  xDynServerSigningProof?: string;
192
198
  }
199
+ export interface SignWaasConfidentialTransactionServerRequest {
200
+ environmentId: string;
201
+ walletId: string;
202
+ waasSignConfidentialTransactionsRequest: WaasSignConfidentialTransactionsRequest;
203
+ xDynServerSigningProof?: string;
204
+ }
193
205
  export interface SignWaasConfidentialTransactionsServerRequest {
194
206
  environmentId: string;
195
207
  walletId: string;
@@ -260,6 +272,16 @@ export declare class ServerApi extends runtime.BaseAPI {
260
272
  * Server — create backup action and event for multiple locations without performing actual backup
261
273
  */
262
274
  backupKeySharesToLocationsServer(requestParameters: BackupKeySharesToLocationsServerRequest, initOverrides?: RequestInit): Promise<BackupKeySharesToLocationsResponse>;
275
+ /**
276
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`. The caller supplies on-chain account state, the rent constant and a fresh blockhash; the enclave is offline and cannot reach Solana RPC.
277
+ * Server — build Token-2022 confidential-transfer transactions
278
+ */
279
+ buildWaasConfidentialTransactionServerRaw(requestParameters: BuildWaasConfidentialTransactionServerRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<WaasSignConfidentialTransferResponse>>;
280
+ /**
281
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`. The caller supplies on-chain account state, the rent constant and a fresh blockhash; the enclave is offline and cannot reach Solana RPC.
282
+ * Server — build Token-2022 confidential-transfer transactions
283
+ */
284
+ buildWaasConfidentialTransactionServer(requestParameters: BuildWaasConfidentialTransactionServerRequest, initOverrides?: RequestInit): Promise<WaasSignConfidentialTransferResponse>;
263
285
  /**
264
286
  * Cancels a flow that is still initiated, meaning no source has been attached yet. Returns 400 if flowId is not a valid UUID and 409 flow_invalid_transition if the flow is in any other state. Requires an environment API token with the flow.write scope.
265
287
  * Cancel a flow
@@ -568,6 +590,16 @@ export declare class ServerApi extends runtime.BaseAPI {
568
590
  * Server — sign a message with a WAAS wallet
569
591
  */
570
592
  signMessageServer(requestParameters: SignMessageServerRequest, initOverrides?: RequestInit): Promise<OpenRoomResponse>;
593
+ /**
594
+ * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
595
+ * Server — co-sign enclave-built confidential-transfer transactions
596
+ */
597
+ signWaasConfidentialTransactionServerRaw(requestParameters: SignWaasConfidentialTransactionServerRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<WaasSignConfidentialTransactionsResponse>>;
598
+ /**
599
+ * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
600
+ * Server — co-sign enclave-built confidential-transfer transactions
601
+ */
602
+ signWaasConfidentialTransactionServer(requestParameters: SignWaasConfidentialTransactionServerRequest, initOverrides?: RequestInit): Promise<WaasSignConfidentialTransactionsResponse>;
571
603
  /**
572
604
  * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
573
605
  * Server — co-sign enclave-built confidential-transfer transactions
@@ -348,6 +348,43 @@ class ServerApi extends BaseAPI {
348
348
  const response = await this.backupKeySharesToLocationsServerRaw(requestParameters, initOverrides);
349
349
  return await response.value();
350
350
  }
351
+ /**
352
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`. The caller supplies on-chain account state, the rent constant and a fresh blockhash; the enclave is offline and cannot reach Solana RPC.
353
+ * Server — build Token-2022 confidential-transfer transactions
354
+ */
355
+ async buildWaasConfidentialTransactionServerRaw(requestParameters, initOverrides) {
356
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
357
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling buildWaasConfidentialTransactionServer.');
358
+ }
359
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
360
+ throw new RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling buildWaasConfidentialTransactionServer.');
361
+ }
362
+ if (requestParameters.waasSignConfidentialTransferRequest === null || requestParameters.waasSignConfidentialTransferRequest === undefined) {
363
+ throw new RequiredError('waasSignConfidentialTransferRequest', 'Required parameter requestParameters.waasSignConfidentialTransferRequest was null or undefined when calling buildWaasConfidentialTransactionServer.');
364
+ }
365
+ const queryParameters = {};
366
+ const headerParameters = {};
367
+ headerParameters['Content-Type'] = 'application/json';
368
+ if (requestParameters.xDynServerSigningProof !== undefined && requestParameters.xDynServerSigningProof !== null) {
369
+ headerParameters['x-dyn-server-signing-proof'] = String(requestParameters.xDynServerSigningProof);
370
+ }
371
+ const response = await this.request({
372
+ path: `/server/{environmentId}/waas/{walletId}/buildConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
373
+ method: 'POST',
374
+ headers: headerParameters,
375
+ query: queryParameters,
376
+ body: WaasSignConfidentialTransferRequestToJSON(requestParameters.waasSignConfidentialTransferRequest),
377
+ }, initOverrides);
378
+ return new JSONApiResponse(response, (jsonValue) => WaasSignConfidentialTransferResponseFromJSON(jsonValue));
379
+ }
380
+ /**
381
+ * Decrypts the wallet\'s stored confidential seed inside the enclave, generates the zero-knowledge proofs the requested operation requires, builds the Token-2022 confidential-transfer instructions and returns the transactions unsigned (the wallet\'s signature slot is zeroed) in broadcast order, plus a `transactionsTag` binding them. Signing is a separate step: submit the transactions and tag unchanged to `POST /waas/{walletId}/signConfidentialTransactions`. The caller supplies on-chain account state, the rent constant and a fresh blockhash; the enclave is offline and cannot reach Solana RPC.
382
+ * Server — build Token-2022 confidential-transfer transactions
383
+ */
384
+ async buildWaasConfidentialTransactionServer(requestParameters, initOverrides) {
385
+ const response = await this.buildWaasConfidentialTransactionServerRaw(requestParameters, initOverrides);
386
+ return await response.value();
387
+ }
351
388
  /**
352
389
  * Cancels a flow that is still initiated, meaning no source has been attached yet. Returns 400 if flowId is not a valid UUID and 409 flow_invalid_transition if the flow is in any other state. Requires an environment API token with the flow.write scope.
353
390
  * Cancel a flow
@@ -1402,6 +1439,43 @@ class ServerApi extends BaseAPI {
1402
1439
  const response = await this.signMessageServerRaw(requestParameters, initOverrides);
1403
1440
  return await response.value();
1404
1441
  }
1442
+ /**
1443
+ * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
1444
+ * Server — co-sign enclave-built confidential-transfer transactions
1445
+ */
1446
+ async signWaasConfidentialTransactionServerRaw(requestParameters, initOverrides) {
1447
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
1448
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling signWaasConfidentialTransactionServer.');
1449
+ }
1450
+ if (requestParameters.walletId === null || requestParameters.walletId === undefined) {
1451
+ throw new RequiredError('walletId', 'Required parameter requestParameters.walletId was null or undefined when calling signWaasConfidentialTransactionServer.');
1452
+ }
1453
+ if (requestParameters.waasSignConfidentialTransactionsRequest === null || requestParameters.waasSignConfidentialTransactionsRequest === undefined) {
1454
+ throw new RequiredError('waasSignConfidentialTransactionsRequest', 'Required parameter requestParameters.waasSignConfidentialTransactionsRequest was null or undefined when calling signWaasConfidentialTransactionServer.');
1455
+ }
1456
+ const queryParameters = {};
1457
+ const headerParameters = {};
1458
+ headerParameters['Content-Type'] = 'application/json';
1459
+ if (requestParameters.xDynServerSigningProof !== undefined && requestParameters.xDynServerSigningProof !== null) {
1460
+ headerParameters['x-dyn-server-signing-proof'] = String(requestParameters.xDynServerSigningProof);
1461
+ }
1462
+ const response = await this.request({
1463
+ path: `/server/{environmentId}/waas/{walletId}/signConfidentialTransaction`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"walletId"}}`, encodeURIComponent(String(requestParameters.walletId))),
1464
+ method: 'POST',
1465
+ headers: headerParameters,
1466
+ query: queryParameters,
1467
+ body: WaasSignConfidentialTransactionsRequestToJSON(requestParameters.waasSignConfidentialTransactionsRequest),
1468
+ }, initOverrides);
1469
+ return new JSONApiResponse(response, (jsonValue) => WaasSignConfidentialTransactionsResponseFromJSON(jsonValue));
1470
+ }
1471
+ /**
1472
+ * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
1473
+ * Server — co-sign enclave-built confidential-transfer transactions
1474
+ */
1475
+ async signWaasConfidentialTransactionServer(requestParameters, initOverrides) {
1476
+ const response = await this.signWaasConfidentialTransactionServerRaw(requestParameters, initOverrides);
1477
+ return await response.value();
1478
+ }
1405
1479
  /**
1406
1480
  * Provisions one MPC signing room for the operation (Solana v1 packs it into a single transaction) and hands the enclave-built transaction and its `transactionsTag` to the enclave\'s `SignConfidentialTransactions` action, which verifies the tag and joins the room to co-sign. The response returns immediately with the room id; join it with the wallet\'s client share to complete the threshold signature.
1407
1481
  * Server — co-sign enclave-built confidential-transfer transactions