This tutorial guides you through fetching oracle prices in a WasmVM on Minitia environment utilizing stargate query. By following this tutorial, developers can understand how to integrate and retrieve real-time financial data within their smart contracts on the Minitia blockchain.
Using thewasm-slinky-query repository, you can fetch oracle prices through a CosmWasm contract.
In this section, we'll provide an example contract and show how to deploy it so that you can call stargate query or directly implement it in your contract.
Get All Currency Pairs
Function to fetch all currency pairs available from the oracle.
This contract provides a foundation for integrating real-time oracle data into your blockchain applications, leveraging Cosmos-based oracles within an WasmVM context. It's suitable for financial applications requiring access to up-to-date currency prices and can be expanded or modified to fit specific requirements or additional functionalities.