@neutral-trade/sdk 0.2.9 → 0.2.11
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 +5 -3
- package/dist/index.mjs +15 -3
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -3034,6 +3034,8 @@ declare function createBundleProgramById(provider: AnchorProvider, programId: st
|
|
|
3034
3034
|
* Auto-generated from the vault registry JSON.
|
|
3035
3035
|
*/
|
|
3036
3036
|
declare enum VaultId {
|
|
3037
|
+
/** Velox-Cross-USDC-Bundle */
|
|
3038
|
+
velox_cross_usdc_bundle_78 = 78,
|
|
3037
3039
|
/** Hyperithm-CTA-USDC-Bundle */
|
|
3038
3040
|
hyperithm_cta_usdc_bundle_77 = 77,
|
|
3039
3041
|
/** Master Bundle */
|
|
@@ -3324,7 +3326,7 @@ interface NeutralTradeConfig {
|
|
|
3324
3326
|
rpcUrl: string;
|
|
3325
3327
|
/** Bundle program cluster selector. Defaults to 'mainnet'. */
|
|
3326
3328
|
bundleCluster?: BundleCluster;
|
|
3327
|
-
/** If true, include built-in vault registry
|
|
3329
|
+
/** If true, include built-in vault registry for `bundleCluster` (mainnet vs devnet fixtures). Defaults to true. */
|
|
3328
3330
|
includeBuiltInVaults?: boolean;
|
|
3329
3331
|
/** Optional local registry entries. Applied after built-in configs and before registryUrl (if provided). */
|
|
3330
3332
|
registry?: VaultRegistryEntry[];
|
|
@@ -3343,14 +3345,14 @@ declare class NeutralTrade {
|
|
|
3343
3345
|
readonly connection: Connection;
|
|
3344
3346
|
readonly bundlePrograms: Record<string, Program<Ntbundle>>;
|
|
3345
3347
|
readonly bundleCluster: BundleCluster;
|
|
3346
|
-
/** Vault configurations after merge order: built-in < local registry < registryUrl */
|
|
3348
|
+
/** Vault configurations after merge order: built-in (cluster-specific) < local registry < registryUrl */
|
|
3347
3349
|
readonly vaults: VaultRegistry;
|
|
3348
3350
|
/** Price map for deposit tokens */
|
|
3349
3351
|
readonly priceMap: Map<SupportedToken, number>;
|
|
3350
3352
|
protected constructor(connection: Connection, bundlePrograms: Record<string, Program<Ntbundle>>, bundleCluster: BundleCluster, vaults: VaultRegistry, priceMap: Map<SupportedToken, number>);
|
|
3351
3353
|
/**
|
|
3352
3354
|
* Create a new NeutralTrade instance
|
|
3353
|
-
* Merge order: built-in (when allowed) < local registry < registryUrl
|
|
3355
|
+
* Merge order: built-in catalog for `bundleCluster` (when allowed) < local registry < registryUrl
|
|
3354
3356
|
* @throws Error if registry or registryUrl validation fails (or fetch fails for registryUrl)
|
|
3355
3357
|
*/
|
|
3356
3358
|
protected static initCore(config: NeutralTradeConfig): Promise<NeutralTradeCoreContext>;
|
package/dist/index.mjs
CHANGED
|
@@ -11617,6 +11617,8 @@ function createBundleProgramById(provider, programId) {
|
|
|
11617
11617
|
* Auto-generated from the vault registry JSON.
|
|
11618
11618
|
*/
|
|
11619
11619
|
let VaultId = /* @__PURE__ */ function(VaultId$1) {
|
|
11620
|
+
/** Velox-Cross-USDC-Bundle */
|
|
11621
|
+
VaultId$1[VaultId$1["velox_cross_usdc_bundle_78"] = 78] = "velox_cross_usdc_bundle_78";
|
|
11620
11622
|
/** Hyperithm-CTA-USDC-Bundle */
|
|
11621
11623
|
VaultId$1[VaultId$1["hyperithm_cta_usdc_bundle_77"] = 77] = "hyperithm_cta_usdc_bundle_77";
|
|
11622
11624
|
/** Master Bundle */
|
|
@@ -11805,6 +11807,16 @@ var vaults_devnet_default = [{
|
|
|
11805
11807
|
//#endregion
|
|
11806
11808
|
//#region src/registry/vaults.json
|
|
11807
11809
|
var vaults_default = [
|
|
11810
|
+
{
|
|
11811
|
+
"vaultId": 78,
|
|
11812
|
+
"name": "Velox-Cross-USDC-Bundle",
|
|
11813
|
+
"type": "Bundle",
|
|
11814
|
+
"category": "Market Neutral",
|
|
11815
|
+
"vaultAddress": "De47QBuMP7xukYBek5r4ScZF4HEk1kHW34ymKASz3DLt",
|
|
11816
|
+
"depositToken": "USDC",
|
|
11817
|
+
"pointsMultiplier": 1,
|
|
11818
|
+
"pointsEnabled": true
|
|
11819
|
+
},
|
|
11808
11820
|
{
|
|
11809
11821
|
"vaultId": 77,
|
|
11810
11822
|
"name": "Hyperithm-CTA-USDC-Bundle",
|
|
@@ -13248,7 +13260,7 @@ var NeutralTrade = class NeutralTrade {
|
|
|
13248
13260
|
connection;
|
|
13249
13261
|
bundlePrograms;
|
|
13250
13262
|
bundleCluster;
|
|
13251
|
-
/** Vault configurations after merge order: built-in < local registry < registryUrl */
|
|
13263
|
+
/** Vault configurations after merge order: built-in (cluster-specific) < local registry < registryUrl */
|
|
13252
13264
|
vaults;
|
|
13253
13265
|
/** Price map for deposit tokens */
|
|
13254
13266
|
priceMap;
|
|
@@ -13261,14 +13273,14 @@ var NeutralTrade = class NeutralTrade {
|
|
|
13261
13273
|
}
|
|
13262
13274
|
/**
|
|
13263
13275
|
* Create a new NeutralTrade instance
|
|
13264
|
-
* Merge order: built-in (when allowed) < local registry < registryUrl
|
|
13276
|
+
* Merge order: built-in catalog for `bundleCluster` (when allowed) < local registry < registryUrl
|
|
13265
13277
|
* @throws Error if registry or registryUrl validation fails (or fetch fails for registryUrl)
|
|
13266
13278
|
*/
|
|
13267
13279
|
static async initCore(config) {
|
|
13268
13280
|
const connection = createConnection(config.rpcUrl);
|
|
13269
13281
|
const provider = createAnchorProvider(connection);
|
|
13270
13282
|
const cluster = config.bundleCluster ?? "mainnet";
|
|
13271
|
-
let vaults$1 = config.includeBuiltInVaults !== false ? { ...
|
|
13283
|
+
let vaults$1 = config.includeBuiltInVaults !== false ? { ...getVaultRegistry(cluster) } : {};
|
|
13272
13284
|
if (config.registry) {
|
|
13273
13285
|
const localVaults = NeutralTrade.parseVaultRegistryEntries(config.registry, "registry");
|
|
13274
13286
|
vaults$1 = {
|