pivotal-cf/go-pivnet

Name: go-pivnet

Owner: Pivotal Cloud Foundry

Description: A golang libary for Pivotal Network.

Created: 2016-04-14 15:45:23.0

Updated: 2018-05-14 21:43:27.0

Pushed: 2018-05-14 21:43:26.0

Homepage:

Size: 4090

Language: Go

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

go-pivnet API library

A golang library for Pivotal Network.

See also the pivnet-cli and the pivnet-resource.

Usage

See example for an executable example.

rt github.com/pivotal-cf/pivnet

]

ig := pivnet.ClientConfig{
st:      pivnet.DefaultHost,
ken:     "token-from-pivnet",
erAgent: "user-agent",


utLogger := log.New(os.Stdout, "", log.LstdFlags)
rrLogger := log.New(os.Stderr, "", log.LstdFlags)

ose := false
er := logshim.NewLogShim(stdoutLogger, stderrLogger, verbose)

nt := pivnet.NewClient(config, logger)

ucts, _ := client.Products.List()

Printf("products: %v", products)
Running the tests

Install the ginkgo executable with:

et -u github.com/onsi/ginkgo/ginkgo

The tests require a valid Pivotal Network API token and host.

Refer to the official docs for more details on obtaining a Pivotal Network API token.

It is advised to run the acceptance tests against the Pivotal Network integration environment endpoint i.e. HOST='https://pivnet-integration.cfapps.io'.

Run the tests with the following command:

TOKEN=my-token \
='https://pivnet-integration.cfapps.io' \
n/test_all
Contributing

Please make all pull requests to the develop branch, and ensure the tests pass locally.

Project management

The CI for this project can be found here and the scripts can be found in the pivnet-resource-ci repo.

The roadmap is captured in Pivotal Tracker.


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.