Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jan 11 10:03
    vishnu-rai commented #100
  • Jun 16 2021 21:09
    aelmanaa edited #105
  • Jun 16 2021 21:09
    aelmanaa edited #105
  • Jun 16 2021 09:54
    aelmanaa opened #105
  • Jun 15 2021 10:08
    nft1126 commented #100
  • Jun 15 2021 10:02
    lhoenig commented #100
  • Jun 15 2021 09:58
    nft1126 commented #100
  • Jun 08 2021 15:07
    lhoenig commented #100
  • Jun 08 2021 14:52
    nft1126 commented #100
  • Jun 08 2021 14:34
    lhoenig commented #100
  • Jun 08 2021 14:34
    lhoenig commented #100
  • Jun 08 2021 14:13
    nft1126 commented #100
  • May 13 2021 21:53
    lhoenig commented #100
  • May 13 2021 18:37
    citizen-stig commented #99
  • May 12 2021 14:11
    lhoenig commented #100
  • Apr 02 2021 13:07
    cTatu commented #103
  • Mar 11 2021 09:31
    gskapka commented #78
  • Feb 12 2021 13:08
    ytrezq commented #78
  • Feb 12 2021 02:41
    ytrezq opened #104
  • Feb 09 2021 05:47
    kroos47 commented #103
Oraclize Support
@oraclize-support
@TheCryptoCracks - it can access external APIs so long as you have them available!
14gautam
@14gautam
@oraclize-support, I am trying the example at https://github.com/provable-things/truffle-starter. The test step "Callback should have logged a new ETH price" is failing after waiting for 5 mins. Is this example still valid? Any help with this or any beginner example with truffle will be greatly appreciated. Thank you
sarem eskandary
@saremeskandary
hi. is there api for solidity V8 . if not how can I implement it on V8.4?
Oraclize Support
@oraclize-support
Hi @14gautam - we've just tried that repository and it does appear to have some issues due to older versions of npm plus the ethereum-bridge, so we'll look into that fix. Meanwhile, have you tried our examples that use truffle here: https://github.com/provable-things/ethereum-examples/tree/master/solidity/truffle-examples?
@saremeskandary - the latest version in our repo is for 0.6 and is here: https://github.com/provable-things/ethereum-api/blob/master/provableAPI_0.6.sol. If you need 0.8 we are accepting pull requests as ever, otherwise we will get round to updating it sooner or later.
NFT-C0NTACT
@NC0ntact_twitter
Hey guys I really need some help. I need to get some data from an Array to my Contract through an oracle. So essentially I have a smart contract that needs to get the returned data from the oracle contract, but I cannot figure out how to do this, been struggling with it for a couple of days now :/
Oraclize Support
@oraclize-support
HI @NC0ntact - where do you get your data from? You can call an external API via the provable oracle ala: https://github.com/provable-things/ethereum-examples/blob/master/solidity/KrakenPriceTicker.sol
NFT-C0NTACT
@NC0ntact_twitter
I get my data from my website which is a json file. Or from IPFS no matter, the main problem is getting that data to my real contract and not only on the provable one
Oraclize Support
@oraclize-support
@NC0ntact - "getting that data to my real contract and not only on the provable one" <- can you explain that part a bit more?
NFT-C0NTACT
@NC0ntact_twitter
@oraclize-support sure thing. So I have my smart contract which mints NFTs. When the person hits the mint button, a function will be activated, which creates some attributes for that token, one of them depends on the rarity of this item. The rarity is stored offchain in a json file, an array with 4500 values, each value for each token. Now to get that rarity from the Json File, I need to use an oracle, because I cannot get it in any different way (as far as I know), so I send a oracle which gets the data. Cool the rarity is now stored in the contract that has the oracle function, but I cannot send it automatically to my NFT contract, for it to use that rarity to decide which attribute that token should get
NFT-C0NTACT
@NC0ntact_twitter
@oraclize-support you gave up on me mate? :*)
Oraclize Support
@oraclize-support
@N0contact - once you have the rarity in your oracle contract, you just need your oracle __callback fxn to call a fxn in your NFT contract, passing along that rarity as an argument.
NFT-C0NTACT
@NC0ntact_twitter
@oraclize-support you the king
Beatz 748
@748Beatz_twitter
image.png
@oraclize-support hi, https://gist.github.com/Beatz748/0c721617ce0817224dd523a5440dad5b, my code is not working. In remix ide there is QueryId and no result. This queryId not found in app.provable. What's a problem?
vishnu-rai
@vishnu-rai

@oraclize-support I am trying the code from provable documentation
// SPDX-License-Identifier: GPL-3.0
pragma solidity > 0.6.1 < 0.7.0;
import "github.com/provable-things/ethereum-api/provableAPI_0.6.sol";

contract ExampleContract is usingProvable {

string public ETHUSD;
bytes32 public queryId;
event LogConstructorInitiated(string nextStep);
event LogPriceUpdated(string data,string price);
event LogNewProvableQuery(string description);
event LogCallbackCalled(string data);

constructor() public payable {
provable_setCustomGasPrice(10000000000);
emit LogConstructorInitiated("Constructor was initiated. Call 'updatePrice()' to send the Provable Query.");
}

function __callback(bytes32 myid, string memory result) public override {
emit LogCallbackCalled("Callback called");
if (msg.sender != provable_cbAddress()) revert();
ETHUSD = result;
emit LogPriceUpdated("Update done",result);

}

function updatePrice() public payable {
if (provable_getPrice("URL") > address(this).balance) {
emit LogNewProvableQuery("Provable query was NOT sent, please add some ETH to cover for the query fee");
} else {
emit LogNewProvableQuery("Provable query was sent, standing by for the answer..");
queryId = provable_query("URL", "json(https://api.pro.coinbase.com/products/ETH-USD/ticker).price");
}
}
}

