Skip to content
Write and publish your own blockchain in less than 200 lines of Go
Branch: master
Clone or download
Pull request Compare This branch is even with mycoralhealth:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
networking
p2p
proof-stake
proof-work
.gitignore
.travis.yml
README.md
example.env
main.go

README.md

Build Status

Code your own blockchain in less than 200 lines of Go!

Tutorial

Read our blog post first to see a walkthrough of the code.

Ask us anything!

Join our Telegram chat and follow us on Twitter!

Check out our follow-up tutorials:

Deployment steps:

  • git clone https://github.com/mycoralhealth/blockchain-tutorial.git
  • navigate to this directory and rename the example file mv example.env .env
  • go run main.go
  • open a web browser and visit http://localhost:8080/
  • to write new blocks, send a POST request (I like to use Postman) to http://localhost:8080/ with a JSON payload with BPM as the key and an integer as the value. For example:
{"BPM":50}
  • Send as many requests as you like and refresh your browser to see your blocks grow! Use your actual heart rate (Beats Per Minute) to track it over time.

Screenshot

screen

You can’t perform that action at this time.