Skip to content

Instantly share code, notes, and snippets.

@gronnbeck gronnbeck/datadog.go Secret
Last active Mar 8, 2016

Embed
What would you like to do?
var (
envTag = fmt.Sprintf("environment-%s", os.Getenv("environment"))
)
func PostOK() {
event := datadog.Event{
Title: "SyntheticTransaction: OK",
Text: "Synthetic transaction succeded. The API is working as expected.",
Time: int(time.Now().UTC().Unix()),
AlertType: "info",
Tags: []string{"api-ok", envTag},
}
_, err := ddClient.PostEvent(&event)
if err != nil {
log.Fatal(err)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.