smartcontractkit / hardhat-starter-kit

A repo for boilerplate code for testing, deploying, and shipping chainlink solidity code.
MIT License
1.22k stars 492 forks source link

Add examples for Any API Large and Multi-word responses #78

Open mhpaler opened 2 years ago

mhpaler commented 2 years ago

In addition to the standard GET request for Chainlink Connect to any API, Chainlink also supports multi-variable and large (bytes or string > 32bytes) responses.

On first glance it appears that executing these examples in hardhat-starter-kit will require a adjustment to, or the addition of a second MockOracle.

andrejrakic commented 2 years ago

Excellent idea, @mpaler. Thanks for raising this issue!

mhpaler commented 2 years ago

Taking a crack at it now...

Appears to be an issue over in core Chainlink too? not finding any test examples over there (yet) that we can pull from...

There is this https://github.com/smartcontractkit/chainlink/issues/5639 which seems related as i believe we'll need to create an Operator mock, vs. the current Oracle mock.

kevin3010 commented 2 years ago

Will this work ?

Action Steps

andrejrakic commented 2 years ago

Hey @kevin3010, that sounds like a great plan. If you are going to open a PR, feel free to use examples from the official documentation as inspiration. Looking forward to it!

kevin3010 commented 2 years ago

ok I'll work on this issue.