@imtbl/sdk 1.4.1 → 1.5.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/dist/index.cjs CHANGED
@@ -173,7 +173,7 @@ const flattenProperties$1 = (properties) => {
173
173
  };
174
174
 
175
175
  // WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
176
- const SDK_VERSION$1 = '1.4.1';
176
+ const SDK_VERSION$1 = '1.5.0';
177
177
  let initialised$1 = false;
178
178
  const isInitialised$1 = () => initialised$1;
179
179
  const getReferrer$1 = () => {
@@ -11260,7 +11260,7 @@ class MultiRollupApiClients {
11260
11260
  }
11261
11261
 
11262
11262
  // eslint-disable-next-line @typescript-eslint/naming-convention
11263
- const defaultHeaders$1 = { 'x-sdk-version': 'ts-immutable-sdk-1.4.1' };
11263
+ const defaultHeaders$1 = { 'x-sdk-version': 'ts-immutable-sdk-1.5.0' };
11264
11264
  const createConfig = ({ basePath, headers, }) => {
11265
11265
  if (!basePath.trim()) {
11266
11266
  throw Error('basePath can not be empty');
@@ -11332,7 +11332,7 @@ class APIError extends Error {
11332
11332
 
11333
11333
  /* eslint-disable implicit-arrow-linebreak */
11334
11334
  const defaultHeaders = {
11335
- sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.4.1',
11335
+ sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.5.0',
11336
11336
  };
11337
11337
  /**
11338
11338
  * createAPIConfiguration to create a custom Configuration
@@ -11765,7 +11765,7 @@ const createImmutableXConfiguration = ({ basePath, chainID, coreContractAddress,
11765
11765
  chainID,
11766
11766
  coreContractAddress,
11767
11767
  registrationContractAddress,
11768
- sdkVersion: 'ts-immutable-sdk-1.4.1',
11768
+ sdkVersion: 'ts-immutable-sdk-1.5.0',
11769
11769
  });
11770
11770
  /**
11771
11771
  * Sets `sdkVersion` at the time of build
@@ -18464,6 +18464,52 @@ class ZkEvmProvider {
18464
18464
  }
18465
18465
  }
18466
18466
 
18467
+ const buildImxClientConfig = (passportModuleConfiguration) => {
18468
+ if (passportModuleConfiguration.overrides) {
18469
+ return createConfig({ basePath: passportModuleConfiguration.overrides.imxPublicApiDomain });
18470
+ }
18471
+ if (passportModuleConfiguration.baseConfig.environment === Environment$1.SANDBOX) {
18472
+ return imxApiConfig.getSandbox();
18473
+ }
18474
+ return imxApiConfig.getProduction();
18475
+ };
18476
+ const buildImxApiClients = (passportModuleConfiguration) => {
18477
+ if (passportModuleConfiguration.overrides?.imxApiClients)
18478
+ return passportModuleConfiguration.overrides.imxApiClients;
18479
+ const config = buildImxClientConfig(passportModuleConfiguration);
18480
+ return new ImxApiClients(config);
18481
+ };
18482
+ const buildPrivateVars = (passportModuleConfiguration) => {
18483
+ const config = new PassportConfiguration(passportModuleConfiguration);
18484
+ const authManager = new AuthManager(config);
18485
+ const magicAdapter = new MagicAdapter(config);
18486
+ const confirmationScreen = new ConfirmationScreen(config);
18487
+ const multiRollupApiClients = new MultiRollupApiClients(config.multiRollupConfig);
18488
+ const passportEventEmitter = new TypedEventEmitter();
18489
+ const immutableXClient = passportModuleConfiguration.overrides
18490
+ ? passportModuleConfiguration.overrides.immutableXClient
18491
+ : new IMXClient({ baseConfig: passportModuleConfiguration.baseConfig });
18492
+ const imxApiClients = buildImxApiClients(passportModuleConfiguration);
18493
+ const passportImxProviderFactory = new PassportImxProviderFactory({
18494
+ authManager,
18495
+ config,
18496
+ confirmationScreen,
18497
+ immutableXClient,
18498
+ magicAdapter,
18499
+ passportEventEmitter,
18500
+ imxApiClients,
18501
+ });
18502
+ return {
18503
+ config,
18504
+ authManager,
18505
+ magicAdapter,
18506
+ confirmationScreen,
18507
+ immutableXClient,
18508
+ multiRollupApiClients,
18509
+ passportEventEmitter,
18510
+ passportImxProviderFactory,
18511
+ };
18512
+ };
18467
18513
  class Passport {
18468
18514
  authManager;
18469
18515
  config;
@@ -18474,30 +18520,15 @@ class Passport {
18474
18520
  passportImxProviderFactory;
18475
18521
  passportEventEmitter;
18476
18522
  constructor(passportModuleConfiguration) {
18477
- this.config = new PassportConfiguration(passportModuleConfiguration);
18478
- this.authManager = new AuthManager(this.config);
18479
- this.magicAdapter = new MagicAdapter(this.config);
18480
- this.confirmationScreen = new ConfirmationScreen(this.config);
18481
- this.immutableXClient = passportModuleConfiguration.overrides?.immutableXClient
18482
- || new IMXClient({
18483
- baseConfig: passportModuleConfiguration.baseConfig,
18484
- });
18485
- this.multiRollupApiClients = new MultiRollupApiClients(this.config.multiRollupConfig);
18486
- this.passportEventEmitter = new TypedEventEmitter();
18487
- const imxClientConfig = this.config.baseConfig.environment === Environment$1.PRODUCTION
18488
- ? imxApiConfig.getProduction()
18489
- : imxApiConfig.getSandbox();
18490
- const imxApiClients = passportModuleConfiguration.overrides?.imxApiClients
18491
- || new ImxApiClients(imxClientConfig);
18492
- this.passportImxProviderFactory = new PassportImxProviderFactory({
18493
- authManager: this.authManager,
18494
- config: this.config,
18495
- confirmationScreen: this.confirmationScreen,
18496
- immutableXClient: this.immutableXClient,
18497
- magicAdapter: this.magicAdapter,
18498
- passportEventEmitter: this.passportEventEmitter,
18499
- imxApiClients,
18500
- });
18523
+ const privateVars = buildPrivateVars(passportModuleConfiguration);
18524
+ this.config = privateVars.config;
18525
+ this.authManager = privateVars.authManager;
18526
+ this.magicAdapter = privateVars.magicAdapter;
18527
+ this.confirmationScreen = privateVars.confirmationScreen;
18528
+ this.immutableXClient = privateVars.immutableXClient;
18529
+ this.multiRollupApiClients = privateVars.multiRollupApiClients;
18530
+ this.passportEventEmitter = privateVars.passportEventEmitter;
18531
+ this.passportImxProviderFactory = privateVars.passportImxProviderFactory;
18501
18532
  setPassportClientId(passportModuleConfiguration.clientId);
18502
18533
  track('passport', 'initialised');
18503
18534
  }
@@ -19058,7 +19089,7 @@ class OrdersService {
19058
19089
  * @returns ListListingsResult OK response.
19059
19090
  * @throws ApiError
19060
19091
  */
19061
- listListings({ chainName, status, sellItemContractAddress, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }) {
19092
+ listListings({ chainName, status, sellItemContractAddress, buyItemType, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }) {
19062
19093
  return this.httpRequest.request({
19063
19094
  method: 'GET',
19064
19095
  url: '/v1/chains/{chain_name}/orders/listings',
@@ -19068,6 +19099,7 @@ class OrdersService {
19068
19099
  query: {
19069
19100
  'status': status,
19070
19101
  'sell_item_contract_address': sellItemContractAddress,
19102
+ 'buy_item_type': buyItemType,
19071
19103
  'buy_item_contract_address': buyItemContractAddress,
19072
19104
  'account_address': accountAddress,
19073
19105
  'sell_item_metadata_id': sellItemMetadataId,
@@ -37030,7 +37062,7 @@ const flattenProperties = (properties) => {
37030
37062
  };
37031
37063
 
37032
37064
  // WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
37033
- const SDK_VERSION = '1.4.1';
37065
+ const SDK_VERSION = '1.5.0';
37034
37066
  let initialised = false;
37035
37067
  const isInitialised = () => initialised;
37036
37068
  const getReferrer = () => {
@@ -41255,6 +41287,9 @@ var SaleEventType;
41255
41287
  SaleEventType["TRANSACTION_SUCCESS"] = "transaction-success";
41256
41288
  SaleEventType["LANGUAGE_CHANGED"] = "language-changed";
41257
41289
  SaleEventType["PAYMENT_METHOD"] = "payment-method";
41290
+ SaleEventType["REQUEST_BRIDGE"] = "request-bridge";
41291
+ SaleEventType["REQUEST_ONRAMP"] = "request-onramp";
41292
+ SaleEventType["REQUEST_SWAP"] = "request-swap";
41258
41293
  })(SaleEventType || (SaleEventType = {}));
41259
41294
  /**
41260
41295
  * Enum representing Sale Widget available payment types.
@@ -42135,7 +42170,7 @@ const IMMUTABLE_ZKVEM_GAS_OVERRIDES = {
42135
42170
  maxPriorityFeePerGas: ethers.BigNumber.from(10e9),
42136
42171
  };
42137
42172
 
42138
- const SDK_VERSION_MARKER = '1.4.1';
42173
+ const SDK_VERSION_MARKER = '1.5.0';
42139
42174
  // This SDK version is replaced by the `yarn build` command ran on the root level
42140
42175
  const globalPackageVersion = () => SDK_VERSION_MARKER;
42141
42176
 
package/dist/index.d.ts CHANGED
@@ -28508,12 +28508,12 @@ interface PassportOverrides {
28508
28508
  passportDomain: string;
28509
28509
  imxPublicApiDomain: string;
28510
28510
  immutableXClient: IMXClient;
28511
- imxApiClients: ImxApiClients;
28512
28511
  zkEvmRpcUrl: string;
28513
28512
  relayerUrl: string;
28514
28513
  indexerMrBasePath: string;
28515
28514
  orderBookMrBasePath: string;
28516
28515
  passportMrBasePath: string;
28516
+ imxApiClients?: ImxApiClients;
28517
28517
  }
28518
28518
  interface PassportModuleConfiguration extends ModuleConfiguration<PassportOverrides>, OidcConfiguration {
28519
28519
  /**
@@ -29148,7 +29148,7 @@ type FulfillmentDataRequest = {
29148
29148
  /**
29149
29149
  * Address of the intended account fulfilling the order
29150
29150
  */
29151
- taker_address?: string;
29151
+ taker_address: string;
29152
29152
  fees: Array<Fee$2>;
29153
29153
  };
29154
29154
 
@@ -29279,7 +29279,7 @@ declare class OrdersService {
29279
29279
  * @returns ListListingsResult OK response.
29280
29280
  * @throws ApiError
29281
29281
  */
29282
- listListings({ chainName, status, sellItemContractAddress, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }: {
29282
+ listListings({ chainName, status, sellItemContractAddress, buyItemType, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }: {
29283
29283
  chainName: ChainName$1;
29284
29284
  /**
29285
29285
  * Order status to filter by
@@ -29289,6 +29289,10 @@ declare class OrdersService {
29289
29289
  * Sell item contract address to filter by
29290
29290
  */
29291
29291
  sellItemContractAddress?: string;
29292
+ /**
29293
+ * Buy item type to filter by
29294
+ */
29295
+ buyItemType?: 'NATIVE' | 'ERC20';
29292
29296
  /**
29293
29297
  * Buy item contract address to filter by
29294
29298
  */
@@ -31600,7 +31604,10 @@ declare enum SaleEventType {
31600
31604
  REJECTED = "rejected",
31601
31605
  TRANSACTION_SUCCESS = "transaction-success",
31602
31606
  LANGUAGE_CHANGED = "language-changed",
31603
- PAYMENT_METHOD = "payment-method"
31607
+ PAYMENT_METHOD = "payment-method",
31608
+ REQUEST_BRIDGE = "request-bridge",
31609
+ REQUEST_ONRAMP = "request-onramp",
31610
+ REQUEST_SWAP = "request-swap"
31604
31611
  }
31605
31612
  /**
31606
31613
  * Represents a successful Sale transaction.
@@ -32026,6 +32033,9 @@ type WidgetEventData = {
32026
32033
  [SaleEventType.CLOSE_WIDGET]: {};
32027
32034
  [SaleEventType.TRANSACTION_SUCCESS]: SaleTransactionSuccess;
32028
32035
  [SaleEventType.PAYMENT_METHOD]: SalePaymentMethod;
32036
+ [SaleEventType.REQUEST_BRIDGE]: {};
32037
+ [SaleEventType.REQUEST_SWAP]: {};
32038
+ [SaleEventType.REQUEST_ONRAMP]: {};
32029
32039
  } & OrchestrationMapping & ProviderEventMapping;
32030
32040
  };
32031
32041
  /**
package/dist/index.js CHANGED
@@ -151,7 +151,7 @@ const flattenProperties$1 = (properties) => {
151
151
  };
152
152
 
153
153
  // WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
154
- const SDK_VERSION$1 = '1.4.1';
154
+ const SDK_VERSION$1 = '1.5.0';
155
155
  let initialised$1 = false;
156
156
  const isInitialised$1 = () => initialised$1;
157
157
  const getReferrer$1 = () => {
@@ -11238,7 +11238,7 @@ class MultiRollupApiClients {
11238
11238
  }
11239
11239
 
11240
11240
  // eslint-disable-next-line @typescript-eslint/naming-convention
11241
- const defaultHeaders$1 = { 'x-sdk-version': 'ts-immutable-sdk-1.4.1' };
11241
+ const defaultHeaders$1 = { 'x-sdk-version': 'ts-immutable-sdk-1.5.0' };
11242
11242
  const createConfig = ({ basePath, headers, }) => {
11243
11243
  if (!basePath.trim()) {
11244
11244
  throw Error('basePath can not be empty');
@@ -11310,7 +11310,7 @@ class APIError extends Error {
11310
11310
 
11311
11311
  /* eslint-disable implicit-arrow-linebreak */
11312
11312
  const defaultHeaders = {
11313
- sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.4.1',
11313
+ sdkVersion: 'ts-immutable-sdk-multi-rollup-api-client-1.5.0',
11314
11314
  };
11315
11315
  /**
11316
11316
  * createAPIConfiguration to create a custom Configuration
@@ -11743,7 +11743,7 @@ const createImmutableXConfiguration = ({ basePath, chainID, coreContractAddress,
11743
11743
  chainID,
11744
11744
  coreContractAddress,
11745
11745
  registrationContractAddress,
11746
- sdkVersion: 'ts-immutable-sdk-1.4.1',
11746
+ sdkVersion: 'ts-immutable-sdk-1.5.0',
11747
11747
  });
11748
11748
  /**
11749
11749
  * Sets `sdkVersion` at the time of build
@@ -18442,6 +18442,52 @@ class ZkEvmProvider {
18442
18442
  }
18443
18443
  }
18444
18444
 
18445
+ const buildImxClientConfig = (passportModuleConfiguration) => {
18446
+ if (passportModuleConfiguration.overrides) {
18447
+ return createConfig({ basePath: passportModuleConfiguration.overrides.imxPublicApiDomain });
18448
+ }
18449
+ if (passportModuleConfiguration.baseConfig.environment === Environment$1.SANDBOX) {
18450
+ return imxApiConfig.getSandbox();
18451
+ }
18452
+ return imxApiConfig.getProduction();
18453
+ };
18454
+ const buildImxApiClients = (passportModuleConfiguration) => {
18455
+ if (passportModuleConfiguration.overrides?.imxApiClients)
18456
+ return passportModuleConfiguration.overrides.imxApiClients;
18457
+ const config = buildImxClientConfig(passportModuleConfiguration);
18458
+ return new ImxApiClients(config);
18459
+ };
18460
+ const buildPrivateVars = (passportModuleConfiguration) => {
18461
+ const config = new PassportConfiguration(passportModuleConfiguration);
18462
+ const authManager = new AuthManager(config);
18463
+ const magicAdapter = new MagicAdapter(config);
18464
+ const confirmationScreen = new ConfirmationScreen(config);
18465
+ const multiRollupApiClients = new MultiRollupApiClients(config.multiRollupConfig);
18466
+ const passportEventEmitter = new TypedEventEmitter();
18467
+ const immutableXClient = passportModuleConfiguration.overrides
18468
+ ? passportModuleConfiguration.overrides.immutableXClient
18469
+ : new IMXClient({ baseConfig: passportModuleConfiguration.baseConfig });
18470
+ const imxApiClients = buildImxApiClients(passportModuleConfiguration);
18471
+ const passportImxProviderFactory = new PassportImxProviderFactory({
18472
+ authManager,
18473
+ config,
18474
+ confirmationScreen,
18475
+ immutableXClient,
18476
+ magicAdapter,
18477
+ passportEventEmitter,
18478
+ imxApiClients,
18479
+ });
18480
+ return {
18481
+ config,
18482
+ authManager,
18483
+ magicAdapter,
18484
+ confirmationScreen,
18485
+ immutableXClient,
18486
+ multiRollupApiClients,
18487
+ passportEventEmitter,
18488
+ passportImxProviderFactory,
18489
+ };
18490
+ };
18445
18491
  class Passport {
18446
18492
  authManager;
18447
18493
  config;
@@ -18452,30 +18498,15 @@ class Passport {
18452
18498
  passportImxProviderFactory;
18453
18499
  passportEventEmitter;
18454
18500
  constructor(passportModuleConfiguration) {
18455
- this.config = new PassportConfiguration(passportModuleConfiguration);
18456
- this.authManager = new AuthManager(this.config);
18457
- this.magicAdapter = new MagicAdapter(this.config);
18458
- this.confirmationScreen = new ConfirmationScreen(this.config);
18459
- this.immutableXClient = passportModuleConfiguration.overrides?.immutableXClient
18460
- || new IMXClient({
18461
- baseConfig: passportModuleConfiguration.baseConfig,
18462
- });
18463
- this.multiRollupApiClients = new MultiRollupApiClients(this.config.multiRollupConfig);
18464
- this.passportEventEmitter = new TypedEventEmitter();
18465
- const imxClientConfig = this.config.baseConfig.environment === Environment$1.PRODUCTION
18466
- ? imxApiConfig.getProduction()
18467
- : imxApiConfig.getSandbox();
18468
- const imxApiClients = passportModuleConfiguration.overrides?.imxApiClients
18469
- || new ImxApiClients(imxClientConfig);
18470
- this.passportImxProviderFactory = new PassportImxProviderFactory({
18471
- authManager: this.authManager,
18472
- config: this.config,
18473
- confirmationScreen: this.confirmationScreen,
18474
- immutableXClient: this.immutableXClient,
18475
- magicAdapter: this.magicAdapter,
18476
- passportEventEmitter: this.passportEventEmitter,
18477
- imxApiClients,
18478
- });
18501
+ const privateVars = buildPrivateVars(passportModuleConfiguration);
18502
+ this.config = privateVars.config;
18503
+ this.authManager = privateVars.authManager;
18504
+ this.magicAdapter = privateVars.magicAdapter;
18505
+ this.confirmationScreen = privateVars.confirmationScreen;
18506
+ this.immutableXClient = privateVars.immutableXClient;
18507
+ this.multiRollupApiClients = privateVars.multiRollupApiClients;
18508
+ this.passportEventEmitter = privateVars.passportEventEmitter;
18509
+ this.passportImxProviderFactory = privateVars.passportImxProviderFactory;
18479
18510
  setPassportClientId(passportModuleConfiguration.clientId);
18480
18511
  track('passport', 'initialised');
18481
18512
  }
@@ -19036,7 +19067,7 @@ class OrdersService {
19036
19067
  * @returns ListListingsResult OK response.
19037
19068
  * @throws ApiError
19038
19069
  */
19039
- listListings({ chainName, status, sellItemContractAddress, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }) {
19070
+ listListings({ chainName, status, sellItemContractAddress, buyItemType, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }) {
19040
19071
  return this.httpRequest.request({
19041
19072
  method: 'GET',
19042
19073
  url: '/v1/chains/{chain_name}/orders/listings',
@@ -19046,6 +19077,7 @@ class OrdersService {
19046
19077
  query: {
19047
19078
  'status': status,
19048
19079
  'sell_item_contract_address': sellItemContractAddress,
19080
+ 'buy_item_type': buyItemType,
19049
19081
  'buy_item_contract_address': buyItemContractAddress,
19050
19082
  'account_address': accountAddress,
19051
19083
  'sell_item_metadata_id': sellItemMetadataId,
@@ -37008,7 +37040,7 @@ const flattenProperties = (properties) => {
37008
37040
  };
37009
37041
 
37010
37042
  // WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
37011
- const SDK_VERSION = '1.4.1';
37043
+ const SDK_VERSION = '1.5.0';
37012
37044
  let initialised = false;
37013
37045
  const isInitialised = () => initialised;
37014
37046
  const getReferrer = () => {
@@ -41233,6 +41265,9 @@ var SaleEventType;
41233
41265
  SaleEventType["TRANSACTION_SUCCESS"] = "transaction-success";
41234
41266
  SaleEventType["LANGUAGE_CHANGED"] = "language-changed";
41235
41267
  SaleEventType["PAYMENT_METHOD"] = "payment-method";
41268
+ SaleEventType["REQUEST_BRIDGE"] = "request-bridge";
41269
+ SaleEventType["REQUEST_ONRAMP"] = "request-onramp";
41270
+ SaleEventType["REQUEST_SWAP"] = "request-swap";
41236
41271
  })(SaleEventType || (SaleEventType = {}));
41237
41272
  /**
41238
41273
  * Enum representing Sale Widget available payment types.
@@ -42113,7 +42148,7 @@ const IMMUTABLE_ZKVEM_GAS_OVERRIDES = {
42113
42148
  maxPriorityFeePerGas: BigNumber$1.from(10e9),
42114
42149
  };
42115
42150
 
42116
- const SDK_VERSION_MARKER = '1.4.1';
42151
+ const SDK_VERSION_MARKER = '1.5.0';
42117
42152
  // This SDK version is replaced by the `yarn build` command ran on the root level
42118
42153
  const globalPackageVersion = () => SDK_VERSION_MARKER;
42119
42154
 
@@ -1031,7 +1031,7 @@ type FulfillmentDataRequest = {
1031
1031
  /**
1032
1032
  * Address of the intended account fulfilling the order
1033
1033
  */
1034
- taker_address?: string;
1034
+ taker_address: string;
1035
1035
  fees: Array<Fee$1>;
1036
1036
  };
1037
1037
 
@@ -1162,7 +1162,7 @@ declare class OrdersService {
1162
1162
  * @returns ListListingsResult OK response.
1163
1163
  * @throws ApiError
1164
1164
  */
1165
- listListings({ chainName, status, sellItemContractAddress, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }: {
1165
+ listListings({ chainName, status, sellItemContractAddress, buyItemType, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }: {
1166
1166
  chainName: ChainName;
1167
1167
  /**
1168
1168
  * Order status to filter by
@@ -1172,6 +1172,10 @@ declare class OrdersService {
1172
1172
  * Sell item contract address to filter by
1173
1173
  */
1174
1174
  sellItemContractAddress?: string;
1175
+ /**
1176
+ * Buy item type to filter by
1177
+ */
1178
+ buyItemType?: 'NATIVE' | 'ERC20';
1175
1179
  /**
1176
1180
  * Buy item contract address to filter by
1177
1181
  */
package/dist/orderbook.js CHANGED
@@ -126,7 +126,7 @@ const flattenProperties = (properties) => {
126
126
  };
127
127
 
128
128
  // WARNING: DO NOT CHANGE THE STRING BELOW. IT GETS REPLACED AT BUILD TIME.
129
- const SDK_VERSION = '1.4.1';
129
+ const SDK_VERSION = '1.5.0';
130
130
  let initialised = false;
131
131
  const isInitialised = () => initialised;
132
132
  const getReferrer = () => {
@@ -676,7 +676,7 @@ class OrdersService {
676
676
  * @returns ListListingsResult OK response.
677
677
  * @throws ApiError
678
678
  */
679
- listListings({ chainName, status, sellItemContractAddress, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }) {
679
+ listListings({ chainName, status, sellItemContractAddress, buyItemType, buyItemContractAddress, accountAddress, sellItemMetadataId, sellItemTokenId, fromUpdatedAt, pageSize, sortBy, sortDirection, pageCursor, }) {
680
680
  return this.httpRequest.request({
681
681
  method: 'GET',
682
682
  url: '/v1/chains/{chain_name}/orders/listings',
@@ -686,6 +686,7 @@ class OrdersService {
686
686
  query: {
687
687
  'status': status,
688
688
  'sell_item_contract_address': sellItemContractAddress,
689
+ 'buy_item_type': buyItemType,
689
690
  'buy_item_contract_address': buyItemContractAddress,
690
691
  'account_address': accountAddress,
691
692
  'sell_item_metadata_id': sellItemMetadataId,