Questions tagged [oracles]

Oracle is a way of implementing a Smart Contract. Instead of running the contract code directly on the blockchain, the code is executed on some special off-chain entities called oracles which then send the result of the code to the blockchain network with a signature.

Filter by
Sorted by
Tagged with
0
votes
1answer
50 views

Apparent mismatch between Oraclize CBOR and python3 CBOR encodings

I encoded a value using the Oraclize CBOR library like so: Buffer.buffer memory cborArgs; Buffer.init(cborArgs, 64); cborArgs.startArray(); cborArgs.encodeUInt(10); cborArgs....
0
votes
0answers
59 views

Oraclize + CBOR Bug?

I'm making a computation query to Oraclize: import "https://github.com/oraclize/ethereum-api/blob/master/oraclizeAPI_0.4.sol" bytes scriptMultihash = "QmVJyXAmxdfuVgazi2PtnwXJdSiYPpkcvv6EydccQKkiZW";...
0
votes
1answer
148 views

Concatenating a variable value to a bytes32

I am using Oraclize for randomness. The range of random numbers I want depends on a variable maxNumber, and will be 0 - maxNumber. If you scroll to the right of my code snippet below, you'll see ...
0
votes
1answer
272 views

Oraclize : Ethereum-bridge on my local private chain

I can work with oraclize only using a private chain created with testrpc. If I try to use the ethereum-bridge over my locally created private chain it doesn't answer, nether I get message in the ...
0
votes
1answer
48 views

Unable to mine smart contract using Oraclize - Invalid JSON RPC response,error code : -32603

I am trying to use Oraclize to make a REST call. Please find below my contract code - pragma solidity ^0.4.16; import "./usingOraclize.sol"; //Importing Oraclize(verion 0.4) contract ...
0
votes
1answer
92 views

Orcalize query multi value callback

So I know JSONPATH can be used to select multiple values from a json response with an orcalize query like in the below example http://app.oraclize.it/home/test_query#VVJMKEdFVCk=:...
0
votes
1answer
169 views

Do Solidity functions time out?

I have a design where contract A is calling contract B, which then calls Oraclize a few times, and then sends the results back to contract A. The Oraclize calls could end up taking upwards of 30 ...
0
votes
1answer
147 views

Private Ethereum Smart Contract API call to notify (without needing the external api response to update the state) without using Oraclize

In a Private Ethereum Smart Contract, can we do an external API call just to notify (without needing the external api response to update the state) without using Oraclize? Understand Oraclize is ...
1
vote
1answer
286 views

Getting an HTTP Query Error when making GET-Requests using Oraclize to a local Node.js server

I am running a testrpc instance combined with Ethereum Bridge. Upon calling the smart-contract function "purchaseLogo" using Metamask (and web3), 2 oraclize_queries are getting initiated and make a ...
0
votes
1answer
67 views

How to install/use Oraclize on Windows 10?

I wanna get data from external data(web or just text files) to my smart contract. I found how to install and use the external data! But all the data was for Linux. like, sudo apt-get install npm ...
2
votes
1answer
158 views

Is there any specific configuration needed for Oraclize ethereum-bridge to support oraclize_newRandomDSQuery()?

I am using ganache-cli and ethereum-bridge in order to test oraclize locally. Other calls to oraclize, such as oraclize_query("URL","..."), work just fine. I am only having trouble with ...
-1
votes
1answer
169 views

Problem in Veifying Smart Contract On Testnet

I'm not able to verify my smart contract on Rinkeby and Ropsten Testnet Network. Rinkeby Link - https://rinkeby.etherscan.io/address/0x029798a8c21050cbaaa2d5ecbd5e06622b602b82 Ropsten Link - https:/...
1
vote
1answer
79 views

Deploying Smart Contract with Oraclize to the test net

I'm having difficulty deploying my contract to the Rinkeby TestNet. I made a local copy of the Oraclize API and saved it here:n//Users/simon/Documents/usingOraclize.sol In the Ethereum Wallet ...
3
votes
1answer
259 views

Oraclize __callback function with unbounded gas usage

I am making a lottery contract and using Oraclize to select a winning number. Here is what I have now: The owner calls a finalize() function, which disallows new entries, and makes a call to ...
0
votes
0answers
110 views

Using Oraclize for ICO smart contract

What is the advantages of using Oraclize for the development of an ICO Smart contract? doesn't it just add unnecessary complexity?
1
vote
1answer
196 views

