@morpho-org/blue-sdk 5.19.0 → 5.21.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.
@@ -357,17 +357,18 @@ declare const _addressesRegistry: {
357
357
  readonly wNative: "0xEa237441c92CAe6FC17Caaf9a7acB3f953be4bd1";
358
358
  };
359
359
  readonly 123420001114: {
360
- readonly morpho: "0xc7CAd9B1377Eb8103397Cb07Cb5c4f03eb2eBEa8";
360
+ readonly morpho: "0xea4f2979D7A99B40404b447Cf71c008e3805760F";
361
361
  readonly bundler3: {
362
- readonly bundler3: "0xc1A86b3a552C5a34e1ecc910341A64Cc89b2CB01";
363
- readonly generalAdapter1: "0x86eaf48Fd73c1Aa30E801D01d0efFd731c3E5E85";
362
+ readonly bundler3: "0x88A4038BB4A14ecD7301c8Fb1f1e8732c4355D53";
363
+ readonly generalAdapter1: "0x29dcA26F9862CFb8064163ddc3401aaB4D4D05c6";
364
364
  };
365
- readonly adaptiveCurveIrm: "0xeEccdD33c0C06d7DDa31E3C4a1Cdb35a2A756246";
366
- readonly publicAllocator: "0x1e145648DA9aC9d831B4F7931C06e9828083BD40";
367
- readonly metaMorphoFactory: "0xa8CD521d42b716821D7ddD2Ca6a237087aA5b487";
368
- readonly chainlinkOracleFactory: "0x24Bc64f44B429EEA86c8B1f9C03F54Ab0C6c0C15";
369
- readonly preLiquidationFactory: "0x6C0155CC30f760DC49138B389F5B69F56eD08841";
370
- readonly wNative: "0x1aE9c40eCd2DD6ad5858E5430A556d7aff28A44b";
365
+ readonly adaptiveCurveIrm: "0xd5661D965cc60ed1954d4f6725b766051De3ef97";
366
+ readonly publicAllocator: "0x0b7a3A49dafd98363B428cEC966106f29c0eee75";
367
+ readonly metaMorphoFactory: "0x3F4b9246b7Cd3F7671c70BeBd5AAFC08e5bb5f16";
368
+ readonly chainlinkOracleFactory: "0x391A3fd481743FE48409e2e31eDac8a5f4C7653A";
369
+ readonly preLiquidationFactory: "0xD55fA5DF6F1A21C2B93009A702aad3a0891C1B48";
370
+ readonly wNative: "0x3bd5C81a8Adf3355078Dc5F73c41d3194B316690";
371
+ readonly usdc: "0x8a2B28364102Bea189D99A475C494330Ef2bDD0B";
371
372
  };
