@dynamic-labs/sdk-api 0.152.0 → 0.154.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 +1 -1
- package/src/apis/SDKApi.cjs +196 -0
- package/src/apis/SDKApi.d.ts +82 -1
- package/src/apis/SDKApi.js +196 -0
- package/src/apis/ServerApi.cjs +74 -0
- package/src/apis/ServerApi.d.ts +32 -0
- package/src/apis/ServerApi.js +74 -0
- package/src/index.cjs +20 -0
- package/src/index.js +5 -0
- package/src/models/FlowSourceTokenOption.cjs +39 -0
- package/src/models/FlowSourceTokenOption.d.ts +42 -0
- package/src/models/FlowSourceTokenOption.js +33 -0
- package/src/models/FlowSourceTokenOptionChain.cjs +36 -0
- package/src/models/FlowSourceTokenOptionChain.d.ts +34 -0
- package/src/models/FlowSourceTokenOptionChain.js +30 -0
- package/src/models/FlowSourceTokenOptionNetwork.cjs +37 -0
- package/src/models/FlowSourceTokenOptionNetwork.d.ts +39 -0
- package/src/models/FlowSourceTokenOptionNetwork.js +31 -0
- package/src/models/FlowSourceTokenOptionToken.cjs +39 -0
- package/src/models/FlowSourceTokenOptionToken.d.ts +45 -0
- package/src/models/FlowSourceTokenOptionToken.js +33 -0
- package/src/models/FlowSourceTokenOptionsResponse.cjs +33 -0
- package/src/models/FlowSourceTokenOptionsResponse.d.ts +28 -0
- package/src/models/FlowSourceTokenOptionsResponse.js +27 -0
- package/src/models/index.d.ts +5 -0
package/src/apis/ServerApi.cjs
CHANGED
|
@@ -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
|
package/src/apis/ServerApi.d.ts
CHANGED
|
@@ -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
|
package/src/apis/ServerApi.js
CHANGED
|
@@ -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
|
package/src/index.cjs
CHANGED
|
@@ -430,6 +430,11 @@ var FlowRiskStateEnum = require('./models/FlowRiskStateEnum.cjs');
|
|
|
430
430
|
var FlowSettlementData = require('./models/FlowSettlementData.cjs');
|
|
431
431
|
var FlowSettlementStateEnum = require('./models/FlowSettlementStateEnum.cjs');
|
|
432
432
|
var FlowSourceResponse = require('./models/FlowSourceResponse.cjs');
|
|
433
|
+
var FlowSourceTokenOption = require('./models/FlowSourceTokenOption.cjs');
|
|
434
|
+
var FlowSourceTokenOptionChain = require('./models/FlowSourceTokenOptionChain.cjs');
|
|
435
|
+
var FlowSourceTokenOptionNetwork = require('./models/FlowSourceTokenOptionNetwork.cjs');
|
|
436
|
+
var FlowSourceTokenOptionToken = require('./models/FlowSourceTokenOptionToken.cjs');
|
|
437
|
+
var FlowSourceTokenOptionsResponse = require('./models/FlowSourceTokenOptionsResponse.cjs');
|
|
433
438
|
var FlowSourceTypeEnum = require('./models/FlowSourceTypeEnum.cjs');
|
|
434
439
|
var FlowTokenInfo = require('./models/FlowTokenInfo.cjs');
|
|
435
440
|
var FlowUIConfig = require('./models/FlowUIConfig.cjs');
|
|
@@ -2687,6 +2692,21 @@ exports.FlowSettlementStateEnumToJSON = FlowSettlementStateEnum.FlowSettlementSt
|
|
|
2687
2692
|
exports.FlowSourceResponseFromJSON = FlowSourceResponse.FlowSourceResponseFromJSON;
|
|
2688
2693
|
exports.FlowSourceResponseFromJSONTyped = FlowSourceResponse.FlowSourceResponseFromJSONTyped;
|
|
2689
2694
|
exports.FlowSourceResponseToJSON = FlowSourceResponse.FlowSourceResponseToJSON;
|
|
2695
|
+
exports.FlowSourceTokenOptionFromJSON = FlowSourceTokenOption.FlowSourceTokenOptionFromJSON;
|
|
2696
|
+
exports.FlowSourceTokenOptionFromJSONTyped = FlowSourceTokenOption.FlowSourceTokenOptionFromJSONTyped;
|
|
2697
|
+
exports.FlowSourceTokenOptionToJSON = FlowSourceTokenOption.FlowSourceTokenOptionToJSON;
|
|
2698
|
+
exports.FlowSourceTokenOptionChainFromJSON = FlowSourceTokenOptionChain.FlowSourceTokenOptionChainFromJSON;
|
|
2699
|
+
exports.FlowSourceTokenOptionChainFromJSONTyped = FlowSourceTokenOptionChain.FlowSourceTokenOptionChainFromJSONTyped;
|
|
2700
|
+
exports.FlowSourceTokenOptionChainToJSON = FlowSourceTokenOptionChain.FlowSourceTokenOptionChainToJSON;
|
|
2701
|
+
exports.FlowSourceTokenOptionNetworkFromJSON = FlowSourceTokenOptionNetwork.FlowSourceTokenOptionNetworkFromJSON;
|
|
2702
|
+
exports.FlowSourceTokenOptionNetworkFromJSONTyped = FlowSourceTokenOptionNetwork.FlowSourceTokenOptionNetworkFromJSONTyped;
|
|
2703
|
+
exports.FlowSourceTokenOptionNetworkToJSON = FlowSourceTokenOptionNetwork.FlowSourceTokenOptionNetworkToJSON;
|
|
2704
|
+
exports.FlowSourceTokenOptionTokenFromJSON = FlowSourceTokenOptionToken.FlowSourceTokenOptionTokenFromJSON;
|
|
2705
|
+
exports.FlowSourceTokenOptionTokenFromJSONTyped = FlowSourceTokenOptionToken.FlowSourceTokenOptionTokenFromJSONTyped;
|
|
2706
|
+
exports.FlowSourceTokenOptionTokenToJSON = FlowSourceTokenOptionToken.FlowSourceTokenOptionTokenToJSON;
|
|
2707
|
+
exports.FlowSourceTokenOptionsResponseFromJSON = FlowSourceTokenOptionsResponse.FlowSourceTokenOptionsResponseFromJSON;
|
|
2708
|
+
exports.FlowSourceTokenOptionsResponseFromJSONTyped = FlowSourceTokenOptionsResponse.FlowSourceTokenOptionsResponseFromJSONTyped;
|
|
2709
|
+
exports.FlowSourceTokenOptionsResponseToJSON = FlowSourceTokenOptionsResponse.FlowSourceTokenOptionsResponseToJSON;
|
|
2690
2710
|
Object.defineProperty(exports, 'FlowSourceTypeEnum', {
|
|
2691
2711
|
enumerable: true,
|
|
2692
2712
|
get: function () { return FlowSourceTypeEnum.FlowSourceTypeEnum; }
|
package/src/index.js
CHANGED
|
@@ -426,6 +426,11 @@ export { FlowRiskStateEnum, FlowRiskStateEnumFromJSON, FlowRiskStateEnumFromJSON
|
|
|
426
426
|
export { FlowSettlementDataFromJSON, FlowSettlementDataFromJSONTyped, FlowSettlementDataToJSON } from './models/FlowSettlementData.js';
|
|
427
427
|
export { FlowSettlementStateEnum, FlowSettlementStateEnumFromJSON, FlowSettlementStateEnumFromJSONTyped, FlowSettlementStateEnumToJSON } from './models/FlowSettlementStateEnum.js';
|
|
428
428
|
export { FlowSourceResponseFromJSON, FlowSourceResponseFromJSONTyped, FlowSourceResponseToJSON } from './models/FlowSourceResponse.js';
|
|
429
|
+
export { FlowSourceTokenOptionFromJSON, FlowSourceTokenOptionFromJSONTyped, FlowSourceTokenOptionToJSON } from './models/FlowSourceTokenOption.js';
|
|
430
|
+
export { FlowSourceTokenOptionChainFromJSON, FlowSourceTokenOptionChainFromJSONTyped, FlowSourceTokenOptionChainToJSON } from './models/FlowSourceTokenOptionChain.js';
|
|
431
|
+
export { FlowSourceTokenOptionNetworkFromJSON, FlowSourceTokenOptionNetworkFromJSONTyped, FlowSourceTokenOptionNetworkToJSON } from './models/FlowSourceTokenOptionNetwork.js';
|
|
432
|
+
export { FlowSourceTokenOptionTokenFromJSON, FlowSourceTokenOptionTokenFromJSONTyped, FlowSourceTokenOptionTokenToJSON } from './models/FlowSourceTokenOptionToken.js';
|
|
433
|
+
export { FlowSourceTokenOptionsResponseFromJSON, FlowSourceTokenOptionsResponseFromJSONTyped, FlowSourceTokenOptionsResponseToJSON } from './models/FlowSourceTokenOptionsResponse.js';
|
|
429
434
|
export { FlowSourceTypeEnum, FlowSourceTypeEnumFromJSON, FlowSourceTypeEnumFromJSONTyped, FlowSourceTypeEnumToJSON } from './models/FlowSourceTypeEnum.js';
|
|
430
435
|
export { FlowTokenInfoFromJSON, FlowTokenInfoFromJSONTyped, FlowTokenInfoToJSON } from './models/FlowTokenInfo.js';
|
|
431
436
|
export { FlowUIConfigFromJSON, FlowUIConfigFromJSONTyped, FlowUIConfigToJSON } from './models/FlowUIConfig.js';
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var FlowSourceTokenOptionChain = require('./FlowSourceTokenOptionChain.cjs');
|
|
6
|
+
var FlowSourceTokenOptionNetwork = require('./FlowSourceTokenOptionNetwork.cjs');
|
|
7
|
+
var FlowSourceTokenOptionToken = require('./FlowSourceTokenOptionToken.cjs');
|
|
8
|
+
|
|
9
|
+
/* tslint:disable */
|
|
10
|
+
function FlowSourceTokenOptionFromJSON(json) {
|
|
11
|
+
return FlowSourceTokenOptionFromJSONTyped(json);
|
|
12
|
+
}
|
|
13
|
+
function FlowSourceTokenOptionFromJSONTyped(json, ignoreDiscriminator) {
|
|
14
|
+
if ((json === undefined) || (json === null)) {
|
|
15
|
+
return json;
|
|
16
|
+
}
|
|
17
|
+
return {
|
|
18
|
+
'chain': FlowSourceTokenOptionChain.FlowSourceTokenOptionChainFromJSON(json['chain']),
|
|
19
|
+
'network': FlowSourceTokenOptionNetwork.FlowSourceTokenOptionNetworkFromJSON(json['network']),
|
|
20
|
+
'tokens': (json['tokens'].map(FlowSourceTokenOptionToken.FlowSourceTokenOptionTokenFromJSON)),
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
function FlowSourceTokenOptionToJSON(value) {
|
|
24
|
+
if (value === undefined) {
|
|
25
|
+
return undefined;
|
|
26
|
+
}
|
|
27
|
+
if (value === null) {
|
|
28
|
+
return null;
|
|
29
|
+
}
|
|
30
|
+
return {
|
|
31
|
+
'chain': FlowSourceTokenOptionChain.FlowSourceTokenOptionChainToJSON(value.chain),
|
|
32
|
+
'network': FlowSourceTokenOptionNetwork.FlowSourceTokenOptionNetworkToJSON(value.network),
|
|
33
|
+
'tokens': (value.tokens.map(FlowSourceTokenOptionToken.FlowSourceTokenOptionTokenToJSON)),
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
exports.FlowSourceTokenOptionFromJSON = FlowSourceTokenOptionFromJSON;
|
|
38
|
+
exports.FlowSourceTokenOptionFromJSONTyped = FlowSourceTokenOptionFromJSONTyped;
|
|
39
|
+
exports.FlowSourceTokenOptionToJSON = FlowSourceTokenOptionToJSON;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Dashboard API
|
|
3
|
+
* Dashboard API documentation
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import { FlowSourceTokenOptionChain } from './FlowSourceTokenOptionChain';
|
|
13
|
+
import { FlowSourceTokenOptionNetwork } from './FlowSourceTokenOptionNetwork';
|
|
14
|
+
import { FlowSourceTokenOptionToken } from './FlowSourceTokenOptionToken';
|
|
15
|
+
/**
|
|
16
|
+
* A network a payer can fund a flow from with a deposit address, and the tokens accepted on it.
|
|
17
|
+
* @export
|
|
18
|
+
* @interface FlowSourceTokenOption
|
|
19
|
+
*/
|
|
20
|
+
export interface FlowSourceTokenOption {
|
|
21
|
+
/**
|
|
22
|
+
*
|
|
23
|
+
* @type {FlowSourceTokenOptionChain}
|
|
24
|
+
* @memberof FlowSourceTokenOption
|
|
25
|
+
*/
|
|
26
|
+
chain: FlowSourceTokenOptionChain;
|
|
27
|
+
/**
|
|
28
|
+
*
|
|
29
|
+
* @type {FlowSourceTokenOptionNetwork}
|
|
30
|
+
* @memberof FlowSourceTokenOption
|
|
31
|
+
*/
|
|
32
|
+
network: FlowSourceTokenOptionNetwork;
|
|
33
|
+
/**
|
|
34
|
+
* The tokens the payer can send on this network.
|
|
35
|
+
* @type {Array<FlowSourceTokenOptionToken>}
|
|
36
|
+
* @memberof FlowSourceTokenOption
|
|
37
|
+
*/
|
|
38
|
+
tokens: Array<FlowSourceTokenOptionToken>;
|
|
39
|
+
}
|
|
40
|
+
export declare function FlowSourceTokenOptionFromJSON(json: any): FlowSourceTokenOption;
|
|
41
|
+
export declare function FlowSourceTokenOptionFromJSONTyped(json: any, ignoreDiscriminator: boolean): FlowSourceTokenOption;
|
|
42
|
+
export declare function FlowSourceTokenOptionToJSON(value?: FlowSourceTokenOption | null): any;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { FlowSourceTokenOptionChainFromJSON, FlowSourceTokenOptionChainToJSON } from './FlowSourceTokenOptionChain.js';
|
|
2
|
+
import { FlowSourceTokenOptionNetworkFromJSON, FlowSourceTokenOptionNetworkToJSON } from './FlowSourceTokenOptionNetwork.js';
|
|
3
|
+
import { FlowSourceTokenOptionTokenFromJSON, FlowSourceTokenOptionTokenToJSON } from './FlowSourceTokenOptionToken.js';
|
|
4
|
+
|
|
5
|
+
/* tslint:disable */
|
|
6
|
+
function FlowSourceTokenOptionFromJSON(json) {
|
|
7
|
+
return FlowSourceTokenOptionFromJSONTyped(json);
|
|
8
|
+
}
|
|
9
|
+
function FlowSourceTokenOptionFromJSONTyped(json, ignoreDiscriminator) {
|
|
10
|
+
if ((json === undefined) || (json === null)) {
|
|
11
|
+
return json;
|
|
12
|
+
}
|
|
13
|
+
return {
|
|
14
|
+
'chain': FlowSourceTokenOptionChainFromJSON(json['chain']),
|
|
15
|
+
'network': FlowSourceTokenOptionNetworkFromJSON(json['network']),
|
|
16
|
+
'tokens': (json['tokens'].map(FlowSourceTokenOptionTokenFromJSON)),
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
function FlowSourceTokenOptionToJSON(value) {
|
|
20
|
+
if (value === undefined) {
|
|
21
|
+
return undefined;
|
|
22
|
+
}
|
|
23
|
+
if (value === null) {
|
|
24
|
+
return null;
|
|
25
|
+
}
|
|
26
|
+
return {
|
|
27
|
+
'chain': FlowSourceTokenOptionChainToJSON(value.chain),
|
|
28
|
+
'network': FlowSourceTokenOptionNetworkToJSON(value.network),
|
|
29
|
+
'tokens': (value.tokens.map(FlowSourceTokenOptionTokenToJSON)),
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export { FlowSourceTokenOptionFromJSON, FlowSourceTokenOptionFromJSONTyped, FlowSourceTokenOptionToJSON };
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var runtime = require('../runtime.cjs');
|
|
6
|
+
var ChainEnum = require('./ChainEnum.cjs');
|
|
7
|
+
|
|
8
|
+
/* tslint:disable */
|
|
9
|
+
function FlowSourceTokenOptionChainFromJSON(json) {
|
|
10
|
+
return FlowSourceTokenOptionChainFromJSONTyped(json);
|
|
11
|
+
}
|
|
12
|
+
function FlowSourceTokenOptionChainFromJSONTyped(json, ignoreDiscriminator) {
|
|
13
|
+
if ((json === undefined) || (json === null)) {
|
|
14
|
+
return json;
|
|
15
|
+
}
|
|
16
|
+
return {
|
|
17
|
+
'name': ChainEnum.ChainEnumFromJSON(json['name']),
|
|
18
|
+
'iconUrl': !runtime.exists(json, 'iconUrl') ? undefined : json['iconUrl'],
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
function FlowSourceTokenOptionChainToJSON(value) {
|
|
22
|
+
if (value === undefined) {
|
|
23
|
+
return undefined;
|
|
24
|
+
}
|
|
25
|
+
if (value === null) {
|
|
26
|
+
return null;
|
|
27
|
+
}
|
|
28
|
+
return {
|
|
29
|
+
'name': ChainEnum.ChainEnumToJSON(value.name),
|
|
30
|
+
'iconUrl': value.iconUrl,
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
exports.FlowSourceTokenOptionChainFromJSON = FlowSourceTokenOptionChainFromJSON;
|
|
35
|
+
exports.FlowSourceTokenOptionChainFromJSONTyped = FlowSourceTokenOptionChainFromJSONTyped;
|
|
36
|
+
exports.FlowSourceTokenOptionChainToJSON = FlowSourceTokenOptionChainToJSON;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Dashboard API
|
|
3
|
+
* Dashboard API documentation
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import { ChainEnum } from './ChainEnum';
|
|
13
|
+
/**
|
|
14
|
+
* The chain family the payer sends from.
|
|
15
|
+
* @export
|
|
16
|
+
* @interface FlowSourceTokenOptionChain
|
|
17
|
+
*/
|
|
18
|
+
export interface FlowSourceTokenOptionChain {
|
|
19
|
+
/**
|
|
20
|
+
*
|
|
21
|
+
* @type {ChainEnum}
|
|
22
|
+
* @memberof FlowSourceTokenOptionChain
|
|
23
|
+
*/
|
|
24
|
+
name: ChainEnum;
|
|
25
|
+
/**
|
|
26
|
+
* Absolute HTTPS URL of the chain family's logo.
|
|
27
|
+
* @type {string}
|
|
28
|
+
* @memberof FlowSourceTokenOptionChain
|
|
29
|
+
*/
|
|
30
|
+
iconUrl?: string;
|
|
31
|
+
}
|
|
32
|
+
export declare function FlowSourceTokenOptionChainFromJSON(json: any): FlowSourceTokenOptionChain;
|
|
33
|
+
export declare function FlowSourceTokenOptionChainFromJSONTyped(json: any, ignoreDiscriminator: boolean): FlowSourceTokenOptionChain;
|
|
34
|
+
export declare function FlowSourceTokenOptionChainToJSON(value?: FlowSourceTokenOptionChain | null): any;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { exists } from '../runtime.js';
|
|
2
|
+
import { ChainEnumFromJSON, ChainEnumToJSON } from './ChainEnum.js';
|
|
3
|
+
|
|
4
|
+
/* tslint:disable */
|
|
5
|
+
function FlowSourceTokenOptionChainFromJSON(json) {
|
|
6
|
+
return FlowSourceTokenOptionChainFromJSONTyped(json);
|
|
7
|
+
}
|
|
8
|
+
function FlowSourceTokenOptionChainFromJSONTyped(json, ignoreDiscriminator) {
|
|
9
|
+
if ((json === undefined) || (json === null)) {
|
|
10
|
+
return json;
|
|
11
|
+
}
|
|
12
|
+
return {
|
|
13
|
+
'name': ChainEnumFromJSON(json['name']),
|
|
14
|
+
'iconUrl': !exists(json, 'iconUrl') ? undefined : json['iconUrl'],
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
function FlowSourceTokenOptionChainToJSON(value) {
|
|
18
|
+
if (value === undefined) {
|
|
19
|
+
return undefined;
|
|
20
|
+
}
|
|
21
|
+
if (value === null) {
|
|
22
|
+
return null;
|
|
23
|
+
}
|
|
24
|
+
return {
|
|
25
|
+
'name': ChainEnumToJSON(value.name),
|
|
26
|
+
'iconUrl': value.iconUrl,
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export { FlowSourceTokenOptionChainFromJSON, FlowSourceTokenOptionChainFromJSONTyped, FlowSourceTokenOptionChainToJSON };
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var runtime = require('../runtime.cjs');
|
|
6
|
+
|
|
7
|
+
/* tslint:disable */
|
|
8
|
+
function FlowSourceTokenOptionNetworkFromJSON(json) {
|
|
9
|
+
return FlowSourceTokenOptionNetworkFromJSONTyped(json);
|
|
10
|
+
}
|
|
11
|
+
function FlowSourceTokenOptionNetworkFromJSONTyped(json, ignoreDiscriminator) {
|
|
12
|
+
if ((json === undefined) || (json === null)) {
|
|
13
|
+
return json;
|
|
14
|
+
}
|
|
15
|
+
return {
|
|
16
|
+
'id': json['id'],
|
|
17
|
+
'name': json['name'],
|
|
18
|
+
'iconUrl': !runtime.exists(json, 'iconUrl') ? undefined : json['iconUrl'],
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
function FlowSourceTokenOptionNetworkToJSON(value) {
|
|
22
|
+
if (value === undefined) {
|
|
23
|
+
return undefined;
|
|
24
|
+
}
|
|
25
|
+
if (value === null) {
|
|
26
|
+
return null;
|
|
27
|
+
}
|
|
28
|
+
return {
|
|
29
|
+
'id': value.id,
|
|
30
|
+
'name': value.name,
|
|
31
|
+
'iconUrl': value.iconUrl,
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
exports.FlowSourceTokenOptionNetworkFromJSON = FlowSourceTokenOptionNetworkFromJSON;
|
|
36
|
+
exports.FlowSourceTokenOptionNetworkFromJSONTyped = FlowSourceTokenOptionNetworkFromJSONTyped;
|
|
37
|
+
exports.FlowSourceTokenOptionNetworkToJSON = FlowSourceTokenOptionNetworkToJSON;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Dashboard API
|
|
3
|
+
* Dashboard API documentation
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* The network within the chain family the funds are sent on.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface FlowSourceTokenOptionNetwork
|
|
16
|
+
*/
|
|
17
|
+
export interface FlowSourceTokenOptionNetwork {
|
|
18
|
+
/**
|
|
19
|
+
* The network's id within its chain family, e.g. "8453" for Base.
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof FlowSourceTokenOptionNetwork
|
|
22
|
+
*/
|
|
23
|
+
id: string;
|
|
24
|
+
/**
|
|
25
|
+
* The network's display name, e.g. "Base".
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof FlowSourceTokenOptionNetwork
|
|
28
|
+
*/
|
|
29
|
+
name: string;
|
|
30
|
+
/**
|
|
31
|
+
* Absolute HTTPS URL of the network's logo.
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof FlowSourceTokenOptionNetwork
|
|
34
|
+
*/
|
|
35
|
+
iconUrl?: string;
|
|
36
|
+
}
|
|
37
|
+
export declare function FlowSourceTokenOptionNetworkFromJSON(json: any): FlowSourceTokenOptionNetwork;
|
|
38
|
+
export declare function FlowSourceTokenOptionNetworkFromJSONTyped(json: any, ignoreDiscriminator: boolean): FlowSourceTokenOptionNetwork;
|
|
39
|
+
export declare function FlowSourceTokenOptionNetworkToJSON(value?: FlowSourceTokenOptionNetwork | null): any;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { exists } from '../runtime.js';
|
|
2
|
+
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
function FlowSourceTokenOptionNetworkFromJSON(json) {
|
|
5
|
+
return FlowSourceTokenOptionNetworkFromJSONTyped(json);
|
|
6
|
+
}
|
|
7
|
+
function FlowSourceTokenOptionNetworkFromJSONTyped(json, ignoreDiscriminator) {
|
|
8
|
+
if ((json === undefined) || (json === null)) {
|
|
9
|
+
return json;
|
|
10
|
+
}
|
|
11
|
+
return {
|
|
12
|
+
'id': json['id'],
|
|
13
|
+
'name': json['name'],
|
|
14
|
+
'iconUrl': !exists(json, 'iconUrl') ? undefined : json['iconUrl'],
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
function FlowSourceTokenOptionNetworkToJSON(value) {
|
|
18
|
+
if (value === undefined) {
|
|
19
|
+
return undefined;
|
|
20
|
+
}
|
|
21
|
+
if (value === null) {
|
|
22
|
+
return null;
|
|
23
|
+
}
|
|
24
|
+
return {
|
|
25
|
+
'id': value.id,
|
|
26
|
+
'name': value.name,
|
|
27
|
+
'iconUrl': value.iconUrl,
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export { FlowSourceTokenOptionNetworkFromJSON, FlowSourceTokenOptionNetworkFromJSONTyped, FlowSourceTokenOptionNetworkToJSON };
|