@gearbox-protocol/sdk 17.10.1 → 17.12.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.
Files changed (95) hide show
  1. package/dist/cjs/offchain/AbstractOffchainNamespace.js +31 -8
  2. package/dist/cjs/permissionless/api/GearboxPermissionless.js +79 -0
  3. package/dist/cjs/permissionless/api/chains/ChainsNamespace.js +180 -0
  4. package/dist/cjs/permissionless/api/chains/index.js +4 -0
  5. package/dist/cjs/permissionless/api/chains/schemas.js +34 -0
  6. package/dist/cjs/permissionless/api/chains/types.js +1 -0
  7. package/dist/cjs/permissionless/api/deploy/PermissionlessDeploy.js +152 -0
  8. package/dist/cjs/permissionless/api/deploy/effective-staleness.js +46 -0
  9. package/dist/cjs/permissionless/api/deploy/index.js +8 -0
  10. package/dist/cjs/permissionless/api/deploy/types.js +1 -0
  11. package/dist/cjs/permissionless/api/errors.js +82 -0
  12. package/dist/cjs/permissionless/api/index.js +28 -0
  13. package/dist/cjs/permissionless/api/oracles/PermissionlessOracles.js +84 -0
  14. package/dist/cjs/permissionless/api/oracles/index.js +6 -0
  15. package/dist/cjs/permissionless/api/oracles/schemas.js +51 -0
  16. package/dist/cjs/permissionless/api/oracles/types.js +1 -0
  17. package/dist/cjs/permissionless/api/schemas.js +28 -0
  18. package/dist/cjs/permissionless/api/transactions/InstanceOwnerTransactions.js +234 -0
  19. package/dist/cjs/permissionless/api/transactions/index.js +4 -0
  20. package/dist/cjs/permissionless/api/transactions/lp-price-feeds.js +86 -0
  21. package/dist/cjs/permissionless/api/transactions/types.js +1 -0
  22. package/dist/cjs/permissionless/api/types.js +1 -0
  23. package/dist/cjs/permissionless/bindings/cross-chain-multisig.js +1 -1
  24. package/dist/cjs/permissionless/bindings/index.js +3 -3
  25. package/dist/cjs/permissionless/bindings/instance-manager.js +3 -3
  26. package/dist/cjs/permissionless/bindings/price-feed-store.js +0 -2
  27. package/dist/cjs/permissionless/index.js +31 -8
  28. package/dist/cjs/permissionless/utils/governance/timelock-txs.js +1 -1
  29. package/dist/cjs/permissionless/utils/index.js +4 -4
  30. package/dist/cjs/permissionless/utils/price-update/get-price-update-tx.js +1 -1
  31. package/dist/cjs/permissionless/utils/price-update/index.js +1 -1
  32. package/dist/esm/offchain/AbstractOffchainNamespace.js +31 -8
  33. package/dist/esm/permissionless/api/GearboxPermissionless.js +78 -0
  34. package/dist/esm/permissionless/api/chains/ChainsNamespace.js +179 -0
  35. package/dist/esm/permissionless/api/chains/index.js +3 -0
  36. package/dist/esm/permissionless/api/chains/schemas.js +30 -0
  37. package/dist/esm/permissionless/api/chains/types.js +1 -0
  38. package/dist/esm/permissionless/api/deploy/PermissionlessDeploy.js +149 -0
  39. package/dist/esm/permissionless/api/deploy/effective-staleness.js +46 -0
  40. package/dist/esm/permissionless/api/deploy/index.js +4 -0
  41. package/dist/esm/permissionless/api/deploy/types.js +1 -0
  42. package/dist/esm/permissionless/api/errors.js +77 -0
  43. package/dist/esm/permissionless/api/index.js +13 -0
  44. package/dist/esm/permissionless/api/oracles/PermissionlessOracles.js +81 -0
  45. package/dist/esm/permissionless/api/oracles/index.js +3 -0
  46. package/dist/esm/permissionless/api/oracles/schemas.js +47 -0
  47. package/dist/esm/permissionless/api/oracles/types.js +1 -0
  48. package/dist/esm/permissionless/api/schemas.js +25 -0
  49. package/dist/esm/permissionless/api/transactions/InstanceOwnerTransactions.js +233 -0
  50. package/dist/esm/permissionless/api/transactions/index.js +3 -0
  51. package/dist/esm/permissionless/api/transactions/lp-price-feeds.js +84 -0
  52. package/dist/esm/permissionless/api/transactions/types.js +1 -0
  53. package/dist/esm/permissionless/api/types.js +1 -0
  54. package/dist/esm/permissionless/bindings/cross-chain-multisig.js +1 -1
  55. package/dist/esm/permissionless/bindings/index.js +3 -3
  56. package/dist/esm/permissionless/bindings/instance-manager.js +3 -3
  57. package/dist/esm/permissionless/bindings/price-feed-store.js +0 -2
  58. package/dist/esm/permissionless/index.js +17 -9
  59. package/dist/esm/permissionless/utils/governance/timelock-txs.js +1 -1
  60. package/dist/esm/permissionless/utils/index.js +4 -4
  61. package/dist/esm/permissionless/utils/price-update/get-price-update-tx.js +1 -1
  62. package/dist/esm/permissionless/utils/price-update/index.js +1 -1
  63. package/dist/types/offchain/AbstractOffchainNamespace.d.ts +12 -0
  64. package/dist/types/permissionless/api/GearboxPermissionless.d.ts +71 -0
  65. package/dist/types/permissionless/api/chains/ChainsNamespace.d.ts +99 -0
  66. package/dist/types/permissionless/api/chains/index.d.ts +3 -0
  67. package/dist/types/permissionless/api/chains/schemas.d.ts +49 -0
  68. package/dist/types/permissionless/api/chains/types.d.ts +58 -0
  69. package/dist/types/permissionless/api/deploy/PermissionlessDeploy.d.ts +69 -0
  70. package/dist/types/permissionless/api/deploy/effective-staleness.d.ts +19 -0
  71. package/dist/types/permissionless/api/deploy/index.d.ts +4 -0
  72. package/dist/types/permissionless/api/deploy/types.d.ts +87 -0
  73. package/dist/types/permissionless/api/errors.d.ts +63 -0
  74. package/dist/types/permissionless/api/index.d.ts +17 -0
  75. package/dist/types/permissionless/api/oracles/PermissionlessOracles.d.ts +64 -0
  76. package/dist/types/permissionless/api/oracles/index.d.ts +3 -0
  77. package/dist/types/permissionless/api/oracles/schemas.d.ts +74 -0
  78. package/dist/types/permissionless/api/oracles/types.d.ts +51 -0
  79. package/dist/types/permissionless/api/schemas.d.ts +22 -0
  80. package/dist/types/permissionless/api/transactions/InstanceOwnerTransactions.d.ts +68 -0
  81. package/dist/types/permissionless/api/transactions/index.d.ts +3 -0
  82. package/dist/types/permissionless/api/transactions/lp-price-feeds.d.ts +17 -0
  83. package/dist/types/permissionless/api/transactions/types.d.ts +58 -0
  84. package/dist/types/permissionless/api/types.d.ts +12 -0
  85. package/dist/types/permissionless/bindings/factory/credit-factory.d.ts +1 -1
  86. package/dist/types/permissionless/bindings/factory/loss-policy-factory.d.ts +1 -1
  87. package/dist/types/permissionless/bindings/factory/pool-factory.d.ts +1 -1
  88. package/dist/types/permissionless/bindings/factory/price-oracle-factory.d.ts +1 -1
  89. package/dist/types/permissionless/bindings/index.d.ts +1 -1
  90. package/dist/types/permissionless/core/index.d.ts +1 -1
  91. package/dist/types/permissionless/core/pricefeed.d.ts +0 -1
  92. package/dist/types/permissionless/index.d.ts +23 -10
  93. package/dist/types/permissionless/utils/governance/index.d.ts +1 -1
  94. package/dist/types/permissionless/utils/index.d.ts +1 -1
  95. package/package.json +1 -1
