Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// The workspace to send logs to
WorkspaceID string
SharedKey string
// The custom logs table
CustomTable string
// Allows you to specify a custom http.Client
Client http.Client
}
The Client struct represents a connection to a Log Analytics instance.
Example:
client := loganalytics.Client{
WorkspaceID: WORKSPACE,
SharedKey: SHARED_KEY,
CustomTable: "foo",
}
result, err := client.Log(struct {
Foo string `json:"foo"`
}{Foo: "this will show up in the foo table, under the foo column"})
if err != nil {
log.Fatalln(err)
}
fmt.Println(result.Status)
Click to show internal directories.
Click to hide internal directories.