Service for interacting with the eBTC subgraph

Hierarchy

Constructors

Properties

graphClient: undefined | GraphQLClient
graphUrl: undefined | string
level: LogLevel
sdk: eBTC

Accessors

  • get address(): undefined | string
  • Returns undefined | string

  • get connector(): Signer | MulticallProvider
  • Returns Signer | MulticallProvider

  • get provider(): MulticallProvider
  • Returns MulticallProvider

  • get signer(): undefined | Signer
  • Returns undefined | Signer

Methods

  • Parameters

    • level: LogLevel
    • Optional message: any
    • Rest ...optionalParams: any[]

    Returns void

  • Parameters

    • Optional message: any
    • Rest ...optionalParams: any[]

    Returns void

  • Parameters

    • Optional message: any
    • Rest ...optionalParams: any[]

    Returns void

  • This function returns data about how the cdp was opened. By which contract (BorrowerOperations, Zap, etc.) and with what token if not stETH.

    Parameters

    • _cdpId: string

      the id of the cdp

    Returns Promise<OpenCdpData>

    information on how the cdp was opened

  • Returns all Cdps for a borrower

    Parameters

    • _borrower: string

    Returns Promise<Cdp[]>

  • This function returns data about how the multiple cdps were opened. By which contract (BorrowerOperations, Zap, etc.) and with what token if not stETH.

    Parameters

    • _cdpIds: string[]

      the id of the cdps

    Returns Promise<OpenCdpData[]>

    information on how the cdps were opened

  • Returns all closed Cdps for a borrower

    Parameters

    • _borrower: string

      the owner or borrower of the cdps

    • _skip: number = 0

      the number of cdps to skip for a paginated query

    • _first: number = 5

      the number of cdps to return

    Returns Promise<Cdp[]>

    a list of closed cdps

  • Returns the total amount of ETH/WETH used to mint Cdps. Currently doesn't account for closed Cdps.

    Parameters

    • minBlockNumber: string | number
    • maxBlockNumber: string | number

    Returns Promise<{
        count: number;
        total: BigNumber;
        userStake: Map<string, BigNumber>;
    }>

    the amount of eth/weth used to mint cdps

  • Checks if the graph url is set

    Returns boolean

    true if the graph url is set

  • Parameters

    • Optional message: any
    • Rest ...optionalParams: any[]

    Returns void

  • Parameters

    • Optional message: any
    • Rest ...optionalParams: any[]

    Returns void

  • Parameters

    • Optional message: any
    • Rest ...optionalParams: any[]

    Returns void

Generated using TypeDoc