grafanacloud

package
v0.30.0-rc.0 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package grafanacloud provides an interface to the Grafana Cloud API.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

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

Client is a grafanacloud API client.

func NewClient

func NewClient(c *http.Client, apiKey, apiURL string) *Client

NewClient creates a new Grafana Cloud client. All requests made will be performed using the provided http.Client c. If c is nil, the default http client will be used instead.

apiKey will be used to authenticate against the apiURL.

func (*Client) AgentConfig

func (c *Client) AgentConfig(ctx context.Context, stackID, platforms string) (string, error)

AgentConfig generates a Grafana Agent config from the given stack. The config is returned as a string in YAML form.

Jump to

Keyboard shortcuts

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