Skip to content

tiagolpires/go-grpc-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go gRPC API

  • Cryptocurrency API developed with Go and gRPC
  • Upvote, Downvote and Stream Cryptocurrencies

⚡️ Start

Download and install Go

Run docker compose

docker-compose up

Run seeds and migrations

make seed

Start the server

make start

In a new terminal, start the client

make start_client

# Expected output: 
# UpvoteCrypto...
# Crypto: id:1 name:"Bitcoin" code:"BTC" votes:6 
#
# DownvoteCrypto...
# Crypto: id:1 name:"Bitcoin" code:"BTC" votes:5 
#
# Start crypto streaming...
# Bitcoin Votes: 5...
# Finish crypto streaming
#
# UpdateCrypto...
# Crypto: id:1 name:"Bitcoin" code:"BTC" votes:5 
#
# GetCryptoById...
# Crypto: id:1 name:"Bitcoin" code:"BTC" votes:5 
#
# ListCryptos...
# List: [id:4 name:"Ethereum" votes:10...]

Tests

To run tests

make test

Generate Proto Buffer file

make gen

Built with

About

Cryptocurrency API developed with Go and gRPC

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors