@meteora-ag/cp-amm-sdk 1.3.7 → 1.3.8

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.d.mts CHANGED
@@ -7404,6 +7404,11 @@ declare class CpAmm {
7404
7404
  publicKey: PublicKey;
7405
7405
  account: ConfigState;
7406
7406
  }>>;
7407
+ /**
7408
+ * Retrieves static config public keys where vault and creator authority are default.
7409
+ * @returns Array of static config public keys.
7410
+ */
7411
+ getStaticConfigs(): Promise<PublicKey[]>;
7407
7412
  /**
7408
7413
  * Retrieves all pool accounts.
7409
7414
  * @returns Array of pool public keys and their states.
package/dist/index.d.ts CHANGED
@@ -7404,6 +7404,11 @@ declare class CpAmm {
7404
7404
  publicKey: PublicKey;
7405
7405
  account: ConfigState;
7406
7406
  }>>;
7407
+ /**
7408
+ * Retrieves static config public keys where vault and creator authority are default.
7409
+ * @returns Array of static config public keys.
7410
+ */
7411
+ getStaticConfigs(): Promise<PublicKey[]>;
7407
7412
  /**
7408
7413
  * Retrieves all pool accounts.
7409
7414
  * @returns Array of pool public keys and their states.
package/dist/index.js CHANGED
@@ -8168,6 +8168,7 @@ var InvalidRewardDurationError = class extends Error {
8168
8168
 
8169
8169
 
8170
8170
 
8171
+
8171
8172
  var _web3js = require('@solana/web3.js');
8172
8173
 
8173
8174
  // src/types.ts
@@ -12643,6 +12644,21 @@ var CpAmm = class {
12643
12644
  return configAccounts;
12644
12645
  });
12645
12646
  }
12647
+ /**
12648
+ * Retrieves static config public keys where vault and creator authority are default.
12649
+ * @returns Array of static config public keys.
12650
+ */
12651
+ getStaticConfigs() {
12652
+ return __async(this, null, function* () {
12653
+ const configAccounts = yield this._program.account.config.all();
12654
+ const DEFAULT_PUBLIC_KEY = new (0, _web3js.PublicKey)(
12655
+ "11111111111111111111111111111111"
12656
+ );
12657
+ return configAccounts.filter(
12658
+ (config) => config.account.configType === 0 && config.account.vaultConfigKey.equals(DEFAULT_PUBLIC_KEY) && config.account.poolCreatorAuthority.equals(DEFAULT_PUBLIC_KEY)
12659
+ ).map((config) => config.publicKey);
12660
+ });
12661
+ }
12646
12662
  /**
12647
12663
  * Retrieves all pool accounts.
12648
12664
  * @returns Array of pool public keys and their states.