digitaloceansdk

package
v2.0.0-beta.6+incompat... Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 27, 2018 License: Apache-2.0 Imports: 5 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SDK

type SDK struct {
	// contains filtered or unexported fields
}

SDK encompasses all authorization for working with digital ocean api

func New

func New(accessToken string) *SDK

New is a constructor function for SDK

func NewFromAccount

func NewFromAccount(account *model.CloudAccount) (*SDK, error)

NewFromAccount extracts credentials from accounts and returns SDK ready to be used

func (*SDK) GetClient

func (s *SDK) GetClient() *godo.Client

GetClient return digital ocean client

type TokenSource

type TokenSource struct {
	AccessToken string
}

func (*TokenSource) Token

func (t *TokenSource) Token() (*oauth2.Token, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL