gapi

package module
v0.0.0-...-0ada7cb Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2015 License: Apache-2.0 Imports: 10 Imported by: 0

README

grafana-api-golang-client

Grafana HTTP API Client for Go

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*http.Client
	// contains filtered or unexported fields
}

func New

func New(auth, baseURL string) (*Client, error)

New creates a new grafana client auth can be in user:pass format, or it can be an api key

func (*Client) CreateUserForm

func (c *Client) CreateUserForm(settings dtos.AdminCreateUserForm) error

func (*Client) DeleteOrg

func (c *Client) DeleteOrg(id int64) error

func (*Client) DeleteUser

func (c *Client) DeleteUser(id int64) error

func (*Client) NewOrg

func (c *Client) NewOrg(name string) error

func (*Client) Orgs

func (c *Client) Orgs() ([]Org, error)

func (*Client) Users

func (c *Client) Users() ([]User, error)

type Org

type Org struct {
	Id   int64
	Name string
}

type User

type User struct {
	Id      int64
	Email   string
	Name    string
	Login   string
	IsAdmin bool
}

Jump to

Keyboard shortcuts

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