/go-coinbase

Coinbase API Client

Primary LanguageGoMIT LicenseMIT

go-coinbase

Coinbase API Client
GitHub tag (latest SemVer) GitHub GitHub repo size

Installation

go get -d -u github.com/Reclyptor/go-coinbase

Sample Usage

package main

import (
	"fmt"
	"github.com/Reclyptor/go-coinbase"
)

func main() {
	// Create An API Client
	client := coinbase.NewCoinbaseClient()

	// Retrieve An Asset's Market Price
	price := client.Price.GetSpotPrice(coinbase.CurrencyPairs.BTC_USD)

	fmt.Printf("%+v\n", price)
}

API

The official API documentation can be found on the Coinbase developer portal. (Base | Pro)

The endpoints supported by the client are listed below.

Base

Pro

Roadmap

  1. Formal Testing
  2. Godoc
  3. Proper Error Handling and Propagation
  4. Websocket Feed
  5. Support for Private Endpoints

Notes

2020 August 03

  • Laid out the initial groundwork for WebSocket support. Currently, only the Heartbeat channel is subscribable.

2020 August 02

  • This initial version of the client only supports the use of the public data endpoints, which do not require any form of authentication.
    • Note that these endpoints are throttled by Coinbase at a rate of roughly 2 requests per second.