372
373
  readonly 747474: {
373
374
  readonly morpho: "0xD50F2DffFd62f94Ee4AEd9ca05C61d0753268aBc";
@@ -874,16 +875,16 @@ declare const _deployments: {
874
875
  readonly preLiquidationFactory: 789925n;
875
876
  };
876
877
  readonly 123420001114: {
877
- readonly morpho: 4804080n;
878
+ readonly morpho: 2410315n;
878
879
  readonly bundler3: {
879
- readonly bundler3: 4804690n;
880
- readonly generalAdapter1: 4804690n;
880
+ readonly bundler3: 2471517n;
881
+ readonly generalAdapter1: 2471517n;
881
882
  };
882
- readonly adaptiveCurveIrm: 4804080n;
883
- readonly publicAllocator: 4804080n;
884
- readonly metaMorphoFactory: 4804270n;
885
- readonly chainlinkOracleFactory: 4804270n;
886
- readonly preLiquidationFactory: 4804690n;
883
+ readonly adaptiveCurveIrm: 2410315n;
884
+ readonly publicAllocator: 2410315n;
885
+ readonly metaMorphoFactory: 2410440n;
886
+ readonly chainlinkOracleFactory: 2410440n;
887
+ readonly preLiquidationFactory: 2471517n;
887
888
  };
888
889
  readonly 747474: {
889
890
  readonly morpho: 2741069n;
@@ -1450,17 +1451,18 @@ export declare let addressesRegistry: {
1450
1451
  readonly wNative: "0xEa237441c92CAe6FC17Caaf9a7acB3f953be4bd1";
1451
1452
  };
1452
1453
  readonly 123420001114: {
1453
- readonly morpho: "0xc7CAd9B1377Eb8103397Cb07Cb5c4f03eb2eBEa8";
1454
+ readonly morpho: "0xea4f2979D7A99B40404b447Cf71c008e3805760F";
1454
1455
  readonly bundler3: {
1455
- readonly bundler3: "0xc1A86b3a552C5a34e1ecc910341A64Cc89b2CB01";
1456
- readonly generalAdapter1: "0x86eaf48Fd73c1Aa30E801D01d0efFd731c3E5E85";
1456
+ readonly bundler3: "0x88A4038BB4A14ecD7301c8Fb1f1e8732c4355D53";
1457
+ readonly generalAdapter1: "0x29dcA26F9862CFb8064163ddc3401aaB4D4D05c6";
1457
1458
  };
1458
- readonly adaptiveCurveIrm: "0xeEccdD33c0C06d7DDa31E3C4a1Cdb35a2A756246";
1459
- readonly publicAllocator: "0x1e145648DA9aC9d831B4F7931C06e9828083BD40";
1460
- readonly metaMorphoFactory: "0xa8CD521d42b716821D7ddD2Ca6a237087aA5b487";
1461
- readonly chainlinkOracleFactory: "0x24Bc64f44B429EEA86c8B1f9C03F54Ab0C6c0C15";
1462
- readonly preLiquidationFactory: "0x6C0155CC30f760DC49138B389F5B69F56eD08841";
1463
- readonly wNative: "0x1aE9c40eCd2DD6ad5858E5430A556d7aff28A44b";
1459
+ readonly adaptiveCurveIrm: "0xd5661D965cc60ed1954d4f6725b766051De3ef97";
1460
+ readonly publicAllocator: "0x0b7a3A49dafd98363B428cEC966106f29c0eee75";
1461
+ readonly metaMorphoFactory: "0x3F4b9246b7Cd3F7671c70BeBd5AAFC08e5bb5f16";
1462
+ readonly chainlinkOracleFactory: "0x391A3fd481743FE48409e2e31eDac8a5f4C7653A";
1463
+ readonly preLiquidationFactory: "0xD55fA5DF6F1A21C2B93009A702aad3a0891C1B48";
1464
+ readonly wNative: "0x3bd5C81a8Adf3355078Dc5F73c41d3194B316690";
1465
+ readonly usdc: "0x8a2B28364102Bea189D99A475C494330Ef2bDD0B";
1464
1466
  };
1465
1467
  readonly 747474: {
1466
1468
  readonly morpho: "0xD50F2DffFd62f94Ee4AEd9ca05C61d0753268aBc";
@@ -1965,16 +1967,16 @@ export declare let deployments: {
1965
1967
  readonly preLiquidationFactory: 789925n;
1966
1968
  };
1967
1969
  readonly 123420001114: {
1968
- readonly morpho: 4804080n;
1970
+ readonly morpho: 2410315n;
1969
1971
  readonly bundler3: {
1970
- readonly bundler3: 4804690n;
1971
- readonly generalAdapter1: 4804690n;
1972
+ readonly bundler3: 2471517n;
1973
+ readonly generalAdapter1: 2471517n;
1972
1974
  };
1973
- readonly adaptiveCurveIrm: 4804080n;
1974
- readonly publicAllocator: 4804080n;
1975
- readonly metaMorphoFactory: 4804270n;
1976
- readonly chainlinkOracleFactory: 4804270n;
1977
- readonly preLiquidationFactory: 4804690n;
1975
+ readonly adaptiveCurveIrm: 2410315n;
1976
+ readonly publicAllocator: 2410315n;
1977
+ readonly metaMorphoFactory: 2410440n;
1978
+ readonly chainlinkOracleFactory: 2410440n;
1979
+ readonly preLiquidationFactory: 2471517n;
1978
1980
  };
1979
1981
  readonly 747474: {
1980
1982
  readonly morpho: 2741069n;
@@ -342,17 +342,19 @@ const _addressesRegistry = {
342
342
  wNative: "0xEa237441c92CAe6FC17Caaf9a7acB3f953be4bd1",
343
343
  },
344
344
  [chain_js_1.ChainId.CampMainnet]: {
345
- morpho: "0xc7CAd9B1377Eb8103397Cb07Cb5c4f03eb2eBEa8",
345
+ morpho: "0xea4f2979D7A99B40404b447Cf71c008e3805760F",
346
346
  bundler3: {
347
- bundler3: "0xc1A86b3a552C5a34e1ecc910341A64Cc89b2CB01",
348
- generalAdapter1: "0x86eaf48Fd73c1Aa30E801D01d0efFd731c3E5E85",
347
+ bundler3: "0x88A4038BB4A14ecD7301c8Fb1f1e8732c4355D53",
348
+ generalAdapter1: "0x29dcA26F9862CFb8064163ddc3401aaB4D4D05c6",
349
349
  },
350
- adaptiveCurveIrm: "0xeEccdD33c0C06d7DDa31E3C4a1Cdb35a2A756246",
351
- publicAllocator: "0x1e145648DA9aC9d831B4F7931C06e9828083BD40",
352
- metaMorphoFactory: "0xa8CD521d42b716821D7ddD2Ca6a237087aA5b487",
353
- chainlinkOracleFactory: "0x24Bc64f44B429EEA86c8B1f9C03F54Ab0C6c0C15",
354
- preLiquidationFactory: "0x6C0155CC30f760DC49138B389F5B69F56eD08841",
355
- wNative: "0x1aE9c40eCd2DD6ad5858E5430A556d7aff28A44b",
350
+ adaptiveCurveIrm: "0xd5661D965cc60ed1954d4f6725b766051De3ef97",
351
+ publicAllocator: "0x0b7a3A49dafd98363B428cEC966106f29c0eee75",
352
+ metaMorphoFactory: "0x3F4b9246b7Cd3F7671c70BeBd5AAFC08e5bb5f16",
353
+ chainlinkOracleFactory: "0x391A3fd481743FE48409e2e31eDac8a5f4C7653A",
354
+ preLiquidationFactory: "0xD55fA5DF6F1A21C2B93009A702aad3a0891C1B48",
355
+ wNative: "0x3bd5C81a8Adf3355078Dc5F73c41d3194B316690",
356
+ // Must implement USDC permit version 2 (otherwise breaks permit signatures).
357
+ usdc: "0x8a2B28364102Bea189D99A475C494330Ef2bDD0B",
356
358
  },
357
359
  [chain_js_1.ChainId.KatanaMainnet]: {
358
360
  morpho: "0xD50F2DffFd62f94Ee4AEd9ca05C61d0753268aBc",
@@ -863,16 +865,16 @@ const _deployments = {
863
865
  preLiquidationFactory: 789925n,
864
866
  },
865
867
  [chain_js_1.ChainId.CampMainnet]: {
866
- morpho: 4804080n,
868
+ morpho: 2410315n,
867
869
  bundler3: {
868
- bundler3: 4804690n,
869
- generalAdapter1: 4804690n,
870
+ bundler3: 2471517n,
871
+ generalAdapter1: 2471517n,
870
872
  },
871
- adaptiveCurveIrm: 4804080n,
872
- publicAllocator: 4804080n,
873
- metaMorphoFactory: 4804270n,
874
- chainlinkOracleFactory: 4804270n,
875
- preLiquidationFactory: 4804690n,
873
+ adaptiveCurveIrm: 2410315n,
874
+ publicAllocator: 2410315n,
875
+ metaMorphoFactory: 2410440n,
876
+ chainlinkOracleFactory: 2410440n,
877
+ preLiquidationFactory: 2471517n,
876
878
  },
877
879
  [chain_js_1.ChainId.KatanaMainnet]: {
878
880
  morpho: 2741069n,
@@ -2,17 +2,19 @@ import type { Address, Hash, Hex } from "viem";
2
2
  import type { BigIntish } from "../../types.js";
3
3
  import type { CapacityLimit } from "../../utils.js";
4
4
  export interface IVaultV2Adapter {
5
+ type: string;
5
6
  address: Address;
6
7
  parentVault: Address;
7
8
  adapterId: Hash;
8
9
  skimRecipient: Address;
9
10
  }
10
11
  export declare abstract class VaultV2Adapter implements IVaultV2Adapter {
12
+ readonly type: string;
11
13
  readonly address: Address;
12
14
  readonly parentVault: Address;
13
15
  readonly adapterId: Hash;
14
16
  skimRecipient: Address;
15
- constructor({ address, parentVault, adapterId, skimRecipient, }: IVaultV2Adapter);
17
+ constructor({ type, address, parentVault, adapterId, skimRecipient, }: IVaultV2Adapter);
16
18
  }
17
19
  export interface IAccrualVaultV2Adapter extends IVaultV2Adapter {
18
20
  realAssets(timestamp: BigIntish): bigint;
@@ -2,11 +2,13 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VaultV2Adapter = void 0;
4
4
  class VaultV2Adapter {
5
+ type;
5
6
  address;
6
7
  parentVault;
7
8
  adapterId;
8
9
  skimRecipient;
9
- constructor({ address, parentVault, adapterId, skimRecipient, }) {
10
+ constructor({ type, address, parentVault, adapterId, skimRecipient, }) {
11
+ this.type = type;
10
12
  this.address = address;
11
13
  this.parentVault = parentVault;
12
14
  this.adapterId = adapterId;
@@ -5,10 +5,12 @@ import type { BigIntish } from "../../types.js";
5
5
  import { CapacityLimitReason } from "../../utils.js";
6
6
  import { VaultV2Adapter } from "./VaultV2Adapter.js";
7
7
  import type { IAccrualVaultV2Adapter, IVaultV2Adapter } from "./VaultV2Adapter.js";
8
- export interface IVaultV2MorphoMarketV1Adapter extends Omit<IVaultV2Adapter, "adapterId"> {
8
+ export interface IVaultV2MorphoMarketV1Adapter extends Omit<IVaultV2Adapter, "adapterId" | "type"> {
9
+ type?: "VaultV2MorphoMarketV1Adapter";
9
10
  marketParamsList: IMarketParams[];
10
11
  }
11
12
  export declare class VaultV2MorphoMarketV1Adapter extends VaultV2Adapter implements IVaultV2MorphoMarketV1Adapter {
13
+ readonly type: "VaultV2MorphoMarketV1Adapter";
12
14
  static adapterId(address: Address): `0x${string}`;
13
15
  static collateralId(address: Address): `0x${string}`;
14
16
  static marketParamsId(address: Address, params: MarketParams): `0x${string}`;
@@ -19,6 +19,7 @@ class VaultV2MorphoMarketV1Adapter extends VaultV2Adapter_js_1.VaultV2Adapter {
19
19
  constructor({ marketParamsList, ...vaultV2Adapter }) {
20
20
  super({
21
21
  ...vaultV2Adapter,
22
+ type: "VaultV2MorphoMarketV1Adapter",
22
23
  adapterId: VaultV2MorphoMarketV1Adapter.adapterId(vaultV2Adapter.address),
23
24
  });
24
25
  this.marketParamsList = marketParamsList.map((params) => new index_js_1.MarketParams(params));
@@ -4,12 +4,14 @@ import type { BigIntish, MarketId } from "../../types.js";
4
4
  import { CapacityLimitReason } from "../../utils.js";
5
5
  import { VaultV2Adapter } from "./VaultV2Adapter.js";
6
6
  import type { IAccrualVaultV2Adapter, IVaultV2Adapter } from "./VaultV2Adapter.js";
7
- export interface IVaultV2MorphoMarketV1AdapterV2 extends Omit<IVaultV2Adapter, "adapterId"> {
7
+ export interface IVaultV2MorphoMarketV1AdapterV2 extends Omit<IVaultV2Adapter, "adapterId" | "type"> {
8
+ type?: "VaultV2MorphoMarketV1AdapterV2";
8
9
  marketIds: MarketId[];
9
10
  adaptiveCurveIrm: Address;
10
11
  supplyShares: Record<MarketId, bigint>;
11
12
  }
12
13
  export declare class VaultV2MorphoMarketV1AdapterV2 extends VaultV2Adapter implements IVaultV2MorphoMarketV1AdapterV2 {
14
+ readonly type: "VaultV2MorphoMarketV1AdapterV2";
13
15
  static adapterId(address: Address): `0x${string}`;
14
16
  static collateralId(address: Address): `0x${string}`;
15
17
  static marketParamsId(address: Address, params: MarketParams): `0x${string}`;
@@ -21,6 +21,7 @@ class VaultV2MorphoMarketV1AdapterV2 extends VaultV2Adapter_js_1.VaultV2Adapter
21
21
  constructor({ marketIds, adaptiveCurveIrm, supplyShares, ...vaultV2Adapter }) {
22
22
  super({
23
23
  ...vaultV2Adapter,
24
+ type: "VaultV2MorphoMarketV1AdapterV2",
24
25
  adapterId: VaultV2MorphoMarketV1AdapterV2.adapterId(vaultV2Adapter.address),
25
26
  });
26
27
  this.marketIds = marketIds;
@@ -1,12 +1,14 @@
1
1
  import { type Address, type Hex } from "viem";
2
2
  import { VaultV2Adapter } from "./VaultV2Adapter.js";
3
- export interface IVaultV2MorphoVaultV1Adapter extends Omit<IVaultV2Adapter, "adapterId"> {
3
+ export interface IVaultV2MorphoVaultV1Adapter extends Omit<IVaultV2Adapter, "adapterId" | "type"> {
4
+ type?: "VaultV2MorphoVaultV1Adapter";
4
5
  morphoVaultV1: Address;
5
6
  }
6
7
  import type { BigIntish } from "../../types.js";
7
8
  import type { AccrualVault } from "../Vault.js";
8
9
  import type { IAccrualVaultV2Adapter, IVaultV2Adapter } from "./VaultV2Adapter.js";
9
10
  export declare class VaultV2MorphoVaultV1Adapter extends VaultV2Adapter implements IVaultV2MorphoVaultV1Adapter {
11
+ readonly type: "VaultV2MorphoVaultV1Adapter";
10
12
  static adapterId(address: Address): `0x${string}`;
11
13
  readonly morphoVaultV1: Address;
12
14
  constructor({ morphoVaultV1, ...vaultV2Adapter }: IVaultV2MorphoVaultV1Adapter);
@@ -11,6 +11,7 @@ class VaultV2MorphoVaultV1Adapter extends VaultV2Adapter_js_1.VaultV2Adapter {
11
11
  constructor({ morphoVaultV1, ...vaultV2Adapter }) {
12
12
  super({
13
13
  ...vaultV2Adapter,
14
+ type: "VaultV2MorphoVaultV1Adapter",
14
15
  adapterId: VaultV2MorphoVaultV1Adapter.adapterId(vaultV2Adapter.address),
15
16
  });
16
17
  this.morphoVaultV1 = morphoVaultV1;
@@ -357,17 +357,18 @@ declare const _addressesRegistry: {
357
357
  readonly wNative: "0xEa237441c92CAe6FC17Caaf9a7acB3f953be4bd1";
358
358
  };
359
359
  readonly 123420001114: {
360
- readonly morpho: "0xc7CAd9B1377Eb8103397Cb07Cb5c4f03eb2eBEa8";
360
+ readonly morpho: "0xea4f2979D7A99B40404b447Cf71c008e3805760F";
361
361
  readonly bundler3: {
362
- readonly bundler3: "0xc1A86b3a552C5a34e1ecc910341A64Cc89b2CB01";
363
- readonly generalAdapter1: "0x86eaf48Fd73c1Aa30E801D01d0efFd731c3E5E85";
362
+ readonly bundler3: "0x88A4038BB4A14ecD7301c8Fb1f1e8732c4355D53";
363
+ readonly generalAdapter1: "0x29dcA26F9862CFb8064163ddc3401aaB4D4D05c6";
364
364
  };
365
- readonly adaptiveCurveIrm: "0xeEccdD33c0C06d7DDa31E3C4a1Cdb35a2A756246";
366
- readonly publicAllocator: "0x1e145648DA9aC9d831B4F7931C06e9828083BD40";
367
- readonly metaMorphoFactory: "0xa8CD521d42b716821D7ddD2Ca6a237087aA5b487";
368
- readonly chainlinkOracleFactory: "0x24Bc64f44B429EEA86c8B1f9C03F54Ab0C6c0C15";
369
- readonly preLiquidationFactory: "0x6C0155CC30f760DC49138B389F5B69F56eD08841";
370
- readonly wNative: "0x1aE9c40eCd2DD6ad5858E5430A556d7aff28A44b";
365
+ readonly adaptiveCurveIrm: "0xd5661D965cc60ed1954d4f6725b766051De3ef97";
366
+ readonly publicAllocator: "0x0b7a3A49dafd98363B428cEC966106f29c0eee75";
367
+ readonly metaMorphoFactory: "0x3F4b9246b7Cd3F7671c70BeBd5AAFC08e5bb5f16";
368
+ readonly chainlinkOracleFactory: "0x391A3fd481743FE48409e2e31eDac8a5f4C7653A";
369
+ readonly preLiquidationFactory: "0xD55fA5DF6F1A21C2B93009A702aad3a0891C1B48";
370
+ readonly wNative: "0x3bd5C81a8Adf3355078Dc5F73c41d3194B316690";
371
+ readonly usdc: "0x8a2B28364102Bea189D99A475C494330Ef2bDD0B";
371
372
  };
372
373
  readonly 747474: {
373
374
  readonly morpho: "0xD50F2DffFd62f94Ee4AEd9ca05C61d0753268aBc";
@@ -874,16 +875,16 @@ declare const _deployments: {
874
875
  readonly preLiquidationFactory: 789925n;
875
876
  };
876
877
  readonly 123420001114: {
877
- readonly morpho: 4804080n;
878
+ readonly morpho: 2410315n;
878
879
  readonly bundler3: {
879
- readonly bundler3: 4804690n;
880
- readonly generalAdapter1: 4804690n;
880
+ readonly bundler3: 2471517n;
881
+ readonly generalAdapter1: 2471517n;
881
882
  };
882
- readonly adaptiveCurveIrm: 4804080n;
883
- readonly publicAllocator: 4804080n;
884
- readonly metaMorphoFactory: 4804270n;
885
- readonly chainlinkOracleFactory: 4804270n;
886
- readonly preLiquidationFactory: 4804690n;
883
+ readonly adaptiveCurveIrm: 2410315n;
884
+ readonly publicAllocator: 2410315n;
885
+ readonly metaMorphoFactory: 2410440n;
886
+ readonly chainlinkOracleFactory: 2410440n;
887
+ readonly preLiquidationFactory: 2471517n;
887
888
  };
888
889
  readonly 747474: {
889
890
  readonly morpho: 2741069n;
@@ -1450,17 +1451,18 @@ export declare let addressesRegistry: {
1450
1451
  readonly wNative: "0xEa237441c92CAe6FC17Caaf9a7acB3f953be4bd1";
1451
1452
  };
1452
1453
  readonly 123420001114: {
1453
- readonly morpho: "0xc7CAd9B1377Eb8103397Cb07Cb5c4f03eb2eBEa8";
1454
+ readonly morpho: "0xea4f2979D7A99B40404b447Cf71c008e3805760F";
1454
1455
  readonly bundler3: {
1455
- readonly bundler3: "0xc1A86b3a552C5a34e1ecc910341A64Cc89b2CB01";
1456
- readonly generalAdapter1: "0x86eaf48Fd73c1Aa30E801D01d0efFd731c3E5E85";
1456
+ readonly bundler3: "0x88A4038BB4A14ecD7301c8Fb1f1e8732c4355D53";
1457
+ readonly generalAdapter1: "0x29dcA26F9862CFb8064163ddc3401aaB4D4D05c6";
1457
1458
  };
1458
- readonly adaptiveCurveIrm: "0xeEccdD33c0C06d7DDa31E3C4a1Cdb35a2A756246";
1459
- readonly publicAllocator: "0x1e145648DA9aC9d831B4F7931C06e9828083BD40";
1460
- readonly metaMorphoFactory: "0xa8CD521d42b716821D7ddD2Ca6a237087aA5b487";
1461
- readonly chainlinkOracleFactory: "0x24Bc64f44B429EEA86c8B1f9C03F54Ab0C6c0C15";
1462
- readonly preLiquidationFactory: "0x6C0155CC30f760DC49138B389F5B69F56eD08841";
1463
- readonly wNative: "0x1aE9c40eCd2DD6ad5858E5430A556d7aff28A44b";
1459
+ readonly adaptiveCurveIrm: "0xd5661D965cc60ed1954d4f6725b766051De3ef97";
1460
+ readonly publicAllocator: "0x0b7a3A49dafd98363B428cEC966106f29c0eee75";
1461
+ readonly metaMorphoFactory: "0x3F4b9246b7Cd3F7671c70BeBd5AAFC08e5bb5f16";
1462
+ readonly chainlinkOracleFactory: "0x391A3fd481743FE48409e2e31eDac8a5f4C7653A";
1463
+ readonly preLiquidationFactory: "0xD55fA5DF6F1A21C2B93009A702aad3a0891C1B48";
1464
+ readonly wNative: "0x3bd5C81a8Adf3355078Dc5F73c41d3194B316690";
1465
+ readonly usdc: "0x8a2B28364102Bea189D99A475C494330Ef2bDD0B";
1464
1466
  };
1465
1467
  readonly 747474: {
1466
1468
  readonly morpho: "0xD50F2DffFd62f94Ee4AEd9ca05C61d0753268aBc";
@@ -1965,16 +1967,16 @@ export declare let deployments: {
1965
1967
  readonly preLiquidationFactory: 789925n;
1966
1968
  };
1967
1969
  readonly 123420001114: {
1968
- readonly morpho: 4804080n;
1970
+ readonly morpho: 2410315n;
1969
1971
  readonly bundler3: {
1970
- readonly bundler3: 4804690n;
1971
- readonly generalAdapter1: 4804690n;
1972
+ readonly bundler3: 2471517n;
1973
+ readonly generalAdapter1: 2471517n;
1972
1974
  };
1973
- readonly adaptiveCurveIrm: 4804080n;
1974
- readonly publicAllocator: 4804080n;
1975
- readonly metaMorphoFactory: 4804270n;
1976
- readonly chainlinkOracleFactory: 4804270n;
1977
- readonly preLiquidationFactory: 4804690n;
1975
+ readonly adaptiveCurveIrm: 2410315n;
1976
+ readonly publicAllocator: 2410315n;
1977
+ readonly metaMorphoFactory: 2410440n;
1978
+ readonly chainlinkOracleFactory: 2410440n;
1979
+ readonly preLiquidationFactory: 2471517n;
1978
1980
  };
1979
1981
  readonly 747474: {
1980
1982
  readonly morpho: 2741069n;
@@ -334,17 +334,19 @@ const _addressesRegistry = {
334
334
  wNative: "0xEa237441c92CAe6FC17Caaf9a7acB3f953be4bd1",
335
335
  },
336
336
  [ChainId.CampMainnet]: {
337
- morpho: "0xc7CAd9B1377Eb8103397Cb07Cb5c4f03eb2eBEa8",
337
+ morpho: "0xea4f2979D7A99B40404b447Cf71c008e3805760F",
338
338
  bundler3: {
339
- bundler3: "0xc1A86b3a552C5a34e1ecc910341A64Cc89b2CB01",
340
- generalAdapter1: "0x86eaf48Fd73c1Aa30E801D01d0efFd731c3E5E85",
339
+ bundler3: "0x88A4038BB4A14ecD7301c8Fb1f1e8732c4355D53",
340
+ generalAdapter1: "0x29dcA26F9862CFb8064163ddc3401aaB4D4D05c6",
341
341
  },
342
- adaptiveCurveIrm: "0xeEccdD33c0C06d7DDa31E3C4a1Cdb35a2A756246",
343
- publicAllocator: "0x1e145648DA9aC9d831B4F7931C06e9828083BD40",
344
- metaMorphoFactory: "0xa8CD521d42b716821D7ddD2Ca6a237087aA5b487",
345
- chainlinkOracleFactory: "0x24Bc64f44B429EEA86c8B1f9C03F54Ab0C6c0C15",
346
- preLiquidationFactory: "0x6C0155CC30f760DC49138B389F5B69F56eD08841",
347
- wNative: "0x1aE9c40eCd2DD6ad5858E5430A556d7aff28A44b",
342
+ adaptiveCurveIrm: "0xd5661D965cc60ed1954d4f6725b766051De3ef97",
343
+ publicAllocator: "0x0b7a3A49dafd98363B428cEC966106f29c0eee75",
344
+ metaMorphoFactory: "0x3F4b9246b7Cd3F7671c70BeBd5AAFC08e5bb5f16",
345
+ chainlinkOracleFactory: "0x391A3fd481743FE48409e2e31eDac8a5f4C7653A",
346
+ preLiquidationFactory: "0xD55fA5DF6F1A21C2B93009A702aad3a0891C1B48",
347
+ wNative: "0x3bd5C81a8Adf3355078Dc5F73c41d3194B316690",
348
+ // Must implement USDC permit version 2 (otherwise breaks permit signatures).
349
+ usdc: "0x8a2B28364102Bea189D99A475C494330Ef2bDD0B",
348
350
  },
349
351
  [ChainId.KatanaMainnet]: {
350
352
  morpho: "0xD50F2DffFd62f94Ee4AEd9ca05C61d0753268aBc",
@@ -855,16 +857,16 @@ const _deployments = {
855
857
  preLiquidationFactory: 789925n,
856
858
  },
857
859
  [ChainId.CampMainnet]: {
858
- morpho: 4804080n,
860
+ morpho: 2410315n,
859
861
  bundler3: {
860
- bundler3: 4804690n,
861
- generalAdapter1: 4804690n,
862
+ bundler3: 2471517n,
863
+ generalAdapter1: 2471517n,
862
864
  },
863
- adaptiveCurveIrm: 4804080n,
864
- publicAllocator: 4804080n,
865
- metaMorphoFactory: 4804270n,
866
- chainlinkOracleFactory: 4804270n,
867
- preLiquidationFactory: 4804690n,
865
+ adaptiveCurveIrm: 2410315n,
866
+ publicAllocator: 2410315n,
867
+ metaMorphoFactory: 2410440n,
868
+ chainlinkOracleFactory: 2410440n,
869
+ preLiquidationFactory: 2471517n,
868
870
  },
869
871
  [ChainId.KatanaMainnet]: {
870
872
  morpho: 2741069n,
@@ -2,17 +2,19 @@ import type { Address, Hash, Hex } from "viem";
2
2
  import type { BigIntish } from "../../types.js";
3
3
  import type { CapacityLimit } from "../../utils.js";
4
4
  export interface IVaultV2Adapter {
5
+ type: string;
5
6
  address: Address;
6
7
  parentVault: Address;
7
8
  adapterId: Hash;
8
9
  skimRecipient: Address;
9
10
  }
10
11
  export declare abstract class VaultV2Adapter implements IVaultV2Adapter {
12
+ readonly type: string;
11
13
  readonly address: Address;
12
14
  readonly parentVault: Address;
13
15
  readonly adapterId: Hash;
14
16
  skimRecipient: Address;
15
- constructor({ address, parentVault, adapterId, skimRecipient, }: IVaultV2Adapter);
17
+ constructor({ type, address, parentVault, adapterId, skimRecipient, }: IVaultV2Adapter);
16
18
  }
17
19
  export interface IAccrualVaultV2Adapter extends IVaultV2Adapter {
18
20
  realAssets(timestamp: BigIntish): bigint;
@@ -1,9 +1,11 @@
1
1
  export class VaultV2Adapter {
2
+ type;
2
3
  address;
3
4
  parentVault;
4
5
  adapterId;
5
6
  skimRecipient;
6
- constructor({ address, parentVault, adapterId, skimRecipient, }) {
7
+ constructor({ type, address, parentVault, adapterId, skimRecipient, }) {
8
+ this.type = type;
7
9
  this.address = address;
8
10
  this.parentVault = parentVault;
9
11
  this.adapterId = adapterId;
@@ -5,10 +5,12 @@ import type { BigIntish } from "../../types.js";
5
5
  import { CapacityLimitReason } from "../../utils.js";
6
6
  import { VaultV2Adapter } from "./VaultV2Adapter.js";
7
7
  import type { IAccrualVaultV2Adapter, IVaultV2Adapter } from "./VaultV2Adapter.js";
8
- export interface IVaultV2MorphoMarketV1Adapter extends Omit<IVaultV2Adapter, "adapterId"> {
8
+ export interface IVaultV2MorphoMarketV1Adapter extends Omit<IVaultV2Adapter, "adapterId" | "type"> {
9
+ type?: "VaultV2MorphoMarketV1Adapter";
9
10
  marketParamsList: IMarketParams[];
10
11
  }
11
12
  export declare class VaultV2MorphoMarketV1Adapter extends VaultV2Adapter implements IVaultV2MorphoMarketV1Adapter {
13
+ readonly type: "VaultV2MorphoMarketV1Adapter";
12
14
  static adapterId(address: Address): `0x${string}`;
13
15
  static collateralId(address: Address): `0x${string}`;
14
16
  static marketParamsId(address: Address, params: MarketParams): `0x${string}`;
@@ -16,6 +16,7 @@ export class VaultV2MorphoMarketV1Adapter extends VaultV2Adapter {
16
16
  constructor({ marketParamsList, ...vaultV2Adapter }) {
17
17
  super({
18
18
  ...vaultV2Adapter,
19
+ type: "VaultV2MorphoMarketV1Adapter",
19
20
  adapterId: VaultV2MorphoMarketV1Adapter.adapterId(vaultV2Adapter.address),
20
21
  });
21
22
  this.marketParamsList = marketParamsList.map((params) => new MarketParams(params));
@@ -4,12 +4,14 @@ import type { BigIntish, MarketId } from "../../types.js";
4
4
  import { CapacityLimitReason } from "../../utils.js";
5
5
  import { VaultV2Adapter } from "./VaultV2Adapter.js";
6
6
  import type { IAccrualVaultV2Adapter, IVaultV2Adapter } from "./VaultV2Adapter.js";
7
- export interface IVaultV2MorphoMarketV1AdapterV2 extends Omit<IVaultV2Adapter, "adapterId"> {
7
+ export interface IVaultV2MorphoMarketV1AdapterV2 extends Omit<IVaultV2Adapter, "adapterId" | "type"> {
8
+ type?: "VaultV2MorphoMarketV1AdapterV2";
8
9
  marketIds: MarketId[];
9
10
  adaptiveCurveIrm: Address;
10
11
  supplyShares: Record<MarketId, bigint>;
11
12
  }
12
13
  export declare class VaultV2MorphoMarketV1AdapterV2 extends VaultV2Adapter implements IVaultV2MorphoMarketV1AdapterV2 {
14
+ readonly type: "VaultV2MorphoMarketV1AdapterV2";
13
15
  static adapterId(address: Address): `0x${string}`;
14
16
  static collateralId(address: Address): `0x${string}`;
15
17
  static marketParamsId(address: Address, params: MarketParams): `0x${string}`;
@@ -18,6 +18,7 @@ export class VaultV2MorphoMarketV1AdapterV2 extends VaultV2Adapter {
18
18
  constructor({ marketIds, adaptiveCurveIrm, supplyShares, ...vaultV2Adapter }) {
19
19
  super({
20
20
  ...vaultV2Adapter,
21
+ type: "VaultV2MorphoMarketV1AdapterV2",
21
22
  adapterId: VaultV2MorphoMarketV1AdapterV2.adapterId(vaultV2Adapter.address),
22
23
  });
23
24
  this.marketIds = marketIds;
@@ -1,12 +1,14 @@
1
1
  import { type Address, type Hex } from "viem";
2
2
  import { VaultV2Adapter } from "./VaultV2Adapter.js";
3
- export interface IVaultV2MorphoVaultV1Adapter extends Omit<IVaultV2Adapter, "adapterId"> {
3
+ export interface IVaultV2MorphoVaultV1Adapter extends Omit<IVaultV2Adapter, "adapterId" | "type"> {
4
+ type?: "VaultV2MorphoVaultV1Adapter";
4
5
  morphoVaultV1: Address;
5
6
  }
6
7
  import type { BigIntish } from "../../types.js";
7
8
  import type { AccrualVault } from "../Vault.js";
8
9
  import type { IAccrualVaultV2Adapter, IVaultV2Adapter } from "./VaultV2Adapter.js";
9
10
  export declare class VaultV2MorphoVaultV1Adapter extends VaultV2Adapter implements IVaultV2MorphoVaultV1Adapter {
11
+ readonly type: "VaultV2MorphoVaultV1Adapter";
10
12
  static adapterId(address: Address): `0x${string}`;
11
13
  readonly morphoVaultV1: Address;
12
14
  constructor({ morphoVaultV1, ...vaultV2Adapter }: IVaultV2MorphoVaultV1Adapter);
@@ -8,6 +8,7 @@ export class VaultV2MorphoVaultV1Adapter extends VaultV2Adapter {
8
8
  constructor({ morphoVaultV1, ...vaultV2Adapter }) {
9
9
  super({
10
10
  ...vaultV2Adapter,
11
+ type: "VaultV2MorphoVaultV1Adapter",
11
12
  adapterId: VaultV2MorphoVaultV1Adapter.adapterId(vaultV2Adapter.address),
12
13
  });
13
14
  this.morphoVaultV1 = morphoVaultV1;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@morpho-org/blue-sdk",
3
3
  "description": "Framework-agnostic package that defines Morpho-related entity classes (such as `Market`, `Token`, `Vault`).",
4
- "version": "5.19.0",
4
+ "version": "5.21.0",
5
5
  "author": "Morpho Association <contact@morpho.org>",
6
6
  "contributors": [
7
7
  "Rubilmax <rmilon@gmail.com>"