The __callback function is not called on the rinkbey network and the queryId I am getting is showing does not exist on query status search.

vishnu-rai
@vishnu-rai
@oraclize-support can you help me out??
Oraclize Support
@oraclize-support
Hello @748Beatz_twitter is your problem on testnet or mainnet? If it's on testnet can you specify the chain in use?
Hi @vishnu-rai, thanks for reporting the problem, we will check this out, can you please tell us the query id too?
Oraclize Support
@oraclize-support
@748Beatz_twitter - a link to the tx in question is fine too
vishnu-rai
@vishnu-rai
@oraclize-support the queryId is 0x94872ec0963f73898e3b35319ae4390ea18eb03e2dd1246c8d8f3be2f20789ff
Oraclize Support
@oraclize-support
@vishnu-rai - what testnet did you use?
Sorry, seen you post the chain, looking now
Oraclize Support
@oraclize-support
@vishnu-rai - Look that the code you posted is wrong:
function *callback(bytes32 myid, string memory result)
should be
function __callback(bytes32 myid, string memory result)
Pavel
@Beatz748

@oraclize-support i've tried ropsten, kovan and goerli. Also, I verified and published code for ropsten. For more info, I've tried exec test-query on app.provable and get "timed out" after infinite loading.

https://ropsten.etherscan.io/tx/0x94047ac6b2beaa935a7532ee78d74e4299f58162931fe1b099764abcf73b366d
https://kovan.etherscan.io/tx/0xdc387864f34bcc04a6a63898149fbf15837604eaafdf600b1b72837de9be89fb
https://goerli.etherscan.io/tx/0x25d6af208316e8254f56a5bba3dc32615c4bfdd0a168dd50ee1c562a8eb2e541

vishnu-rai
@vishnu-rai

@oraclize-support I have written the same thing which was in the documentation
function __callback(bytes32 myid, string memory result) public override {
emit LogCallbackCalled("Callback called");
if (msg.sender != provable_cbAddress()) revert();
ETHUSD = result;
emit LogPriceUpdated("Update done",result);
}

What's wrong in this code??

Oraclize Support
@oraclize-support
Hi @Beatz748 - we are experiencing issues on testnets netoworks, we will let you know asap when everything is back to normal
vishnu-rai
@vishnu-rai
@oraclize-support Can you tell my fault
@oraclize-support I have tried ropsnet, kovan and rinkbey but same problem. The callback function is not called
Oraclize Support
@oraclize-support
@vishnu-rai - no fault on your side, the problem is with ours, will update you guys when everything is fixed
vishnu-rai
@vishnu-rai
@oraclize-support Thank you
Pavel
@Beatz748
@oraclize-support thank you <3
vishnu-rai
@vishnu-rai
@oraclize-support can you give us a time ??
Oraclize Support
@oraclize-support
@vishnu-rai - we should spin up ropsten within the next hour, for the other will take more time
Oraclize Support
@oraclize-support
@vishnu-rai - ropsten is up, however we need more time to get the random_ds working back again, hopefully withing tomorrow morning everything should be back in place
vishnu-rai
@vishnu-rai
@oraclize-support can I try API call with ropsten?
Oraclize Support
@oraclize-support
yes you can
vishnu-rai
@vishnu-rai
@oraclize-support Thanks .. It's working
Oraclize Support
@oraclize-support
@Beatz748 - random ds has been recovered on ropsten, we will spin back up the service in the other testnets in the next few days. Apologies for the inconvenience
Oraclize Support
@oraclize-support
we are working on a major refactoring of the oracle service as it is being moved on top of the pnetwork v2 :)
vishnu-rai
@vishnu-rai
@oraclize-support is ropsten network again down. same problem happening
Oraclize Support
@oraclize-support
@vishnu-rai may you try again?
Oraclize Support
@oraclize-support
Hello everyone, glad to announce that the service is fully operational on the following testnets:
• ropsten
• rinkeby
• goerli
• kovan
they were subjected to a major update in order to improve stability
Eric DeVito
@EricDevito
Hi devs, does provable work with solidity ^0.8.6 ?
Also, is there any info on how to call a url and fetch multiple values? eg fetching both variables in {var1: 1111, var2: 22222}
And maybe placing __callback in another contract if provable doesn't work with solidity ^0.8.6?
Oraclize Support
@oraclize-support

@EricDevito - The latest version of our API is compatible with 0.5.x.

• As for fetching multiple values, you can either use the computation datasource (which is the most powerful, and flexible way) (example here: https://github.com/provable-things/ethereum-examples/tree/master/solidity/computation-datasource) or, if your multiple results are in the same JSON returned by whatever API you're calling, you can pluck > 1 variables from that json like so:
json(<your-api-endpoint>).[<json-field>].[<key1>,<key2>...]
See the above in action in our query tester here: https://app.provable.xyz/home/test_query#VVJMKEdFVCk=:anNvbihodHRwczovL3d3dy50aGVyb2NrdHJhZGl[…]L3RpY2tlci9CVENFVVIpLnJlc3VsdC4wLltzeW1ib2wsbGFzdF0=

• As for placing the __callback in another contract. You can't do that in order to get a different compiler version, but you can do the equivalent but the other way around. IE, call another contract in your __callback, which other contract could be compiled with a later compiler version.

Shivam Mukherjee
@Vivraan_gitlab
Does Provable support the Polygon Mumbai Testnet?
Oraclize Support
@oraclize-support
Hello @Vivraan_gitlab - unfortunately we don't support that chain yet
Shivam Mukherjee
@Vivraan_gitlab

Hello @Vivraan_gitlab - unfortunately we don't support that chain yet

Understood. Is there a way to run a node for Provable on Polygon, like Chainlink allows?