diff --git a/incident/result.go b/incident/result.go index b8d35e7..2940aec 100644 --- a/incident/result.go +++ b/incident/result.go @@ -1,8 +1,9 @@ package incident import ( - "github.com/opsgenie/opsgenie-go-sdk-v2/client" "time" + + "github.com/opsgenie/opsgenie-go-sdk-v2/client" ) type Incident struct { @@ -14,6 +15,8 @@ type Incident struct { Tags []string `json:"tags"` CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` + ImpactStartDate time.Time `json:"impactStartDate"` + ImpactEndDate time.Time `json:"impactEndDate"` Priority Priority `json:"priority"` OwnerTeam string `json:"ownerTeam"` Responders []Responder `json:"responders"` @@ -65,7 +68,7 @@ type NoteResult struct { Note string `json:"note"` Owner string `json:"owner"` CreatedAt time.Time `json:"createdAt"` - Offset string `json:"offset"` + Offset int `json:"offset"` } type ListNotesResult struct { diff --git a/og/entity.go b/og/entity.go index 2215d9a..51556ec 100644 --- a/og/entity.go +++ b/og/entity.go @@ -81,7 +81,7 @@ func validateParticipants(rotation *Rotation) error { } if participant.Type == Escalation && participant.Name == "" && participant.Id == "" { return errors.New("For participant type escalation either escalation name or id must be provided.") - } + } } return nil } diff --git a/policy/request.go b/policy/request.go index e062136..51f719d 100644 --- a/policy/request.go +++ b/policy/request.go @@ -257,9 +257,9 @@ func (r *UpdateAlertPolicyRequest) ResourcePath() string { } func (r *UpdateAlertPolicyRequest) RequestParams() map[string]string { - params := make(map[string]string) - params["teamId"] = r.TeamId - return params + params := make(map[string]string) + params["teamId"] = r.TeamId + return params } func (r *UpdateAlertPolicyRequest) Method() string {