@@ -0,0 +1,63 @@
1
+ import { Address, BaseError } from "viem";
2
+ //#region src/permissionless/api/errors.d.ts
3
+ /**
4
+ * Thrown when anything is read off {@link ChainsNamespace} before
5
+ * {@link GearboxPermissionless.attach} has completed.
6
+ *
7
+ * The chain list is the backend's answer, so there is nothing to report until
8
+ * it arrives. Answering with an empty list instead would be indistinguishable
9
+ * from a backend that serves no chains at all.
10
+ **/
11
+ declare class PermissionlessNotAttachedError extends BaseError {
12
+ name: string;
13
+ constructor();
14
+ }
15
+ /**
16
+ * Thrown when a call has to read a chain the client holds no viem client for.
17
+ *
18
+ * Either the backend does not serve the chain, or it serves one this SDK
19
+ * carries no definition for: endpoints come from the chain definition, since
20
+ * the backend's own urls carry provider keys and are never handed out.
21
+ **/
22
+ declare class PermissionlessChainUnreachableError extends BaseError {
23
+ name: string;
24
+ /** Chain that was asked for. */
25
+ readonly chainId: number;
26
+ constructor(chainId: number);
27
+ }
28
+ /**
29
+ * Thrown when a rename names a feed the PriceFeedStore does not carry. A name
30
+ * is part of what the store holds, so there is nothing to change on a feed
31
+ * that never reached it.
32
+ **/
33
+ declare class PriceFeedNotInStoreError extends BaseError {
34
+ name: string;
35
+ /** Feed that was named. */
36
+ readonly priceFeed: Address;
37
+ readonly chainId: number;
38
+ constructor(priceFeed: Address, chainId: number);
39
+ }
40
+ /**
41
+ * Thrown when a composite feed names a leg whose own staleness bound cannot be
42
+ * read off the chain.
43
+ *
44
+ * Deploying with a placeholder is not an option: a composite whose check can
45
+ * never pass reverts on every read, and the store will not take it. The bound
46
+ * has to be set on the leg first.
47
+ **/
48
+ declare class PriceFeedStalenessUnknownError extends BaseError {
49
+ name: string;
50
+ /** Leg whose bound could not be determined. */
51
+ readonly priceFeed: Address;
52
+ constructor(priceFeed: Address);
53
+ }
54
+ /**
55
+ * Thrown when a price feed deploy names neither a salt nor the name one would
56
+ * be derived from, leaving CREATE2 nothing to distinguish it by.
57
+ **/
58
+ declare class PriceFeedSaltMissingError extends BaseError {
59
+ name: string;
60
+ constructor();
61
+ }
62
+ //#endregion
63
+ export { PermissionlessChainUnreachableError, PermissionlessNotAttachedError, PriceFeedNotInStoreError, PriceFeedSaltMissingError, PriceFeedStalenessUnknownError };
@@ -0,0 +1,17 @@
1
+ import { GearboxPermissionlessOptions } from "./types.js";
2
+ import { AttachChainsArgs, ChainScope, ChainSummaryArgs, PermissionlessChain, PermissionlessChainSummary } from "./chains/types.js";
3
+ import { ChainsNamespace } from "./chains/ChainsNamespace.js";
4
+ import { DeployArgs, DeployContractArgs, DeployPriceFeedArgs, PreparedDeployment, PreparedPriceFeedDeployment } from "./deploy/types.js";
5
+ import { DEFAULT_DEPLOY_SALT, PermissionlessDeploy, priceFeedSalt } from "./deploy/PermissionlessDeploy.js";
6
+ import { GetPricesArgs, PermissionlessAsset, PermissionlessPriceFeedStore, PermissionlessPrices } from "./oracles/types.js";
7
+ import { GET_PRICES_CHUNK_SIZE, GET_PRICES_GAS_LIMIT_BY_CHAIN_ID, PermissionlessOracles } from "./oracles/PermissionlessOracles.js";
8
+ import { AddFeedsArgs, ChangeNamesArgs, ChangeStalenessPeriodsArgs, ForbidFeedsArgs, InstanceTxsArgs, PriceFeedPair } from "./transactions/types.js";
9
+ import { InstanceOwnerTransactions } from "./transactions/InstanceOwnerTransactions.js";
10
+ import { GearboxPermissionless } from "./GearboxPermissionless.js";
11
+ import "./chains/index.js";
12
+ import { deriveEffectiveStalenessPeriod } from "./deploy/effective-staleness.js";
13
+ import "./deploy/index.js";
14
+ import { PermissionlessChainUnreachableError, PermissionlessNotAttachedError, PriceFeedNotInStoreError, PriceFeedSaltMissingError, PriceFeedStalenessUnknownError } from "./errors.js";
15
+ import "./oracles/index.js";
16
+ import "./transactions/index.js";
17
+ export { AddFeedsArgs, AttachChainsArgs, ChainScope, ChainSummaryArgs, ChainsNamespace, ChangeNamesArgs, ChangeStalenessPeriodsArgs, DEFAULT_DEPLOY_SALT, DeployArgs, DeployContractArgs, DeployPriceFeedArgs, ForbidFeedsArgs, GET_PRICES_CHUNK_SIZE, GET_PRICES_GAS_LIMIT_BY_CHAIN_ID, GearboxPermissionless, GearboxPermissionlessOptions, GetPricesArgs, InstanceOwnerTransactions, InstanceTxsArgs, PermissionlessAsset, PermissionlessChain, PermissionlessChainSummary, PermissionlessChainUnreachableError, PermissionlessDeploy, PermissionlessNotAttachedError, PermissionlessOracles, PermissionlessPriceFeedStore, PermissionlessPrices, PreparedDeployment, PreparedPriceFeedDeployment, PriceFeedNotInStoreError, PriceFeedPair, PriceFeedSaltMissingError, PriceFeedStalenessUnknownError, deriveEffectiveStalenessPeriod, priceFeedSalt };
@@ -0,0 +1,64 @@
1
+ import { AbstractOffchainNamespace } from "../../../offchain/AbstractOffchainNamespace.js";
2
+ import { GearboxPermissionlessOptions } from "../types.js";
3
+ import { ChainsNamespace } from "../chains/ChainsNamespace.js";
4
+ import { GetPricesArgs, PermissionlessPriceFeedStore, PermissionlessPrices } from "./types.js";
5
+ import { Address } from "viem";
6
+ //#region src/permissionless/api/oracles/PermissionlessOracles.d.ts
7
+ declare const GET_PRICES_GAS_LIMIT_BY_CHAIN_ID: Record<number, bigint>;
8
+ declare const GET_PRICES_CHUNK_SIZE = 200;
9
+ /**
10
+ * The price feeds of one chain: the PriceFeedStore as the backend has indexed
11
+ * it, and the prices behind it.
12
+ *
13
+ * ```ts
14
+ * const store = await permissionless.oracles.store({ chainId: 1 });
15
+ * const { prices } = await permissionless.oracles.prices({ chainId: 1 });
16
+ * ```
17
+ *
18
+ * Read-only. What the store carries is decided on chain, so putting a feed
19
+ * there is a batch the instance owner executes — see
20
+ * {@link InstanceOwnerTransactions} — not a row a client writes here.
21
+ **/
22
+ declare class PermissionlessOracles extends AbstractOffchainNamespace {
23
+ #private;
24
+ constructor(options: GearboxPermissionlessOptions, chains: ChainsNamespace);
25
+ /**
26
+ * The store with the assets and feeds of one chain.
27
+ **/
28
+ store({ chainId }: {
29
+ chainId: number;
30
+ }): Promise<PermissionlessPriceFeedStore>;
31
+ /**
32
+ * A price per feed, and a market cap per feed and asset. The feeds the
33
+ * indexer has not seen are read off the chain by the backend, so the store
34
+ * is priced whole.
35
+ **/
36
+ prices({ chainId }: {
37
+ chainId: number;
38
+ }): Promise<PermissionlessPrices>;
39
+ /**
40
+ * The price each of the named feeds reports, read off the chain.
41
+ *
42
+ * Where {@link prices} answers for the store as a whole and at whatever
43
+ * moment the backend priced it, this prices exactly the feeds asked for, at
44
+ * the current block. A feed the store does not carry prices the same way,
45
+ * which is what makes this the call to reach for after a deploy, or while a
46
+ * form is still choosing between candidates.
47
+ *
48
+ * Feeds needing a fresh answer before they can be read are updated inside
49
+ * the same simulation, so a push-based feed prices as readily as a
50
+ * pull-based one. `null` is a feed whose read reverted, not a zero.
51
+ *
52
+ * ```ts
53
+ * const prices = await permissionless.oracles.getPrices({
54
+ * chainId: 1,
55
+ * priceFeeds: [feed],
56
+ * });
57
+ * ```
58
+ *
59
+ * @returns A price per feed, in the 8 decimals every Gearbox feed reports.
60
+ **/
61
+ getPrices({ chainId, priceFeeds }: GetPricesArgs): Promise<Record<Address, bigint | null>>;
62
+ }
63
+ //#endregion
64
+ export { GET_PRICES_CHUNK_SIZE, GET_PRICES_GAS_LIMIT_BY_CHAIN_ID, PermissionlessOracles };
@@ -0,0 +1,3 @@
1
+ import { GetPricesArgs, PermissionlessAsset, PermissionlessPriceFeedStore, PermissionlessPrices } from "./types.js";
2
+ import { GET_PRICES_CHUNK_SIZE, GET_PRICES_GAS_LIMIT_BY_CHAIN_ID, PermissionlessOracles } from "./PermissionlessOracles.js";
3
+ export { GET_PRICES_CHUNK_SIZE, GET_PRICES_GAS_LIMIT_BY_CHAIN_ID, GetPricesArgs, PermissionlessAsset, PermissionlessOracles, PermissionlessPriceFeedStore, PermissionlessPrices };
@@ -0,0 +1,74 @@
1
+ import { z } from "zod/v4";
2
+ //#region src/permissionless/api/oracles/schemas.d.ts
3
+ /**
4
+ * Runtime schemas for {@link ./types.js}.
5
+ *
6
+ * The objects are loose: the backend reads most of these rows straight off the
7
+ * chain through the SDK's own bindings, which attach fields the hand-written
8
+ * types do not declare, and dropping them would make this client lossier than
9
+ * the payload it decodes.
10
+ **/
11
+ /** {@link PriceFeed}, as the backend serves it. */
12
+ declare const priceFeedSchema: z.ZodObject<{
13
+ address: z.ZodCustom<`0x${string}`, `0x${string}`>;
14
+ contractType: z.ZodString;
15
+ version: z.ZodNumber;
16
+ deployedBy: z.ZodCustom<`0x${string}`, `0x${string}`>;
17
+ stalenessPeriod: z.ZodNumber;
18
+ name: z.ZodString;
19
+ }, z.core.$loose>;
20
+ /** {@link PermissionlessAsset} */
21
+ declare const assetSchema: z.ZodObject<{
22
+ address: z.ZodCustom<`0x${string}`, `0x${string}`>;
23
+ symbol: z.ZodString;
24
+ name: z.ZodString;
25
+ decimals: z.ZodNumber;
26
+ owner: z.ZodCustom<`0x${string}`, `0x${string}`>;
27
+ priceFeeds: z.ZodArray<z.ZodObject<{
28
+ address: z.ZodCustom<`0x${string}`, `0x${string}`>;
29
+ contractType: z.ZodString;
30
+ version: z.ZodNumber;
31
+ deployedBy: z.ZodCustom<`0x${string}`, `0x${string}`>;
32
+ stalenessPeriod: z.ZodNumber;
33
+ name: z.ZodString;
34
+ }, z.core.$loose>>;
35
+ }, z.core.$loose>;
36
+ /** {@link PermissionlessPriceFeedStore} */
37
+ declare const priceFeedStoreSchema: z.ZodObject<{
38
+ chainId: z.ZodNumber;
39
+ name: z.ZodString;
40
+ isPublic: z.ZodBoolean;
41
+ isActivated: z.ZodBoolean;
42
+ explorerUrl: z.ZodString;
43
+ assets: z.ZodArray<z.ZodObject<{
44
+ address: z.ZodCustom<`0x${string}`, `0x${string}`>;
45
+ symbol: z.ZodString;
46
+ name: z.ZodString;
47
+ decimals: z.ZodNumber;
48
+ owner: z.ZodCustom<`0x${string}`, `0x${string}`>;
49
+ priceFeeds: z.ZodArray<z.ZodObject<{
50
+ address: z.ZodCustom<`0x${string}`, `0x${string}`>;
51
+ contractType: z.ZodString;
52
+ version: z.ZodNumber;
53
+ deployedBy: z.ZodCustom<`0x${string}`, `0x${string}`>;
54
+ stalenessPeriod: z.ZodNumber;
55
+ name: z.ZodString;
56
+ }, z.core.$loose>>;
57
+ }, z.core.$loose>>;
58
+ priceFeeds: z.ZodArray<z.ZodObject<{
59
+ address: z.ZodCustom<`0x${string}`, `0x${string}`>;
60
+ contractType: z.ZodString;
61
+ version: z.ZodNumber;
62
+ deployedBy: z.ZodCustom<`0x${string}`, `0x${string}`>;
63
+ stalenessPeriod: z.ZodNumber;
64
+ name: z.ZodString;
65
+ }, z.core.$loose>>;
66
+ }, z.core.$loose>;
67
+ /** {@link PermissionlessPrices} */
68
+ declare const pricesSchema: z.ZodObject<{
69
+ prices: z.ZodType<Record<`0x${string}`, string | null>, unknown, z.core.$ZodTypeInternals<Record<`0x${string}`, string | null>, unknown>>;
70
+ marketCaps: z.ZodType<Record<`0x${string}`, Record<`0x${string}`, string | null>>, unknown, z.core.$ZodTypeInternals<Record<`0x${string}`, Record<`0x${string}`, string | null>>, unknown>>;
71
+ time: z.ZodNumber;
72
+ }, z.core.$loose>;
73
+ //#endregion
74
+ export { assetSchema, priceFeedSchema, priceFeedStoreSchema, pricesSchema };
@@ -0,0 +1,51 @@
1
+ import { PriceFeed } from "../../core/pricefeed.js";
2
+ import "../../core/index.js";
3
+ import { Address } from "viem";
4
+ //#region src/permissionless/api/oracles/types.d.ts
5
+ /**
6
+ * One asset of a chain, with the feeds allowed for it. The backend indexes
7
+ * the chain, so every feed listed here is one the PriceFeedStore carries and
8
+ * allows for the asset.
9
+ **/
10
+ interface PermissionlessAsset {
11
+ address: Address;
12
+ symbol: string;
13
+ name: string;
14
+ decimals: number;
15
+ owner: Address;
16
+ priceFeeds: PriceFeed[];
17
+ }
18
+ /**
19
+ * The PriceFeedStore of one chain as the backend has indexed it: the assets
20
+ * it prices, the feeds it carries, and which feed is allowed on which asset.
21
+ **/
22
+ interface PermissionlessPriceFeedStore {
23
+ chainId: number;
24
+ name: string;
25
+ isPublic: boolean;
26
+ isActivated: boolean;
27
+ explorerUrl: string;
28
+ assets: PermissionlessAsset[];
29
+ priceFeeds: PriceFeed[];
30
+ }
31
+ /**
32
+ * A price per feed, and a market cap per feed and the asset it prices.
33
+ * `null` is a price the backend could not read, not a zero.
34
+ **/
35
+ interface PermissionlessPrices {
36
+ prices: Record<Address, string | null>;
37
+ marketCaps: Record<Address, Record<Address, string | null>>;
38
+ time: number;
39
+ }
40
+ /** Args of {@link PermissionlessOracles.getPrices}. */
41
+ interface GetPricesArgs {
42
+ chainId: number;
43
+ /**
44
+ * The feeds to price. Any address answering `latestRoundData` works — the
45
+ * store does not have to carry it, which is the point of reading the chain
46
+ * rather than asking the backend.
47
+ **/
48
+ priceFeeds: Address[];
49
+ }
50
+ //#endregion
51
+ export { GetPricesArgs, PermissionlessAsset, PermissionlessPriceFeedStore, PermissionlessPrices };
@@ -0,0 +1,22 @@
1
+ import { Address } from "viem";
2
+ import { z } from "zod/v4";
3
+ //#region src/permissionless/api/schemas.d.ts
4
+ /**
5
+ * Runtime schemas shared by the {@link GearboxPermissionless} namespaces.
6
+ *
7
+ * Addresses are validated but never rewritten: the backend serves them in the
8
+ * case its database holds, and its payloads key records by address, so
9
+ * checksumming here would silently break a lookup by the key it answered with.
10
+ * A caller that needs one form converts with viem's `getAddress`.
11
+ **/
12
+ /** An address, in whatever case the backend serves it. */
13
+ declare const addressSchema: z.ZodCustom<`0x${string}`, `0x${string}`>;
14
+ /** A `0x`-prefixed hex string, as viem's `Hex`. */
15
+ declare const hexSchema: z.ZodCustom<`0x${string}`, `0x${string}`>;
16
+ /**
17
+ * A record keyed by address. Spelled out here because zod types a record key
18
+ * by the schema's output, which the branded `Address` is not inferred as.
19
+ **/
20
+ declare function addressRecord<V extends z.ZodType>(value: V): z.ZodType<Record<Address, z.output<V>>>;
21
+ //#endregion
22
+ export { addressRecord, addressSchema, hexSchema };
@@ -0,0 +1,68 @@
1
+ import { ChainsNamespace } from "../chains/ChainsNamespace.js";
2
+ import { PermissionlessOracles } from "../oracles/PermissionlessOracles.js";
3
+ import { InstanceTxs } from "../../utils/governance/types.js";
4
+ import { AddFeedsArgs, ChangeNamesArgs, ChangeStalenessPeriodsArgs, ForbidFeedsArgs, InstanceTxsArgs } from "./types.js";
5
+ //#region src/permissionless/api/transactions/InstanceOwnerTransactions.d.ts
6
+ /**
7
+ * The Safe batches an instance owner executes to apply what a curator
8
+ * prepared: adding their private feeds to the PriceFeedStore, renaming feeds,
9
+ * changing staleness periods, forbidding feeds and refreshing LP bounds.
10
+ *
11
+ * Every batch is wrapped with `wrapConfigureLocal`, so the InstanceManager is
12
+ * the only caller the PriceFeedStore ever sees.
13
+ *
14
+ * Backend-free: a batch is built off the chain it will be executed on, and
15
+ * the store it reads is the one {@link PermissionlessOracles} already
16
+ * fetched. Nothing is sent either — a curator never executes these
17
+ * themselves. They prepare a batch and hand it to the instance owner, who
18
+ * reviews and executes it from their Safe.
19
+ *
20
+ * ```ts
21
+ * const txs = await permissionless.transactions.addFeeds({
22
+ * chainId: 1,
23
+ * owner: curator,
24
+ * feeds: [feed],
25
+ * pairs: [{ asset, priceFeed: feed.address }],
26
+ * });
27
+ * ```
28
+ **/
29
+ declare class InstanceOwnerTransactions {
30
+ #private;
31
+ constructor(chains: ChainsNamespace, oracles: PermissionlessOracles);
32
+ /**
33
+ * The batch that adds the named feeds to the store and allows the named
34
+ * edges on it.
35
+ *
36
+ * Both lists come from the caller. Which feeds are private, and which asset
37
+ * each is meant to price, is held wherever the curator prepared them — the
38
+ * backend indexes the store, so a feed that has not reached it yet is not
39
+ * something this client can discover.
40
+ *
41
+ * Only feeds that actually carry an edge are added: a feed nobody priced
42
+ * would land in the store doing nothing.
43
+ **/
44
+ addFeeds({ chainId, owner, feeds, pairs }: AddFeedsArgs): Promise<InstanceTxs>;
45
+ /**
46
+ * The batch that renames feeds already in the store. A name is part of what
47
+ * the store holds, so changing one is a remove and a fresh add, followed by
48
+ * allowing the feed again on every asset that priced it.
49
+ **/
50
+ changeNames({ chainId, owner, names }: ChangeNamesArgs): Promise<InstanceTxs>;
51
+ /**
52
+ * The batch that changes how long each feed's price stays valid.
53
+ **/
54
+ changeStalenessPeriods({ chainId, owner, periods }: ChangeStalenessPeriodsArgs): Promise<InstanceTxs>;
55
+ /**
56
+ * The batch that forbids feeds on the assets they were allowed for.
57
+ **/
58
+ forbidFeeds({ chainId, owner, tokens }: ForbidFeedsArgs): Promise<InstanceTxs>;
59
+ /**
60
+ * The batch that pulls every drifted LP feed's lower bound back under its
61
+ * exchange rate. Unlike the others this takes no input: the whole store is
62
+ * scanned and only the feeds that drifted produce a transaction, so this
63
+ * one is slow.
64
+ **/
65
+ updateBounds({ chainId, owner }: InstanceTxsArgs): Promise<InstanceTxs>;
66
+ }
67
+ //#endregion
68
+ export { InstanceOwnerTransactions };
@@ -0,0 +1,3 @@
1
+ import { AddFeedsArgs, ChangeNamesArgs, ChangeStalenessPeriodsArgs, ForbidFeedsArgs, InstanceTxsArgs, PriceFeedPair } from "./types.js";
2
+ import { InstanceOwnerTransactions } from "./InstanceOwnerTransactions.js";
3
+ export { AddFeedsArgs, ChangeNamesArgs, ChangeStalenessPeriodsArgs, ForbidFeedsArgs, InstanceOwnerTransactions, InstanceTxsArgs, PriceFeedPair };
@@ -0,0 +1,17 @@
1
+ import { RawTx } from "../../../onchain/types/transactions.js";
2
+ import "../../../onchain/index.js";
3
+ import { Address, PublicClient } from "viem";
4
+ //#region src/permissionless/api/transactions/lp-price-feeds.d.ts
5
+ /**
6
+ * Moves an LP feed's lower bound back under its current exchange rate, when
7
+ * the rate has outgrown the bound or drifted far enough from it to be worth a
8
+ * transaction. Returns nothing when the bound still fits.
9
+ **/
10
+ declare function updateBounds(client: PublicClient, address: Address): Promise<RawTx[]>;
11
+ /**
12
+ * Of the whole feed tree behind `feeds`, the ones that are LP feeds: the
13
+ * probe keeps whatever answers `getLPExchangeRate`.
14
+ **/
15
+ declare function getFeedsToUpdate(client: PublicClient, pfCompressor: Address, feeds: Address[]): Promise<Address[]>;
16
+ //#endregion
17
+ export { getFeedsToUpdate, updateBounds };
@@ -0,0 +1,58 @@
1
+ import { PriceFeed } from "../../core/pricefeed.js";
2
+ import { Address } from "viem";
3
+ //#region src/permissionless/api/transactions/types.d.ts
4
+ /**
5
+ * What every batch of {@link InstanceOwnerTransactions} names.
6
+ *
7
+ * The chain must be one {@link ChainsNamespace} serves a client for: a batch
8
+ * is built off the chain it will be executed on.
9
+ **/
10
+ interface InstanceTxsArgs {
11
+ chainId: number;
12
+ /**
13
+ * Whose rows the batch is built from, and who it records as its author.
14
+ *
15
+ * Required: unlike the backend routes this replaced, nothing here carries
16
+ * an identity of its own, so the caller names the curator whose feeds and
17
+ * connections the batch applies.
18
+ **/
19
+ owner: Address;
20
+ }
21
+ /**
22
+ * One asset-to-feed edge the store has to carry, see
23
+ * {@link AddFeedsArgs.pairs}.
24
+ **/
25
+ interface PriceFeedPair {
26
+ asset: Address;
27
+ priceFeed: Address;
28
+ }
29
+ /** Args of {@link InstanceOwnerTransactions.addFeeds}. */
30
+ interface AddFeedsArgs extends InstanceTxsArgs {
31
+ /**
32
+ * The feeds to put in the store. Only what the store records is read, so a
33
+ * caller holding a whole {@link PriceFeed} passes it unchanged.
34
+ **/
35
+ feeds: Array<Pick<PriceFeed, "address" | "stalenessPeriod" | "name">>;
36
+ /**
37
+ * The edges to allow. Independent of {@link feeds}: an edge may name a feed
38
+ * the store already carries, which is allowed without adding it again.
39
+ **/
40
+ pairs: PriceFeedPair[];
41
+ }
42
+ /** Args of {@link InstanceOwnerTransactions.changeNames}. */
43
+ interface ChangeNamesArgs extends InstanceTxsArgs {
44
+ /** The new name of each feed, keyed by the feed's address. */
45
+ names: Record<Address, string>;
46
+ }
47
+ /** Args of {@link InstanceOwnerTransactions.changeStalenessPeriods}. */
48
+ interface ChangeStalenessPeriodsArgs extends InstanceTxsArgs {
49
+ /** The new staleness period in seconds, keyed by the feed's address. */
50
+ periods: Record<Address, number>;
51
+ }
52
+ /** Args of {@link InstanceOwnerTransactions.forbidFeeds}. */
53
+ interface ForbidFeedsArgs extends InstanceTxsArgs {
54
+ /** The feeds to forbid, keyed by the asset they were allowed for. */
55
+ tokens: Record<Address, Address[]>;
56
+ }
57
+ //#endregion
58
+ export { AddFeedsArgs, ChangeNamesArgs, ChangeStalenessPeriodsArgs, ForbidFeedsArgs, InstanceTxsArgs, PriceFeedPair };
@@ -0,0 +1,12 @@
1
+ import { GearboxAPIOptions } from "../../offchain/types.js";
2
+ //#region src/permissionless/api/types.d.ts
3
+ /**
4
+ * Options for creating a {@link GearboxPermissionless} instance.
5
+ *
6
+ * The same options {@link GearboxAPI} takes, since both clients read the same
7
+ * backend, minus the chains: those the permissionless backend decides, and
8
+ * {@link ChainsNamespace} reads that list and builds the clients from it.
9
+ **/
10
+ type GearboxPermissionlessOptions = Omit<GearboxAPIOptions, "chainIds">;
11
+ //#endregion
12
+ export { GearboxPermissionlessOptions };
@@ -1,5 +1,5 @@
1
- import { AbstractFactory } from "./abstract-factory.js";
2
1
  import { DeployParams, SetExpirationDateParams, SetFeesParams } from "../types.js";
