Importing contracts and interfaces
There are 3 different GearboxV3 repositories that can be useful to integrators.
core-v3 (opens in a new tab) is a repository that holds important system contracts (such as
BotListV3, etc.), pool contracts (
GaugeV3), and, most importantly. credit contracts such as
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.
core-v3 package that contains all contracts and interfaces can be installed using
npm install @gearbox-protocol/core-v3;
yarn add @gearbox-protocol/core-v3;
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.
integrations-v3 package that contains all contracts and interfaces can be installed using
npm install @gearbox-protocol/integrations-v3;
yarn add @gearbox-protocol/integrations-v3;
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 install @gearbox-protocol/periphery-v3;
yarn add @gearbox-protocol/periphery-v3;