diff --git a/typescript/sdk/src/core/contracts.ts b/typescript/sdk/src/core/contracts.ts index ddb095ae8..80a6f15e1 100644 --- a/typescript/sdk/src/core/contracts.ts +++ b/typescript/sdk/src/core/contracts.ts @@ -3,8 +3,10 @@ import { XAppConnectionManager__factory, UpgradeBeaconController, UpgradeBeaconController__factory, - ValidatorManager, - ValidatorManager__factory, + OutboxMultisigValidatorManager, + OutboxMultisigValidatorManager__factory, + InboxMultisigValidatorManager, + InboxMultisigValidatorManager__factory, Outbox, Outbox__factory, Inbox, @@ -18,9 +20,10 @@ import { ChainName, ProxiedAddress } from '../types'; export type CoreContractAddresses = { upgradeBeaconController: types.Address; xAppConnectionManager: types.Address; - validatorManager: types.Address; outbox: ProxiedAddress; inboxes: Partial>; + outboxMultisigValidatorManager: types.Address; + inboxMultisigValidatorManagers: Partial>; }; export class CoreContracts extends AbacusAppContracts { @@ -32,6 +35,17 @@ export class CoreContracts extends AbacusAppContracts { return Inbox__factory.connect(inbox.proxy, this.connection); } + inboxMultisigValidatorManager(chain: ChainName): InboxMultisigValidatorManager { + const inboxMultisigValidatorManager = this.addresses.inboxMultisigValidatorManagers[chain]; + if (!inboxMultisigValidatorManager) { + throw new Error(`No inboxMultisigValidatorManager for ${chain}`); + } + return InboxMultisigValidatorManager__factory.connect( + inboxMultisigValidatorManager, + this.connection, + ); + } + get outbox(): Outbox { return Outbox__factory.connect( this.addresses.outbox.proxy, @@ -39,9 +53,9 @@ export class CoreContracts extends AbacusAppContracts { ); } - get validatorManager(): ValidatorManager { - return ValidatorManager__factory.connect( - this.addresses.validatorManager, + get outboxMultisigValidatorManager(): OutboxMultisigValidatorManager { + return OutboxMultisigValidatorManager__factory.connect( + this.addresses.outboxMultisigValidatorManager, this.connection, ); }