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 start geth with below command.
go-ethereum/build/bin/geth console --rpc --rpcapi="db,eth,net,web3,personal,web3" --rpccorsdomain "*" --syncmode "light"
How to acheive the functionality of a wallet on geth over rpc ? Is there a command or API call for that? Iam finding it hard to understand the documentation.
UPDATE: What I want to do is transfer ETH from one account to another. Below are the api calls i tried and the errors I got in the browser when i call transfer function in my php class. Can someone please correct me
{"jsonrpc":"2.0","id":1,"method":"personal_signAndSendTransaction","params":[[{"from":"0xb60e8dd61c5d32be8058bb8eb970870f07233155","to":"0xd46e8dd67c5d32be8058bb8eb970870f07244567","gas":"0x76c0","gasPrice":"0x9184e72a000","value":"0x9184e72a","data":"0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"}],"passphrase"]}
Fatal error: Uncaught RPCException: json: cannot unmarshal array into Go value of type eth.SendTxArgs
{"jsonrpc":"2.0","id":1,"method":"personal_sendTransaction","params":[[{"from":"0xb60e8dd61c5d32be8058bb8eb970870f07233155","to":"0xd46e8dd67c5d32be8058bb8eb970870f07244567","gas":"0x76c0","gasPrice":"0x9184e72a000","value":"0x9184e72a","data":"0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"}],"passphrase"]}
Fatal error: Uncaught RPCException: The method personal_sendTransaction does not exist/is not available thrown
{"jsonrpc":"2.0","id":1,"method":"eth_sendTransaction","params":[{"from":"0xb60e8dd61c5d32be8058bb8eb970870f07233155","to":"0xd46e8dd67c5d32be8058bb8eb970870f07244567","gas":"0x76c0","gasPrice":"0x9184e72a000","value":"0x9184e72a","data":"0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"}]}
Fatal error: Uncaught RPCException: account is locked thrown
Please help!