Skip to content

React client displays BTC and ETH market info. If MetaMask with authorized private key is present in browser, user can send test ETH purchase on Rinkeby network to node server. NOTE: This is a demo, not intended to show best security practices.

Notifications You must be signed in to change notification settings

woodylewis/remote_ether_purchase

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Remote Rinkeby Purchase

For any client

  1. Display the current price for Bitcoin and Ethereum every 60 seconds from Coinbase API.
  2. Button for user to manually refresh price.

Additional for client with MetaMask wallet for destination address

  1. Button for user to transfer 5$ at current price of ether to another address using the rinkeby test network.
  2. Historical Data (console for now, need to add display)
  3. Make Recommendations to user if they should buy.(buy or sell based on last up or down tick, need to elaborate)

Server

In .env, add values for: Your Infura access token (or token for another platform). Address and private key of your sending wallet. Address of your destination wallet (same as PROD_ADDRESS in App.js)

Run yarn install to build. Run yarn start.

Client

In App.js, change PROD_ADDRESS to the destination wallet (where you'll send the ether). In App.js, add a remote server URL if you're using one (e.g. - myapi.awsinstance.com = example, does not exist). To use local server, change LOCAL to true.

Run yarn to build.

After starting server, run yarn start.

Note: Requires MetaMask. If you have more than one wallet, make sure you're on the one that has PROD_ADDRESS, otherwise you won't see the Buy Ether button.

To make a purchase, hit the Buy Ether button and wait. A URL to the transaction hash will appear when the transaction is about done.

Adding Redux

About

React client displays BTC and ETH market info. If MetaMask with authorized private key is present in browser, user can send test ETH purchase on Rinkeby network to node server. NOTE: This is a demo, not intended to show best security practices.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published