Golang client for the CoinGate Exchange Rate API.
First, ensure the library is installed and up to date by running
go get -u github.com/ivanglie/go-coingate-client
This is a very simple app that just displays US Dollar to Chinese Yuan Renminbi conversion.
package main
import (
"fmt"
"time"
coingate "github.com/ivanglie/go-coingate-client"
)
func main() {
client := coingate.NewClient()
rate, err := client.GetRate("USD", "CNY")
if err != nil {
panic(err)
}
fmt.Println(rate)
}
See main.go.
For more information check out the following links: