Questions tagged [json-rpc]

json-formatted remote procedure calls to communicate with ethereum clients

Filter by
Sorted by
Tagged with
1
vote
1answer
655 views

Why am I having trouble connecting to the Infura mainnet?

I ran the below command, which I understood should've connected me to the mainnet: curl -X POST \ -H "Content-Type: application/json" \ --data '{"jsonrpc": "2.0", "id": 1, "method": "eth_blockNumber",...
1
vote
1answer
291 views

find first transactions to a contract

I'd ike to know the date or block of the first transaction of an account that has more transactions than the Etherscan display limit, like this one for example: https://etherscan.io/address/...
0
votes
1answer
488 views

JSON RPC + web3: Subscribe to Solidity events

When using web3 and the JSON RPC, is there a way to subscribe to Solidity events? For instance, I want to subscribe to every event Transfer(address indexed from, address indexed to, uint256 value); ...
0
votes
2answers
72 views

What bad things could happens if Geth RPC is public?

Geth does not ship with RPC support. By default Geth enables modules ["net", "web3", "eth", "shh"]. In case the RPC get compromised, what kind of bad things could happens? Money lost will definitely ...
0
votes
1answer
58 views

Is it possible send from multiaddress using single transaction without contract?

Is it possible send from multiaddress using single transaction without Smart contract? I have read somewhere, using https://wiki.parity.io/JSONRPC-eth-module#eth_signtransaction (signTransaction) you ...
0
votes
1answer
3k views

What do these geth --rpcapi parameters mean: db and net?

Many times in different guides I met the following string to start geth: geth --rpc --rpcapi="db,eth,net,web3,personal" Here we can find commands provided by admin, personal, eth options. But what ...
1
vote
1answer
772 views

Understanding “eth_estimateGas” results estimating gas

I have been playing around with parity's "eth_estimateGas" call to determine different tokens gas requirements. Generally using this code: let transfer_data = contract.transfer.getData("<...
1
vote
2answers
3k views

How to transfer ETH between two addresses using geth and json rpc

I have geth running on my server. I am building a php website which act as wallet. Now iam able to create addresses. I need to be able to deposit and withdraw ETH between addresses on same node. I ...
2
votes
1answer
867 views

Subscribe to events usign geth websocket

I'm trying to subscribe to geth using the websocket api. First step was to start geth: geth --ws --wsport=8456 --wsorigins="*" --fast --cache=512 --rpcport=8455 --rpc --rpcapi="personal,eth,network" ...
5
votes
2answers
806 views

ERC20 Token Transaction

How does etherscan know that a particular transaction is an ERC20 token transfer? If you look here: https://rinkeby.etherscan.io/tx/0xa8e4aa4f533e03bd8298f393d50d4ca41dba3368493c481e386d11389008353d ...
1
vote
1answer
631 views

web3.isConnected() returns false when connecting to geth with web3.js

I am totally new to cryptocurrency stuff. I have installed geth and web3. I want to build a web page showing account balance. I start geth with below command build/bin/geth --rpc --rpcaddr 127.0.0.1 ...
-1
votes
1answer
37 views

How do we know what time/what website is a MEW wallet created?

I lost Private Key + JSON file to open my myEtherwallet. But is there anybody knowing somehow to find: What time is a MEW wallet created? what website that has created an Ethereum wallet? (This is ...
1
vote
0answers
63 views

ETH Accounts per block

Correct me if Im wrong but from my understanding each block has a "stateRoot" property that point to status of the State tree at the time of mining. I also believe that tha state tree contais a list ...
0
votes
2answers
133 views

ETH Json RPC output [duplicate]

Looking at the output of https://github.com/ethereum/wiki/wiki/JSON-RPC#eth_getblockbyhash Does anyone know what do the "mixHash" and "extraData" field mean? and what is the Unit of gasLimit and ...
0
votes
2answers
1k views

Sending Transactions via RPC or IPC?

Recently i'm trying to comunicate to a private Ethereum blockchain via RPC/IPC to create a Transaction but what i'm seeing is that i cannot do it via RPC because: - i Always need to unlock my account ...
0
votes
3answers
856 views

JSON- RPC no response

I'm trying to use jscon-rpc but I dont get any response. After installing geth and loading the rinkeby test net does the ethereum node start ? I used "localhost" as the IP and "8545" as the port ...
1
vote
1answer
407 views

Convert Block Number Hash to Readable Block Number?

When i use this command : curl --data '{"method":"eth_getBlockByNumber","params":["latest", true],"id":1,"jsonrpc":"2.0"}' -H "Content-Type: application/json" -X POST localhost:8544 Then I am ...
0
votes
1answer
891 views

RPC authentication in Ethereum?

As far as I understand Ethereum uses JSON-RPC to communicate between clients. What is the authentication mechanism? That is, how does the network know that the RPC request is coming from a legit ...
0
votes
1answer
120 views

How to get the historical block mining information

I am still new to ethereum. How I can get the getWork information for an old block? as an example, how to get the block header hash pow, seedhash and target for block 1000,000? eth_getWork retrieve ...
1
vote
2answers
587 views

Can I run seperatly docker and geth?

I run private geth testnet and my program is on docker. Everytime I try to call api I get: no JSON RCP response. Must I run geth on docker too?
2
votes
2answers
2k views

Invalid JSON RPC response when creating contract

I am getting this error while trying to deploy contract on Mainnet via remix.ethereum.org creation of XXXTokenCrowdsale errored: Invalid JSON RPC response: {"id":22,"jsonrpc":"2.0","error":{"code":-...
3
votes
2answers
3k views

connecting geth to web3.js 1.0 via websockets or HTTP

I am building a minimal nodeJS application that should connect via web3.js to my geth node. I am following the official web3.js1.0 documentation and I am using web3 1.0.0-beta.29. I do manage to ...
2
votes
0answers
748 views

public facing full node with nginx

I am running a node on a Hosted root server, and will soon be synced, but I am not sure how I can now use this node to mine with my local Unix miner. What I have Xenon CPU with 32GB RAM 1 Terrabyte ...
4
votes
1answer
2k views

Get ERC-20 token transfer transaction for some address with JSON-RPC node

How can I get ERC-20 token transfer transactions for some address with JSON-RPC node? Input: Token Contract address Token Contract ABI Address Start block End block Output: JSON with list of token ...
0
votes
1answer
157 views

what is the 'QUANTITY|TAG' for in eth_call

How does that parameter affect eth_call? From the doc, this should specify a block? Does that mean it is as if the transaction were in the block?
0
votes
0answers
443 views

Running Npm init on powershell but its stuck and I can't proceed

I can't run truffle commands on windows powershell so I went to do the steps that I got here. However npm init got me stuck and I can't proceed: Here is the stuck screen: EDIT: After I uninstalled ...
4
votes
2answers
828 views

how to get balance for multiple addresses(batch request)?

I need to check the balance for multiple addresses (i.e. 100) a eth_getbalance seems to accept only one address.
0
votes
1answer
78 views

Building Ethereum application with in-process client

Most applications connect to an Ethereum Node through RPC, using a library like Web3.js and Nethereum. That introduces a need to deploy a full node side-by-side with the application, be it on the ...
2
votes
0answers
48 views

Why does my JSON-RPC request never complete?

I've set up geth to run in a Docker container with the following command (yes, I realize it's wide open to the world): docker run -it -p 127.0.0.1:8545:8545 -p 30303:30303 -v /data/ethereum:/root/....
0
votes
1answer
880 views

geth light mode features

I am trying to fully grasp the concepts of the ethereum network. Therefore I want to setup a simple website which can manage ethereum wallets. I'm using the geth client with the following ...
2
votes
1answer
119 views

How do you deploy a json script into the blockchain?

I was trying to find a way to test out the blockcerts example link, however I do not know how to deploy the script in the html page into the blockchain. Any good tutorials for this?
1
vote
1answer
341 views

Sending signed transaction to create a contract

My goal is to send a signed transaction to create a smart contract, however, I am facing an issue I have not been able to solve for few days: When I send the transaction (on a private chain), there ...
2
votes
3answers
2k views

Trying to use eth_call to contract function which takes an address as it's argument

I'm trying to call a function on my smart contract that's deployed on the main Ethereum network. The function signature is balanceOf(address). So far I've followed the instructions of doing the SHA3 ...
0
votes
2answers
1k views

JSON RPC get address balance

I'm trying to get the ether balance for any ethereum address. I've set up a node with the Ethereum daemon, but as far as I can tell, using eth_getBalance you can only get the balance of your own ...
0
votes
1answer
864 views

How do I checkout all the token transactions in a ether transaction using GETH?

I create an erc20 contract on my private blockchain. Then I transfer some tokens from one accout to another. Now I can check on the new block and find that transaction like this: { blockHash: "...
1
vote
2answers
404 views

Parity: Determine if Transaction is an Internal Transaction from JSON-RPC call

Given the results from a JSON-RPC call (calling a Parity Archive Node), is there any way to tell if a transaction is an Internal Transaction other than looking at the Gas Used in the Transaction ...
0
votes
1answer
238 views

Geth error with HTTP JSON RPC and urllib python3

I try to run this (geth is started with rpc on http://localhost:8545) #!/usr/bin/env python3 from urllib.parse import urlencode from urllib.request import Request, urlopen rpc = "http://localhost:...
1
vote
0answers
246 views

How to verify whether a certain transaction is mined by the newest block programmatically?

What I thought I should do I implemented this functionality with Bitcoin Core through zmq support. Keep "my transactions" through zmq's rawtx topic. When received zmq's rawblock, decode the raw ...
0
votes
1answer
141 views

Is it possible to know which Events a given transaction triggered?

I've noticed the GetTransactionReceipt function returns an array of logs that were created as a result of the transaction being processed. However, I wonder if there is a way to get a list of Events ...
0
votes
1answer
93 views

Exposing Smart Contract over HTTP

Would like to deploy a smart contract that any Web2 user can communicate with - given my smart contract public functions accept a few parameters. This essentially makes it "centralized" in a way, as ...
2
votes
0answers
445 views

How to check token transactions with geth

I'm new to smart contracts, my apologies if this is a wrong approach. I want to monitor incoming (confirmed, not caring about pending) token transactions to my wallet (using geth). I found out how to ...
0
votes
2answers
522 views

How to get deployed contract's address via JSON RPC?

Knowing the hash of a transaction that created the contract, how do I get the address of created contract? For instance: curl -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","...
2
votes
2answers
1k views

web3 js eth.contract equivalent in PHP

var Web3 = require('web3'); var web3 = new Web3(); web3.setProvider(new web3.providers.HttpProvider("http://blahblah.com:8545")); var token = web3.eth.contract(ABI).at("x0x_contract_address") How ...
2
votes
1answer
490 views

Which JSONRPC APIs are required by MetaMask?

This question is related to What RPC APIs are safe to expose? I want to run a Parity node not to have a wallet but only to have my own personal JSON RPC node for MetaMask. Parity will not be running ...
3
votes
0answers
229 views

Parity RPC eth_newFilter not returning pending events

I'm trying to create a listener for new pending TXs on the network using Parity RPC's eth_newFilter method. I'm sending the request using the following parameters, expecting to get pending ...
2
votes
3answers
806 views

How to get token holders via json RPC

So I want to get the token holders of a token like this: https://ropsten.etherscan.io/token/0xfa68d281e7ff1a8e9393428ba0abe8961cf342cb#balances Via my Ethereum node. I tried: https://github.com/...
0
votes
1answer
298 views

how to get miner address from transaction hash

In ethereum private blockchain i want to get the miner address from transaction hash. eth.getTransaction and eth.getTransactionReceipt are not giving miner details. is there any way to get miner ...
1
vote
1answer
536 views

Ethereum node has low RPC performance

I'm running an Ethereum Parity node on my home laptop (i7-7500U @2.7ghz, 2CPUs, w/ SSD) and getting massively more RPC throughput than on a dedicated Amazon AWS linux instance (i3.xlarge, 4vCPUs, w/ ...
0
votes
1answer
67 views

Output of log.memory.slice in Geth debug_traceTransaction

Has anyone else used the JavaScript-based tracer that Geth provides, as part of its debug_traceTransaction method? I want to look at segments of memory during a transaction's execution (specifically, ...
4
votes
1answer
623 views

How to make geth log RPC calls?

I want to see the logs of the JSON-RPC calls to geth (with all the details if possible). How can I do that? In this page, I have found a command line option: --vmodule value Per-module ...