1

I want a very simple example, maybe a function in a solidity contract that returns any value from an off-chain data source. Basically, I'm asking how to incorporate oracles into a contract, because I cannot for the life of me figure out how. I've downloaded Truffle, Ganache, Web3, etc. What environment should I be doing this all in? Is there a way to write JavaScript code in Remix? If not, where do I write my off-chain code and how do I integrate it with my contract I wrote in Remix?

Edit: I want some way to get off chain data into a smart contract. I'll deal with getting a reliable data source later, but I want to know how to get up an environment where I can code in that can send data to a blockchain.

1 Answer 1

0

You can take a look at this on how to incorporate Oracles such as Chainlink and Amberdata into smart contracts in Remix:

https://medium.com/amberdata/the-definitive-guide-to-successfully-integrating-off-chain-data-into-your-ethereum-smart-contract-ec81d95ea441

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.