• getOracle is a utility that will retrieve the contract address for a price oracle for the specified token in the specified network. The easiest way to use this function is to just pass your web3 instance to the function, and the function will query the web3 instance to see what network it is currently using. You can also just pass in the network name. Please omit the ".CPXD" suffix in the token name that you provide.

    Example

    let daiOracle = await getOracle("DAI", web3);
    let cardOracle = await getOracle("CARD", web3);

    Parameters

    • tokenName: string
    • web3: default

    Returns Promise<string>

Generated using TypeDoc