2
+ import { AbstractFactory } from "./abstract-factory.js";
3
3
  import { Address, Hex } from "viem";
4
4
  //#region src/permissionless/bindings/factory/credit-factory.d.ts
5
5
  declare const abi: readonly [{
@@ -1,5 +1,5 @@
1
- import { AbstractFactory } from "./abstract-factory.js";
2
1
  import { AccessMode } from "../types.js";
2
+ import { AbstractFactory } from "./abstract-factory.js";
3
3
  import { Hex } from "viem";
4
4
  //#region src/permissionless/bindings/factory/loss-policy-factory.d.ts
5
5
  declare const abi: readonly [{
@@ -1,5 +1,5 @@
1
- import { AbstractFactory } from "./abstract-factory.js";
2
1
  import { SetTokenQuotaIncreaseFeeParams } from "../types.js";
2
+ import { AbstractFactory } from "./abstract-factory.js";
3
3
  import { Address, Hex } from "viem";
4
4
  //#region src/permissionless/bindings/factory/pool-factory.d.ts
5
5
  declare const abi: readonly [{
@@ -1,5 +1,5 @@
1
- import { AbstractFactory } from "./abstract-factory.js";
2
1
  import { SetPriceFeedParams, SetReservePriceFeedParams } from "../types.js";
2
+ import { AbstractFactory } from "./abstract-factory.js";
3
3
  import { Hex } from "viem";
4
4
  //#region src/permissionless/bindings/factory/price-oracle-factory.d.ts
5
5
  declare const abi: readonly [{
@@ -4,12 +4,12 @@ import { TokenCompressorContract } from "./compressors/token-compressor.js";
4
4
  import { WithdrawalCompressorContract } from "./compressors/withdrawal-compressor.js";
5
5
  import "./compressors/index.js";
6
6
  import { ConstructorParams, CrossChainMultisigContract, Proposal } from "./cross-chain-multisig.js";
7
- import { AccessMode, AddAssetParams, AllowTokenParams, CreditManagerFees, DeployParams, ForbidAdapterParams, ForbidTokenParams, Market, PauseCreditManagerParams, PeripheryDomain, SetExpirationDateParams, SetFeesParams, SetPriceFeedParams, SetReservePriceFeedParams, SetTokenQuotaIncreaseFeeParams, UnpauseCreditManagerParams } from "./types.js";
8
7
  import { QueuedAndExecutedTransaction, SafeBatch, SafeMeta, SafeTx, TimelockTransaction, TimelockTxParams } from "./governance/types.js";
9
8
  import { GovernorContract } from "./governance/governor.js";
10
9
  import { TimeLockContract } from "./governance/timelock.js";
11
10
  import "./governance/index.js";
12
11
  import { InstanceManagerContract } from "./instance-manager.js";
12
+ import { AccessMode, AddAssetParams, AllowTokenParams, CreditManagerFees, DeployParams, ForbidAdapterParams, ForbidTokenParams, Market, PauseCreditManagerParams, PeripheryDomain, SetExpirationDateParams, SetFeesParams, SetPriceFeedParams, SetReservePriceFeedParams, SetTokenQuotaIncreaseFeeParams, UnpauseCreditManagerParams } from "./types.js";
13
13
  import { MarketConfiguratorContract } from "./market-configurator.js";
14
14
  import { MarketConfiguratorFactoryContract } from "./market-configurator-factory.js";
15
15
  import { PriceFeedStoreContract } from "./price-feed-store.js";
@@ -1,7 +1,7 @@
1
1
  import { Auditor } from "./auditor.js";
2
2
  import { AuditEvent, Bytecode, Deployment, DeploymentExtended } from "./bytecode.js";
3
- import { Batch, CrossChainCall, RecoveryMessage, Signature } from "./proposal.js";
4
3
  import { PriceFeed } from "./pricefeed.js";
5
4
  import { InputValueParams, PriceFeedConstructorParam, PriceFeedParamType, PriceFeedParams, PriceFeedSetupParams } from "./pricefeed-builder.js";
5
+ import { Batch, CrossChainCall, RecoveryMessage, Signature } from "./proposal.js";
6
6
  import { createCallData } from "./raw-tx.js";
7
7
  export { AuditEvent, Auditor, Batch, Bytecode, CrossChainCall, Deployment, DeploymentExtended, InputValueParams, PriceFeed, PriceFeedConstructorParam, PriceFeedParamType, PriceFeedParams, PriceFeedSetupParams, RecoveryMessage, Signature, createCallData };
@@ -5,7 +5,6 @@ interface PriceFeed {
5
5
  contractType: string;
6
6
  version: number;
7
7
  deployedBy: Address;
8
- isInStore: boolean;
9
8
  stalenessPeriod: number;
10
9
  name: string;
11
10
  }
@@ -1,42 +1,55 @@
1
- import { AddressProviderContract } from "./bindings/address-provider.js";
1
+ import { GearboxPermissionlessOptions } from "./api/types.js";
2
+ import { AttachChainsArgs, ChainScope, ChainSummaryArgs, PermissionlessChain, PermissionlessChainSummary } from "./api/chains/types.js";
3
+ import { ChainsNamespace } from "./api/chains/ChainsNamespace.js";
2
4
  import { Auditor } from "./core/auditor.js";
3
5
  import { AuditEvent, Bytecode, Deployment, DeploymentExtended } from "./core/bytecode.js";
6
+ import { PriceFeed } from "./core/pricefeed.js";
7
+ import { InputValueParams, PriceFeedConstructorParam, PriceFeedParamType, PriceFeedParams, PriceFeedSetupParams } from "./core/pricefeed-builder.js";
8
+ import { Batch, CrossChainCall, RecoveryMessage, Signature } from "./core/proposal.js";
9
+ import { createCallData } from "./core/raw-tx.js";
10
+ import "./core/index.js";
11
+ import { FunctionParams, ValueParams, encodeFunctionParams } from "./utils/abi-encoder.js";
12
+ import { DeployArgs, DeployContractArgs, DeployPriceFeedArgs, PreparedDeployment, PreparedPriceFeedDeployment } from "./api/deploy/types.js";
13
+ import { DEFAULT_DEPLOY_SALT, PermissionlessDeploy, priceFeedSalt } from "./api/deploy/PermissionlessDeploy.js";
14
+ import { GetPricesArgs, PermissionlessAsset, PermissionlessPriceFeedStore, PermissionlessPrices } from "./api/oracles/types.js";
15
+ import { GET_PRICES_CHUNK_SIZE, GET_PRICES_GAS_LIMIT_BY_CHAIN_ID, PermissionlessOracles } from "./api/oracles/PermissionlessOracles.js";
16
+ import { AddressProviderContract } from "./bindings/address-provider.js";
4
17
  import { BytecodeRepositoryContract } from "./bindings/bytecode-repository.js";
5
18
  import { TokenCompressorContract } from "./bindings/compressors/token-compressor.js";
6
19
  import { WithdrawalCompressorContract } from "./bindings/compressors/withdrawal-compressor.js";
7
- import { Batch, CrossChainCall, RecoveryMessage, Signature } from "./core/proposal.js";
8
20
  import { ConstructorParams, CrossChainMultisigContract, Proposal } from "./bindings/cross-chain-multisig.js";
9
- import { AccessMode, AddAssetParams, AllowTokenParams, CreditManagerFees, DeployParams, ForbidAdapterParams, ForbidTokenParams, Market, PauseCreditManagerParams, PeripheryDomain, SetExpirationDateParams, SetFeesParams, SetPriceFeedParams, SetReservePriceFeedParams, SetTokenQuotaIncreaseFeeParams, UnpauseCreditManagerParams } from "./bindings/types.js";
10
21
  import { QueuedAndExecutedTransaction, SafeBatch, SafeMeta, SafeTx, TimelockTransaction, TimelockTxParams } from "./bindings/governance/types.js";
11
22
  import { GovernorContract } from "./bindings/governance/governor.js";
12
23
  import { TimeLockContract } from "./bindings/governance/timelock.js";
13
24
  import { InstanceManagerContract } from "./bindings/instance-manager.js";
25
+ import { AccessMode, AddAssetParams, AllowTokenParams, CreditManagerFees, DeployParams, ForbidAdapterParams, ForbidTokenParams, Market, PauseCreditManagerParams, PeripheryDomain, SetExpirationDateParams, SetFeesParams, SetPriceFeedParams, SetReservePriceFeedParams, SetTokenQuotaIncreaseFeeParams, UnpauseCreditManagerParams } from "./bindings/types.js";
14
26
  import { MarketConfiguratorContract } from "./bindings/market-configurator.js";
15
27
  import { MarketConfiguratorFactoryContract } from "./bindings/market-configurator-factory.js";
16
- import { PriceFeed } from "./core/pricefeed.js";
17
- import { InputValueParams, PriceFeedConstructorParam, PriceFeedParamType, PriceFeedParams, PriceFeedSetupParams } from "./core/pricefeed-builder.js";
18
- import { createCallData } from "./core/raw-tx.js";
19
- import "./core/index.js";
20
28
  import { PriceFeedStoreContract } from "./bindings/price-feed-store.js";
21
29
  import { priceFeedSetupParams } from "./bindings/pricefeeds/index.js";
22
30
  import { RoutingManagerContract } from "./bindings/router/routing-manager.js";
23
31
  import { TreasurySplitterContract } from "./bindings/treasury-splitter.js";
24
32
  import "./bindings/index.js";
33
+ import { InstanceTxs, TimelockTxs } from "./utils/governance/types.js";
34
+ import { AddFeedsArgs, ChangeNamesArgs, ChangeStalenessPeriodsArgs, ForbidFeedsArgs, InstanceTxsArgs, PriceFeedPair } from "./api/transactions/types.js";
35
+ import { InstanceOwnerTransactions } from "./api/transactions/InstanceOwnerTransactions.js";
36
+ import { GearboxPermissionless } from "./api/GearboxPermissionless.js";
37
+ import { deriveEffectiveStalenessPeriod } from "./api/deploy/effective-staleness.js";
38
+ import { PermissionlessChainUnreachableError, PermissionlessNotAttachedError, PriceFeedNotInStoreError, PriceFeedSaltMissingError, PriceFeedStalenessUnknownError } from "./api/errors.js";
39
+ import "./api/index.js";
25
40
  import { ArchiveTransport, ArchiveTransportConfig } from "./chains/archive-transport.js";
26
41
  import { chunkedLogsTransport } from "./chains/chunked-log-transport.js";
27
42
  import { Addresses } from "./deployment/addresses.js";
28
43
  import { CCMConstructorParams, MAINNET_CCM_CONSTRUCTOR_PARAMS, MAINNET_DEPLOYMENT_BLOCK, MAINNET_DEPLOYMENT_CCM_SALT, MAINNET_DEPLOYMENT_IM_SALT } from "./deployment/mainnet.js";
29
- import { FunctionParams, ValueParams, encodeFunctionParams } from "./utils/abi-encoder.js";
30
44
  import { getBlockNumberByTimestamp } from "./utils/block-utils.js";
31
45
  import { PUBLIC_CREATE2_FACTORY, checkCreate2Deployment, checkCreate2DeploymentAddress, createCreate2DeployRawTx, deployUsingPublicCreate2, getCreate2AddressPublicFactory, getCreate2DeploymentAddress, handleSalt } from "./utils/create2.js";
32
46
  import { convertPercent, deepJsonParse, formatBytecodeSize, formatBytecodeVersion, shortenHash, significantTrunc } from "./utils/format.js";
33
47
  import { calculateChecksum, convertRawTxToSafeMultisigTx, getSafeBatch, getSafeBatches } from "./utils/governance/batch.js";
34
48
  import { convertQueueBatchToExecuteTx } from "./utils/governance/timelock-txs.js";
35
- import { InstanceTxs, TimelockTxs } from "./utils/governance/types.js";
36
49
  import { BYTECODE_REPOSITORY, CROSS_CHAIN_GOVERNANCE, CROSS_CHAIN_MULTISIG, INSTANCE_MANAGER, MARKET_CONFIGURATOR_FACTORY, PRICE_FEED_STORE, TOKEN_COMPRESSOR } from "./utils/literals.js";
37
50
  import { getPriceUpdateTx } from "./utils/price-update/get-price-update-tx.js";
38
51
  import { getPrices } from "./utils/price-update/get-prices.js";
39
52
  import { GetUpdatablePriceFeedsArgs, getUpdatablePriceFeeds } from "./utils/price-update/get-updatable-feeds.js";
40
53
  import { normalizeSignature } from "./utils/signature.js";
41
54
  import "./utils/index.js";
42
- export { AccessMode, AddAssetParams, AddressProviderContract, Addresses, AllowTokenParams, ArchiveTransport, ArchiveTransportConfig, AuditEvent, Auditor, BYTECODE_REPOSITORY, Batch, Bytecode, BytecodeRepositoryContract, CCMConstructorParams, CROSS_CHAIN_GOVERNANCE, CROSS_CHAIN_MULTISIG, ConstructorParams, CreditManagerFees, CrossChainCall, CrossChainMultisigContract, DeployParams, Deployment, DeploymentExtended, ForbidAdapterParams, ForbidTokenParams, FunctionParams, GetUpdatablePriceFeedsArgs, GovernorContract, INSTANCE_MANAGER, InputValueParams, InstanceManagerContract, InstanceTxs, MAINNET_CCM_CONSTRUCTOR_PARAMS, MAINNET_DEPLOYMENT_BLOCK, MAINNET_DEPLOYMENT_CCM_SALT, MAINNET_DEPLOYMENT_IM_SALT, MARKET_CONFIGURATOR_FACTORY, Market, MarketConfiguratorContract, MarketConfiguratorFactoryContract, PRICE_FEED_STORE, PUBLIC_CREATE2_FACTORY, PauseCreditManagerParams, PeripheryDomain, PriceFeed, PriceFeedConstructorParam, PriceFeedParamType, PriceFeedParams, PriceFeedSetupParams, PriceFeedStoreContract, Proposal, QueuedAndExecutedTransaction, RecoveryMessage, RoutingManagerContract, SafeBatch, SafeMeta, SafeTx, SetExpirationDateParams, SetFeesParams, SetPriceFeedParams, SetReservePriceFeedParams, SetTokenQuotaIncreaseFeeParams, Signature, TOKEN_COMPRESSOR, TimeLockContract, TimelockTransaction, TimelockTxParams, TimelockTxs, TokenCompressorContract, TreasurySplitterContract, UnpauseCreditManagerParams, ValueParams, WithdrawalCompressorContract, calculateChecksum, checkCreate2Deployment, checkCreate2DeploymentAddress, chunkedLogsTransport, convertPercent, convertQueueBatchToExecuteTx, convertRawTxToSafeMultisigTx, createCallData, createCreate2DeployRawTx, deepJsonParse, deployUsingPublicCreate2, encodeFunctionParams, formatBytecodeSize, formatBytecodeVersion, getBlockNumberByTimestamp, getCreate2AddressPublicFactory, getCreate2DeploymentAddress, getPriceUpdateTx, getPrices, getSafeBatch, getSafeBatches, getUpdatablePriceFeeds, handleSalt, normalizeSignature, priceFeedSetupParams, shortenHash, significantTrunc };
55
+ export { AccessMode, AddAssetParams, AddFeedsArgs, AddressProviderContract, Addresses, AllowTokenParams, ArchiveTransport, ArchiveTransportConfig, AttachChainsArgs, AuditEvent, Auditor, BYTECODE_REPOSITORY, Batch, Bytecode, BytecodeRepositoryContract, CCMConstructorParams, CROSS_CHAIN_GOVERNANCE, CROSS_CHAIN_MULTISIG, ChainScope, ChainSummaryArgs, ChainsNamespace, ChangeNamesArgs, ChangeStalenessPeriodsArgs, ConstructorParams, CreditManagerFees, CrossChainCall, CrossChainMultisigContract, DEFAULT_DEPLOY_SALT, DeployArgs, DeployContractArgs, DeployParams, DeployPriceFeedArgs, Deployment, DeploymentExtended, ForbidAdapterParams, ForbidFeedsArgs, ForbidTokenParams, FunctionParams, GET_PRICES_CHUNK_SIZE, GET_PRICES_GAS_LIMIT_BY_CHAIN_ID, GearboxPermissionless, GearboxPermissionlessOptions, GetPricesArgs, GetUpdatablePriceFeedsArgs, GovernorContract, INSTANCE_MANAGER, InputValueParams, InstanceManagerContract, InstanceOwnerTransactions, InstanceTxs, InstanceTxsArgs, MAINNET_CCM_CONSTRUCTOR_PARAMS, MAINNET_DEPLOYMENT_BLOCK, MAINNET_DEPLOYMENT_CCM_SALT, MAINNET_DEPLOYMENT_IM_SALT, MARKET_CONFIGURATOR_FACTORY, Market, MarketConfiguratorContract, MarketConfiguratorFactoryContract, PRICE_FEED_STORE, PUBLIC_CREATE2_FACTORY, PauseCreditManagerParams, PeripheryDomain, PermissionlessAsset, PermissionlessChain, PermissionlessChainSummary, PermissionlessChainUnreachableError, PermissionlessDeploy, PermissionlessNotAttachedError, PermissionlessOracles, PermissionlessPriceFeedStore, PermissionlessPrices, PreparedDeployment, PreparedPriceFeedDeployment, PriceFeed, PriceFeedConstructorParam, PriceFeedNotInStoreError, PriceFeedPair, PriceFeedParamType, PriceFeedParams, PriceFeedSaltMissingError, PriceFeedSetupParams, PriceFeedStalenessUnknownError, PriceFeedStoreContract, Proposal, QueuedAndExecutedTransaction, RecoveryMessage, RoutingManagerContract, SafeBatch, SafeMeta, SafeTx, SetExpirationDateParams, SetFeesParams, SetPriceFeedParams, SetReservePriceFeedParams, SetTokenQuotaIncreaseFeeParams, Signature, TOKEN_COMPRESSOR, TimeLockContract, TimelockTransaction, TimelockTxParams, TimelockTxs, TokenCompressorContract, TreasurySplitterContract, UnpauseCreditManagerParams, ValueParams, WithdrawalCompressorContract, calculateChecksum, checkCreate2Deployment, checkCreate2DeploymentAddress, chunkedLogsTransport, convertPercent, convertQueueBatchToExecuteTx, convertRawTxToSafeMultisigTx, createCallData, createCreate2DeployRawTx, deepJsonParse, deployUsingPublicCreate2, deriveEffectiveStalenessPeriod, encodeFunctionParams, formatBytecodeSize, formatBytecodeVersion, getBlockNumberByTimestamp, getCreate2AddressPublicFactory, getCreate2DeploymentAddress, getPriceUpdateTx, getPrices, getSafeBatch, getSafeBatches, getUpdatablePriceFeeds, handleSalt, normalizeSignature, priceFeedSalt, priceFeedSetupParams, shortenHash, significantTrunc };
@@ -1,4 +1,4 @@
1
+ import { InstanceTxs, TimelockTxs } from "./types.js";
1
2
  import { calculateChecksum, convertRawTxToSafeMultisigTx, getSafeBatch, getSafeBatches } from "./batch.js";
2
3
  import { convertQueueBatchToExecuteTx } from "./timelock-txs.js";
3
- import { InstanceTxs, TimelockTxs } from "./types.js";
4
4
  export { InstanceTxs, TimelockTxs, calculateChecksum, convertQueueBatchToExecuteTx, convertRawTxToSafeMultisigTx, getSafeBatch, getSafeBatches };
@@ -1,10 +1,10 @@
1
1
  import { FunctionParams, ValueParams, encodeFunctionParams } from "./abi-encoder.js";
2
+ import { InstanceTxs, TimelockTxs } from "./governance/types.js";
2
3
  import { getBlockNumberByTimestamp } from "./block-utils.js";
3
4
  import { PUBLIC_CREATE2_FACTORY, checkCreate2Deployment, checkCreate2DeploymentAddress, createCreate2DeployRawTx, deployUsingPublicCreate2, getCreate2AddressPublicFactory, getCreate2DeploymentAddress, handleSalt } from "./create2.js";
4
5
  import { convertPercent, deepJsonParse, formatBytecodeSize, formatBytecodeVersion, shortenHash, significantTrunc } from "./format.js";
5
6
  import { calculateChecksum, convertRawTxToSafeMultisigTx, getSafeBatch, getSafeBatches } from "./governance/batch.js";
6
7
  import { convertQueueBatchToExecuteTx } from "./governance/timelock-txs.js";
7
- import { InstanceTxs, TimelockTxs } from "./governance/types.js";
8
8
  import "./governance/index.js";
9
9
  import { BYTECODE_REPOSITORY, CROSS_CHAIN_GOVERNANCE, CROSS_CHAIN_MULTISIG, INSTANCE_MANAGER, MARKET_CONFIGURATOR_FACTORY, PRICE_FEED_STORE, TOKEN_COMPRESSOR } from "./literals.js";
10
10
  import { getPriceUpdateTx } from "./price-update/get-price-update-tx.js";