Easy on-chain Oracles

Synthetix SIP-120 required the development of easily integratable on-chain oracles;

With the advent of Uniswap V3, we have 0 maintenance on-chain TWAP price feeds. The TWAP code however can be tricky to use, to help simplify this, Brett Sun developed on-chain, easy to use oracles;

Contract: 0x0F1f5A87f99f0918e6C81F16E59F3518698221Ff

Solidity Implementation: here

The easiest way to use is to simply call assetToAsset however, this will route through WETH, alternatively, use assetToAssetThruRoute, which specifies a non default route.

Further to the above, a multiprice-oracle was also developed;

Contract: 0x1f53a354b726Dcd1FC8053182a46dE6b9995740F

Usage of the multiprice oracle will provide feeds from uniswap v3 twap, v3 spot, v2 spot, sushi spot, and chainlink, and currently being deployed to support Band Protocol.

Hopefully this makes querying on-chain price feeds easier for teams.