@medialane/sdk 0.19.0 → 0.20.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
@@ -6374,14 +6374,19 @@ var SERVICES = {
6374
6374
  capabilities: ["list", "buy", "make_offer", "cancel", "transfer"]
6375
6375
  }
6376
6376
  };
6377
+ function isServiceId(id) {
6378
+ return typeof id === "string" && id in SERVICES;
6379
+ }
6377
6380
  function getService(id) {
6378
- return id ? SERVICES[id] : void 0;
6381
+ return id && id in SERVICES ? SERVICES[id] : void 0;
6379
6382
  }
6380
6383
  function listServices() {
6381
6384
  return Object.values(SERVICES);
6382
6385
  }
6383
6386
  function getServicesByCapability(cap) {
6384
- return Object.values(SERVICES).filter((s) => s.capabilities.includes(cap));
6387
+ return Object.values(SERVICES).filter(
6388
+ (s) => s.capabilities.includes(cap)
6389
+ );
6385
6390
  }
6386
6391
 
6387
6392
  exports.ApiClient = ApiClient;
@@ -6442,6 +6447,7 @@ exports.getService = getService;
6442
6447
  exports.getServicesByCapability = getServicesByCapability;
6443
6448
  exports.getTokenByAddress = getTokenByAddress;
6444
6449
  exports.getTokenBySymbol = getTokenBySymbol;
6450
+ exports.isServiceId = isServiceId;
6445
6451
  exports.listServices = listServices;
6446
6452
  exports.normalizeAddress = normalizeAddress;
6447
6453
  exports.parseAmount = parseAmount;