Skip to content

Commit

Permalink
Merge pull request #75 from opsgenie/custom-pri_to-int-action
Browse files Browse the repository at this point in the history
customPriority to IntegrationAction
  • Loading branch information
ilteristabak authored Dec 23, 2020
2 parents d90cad0 + bdd1ddc commit 4951c0d
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions integration/request.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,16 +76,16 @@ func (r *APIBasedIntegrationRequest) Method() string {

type WebhookIntegrationRequest struct {
client.BaseRequest
Name string `json:"name"`
Type string `json:"type"`
AllowWriteAccess *bool `json:"allowWriteAccess"`
SuppressNotifications *bool `json:"suppressNotifications"`
OwnerTeam *og.OwnerTeam `json:"ownerTeam,omitempty"`
Responders []Responder `json:"responders,omitempty"`
WebhookUrl string `json:"url"`
AddAlertDescription *bool `json:"addAlertDescription"`
AddAlertDetails *bool `json:"addAlertDetails"`
Headers map[string]string `json:"headers,omitempty"`
Name string `json:"name"`
Type string `json:"type"`
AllowWriteAccess *bool `json:"allowWriteAccess"`
SuppressNotifications *bool `json:"suppressNotifications"`
OwnerTeam *og.OwnerTeam `json:"ownerTeam,omitempty"`
Responders []Responder `json:"responders,omitempty"`
WebhookUrl string `json:"url"`
AddAlertDescription *bool `json:"addAlertDescription"`
AddAlertDetails *bool `json:"addAlertDetails"`
Headers map[string]string `json:"headers,omitempty"`
}

func (r *WebhookIntegrationRequest) Validate() error {
Expand All @@ -110,7 +110,6 @@ func (r *WebhookIntegrationRequest) Method() string {
return http.MethodPost
}


type EmailBasedIntegrationRequest struct {
client.BaseRequest
Name string `json:"name"`
Expand Down Expand Up @@ -386,6 +385,7 @@ type IntegrationAction struct {
Description string `json:"description,omitempty"`
Entity string `json:"entity,omitempty"`
Priority string `json:"priority,omitempty"`
CustomPriority string `json:"customPriority,omitempty"`
AppendAttachments *bool `json:"appendAttachments,omitempty"`
AlertActions []string `json:"alertActions,omitempty"`
IgnoreAlertActionsFromPayload *bool `json:"ignoreAlertActionsFromPayload,omitempty"`
Expand Down

0 comments on commit 4951c0d

Please sign in to comment.