@dynamic-labs/sdk-api-core 0.0.869 → 0.0.870

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/sdk-api-core",
3
- "version": "0.0.869",
3
+ "version": "0.0.870",
4
4
  "author": "Dynamic Labs",
5
5
  "license": "Apache-2.0",
6
6
  "publishConfig": {
@@ -106,6 +106,7 @@ var InitEmailAuthRequest = require('../models/InitEmailAuthRequest.cjs');
106
106
  var InitEmailAuthResponse = require('../models/InitEmailAuthResponse.cjs');
107
107
  var InitPasskeyRecoveryRequest = require('../models/InitPasskeyRecoveryRequest.cjs');
108
108
  var InitPasskeyRecoveryResponse = require('../models/InitPasskeyRecoveryResponse.cjs');
109
+ var InlineObject = require('../models/InlineObject.cjs');
109
110
  var JwksResponse = require('../models/JwksResponse.cjs');
110
111
  require('../models/MFAAction.cjs');
111
112
  require('../models/PublicKeyCredentialType.cjs');
@@ -184,6 +185,7 @@ var SupportedOfframpsResponse = require('../models/SupportedOfframpsResponse.cjs
184
185
  var SupportedOnrampsResponse = require('../models/SupportedOnrampsResponse.cjs');
185
186
  var TelegramPostRequest = require('../models/TelegramPostRequest.cjs');
186
187
  require('../models/TokenScope.cjs');
188
+ var TransactionFeeEstimateResponse = require('../models/TransactionFeeEstimateResponse.cjs');
187
189
  var TransferDestinationResponse = require('../models/TransferDestinationResponse.cjs');
188
190
  var TurnkeyCreateWalletAccountsRequestBody = require('../models/TurnkeyCreateWalletAccountsRequestBody.cjs');
189
191
  var TurnkeyDeleteEmbeddedWalletsRequestBody = require('../models/TurnkeyDeleteEmbeddedWalletsRequestBody.cjs');
@@ -2293,6 +2295,87 @@ class SDKApi extends runtime.BaseAPI {
2293
2295
  yield this.embeddedWalletExportOptionsRaw(requestParameters, initOverrides);
2294
2296
  });
2295
2297
  }
2298
+ /**
2299
+ * Estimates the gas fees for a given raw transaction.
2300
+ * Estimate transaction fees
2301
+ */
2302
+ estimateTransactionFeeRaw(requestParameters, initOverrides) {
2303
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
2304
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
2305
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling estimateTransactionFee.');
2306
+ }
2307
+ if (requestParameters.chainName === null || requestParameters.chainName === undefined) {
2308
+ throw new runtime.RequiredError('chainName', 'Required parameter requestParameters.chainName was null or undefined when calling estimateTransactionFee.');
2309
+ }
2310
+ if (requestParameters.inlineObject === null || requestParameters.inlineObject === undefined) {
2311
+ throw new runtime.RequiredError('inlineObject', 'Required parameter requestParameters.inlineObject was null or undefined when calling estimateTransactionFee.');
2312
+ }
2313
+ const queryParameters = {};
2314
+ const headerParameters = {};
2315
+ headerParameters['Content-Type'] = 'application/json';
2316
+ if (this.configuration && this.configuration.accessToken) {
2317
+ const token = this.configuration.accessToken;
2318
+ const tokenString = yield token("bearerAuth", []);
2319
+ if (tokenString) {
2320
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
2321
+ }
2322
+ }
2323
+ const response = yield this.request({
2324
+ path: `/sdk/{environmentId}/chains/{chainName}/transactions/estimate`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"chainName"}}`, encodeURIComponent(String(requestParameters.chainName))),
2325
+ method: 'POST',
2326
+ headers: headerParameters,
2327
+ query: queryParameters,
2328
+ body: InlineObject.InlineObjectToJSON(requestParameters.inlineObject),
2329
+ }, initOverrides);
2330
+ return new runtime.JSONApiResponse(response, (jsonValue) => TransactionFeeEstimateResponse.TransactionFeeEstimateResponseFromJSON(jsonValue));
2331
+ });
2332
+ }
2333
+ /**
2334
+ * Estimates the gas fees for a given raw transaction.
2335
+ * Estimate transaction fees
2336
+ */
2337
+ estimateTransactionFee(requestParameters, initOverrides) {
2338
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
2339
+ const response = yield this.estimateTransactionFeeRaw(requestParameters, initOverrides);
2340
+ return yield response.value();
2341
+ });
2342
+ }
2343
+ /**
2344
+ * Options call for this endpoint
2345
+ */
2346
+ estimateTransactionFeeOptionsRaw(requestParameters, initOverrides) {
2347
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
2348
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
2349
+ throw new runtime.RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling estimateTransactionFeeOptions.');
2350
+ }
2351
+ if (requestParameters.chainName === null || requestParameters.chainName === undefined) {
2352
+ throw new runtime.RequiredError('chainName', 'Required parameter requestParameters.chainName was null or undefined when calling estimateTransactionFeeOptions.');
2353
+ }
2354
+ if (requestParameters.networkId === null || requestParameters.networkId === undefined) {
2355
+ throw new runtime.RequiredError('networkId', 'Required parameter requestParameters.networkId was null or undefined when calling estimateTransactionFeeOptions.');
2356
+ }
2357
+ const queryParameters = {};
2358
+ if (requestParameters.networkId !== undefined) {
2359
+ queryParameters['networkId'] = requestParameters.networkId;
2360
+ }
2361
+ const headerParameters = {};
2362
+ const response = yield this.request({
2363
+ path: `/sdk/{environmentId}/chains/{chainName}/transactions/estimate`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"chainName"}}`, encodeURIComponent(String(requestParameters.chainName))),
2364
+ method: 'OPTIONS',
2365
+ headers: headerParameters,
2366
+ query: queryParameters,
2367
+ }, initOverrides);
2368
+ return new runtime.VoidApiResponse(response);
2369
+ });
2370
+ }
2371
+ /**
2372
+ * Options call for this endpoint
2373
+ */
2374
+ estimateTransactionFeeOptions(requestParameters, initOverrides) {
2375
+ return _tslib.__awaiter(this, void 0, void 0, function* () {
2376
+ yield this.estimateTransactionFeeOptionsRaw(requestParameters, initOverrides);
2377
+ });
2378
+ }
2296
2379
  /**
2297
2380
  */
