Importing contracts and interfaces
There are 3 different GearboxV3 repositories that can be useful to integrators.
Core contracts
core-v3
(opens in a new tab) is a repository that holds important system contracts (such as AccountFactory
, BotListV3
, etc.), pool contracts (PoolV3
, PoolQuotaKeeperV3
, GaugeV3
), and, most importantly. credit contracts such as CreditManagerV3
, CreditFacadeV3
and CreditAccountV3
.
One of the most important interfaces in this repository is ICreditFacadeV3Multicall
(opens in a new tab). It holds the function signatures that need to be encoded in Credit Facade multicalls to manage the account.
The core-v3
package that contains all contracts and interfaces can be installed using npm
or yarn
:
npm install @gearbox-protocol/core-v3
;yarn add @gearbox-protocol/core-v3
;
Integrations contracts
integrations-v3
(opens in a new tab) contains GearboxV3 adapters to external protocols and various pool zappers. Adapter contracts (opens in a new tab) and interfaces (opens in a new tab) are the most important, since they are used to encode external operations in a multicall.
The integrations-v3
package that contains all contracts and interfaces can be installed using npm
or yarn
:
npm install @gearbox-protocol/integrations-v3
;yarn add @gearbox-protocol/integrations-v3
;
Periphery contracts
periphery-v3
(opens in a new tab) contains various helper contracts for data collections. The particularly useful one is DataCompressor_3_0
(opens in a new tab), which can be used to retrieve data on all Credit Accounts and Credit Managers with a small number of static calls.
periphery-v3
can be installed using npm
or yarn
:
npm install @gearbox-protocol/periphery-v3
;yarn add @gearbox-protocol/periphery-v3
;