diff --git a/opsgenie/resource_opsgenie_role.go b/opsgenie/resource_opsgenie_role.go index 05d9a407..0a10b201 100644 --- a/opsgenie/resource_opsgenie_role.go +++ b/opsgenie/resource_opsgenie_role.go @@ -2,9 +2,10 @@ package opsgenie import ( "context" - "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" "log" + "github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation" + "github.com/opsgenie/opsgenie-go-sdk-v2/custom_user_role" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" @@ -31,12 +32,16 @@ var validCustomRolesRights = []string{ "alert-add-attachment", "alert-delete-attachment", "alert-add-note", + "alert-add-responder", "alert-acknowledge", "alert-unacknowledge", "alert-snooze", "alert-escalate", "alert-close", + "alert-create-issue", "alert-delete", + "alert-delete-note", + "alert-grant-visibility", "alert-take-ownership", "alert-assign-ownership", "alert-add-recipient", @@ -44,16 +49,59 @@ var validCustomRolesRights = []string{ "alert-edit-tags", "alert-edit-details", "alert-custom-action", + "alert-link-issue", + "alert-update-description", + "alert-update-message", + "alert-update-note", "alert-update-priority", "alert-acknowledge-all", "alert-close-all", + "assign-response-role", + "delete-incident-command-center-room", + "edit-incident-command-center-room", + "edit-impacted-services", + "forwardings-edit", + "incident-action", + "incident-add-note", "incident-create", + "incident-close", + "incident-commander", "incident-add-stakeholder", "incident-add-responder", + "incident-associate-alerts", + "incident-create-issue", + "incident-custom-action", + "incident-dissociate-alerts", + "incident-delete", + "incident-edit-details", + "incident-edit-impact-times", + "incident-edit-message", + "incident-edit-postmortem-fields", + "incident-edit-tags", + "incident-link-issue", + "incident-timeline-create", + "incident-timeline-edit", + "incident-timeline-delete", + "incident-remove-responder", "incident-resolve", "incident-reopen", + "incidents-access-all", + "incident-update-priority", + "access-icc-past-sessions", + "create-icc-session", + "join-icc-session", "mass-notification-create", + "postmortem-access-published", + "postmortem-access-unpublished", + "postmortem-create", + "postmortem-edit", + "postmortem-delete", "service-access", + "service-access-status", + "service-send-status-update", + "slack-channel-create", + "slack-channel-unlink", + "update-potential-causes", } func resourceOpsGenieCustomUserRole() *schema.Resource {