I have 2 questions. 1: Is it possible to generate an array of random numbers, with every number to distinct, say 10 numbers in range of 0 and 1000?

I know, that using block hash or timestamp is not secure for gambling applications, and I know that I can use Oraclize to get a real random number. But is it possible to ask for an array of distinct ...
1
vote
0answers
51 views

Back of the envelope Oraclize callback cost calculations for

How does one do a back of the envelope calculation about how much the Oraclize callback will cost? Does it cost more if a query is returning a large amount versus a small amount of data? Does it cost ...
0
votes
1answer
136 views

Eth_call through oraclize

so I have a contract deployed on Ropsten and now I'm trying to access the public variable using a JSON RPC call through Infura and Oraclize. Here's my contract: contract test_contract { uint ...
1
vote
1answer
168 views

Oraclize Sample contracts failing in JavaScript VM: VM Exception: out of gas / invalid opcode

I'm simply trying to run one of the sample contracts here at dapps.oraclize.it/browser-solidity/ e.g. DieselPrice.sol. When I create the contract without passing a value I get VM Exception: out of ...
1
vote
2answers
168 views

How secure is an Oracle?

I am working on oracles. I saw this link - https://kndrck.co/posts/ethereum_oracles_a_simple_guide/ The code works, I tested it. But what is the issue to me, is the code actually secure? Can someone ...
0
votes
2answers
419 views

Request multiple API endpoints in Oraclize call

I want to make calls to multiple API endpoints. In my case, this is because I don't want to store the whole JSON response in my contract. If I wanted to get the ?color=red and ?color=blue endpoints, ...
0
votes
1answer
517 views

Time Specified calls in Solidity using Oraclize

I have started learning coding in Solidity and I have written the below contract using the official Oraclize guidelines. My aim is to: Make the update() function be called on its own on the ...
0
votes
1answer
65 views

Using oraclize function into fallback function

I have an issue with my oraclize. I need to call oraclaze for update exchange rate. If i call function updatePrice() manually - it's ok, global variable dollarCost is updating. But if I call ...
1
vote
2answers
836 views

How to get only latest log from my event?

I currently am using Oraclize in my contract and I make a call to a contract function from my front-end and don't want to continue onto the next call until the Oraclize function has returned. So I ...
1
vote
1answer
557 views

Urgent help setting up ethereum bridge

I've currently download nodejs truffle, testrpc etc etc to set up my development environment. All I need to do is demonstrate the oracle service working. I've found that I need to 'set up an ethereum ...
0
votes
1answer
53 views

Oraclize usage on blockchain

Is it possible to use oraclize for the purpose of communicating between ethereum private and public blockchains? For example, if i triggered an event in private blockchain, that event should be ...
1
vote
2answers
428 views

“Key not found in database” ethereum bridge error

Trying to perform a basic query using ethereum bridge / ganache / truffle. I appear to have Ethereum bridge running correctly. iPod-Classic-3:ethereum-bridge benandre$ node bridge -H localhost:7545 -...
0
votes
1answer
96 views

Unable to return string using Oraclize

I'm trying to do a simple coin flip using WolframAlpha and Oraclize, this is my smart contract pragma solidity ^0.4.18; import './usingOraclize.sol'; contract CoinFlipOracle is usingOraclize { ...
0
votes
1answer
478 views

How to write oracle and put sensor data to blockchain? [closed]

I havea project in which I need to send the readings from the sensor connected to RPi to blockchain. Due to the fact that smart contract cannot manipulate data outside blockchain I need an oracle that ...
1
vote
1answer
258 views

How to invoke multiple oracaliszed queries from a single contract

I want to invoke 2 different orcalized queries from the same contract. I saw a few posts but none of the answer works. Is there any way we can do that? Here is my contract. I was expecting this ...
1
vote
1answer
94 views

Cannot get Oracalize to work on Ropsten

I have tried to run Oracalize as 1:1 of the example provided on their site. During the creation of the contract, I am also sending 1 ether to it (so it is not empty). Still even 30 minutes after this, ...
0
votes
2answers
301 views

Oraclize __callback function not triggered in Remix Injected Web3 Environment on Ropsten

I execute below code and everything works fine until the point in which oraclize has to call __callback function. It doesn't get triggered. I check the status var to understand if it is triggered but ...
1
vote
1answer
250 views

Ethereum Bridge - WARN log with contract myid was triggered, but it was already seen before, skipping event

I am using ganache desktop application with nodejs where, I need to fetch values from API via ethereum-bridge. Following is contract code - pragma solidity ^0.4.4; import "./usingOraclize.sol"; ...
0
votes
2answers
169 views

Creating Contract Gas Problem

When I create my contract on remix using metamask (injected web3) it asks me to lower my gas fee. Once I lower it (if I don't I can't create it) the contract gets created BUT my variables inside the ...
0
votes
1answer
707 views

Read info from block chain from within a contract

Is it possible to read the block chain from within a contract? Specifically, I want to know if I can see how much ether user A has spent during the last 50 or so blocks. I didn't find anything in the ...
1
vote
0answers
60 views

Oracles and randomness, Creating or solving problems? [duplicate]

The idea behind oracles as a way to outsource information to be off the blockchain (Verifiable computing), Can solve a lot of problems, mostly related to randomness, As well as interacting with other ...
1
vote
3answers
605 views

Getting multiple values in single Oraclize query

Is it possible to get multiple values in single Oraclize query? contract CheckBet is usingOraclize { struct Weather { uint curr_temperature; uint high_temperature; uint low_temperature; }...
0
votes
1answer
55 views

How can I assign the value that I'm fetching using Oraclize to a member in a structure

I have the following code: contract CheckBet is usingOraclize { struct Weather { uint curr_temperature; uint high_temperature; uint low_temperature; } Weather ...
1
vote
2answers
289 views

How to include headers in oraclize GET request

I need to be able to include an API key as a header within my GET request to an api using oraclize in solidity. The oraclize documentation states that you can define arguments to send however, you ...
1
vote
1answer
143 views

In Solidity how to handle delay in mining by Oraclize and prevent code from further execution

I am trying to make a simple betting game using Oraclize in solidity. This code will ask Oraclize to provide a random number between 2 and 12. If this random number is same as the number guessed by ...
0
votes
1answer
239 views

Oraclize querying multiple API's in one call

I wonder if it's possible to call oraclize JUST ONCE, and get results from different APIs. oraclize_query("URL" , "['json1' , 'json2']"); The problem that I have is that the API that I'm using does ...
1
vote
0answers
178 views

Oraclize Queries Not Working On Rinkeby

I have the following contract (https://gist.github.com/postables/365f418b85c9d93503001682d6cc779e) which works when using Oraclize's web IDE version of remix. However when testing the contract out on ...
0
votes
1answer
230 views

How to take a string with variable length decimal places, and convert it to a whole number uint?

I'm experimenting with writing an ethereum-usd price ticker taking data from the coinmarketcap API using Oraclize's API. I noticed that Oraclize has a function called parseInt that can be used to ...
0
votes
1answer
201 views

Oraclize code not compiling using TRUFFLE COMPIL

I am trying to compile below mentioned code (taken from Oraclize documents) using TRUFFLE but am getting compilation error saying : 'Cannot parse one.sol: Unexpected token p in JSON at position 0'. ...
2
votes
0answers
154 views

Call several endpoints in an Oraclize nested query and return an array

I am trying to get an average of ETH/USD conversion rate through Oraclize. My query works well when calling one single HTTP endpoint but I would like to call several endpoints within the same query ...
0
votes
1answer
39 views

Oraclize parity error

I have a contract in Remix which runs perfectly on the Ethereum Ropsten Test net. I now want to deploy the contractin the main ethereum net using parity. When I click to deploy the contract in parity ...
0
votes
0answers
104 views

Private BlockChain - Cons?

Plan to implement private chain based on PoA to overcome transaction speed and privacy issue. Q1. what is the expected TPS? any advice to increase it? Q2. Understand that we can still leverage tools ...
2
votes
1answer
52 views

Why does Ethereum need exchanges?

As I understand, currently the preferred way to acquire ETH (for investment purpuses) is through a third-party exchange service. Isn't ethereum all about executing smart contracts when a specific ...
1
vote
0answers
146 views

Convert an hexadecimal string to bytes in pure Solidity

I am using Oraclize to recover a signature from a website. When I have it, I have to check if the address who signed it is correct. To do that, I would use ECRecovery from Zeppelin. The signature ...
4
votes
3answers
243 views

Oracle Corruption

I wonder if a service of oracles for smart contract (oraclize style) is corruptible. Let's say a smart contract that do some automatic action, for example, on 1 July 2018. This smart contract checks ...