2298
2381
  eventsOptionsRaw(requestParameters, initOverrides) {
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import { Account, BackupKeySharesToLocationRequest, BackupKeySharesToLocationResponse, BackupKeySharesToLocationsRequest, BackupKeySharesToLocationsResponse, BackupMultipleClientKeySharesRequest, BackupMultipleClientKeySharesResponse, ChainEnum, CoinbaseOnrampGetBuyUrlRequest, CoinbaseOnrampGetBuyUrlResponse, CoinbaseOnrampOrderCreateRequest, CoinbaseOnrampOrderResponse, CompletePasskeyRecoveryRequest, ConnectRequest, CreateEmbeddedWalletsRequest, CreateExchangeTransferRequest, CreateRoomsRequest, CreateRoomsResponse, CreateRoomsWithoutWalletIdRequest, CreateRoomsWithoutWalletIdResponse, CreateWaasAccountRequest, CreateWalletAccountRequest, CryptoDotComPaymentCreateRequest, CryptoDotComPaymentResponse, Currency, DelegatedShareDeliveryRequest, DelegatedShareDeliveryResponse, DeleteEmbeddedWalletsRequest, DeleteUserPasskeyRequest, EmailProviderResponse, EmailVerificationCreateRequest, EmailVerificationCreateResponse, EmailVerificationMfaRequest, EmailVerificationRetryRequest, EmailVerificationVerifyRequest, EmbeddedWalletAuthToken, EmbeddedWalletAuthType, EmbeddedWalletChainEnum, EmbeddedWalletPasscodeClaimRequest, EmbeddedWalletSecret, ExchangeKeyEnum, ExchangeTransaction, ExchangeTransferResponse, ExportEmbeddedWalletResponse, ExportWaasWalletPrivateKeyRequest, ExternalAuthSigninRequest, FarcasterSignInRequest, GeneratedTokenResponse, GetPasskeyAuthenticationOptionsResponse, GetPasskeyRegistrationOptionsResponse, GetUserPasskeysResponse, GlobalWalletConnection, GlobalWalletConnectionCreateRequest, GlobalWalletSettings, HealthcheckResponse, ImportWaasPrivateKeyRequest, InitEmailAuthRequest, InitEmailAuthResponse, InitPasskeyRecoveryRequest, InitPasskeyRecoveryResponse, JwksResponse, MFAAuthRecoveryDevicePostRequest, MFAAuthTotpDevicePostRequest, MFADevice, MFAGetRecoveryCodesResponse, MFAListDevicesResponse, MFAMethodsResponse, MFARegenRecoveryCodesResponse, MFARegisterPasskeyDeviceGetResponse, MFARegisterPasskeyDevicePostRequest, MFARegisterTotpDeviceGetResponse, MFARegisterTotpDevicePostRequest, MFAUpdateDeviceRequest, MergeUserConflictResolutions, MultichainAccountBalanceResponse, MultichainAccountBalancesRequest, NetworkConfigurationResponse, NonceResponse, OauthInitAuthRequest, OauthProviderLoginUrl, OauthRequest, OauthResultRequest, OauthResultResponse, OpenRoomResponse, OpenRoomResponseForReshare, OpenRoomResponseWithServerKeygenIds, PasskeyAuthRequest, PasskeyRegisterRequest, PrefetchRequest, ProjectSettings, ProviderEnum, PublishEvents, RecoverMultipleClientKeySharesRequest, RecoverMultipleClientKeySharesResponse, RegisterEmbeddedWalletSessionKeyResponse, RegisterSessionKeyRequest, ReshareRequest, ScanWebsiteUrlRequest, ScanWebsiteUrlResponse, SdkSettingsRequest, SdkUser, SignMessageWithWaasRequest, SimulateEVMTransactionRequest, SimulateSVMTransactionRequest, SimulateTransactionResponse, SimulateUserOpRequest, SmsVerificationCreateRequest, SmsVerificationCreateResponse, SmsVerificationRetryRequest, SmsVerificationVerifyRequest, SolanaTransactionOptimizationRequest, SolanaTransactionOptimizationResponse, SponsorSVMTransactionRequest, SponsorSVMTransactionResponse, SsoProviderCheckRequest, SsoProviderCheckResponse, SupportedOfframpsResponse, SupportedOnrampsResponse, TelegramPostRequest, TokenBalance, TransferDestinationResponse, TurnkeyCreateWalletAccountsRequestBody, TurnkeyDeleteEmbeddedWalletsRequestBody, UpdateRecoveryEmailRequest, UpdateSelfResponse, UpdateUserPasskeyRequest, UpdateWaasWalletSettingsRequest, UpdateWaasWalletSettingsResponse, UpgradeEmbeddedWalletToV2Request, UserFields, UserFieldsCheckParams, UserFieldsCheckResponse, UserOauthAccessTokenResponse, UserPasskey, UserWalletSelectionRequest, VerifyRequest, VerifyResponse, VerifyUnlinkRequest, WalletSanctionsResponse, WalletTransactionsResponse } from '../models';
13
+ import { Account, BackupKeySharesToLocationRequest, BackupKeySharesToLocationResponse, BackupKeySharesToLocationsRequest, BackupKeySharesToLocationsResponse, BackupMultipleClientKeySharesRequest, BackupMultipleClientKeySharesResponse, ChainEnum, CoinbaseOnrampGetBuyUrlRequest, CoinbaseOnrampGetBuyUrlResponse, CoinbaseOnrampOrderCreateRequest, CoinbaseOnrampOrderResponse, CompletePasskeyRecoveryRequest, ConnectRequest, CreateEmbeddedWalletsRequest, CreateExchangeTransferRequest, CreateRoomsRequest, CreateRoomsResponse, CreateRoomsWithoutWalletIdRequest, CreateRoomsWithoutWalletIdResponse, CreateWaasAccountRequest, CreateWalletAccountRequest, CryptoDotComPaymentCreateRequest, CryptoDotComPaymentResponse, Currency, DelegatedShareDeliveryRequest, DelegatedShareDeliveryResponse, DeleteEmbeddedWalletsRequest, DeleteUserPasskeyRequest, EmailProviderResponse, EmailVerificationCreateRequest, EmailVerificationCreateResponse, EmailVerificationMfaRequest, EmailVerificationRetryRequest, EmailVerificationVerifyRequest, EmbeddedWalletAuthToken, EmbeddedWalletAuthType, EmbeddedWalletChainEnum, EmbeddedWalletPasscodeClaimRequest, EmbeddedWalletSecret, ExchangeKeyEnum, ExchangeTransaction, ExchangeTransferResponse, ExportEmbeddedWalletResponse, ExportWaasWalletPrivateKeyRequest, ExternalAuthSigninRequest, FarcasterSignInRequest, GeneratedTokenResponse, GetPasskeyAuthenticationOptionsResponse, GetPasskeyRegistrationOptionsResponse, GetUserPasskeysResponse, GlobalWalletConnection, GlobalWalletConnectionCreateRequest, GlobalWalletSettings, HealthcheckResponse, ImportWaasPrivateKeyRequest, InitEmailAuthRequest, InitEmailAuthResponse, InitPasskeyRecoveryRequest, InitPasskeyRecoveryResponse, InlineObject, JwksResponse, MFAAuthRecoveryDevicePostRequest, MFAAuthTotpDevicePostRequest, MFADevice, MFAGetRecoveryCodesResponse, MFAListDevicesResponse, MFAMethodsResponse, MFARegenRecoveryCodesResponse, MFARegisterPasskeyDeviceGetResponse, MFARegisterPasskeyDevicePostRequest, MFARegisterTotpDeviceGetResponse, MFARegisterTotpDevicePostRequest, MFAUpdateDeviceRequest, MergeUserConflictResolutions, MultichainAccountBalanceResponse, MultichainAccountBalancesRequest, NetworkConfigurationResponse, NonceResponse, OauthInitAuthRequest, OauthProviderLoginUrl, OauthRequest, OauthResultRequest, OauthResultResponse, OpenRoomResponse, OpenRoomResponseForReshare, OpenRoomResponseWithServerKeygenIds, PasskeyAuthRequest, PasskeyRegisterRequest, PrefetchRequest, ProjectSettings, ProviderEnum, PublishEvents, RecoverMultipleClientKeySharesRequest, RecoverMultipleClientKeySharesResponse, RegisterEmbeddedWalletSessionKeyResponse, RegisterSessionKeyRequest, ReshareRequest, ScanWebsiteUrlRequest, ScanWebsiteUrlResponse, SdkSettingsRequest, SdkUser, SignMessageWithWaasRequest, SimulateEVMTransactionRequest, SimulateSVMTransactionRequest, SimulateTransactionResponse, SimulateUserOpRequest, SmsVerificationCreateRequest, SmsVerificationCreateResponse, SmsVerificationRetryRequest, SmsVerificationVerifyRequest, SolanaTransactionOptimizationRequest, SolanaTransactionOptimizationResponse, SponsorSVMTransactionRequest, SponsorSVMTransactionResponse, SsoProviderCheckRequest, SsoProviderCheckResponse, SupportedOfframpsResponse, SupportedOnrampsResponse, TelegramPostRequest, TokenBalance, TransactionFeeEstimateResponse, TransferDestinationResponse, TurnkeyCreateWalletAccountsRequestBody, TurnkeyDeleteEmbeddedWalletsRequestBody, UpdateRecoveryEmailRequest, UpdateSelfResponse, UpdateUserPasskeyRequest, UpdateWaasWalletSettingsRequest, UpdateWaasWalletSettingsResponse, UpgradeEmbeddedWalletToV2Request, UserFields, UserFieldsCheckParams, UserFieldsCheckResponse, UserOauthAccessTokenResponse, UserPasskey, UserWalletSelectionRequest, VerifyRequest, VerifyResponse, VerifyUnlinkRequest, WalletSanctionsResponse, WalletTransactionsResponse } from '../models';
14
14
  export interface AuthMfaEmailDeviceOptionsRequest {
15
15
  environmentId: string;
16
16
  }
@@ -242,6 +242,16 @@ export interface EmbeddedWalletExportOptionsRequest {
242
242
  walletId: string;
243
243
  activityId: string;
244
244
  }
245
+ export interface EstimateTransactionFeeRequest {
246
+ environmentId: string;
247
+ chainName: ChainEnum;
248
+ inlineObject: InlineObject;
249
+ }
250
+ export interface EstimateTransactionFeeOptionsRequest {
251
+ environmentId: string;
252
+ chainName: ChainEnum;
253
+ networkId: number;
254
+ }
245
255
  export interface EventsOptionsRequest {
246
256
  environmentId: string;
247
257
  }
@@ -1557,6 +1567,24 @@ export declare class SDKApi extends runtime.BaseAPI {
1557
1567
  * Options call for this endpoint
1558
1568
  */
1559
1569
  embeddedWalletExportOptions(requestParameters: EmbeddedWalletExportOptionsRequest, initOverrides?: RequestInit): Promise<void>;
1570
+ /**
1571
+ * Estimates the gas fees for a given raw transaction.
1572
+ * Estimate transaction fees
1573
+ */
1574
+ estimateTransactionFeeRaw(requestParameters: EstimateTransactionFeeRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<TransactionFeeEstimateResponse>>;
1575
+ /**
1576
+ * Estimates the gas fees for a given raw transaction.
1577
+ * Estimate transaction fees
1578
+ */
1579
+ estimateTransactionFee(requestParameters: EstimateTransactionFeeRequest, initOverrides?: RequestInit): Promise<TransactionFeeEstimateResponse>;
1580
+ /**
1581
+ * Options call for this endpoint
1582
+ */
1583
+ estimateTransactionFeeOptionsRaw(requestParameters: EstimateTransactionFeeOptionsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<void>>;
1584
+ /**
1585
+ * Options call for this endpoint
1586
+ */
1587
+ estimateTransactionFeeOptions(requestParameters: EstimateTransactionFeeOptionsRequest, initOverrides?: RequestInit): Promise<void>;
1560
1588
  /**
1561
1589
  */
1562
1590
  eventsOptionsRaw(requestParameters: EventsOptionsRequest, initOverrides?: RequestInit): Promise<runtime.ApiResponse<void>>;
@@ -102,6 +102,7 @@ import { InitEmailAuthRequestToJSON } from '../models/InitEmailAuthRequest.js';
102
102
  import { InitEmailAuthResponseFromJSON } from '../models/InitEmailAuthResponse.js';
103
103
  import { InitPasskeyRecoveryRequestToJSON } from '../models/InitPasskeyRecoveryRequest.js';
104
104
  import { InitPasskeyRecoveryResponseFromJSON } from '../models/InitPasskeyRecoveryResponse.js';
105
+ import { InlineObjectToJSON } from '../models/InlineObject.js';
105
106
  import { JwksResponseFromJSON } from '../models/JwksResponse.js';
106
107
  import '../models/MFAAction.js';
107
108
  import '../models/PublicKeyCredentialType.js';
@@ -180,6 +181,7 @@ import { SupportedOfframpsResponseFromJSON } from '../models/SupportedOfframpsRe
180
181
  import { SupportedOnrampsResponseFromJSON } from '../models/SupportedOnrampsResponse.js';
181
182
  import { TelegramPostRequestToJSON } from '../models/TelegramPostRequest.js';
182
183
  import '../models/TokenScope.js';
184
+ import { TransactionFeeEstimateResponseFromJSON } from '../models/TransactionFeeEstimateResponse.js';
183
185
  import { TransferDestinationResponseFromJSON } from '../models/TransferDestinationResponse.js';
184
186
  import { TurnkeyCreateWalletAccountsRequestBodyFromJSON } from '../models/TurnkeyCreateWalletAccountsRequestBody.js';
185
187
  import { TurnkeyDeleteEmbeddedWalletsRequestBodyFromJSON } from '../models/TurnkeyDeleteEmbeddedWalletsRequestBody.js';
@@ -2289,6 +2291,87 @@ class SDKApi extends BaseAPI {
2289
2291
  yield this.embeddedWalletExportOptionsRaw(requestParameters, initOverrides);
2290
2292
  });
2291
2293
  }
2294
+ /**
2295
+ * Estimates the gas fees for a given raw transaction.
2296
+ * Estimate transaction fees
2297
+ */
2298
+ estimateTransactionFeeRaw(requestParameters, initOverrides) {
2299
+ return __awaiter(this, void 0, void 0, function* () {
2300
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
2301
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling estimateTransactionFee.');
2302
+ }
2303
+ if (requestParameters.chainName === null || requestParameters.chainName === undefined) {
2304
+ throw new RequiredError('chainName', 'Required parameter requestParameters.chainName was null or undefined when calling estimateTransactionFee.');
2305
+ }
2306
+ if (requestParameters.inlineObject === null || requestParameters.inlineObject === undefined) {
2307
+ throw new RequiredError('inlineObject', 'Required parameter requestParameters.inlineObject was null or undefined when calling estimateTransactionFee.');
2308
+ }
2309
+ const queryParameters = {};
2310
+ const headerParameters = {};
2311
+ headerParameters['Content-Type'] = 'application/json';
2312
+ if (this.configuration && this.configuration.accessToken) {
2313
+ const token = this.configuration.accessToken;
2314
+ const tokenString = yield token("bearerAuth", []);
2315
+ if (tokenString) {
2316
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
2317
+ }
2318
+ }
2319
+ const response = yield this.request({
2320
+ path: `/sdk/{environmentId}/chains/{chainName}/transactions/estimate`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"chainName"}}`, encodeURIComponent(String(requestParameters.chainName))),
2321
+ method: 'POST',
2322
+ headers: headerParameters,
2323
+ query: queryParameters,
2324
+ body: InlineObjectToJSON(requestParameters.inlineObject),
2325
+ }, initOverrides);
2326
+ return new JSONApiResponse(response, (jsonValue) => TransactionFeeEstimateResponseFromJSON(jsonValue));
2327
+ });
2328
+ }
2329
+ /**
2330
+ * Estimates the gas fees for a given raw transaction.
2331
+ * Estimate transaction fees
2332
+ */
2333
+ estimateTransactionFee(requestParameters, initOverrides) {
2334
+ return __awaiter(this, void 0, void 0, function* () {
2335
+ const response = yield this.estimateTransactionFeeRaw(requestParameters, initOverrides);
2336
+ return yield response.value();
2337
+ });
2338
+ }
2339
+ /**
2340
+ * Options call for this endpoint
2341
+ */
2342
+ estimateTransactionFeeOptionsRaw(requestParameters, initOverrides) {
2343
+ return __awaiter(this, void 0, void 0, function* () {
2344
+ if (requestParameters.environmentId === null || requestParameters.environmentId === undefined) {
2345
+ throw new RequiredError('environmentId', 'Required parameter requestParameters.environmentId was null or undefined when calling estimateTransactionFeeOptions.');
2346
+ }
2347
+ if (requestParameters.chainName === null || requestParameters.chainName === undefined) {
2348
+ throw new RequiredError('chainName', 'Required parameter requestParameters.chainName was null or undefined when calling estimateTransactionFeeOptions.');
2349
+ }
2350
+ if (requestParameters.networkId === null || requestParameters.networkId === undefined) {
2351
+ throw new RequiredError('networkId', 'Required parameter requestParameters.networkId was null or undefined when calling estimateTransactionFeeOptions.');
2352
+ }
2353
+ const queryParameters = {};
2354
+ if (requestParameters.networkId !== undefined) {
2355
+ queryParameters['networkId'] = requestParameters.networkId;
2356
+ }
2357
+ const headerParameters = {};
2358
+ const response = yield this.request({
2359
+ path: `/sdk/{environmentId}/chains/{chainName}/transactions/estimate`.replace(`{${"environmentId"}}`, encodeURIComponent(String(requestParameters.environmentId))).replace(`{${"chainName"}}`, encodeURIComponent(String(requestParameters.chainName))),
2360
+ method: 'OPTIONS',
2361
+ headers: headerParameters,
2362
+ query: queryParameters,
2363
+ }, initOverrides);
2364
+ return new VoidApiResponse(response);
2365
+ });
2366
+ }
2367
+ /**
2368
+ * Options call for this endpoint
2369
+ */
2370
+ estimateTransactionFeeOptions(requestParameters, initOverrides) {
2371
+ return __awaiter(this, void 0, void 0, function* () {
2372
+ yield this.estimateTransactionFeeOptionsRaw(requestParameters, initOverrides);
2373
+ });
2374
+ }
2292
2375
  /**
2293
2376
  */
2294
2377
  eventsOptionsRaw(requestParameters, initOverrides) {
package/src/index.cjs CHANGED
@@ -148,6 +148,7 @@ var InitEmailAuthRequest = require('./models/InitEmailAuthRequest.cjs');
148
148
  var InitEmailAuthResponse = require('./models/InitEmailAuthResponse.cjs');
149
149
  var InitPasskeyRecoveryRequest = require('./models/InitPasskeyRecoveryRequest.cjs');
150
150
  var InitPasskeyRecoveryResponse = require('./models/InitPasskeyRecoveryResponse.cjs');
151
+ var InlineObject = require('./models/InlineObject.cjs');
151
152
  var IntegrationSetting = require('./models/IntegrationSetting.cjs');
152
153
  var InternalServerError = require('./models/InternalServerError.cjs');
153
154
  var JwksKey = require('./models/JwksKey.cjs');
@@ -334,6 +335,7 @@ var TimeUnitEnum = require('./models/TimeUnitEnum.cjs');
334
335
  var TokenBalance = require('./models/TokenBalance.cjs');
335
336
  var TokenScope = require('./models/TokenScope.cjs');
336
337
  var TooManyRequests = require('./models/TooManyRequests.cjs');
338
+ var TransactionFeeEstimateResponse = require('./models/TransactionFeeEstimateResponse.cjs');
337
339
  var TransferDestination = require('./models/TransferDestination.cjs');
338
340
  var TransferDestinationResponse = require('./models/TransferDestinationResponse.cjs');
339
341
  var TurnkeyCreateWalletAccountsRequestBody = require('./models/TurnkeyCreateWalletAccountsRequestBody.cjs');
@@ -956,6 +958,9 @@ exports.InitPasskeyRecoveryRequestToJSON = InitPasskeyRecoveryRequest.InitPasske
956
958
  exports.InitPasskeyRecoveryResponseFromJSON = InitPasskeyRecoveryResponse.InitPasskeyRecoveryResponseFromJSON;
957
959
  exports.InitPasskeyRecoveryResponseFromJSONTyped = InitPasskeyRecoveryResponse.InitPasskeyRecoveryResponseFromJSONTyped;
958
960
  exports.InitPasskeyRecoveryResponseToJSON = InitPasskeyRecoveryResponse.InitPasskeyRecoveryResponseToJSON;
961
+ exports.InlineObjectFromJSON = InlineObject.InlineObjectFromJSON;
962
+ exports.InlineObjectFromJSONTyped = InlineObject.InlineObjectFromJSONTyped;
963
+ exports.InlineObjectToJSON = InlineObject.InlineObjectToJSON;
959
964
  exports.IntegrationSettingFromJSON = IntegrationSetting.IntegrationSettingFromJSON;
960
965
  exports.IntegrationSettingFromJSONTyped = IntegrationSetting.IntegrationSettingFromJSONTyped;
961
966
  exports.IntegrationSettingToJSON = IntegrationSetting.IntegrationSettingToJSON;
@@ -1638,6 +1643,9 @@ exports.TokenScopeToJSON = TokenScope.TokenScopeToJSON;
1638
1643
  exports.TooManyRequestsFromJSON = TooManyRequests.TooManyRequestsFromJSON;
1639
1644
  exports.TooManyRequestsFromJSONTyped = TooManyRequests.TooManyRequestsFromJSONTyped;
1640
1645
  exports.TooManyRequestsToJSON = TooManyRequests.TooManyRequestsToJSON;
1646
+ exports.TransactionFeeEstimateResponseFromJSON = TransactionFeeEstimateResponse.TransactionFeeEstimateResponseFromJSON;
1647
+ exports.TransactionFeeEstimateResponseFromJSONTyped = TransactionFeeEstimateResponse.TransactionFeeEstimateResponseFromJSONTyped;
1648
+ exports.TransactionFeeEstimateResponseToJSON = TransactionFeeEstimateResponse.TransactionFeeEstimateResponseToJSON;
1641
1649
  exports.TransferDestinationFromJSON = TransferDestination.TransferDestinationFromJSON;
1642
1650
  exports.TransferDestinationFromJSONTyped = TransferDestination.TransferDestinationFromJSONTyped;
1643
1651
  exports.TransferDestinationToJSON = TransferDestination.TransferDestinationToJSON;
package/src/index.js CHANGED
@@ -144,6 +144,7 @@ export { InitEmailAuthRequestFromJSON, InitEmailAuthRequestFromJSONTyped, InitEm
144
144
  export { InitEmailAuthResponseFromJSON, InitEmailAuthResponseFromJSONTyped, InitEmailAuthResponseToJSON } from './models/InitEmailAuthResponse.js';
145
145
  export { InitPasskeyRecoveryRequestFromJSON, InitPasskeyRecoveryRequestFromJSONTyped, InitPasskeyRecoveryRequestToJSON } from './models/InitPasskeyRecoveryRequest.js';
146
146
  export { InitPasskeyRecoveryResponseFromJSON, InitPasskeyRecoveryResponseFromJSONTyped, InitPasskeyRecoveryResponseToJSON } from './models/InitPasskeyRecoveryResponse.js';
147
+ export { InlineObjectFromJSON, InlineObjectFromJSONTyped, InlineObjectToJSON } from './models/InlineObject.js';
147
148
  export { IntegrationSettingFromJSON, IntegrationSettingFromJSONTyped, IntegrationSettingToJSON } from './models/IntegrationSetting.js';
148
149
  export { InternalServerErrorFromJSON, InternalServerErrorFromJSONTyped, InternalServerErrorToJSON } from './models/InternalServerError.js';
149
150
  export { JwksKeyFromJSON, JwksKeyFromJSONTyped, JwksKeyToJSON } from './models/JwksKey.js';
@@ -330,6 +331,7 @@ export { TimeUnitEnum, TimeUnitEnumFromJSON, TimeUnitEnumFromJSONTyped, TimeUnit
330
331
  export { TokenBalanceFromJSON, TokenBalanceFromJSONTyped, TokenBalanceToJSON } from './models/TokenBalance.js';
331
332
  export { TokenScope, TokenScopeFromJSON, TokenScopeFromJSONTyped, TokenScopeToJSON } from './models/TokenScope.js';
332
333
  export { TooManyRequestsFromJSON, TooManyRequestsFromJSONTyped, TooManyRequestsToJSON } from './models/TooManyRequests.js';
334
+ export { TransactionFeeEstimateResponseFromJSON, TransactionFeeEstimateResponseFromJSONTyped, TransactionFeeEstimateResponseToJSON } from './models/TransactionFeeEstimateResponse.js';
333
335
  export { TransferDestinationFromJSON, TransferDestinationFromJSONTyped, TransferDestinationToJSON } from './models/TransferDestination.js';
334
336
  export { TransferDestinationResponseFromJSON, TransferDestinationResponseFromJSONTyped, TransferDestinationResponseToJSON } from './models/TransferDestinationResponse.js';
335
337
  export { TurnkeyCreateWalletAccountsRequestBodyFromJSON, TurnkeyCreateWalletAccountsRequestBodyFromJSONTyped, TurnkeyCreateWalletAccountsRequestBodyToJSON } from './models/TurnkeyCreateWalletAccountsRequestBody.js';
@@ -0,0 +1,43 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ /* tslint:disable */
6
+ /* eslint-disable */
7
+ /**
8
+ * Dashboard API
9
+ * Dashboard API documentation
10
+ *
11
+ * The version of the OpenAPI document: 1.0.0
12
+ *
13
+ *
14
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
15
+ * https://openapi-generator.tech
16
+ * Do not edit the class manually.
17
+ */
18
+ function InlineObjectFromJSON(json) {
19
+ return InlineObjectFromJSONTyped(json);
20
+ }
21
+ function InlineObjectFromJSONTyped(json, ignoreDiscriminator) {
22
+ if ((json === undefined) || (json === null)) {
23
+ return json;
24
+ }
25
+ return {
26
+ 'base64RawTransaction': json['base64RawTransaction'],
27
+ };
28
+ }
29
+ function InlineObjectToJSON(value) {
30
+ if (value === undefined) {
31
+ return undefined;
32
+ }
33
+ if (value === null) {
34
+ return null;
35
+ }
36
+ return {
37
+ 'base64RawTransaction': value.base64RawTransaction,
38
+ };
39
+ }
40
+
41
+ exports.InlineObjectFromJSON = InlineObjectFromJSON;
42
+ exports.InlineObjectFromJSONTyped = InlineObjectFromJSONTyped;
43
+ exports.InlineObjectToJSON = InlineObjectToJSON;
@@ -0,0 +1,27 @@
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
+ *
14
+ * @export
15
+ * @interface InlineObject
16
+ */
17
+ export interface InlineObject {
18
+ /**
19
+ * The raw transaction to estimate gas fees for
20
+ * @type {string}
21
+ * @memberof InlineObject
22
+ */
23
+ base64RawTransaction: string;
24
+ }
25
+ export declare function InlineObjectFromJSON(json: any): InlineObject;
26
+ export declare function InlineObjectFromJSONTyped(json: any, ignoreDiscriminator: boolean): InlineObject;
27
+ export declare function InlineObjectToJSON(value?: InlineObject | null): any;
@@ -0,0 +1,37 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Dashboard API
5
+ * Dashboard API documentation
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ function InlineObjectFromJSON(json) {
15
+ return InlineObjectFromJSONTyped(json);
16
+ }
17
+ function InlineObjectFromJSONTyped(json, ignoreDiscriminator) {
18
+ if ((json === undefined) || (json === null)) {
19
+ return json;
20
+ }
21
+ return {
22
+ 'base64RawTransaction': json['base64RawTransaction'],
23
+ };
24
+ }
25
+ function InlineObjectToJSON(value) {
26
+ if (value === undefined) {
27
+ return undefined;
28
+ }
29
+ if (value === null) {
30
+ return null;
31
+ }
32
+ return {
33
+ 'base64RawTransaction': value.base64RawTransaction,
34
+ };
35
+ }
36
+
37
+ export { InlineObjectFromJSON, InlineObjectFromJSONTyped, InlineObjectToJSON };
@@ -0,0 +1,47 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var runtime = require('../runtime.cjs');
6
+
7
+ /* tslint:disable */
8
+ function TransactionFeeEstimateResponseFromJSON(json) {
9
+ return TransactionFeeEstimateResponseFromJSONTyped(json);
10
+ }
11
+ function TransactionFeeEstimateResponseFromJSONTyped(json, ignoreDiscriminator) {
12
+ if ((json === undefined) || (json === null)) {
13
+ return json;
14
+ }
15
+ return {
16
+ 'estimatedFee': json['estimatedFee'],
17
+ 'currency': json['currency'],
18
+ 'decimals': json['decimals'],
19
+ 'units': !runtime.exists(json, 'units') ? undefined : json['units'],
20
+ 'unitPrice': !runtime.exists(json, 'unitPrice') ? undefined : json['unitPrice'],
21
+ 'baseFee': !runtime.exists(json, 'baseFee') ? undefined : json['baseFee'],
22
+ 'priorityFee': !runtime.exists(json, 'priorityFee') ? undefined : json['priorityFee'],
23
+ 'maxFee': !runtime.exists(json, 'maxFee') ? undefined : json['maxFee'],
24
+ };
25
+ }
26
+ function TransactionFeeEstimateResponseToJSON(value) {
27
+ if (value === undefined) {
28
+ return undefined;
29
+ }
30
+ if (value === null) {
31
+ return null;
32
+ }
33
+ return {
34
+ 'estimatedFee': value.estimatedFee,
35
+ 'currency': value.currency,
36
+ 'decimals': value.decimals,
37
+ 'units': value.units,
38
+ 'unitPrice': value.unitPrice,
39
+ 'baseFee': value.baseFee,
40
+ 'priorityFee': value.priorityFee,
41
+ 'maxFee': value.maxFee,
42
+ };
43
+ }
44
+
45
+ exports.TransactionFeeEstimateResponseFromJSON = TransactionFeeEstimateResponseFromJSON;
46
+ exports.TransactionFeeEstimateResponseFromJSONTyped = TransactionFeeEstimateResponseFromJSONTyped;
47
+ exports.TransactionFeeEstimateResponseToJSON = TransactionFeeEstimateResponseToJSON;
@@ -0,0 +1,69 @@
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
+ *
14
+ * @export
15
+ * @interface TransactionFeeEstimateResponse
16
+ */
17
+ export interface TransactionFeeEstimateResponse {
18
+ /**
19
+ * Total estimated fee in the smallest unit of the native currency
20
+ * @type {string}
21
+ * @memberof TransactionFeeEstimateResponse
22
+ */
23
+ estimatedFee: string;
24
+ /**
25
+ * Native currency symbol (ETH, SOL, BTC, SUI, etc.)
26
+ * @type {string}
27
+ * @memberof TransactionFeeEstimateResponse
28
+ */
29
+ currency: string;
30
+ /**
31
+ * Number of decimals for the native currency
32
+ * @type {number}
33
+ * @memberof TransactionFeeEstimateResponse
34
+ */
35
+ decimals: number;
36
+ /**
37
+ * Estimated units of compute/space required (gas, compute units, vBytes, etc.)
38
+ * @type {string}
39
+ * @memberof TransactionFeeEstimateResponse
40
+ */
41
+ units?: string;
42
+ /**
43
+ * Price per unit in the smallest denomination
44
+ * @type {string}
45
+ * @memberof TransactionFeeEstimateResponse
46
+ */
47
+ unitPrice?: string;
48
+ /**
49
+ * Base fee component
50
+ * @type {string}
51
+ * @memberof TransactionFeeEstimateResponse
52
+ */
53
+ baseFee?: string;
54
+ /**
55
+ * Priority/tip fee component
56
+ * @type {string}
57
+ * @memberof TransactionFeeEstimateResponse
58
+ */
59
+ priorityFee?: string;
60
+ /**
61
+ * Maximum possible fee (for chains with variable pricing)
62
+ * @type {string}
63
+ * @memberof TransactionFeeEstimateResponse
64
+ */
65
+ maxFee?: string;
66
+ }
67
+ export declare function TransactionFeeEstimateResponseFromJSON(json: any): TransactionFeeEstimateResponse;
68
+ export declare function TransactionFeeEstimateResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): TransactionFeeEstimateResponse;
69
+ export declare function TransactionFeeEstimateResponseToJSON(value?: TransactionFeeEstimateResponse | null): any;
@@ -0,0 +1,41 @@
1
+ import { exists } from '../runtime.js';
2
+
3
+ /* tslint:disable */
4
+ function TransactionFeeEstimateResponseFromJSON(json) {
5
+ return TransactionFeeEstimateResponseFromJSONTyped(json);
6
+ }
7
+ function TransactionFeeEstimateResponseFromJSONTyped(json, ignoreDiscriminator) {
8
+ if ((json === undefined) || (json === null)) {
9
+ return json;
10
+ }
11
+ return {
12
+ 'estimatedFee': json['estimatedFee'],
13
+ 'currency': json['currency'],
14
+ 'decimals': json['decimals'],
15
+ 'units': !exists(json, 'units') ? undefined : json['units'],
16
+ 'unitPrice': !exists(json, 'unitPrice') ? undefined : json['unitPrice'],
17
+ 'baseFee': !exists(json, 'baseFee') ? undefined : json['baseFee'],
18
+ 'priorityFee': !exists(json, 'priorityFee') ? undefined : json['priorityFee'],
19
+ 'maxFee': !exists(json, 'maxFee') ? undefined : json['maxFee'],
20
+ };
21
+ }
22
+ function TransactionFeeEstimateResponseToJSON(value) {
23
+ if (value === undefined) {
24
+ return undefined;
25
+ }
26
+ if (value === null) {
27
+ return null;
28
+ }
29
+ return {
30
+ 'estimatedFee': value.estimatedFee,
31
+ 'currency': value.currency,
32
+ 'decimals': value.decimals,
33
+ 'units': value.units,
34
+ 'unitPrice': value.unitPrice,
35
+ 'baseFee': value.baseFee,
36
+ 'priorityFee': value.priorityFee,
37
+ 'maxFee': value.maxFee,
38
+ };
39
+ }
40
+
41
+ export { TransactionFeeEstimateResponseFromJSON, TransactionFeeEstimateResponseFromJSONTyped, TransactionFeeEstimateResponseToJSON };
@@ -141,6 +141,7 @@ export * from './InitEmailAuthRequest';
141
141
  export * from './InitEmailAuthResponse';
142
142
  export * from './InitPasskeyRecoveryRequest';
143
143
  export * from './InitPasskeyRecoveryResponse';
144
+ export * from './InlineObject';
144
145
  export * from './IntegrationSetting';
145
146
  export * from './InternalServerError';
146
147
  export * from './JwksKey';
@@ -327,6 +328,7 @@ export * from './TimeUnitEnum';
327
328
  export * from './TokenBalance';
328
329
  export * from './TokenScope';
329
330
  export * from './TooManyRequests';
331
+ export * from './TransactionFeeEstimateResponse';
330
332
  export * from './TransferDestination';
331
333
  export * from './TransferDestinationResponse';
332
334
  export * from './TurnkeyCreateWalletAccountsRequestBody';