From 2e273202252bfb1b1aea0b790c495dfed3d5082a Mon Sep 17 00:00:00 2001 From: Marc Weistroff Date: Sat, 30 Mar 2013 19:51:13 -0400 Subject: [PATCH] Add example in package documentation --- pagerduty.go | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/pagerduty.go b/pagerduty.go index d87f192..2c3701b 100644 --- a/pagerduty.go +++ b/pagerduty.go @@ -1,5 +1,16 @@ -// Package pagerduty is a client to the Pager Duty Integration API -// described here: http://developer.pagerduty.com/documentation/integration/events +/* +Package pagerduty is a client to the Pager Duty Integration API. +The API is described here: http://developer.pagerduty.com/documentation/integration/events + + // Create a new "trigger" event + event := pagerduty.NewTriggerEvent(myKey, "test API") + + // Customize the incident key. If not done, pager duty will assign one to you. + event.IncidentKey = "My Incident Key" + + // Submit the event to pager duty's API + response, statusCode, err := pagerduty.Submit(event) +*/ package pagerduty import (