event_rules
Creates, updates, deletes or gets an event_rule resource or lists event_rules in a region
Overview
| Name | event_rules |
| Type | Resource |
| Description | Resource Type definition for AWS::Notifications::EventRule |
| Id | awscc.notifications.event_rules |
Fields
| Name | Datatype | Description |
|---|---|---|
arn | string | |
creation_time | string | |
event_pattern | string | |
event_type | string | |
managed_rules | array | |
notification_configuration_arn | string | |
regions | array | |
source | string | |
status_summary_by_region | object | |
region | string | AWS region. |
For more information, see AWS::Notifications::EventRule.
Methods
| Name | Accessible by | Required Params |
|---|---|---|
create_resource | INSERT | EventType, NotificationConfigurationArn, Regions, Source, region |
delete_resource | DELETE | data__Identifier, region |
update_resource | UPDATE | data__Identifier, data__PatchDocument, region |
list_resources | SELECT | region |
get_resource | SELECT | data__Identifier, region |
SELECT examples
Gets all properties from an individual event_rule.
SELECT
region,
arn,
creation_time,
event_pattern,
event_type,
managed_rules,
notification_configuration_arn,
regions,
source,
status_summary_by_region
FROM awscc.notifications.event_rules
WHERE region = 'us-east-1' AND data__Identifier = '<Arn>';
INSERT example
Use the following StackQL query and manifest file to create a new event_rule resource, using stack-deploy.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO awscc.notifications.event_rules (
EventType,
NotificationConfigurationArn,
Regions,
Source,
region
)
SELECT
'{{ EventType }}',
'{{ NotificationConfigurationArn }}',
'{{ Regions }}',
'{{ Source }}',
'{{ region }}';
/*+ create */
INSERT INTO awscc.notifications.event_rules (
EventPattern,
EventType,
NotificationConfigurationArn,
Regions,
Source,
region
)
SELECT
'{{ EventPattern }}',
'{{ EventType }}',
'{{ NotificationConfigurationArn }}',
'{{ Regions }}',
'{{ Source }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: event_rule
props:
- name: EventPattern
value: '{{ EventPattern }}'
- name: EventType
value: '{{ EventType }}'
- name: NotificationConfigurationArn
value: '{{ NotificationConfigurationArn }}'
- name: Regions
value:
- '{{ Regions[0] }}'
- name: Source
value: '{{ Source }}'
DELETE example
/*+ delete */
DELETE FROM awscc.notifications.event_rules
WHERE data__Identifier = '<Arn>'
AND region = 'us-east-1';
Permissions
To operate on the event_rules resource, the following permissions are required:
Create
notifications:CreateEventRule,
notifications:UpdateEventRule,
notifications:GetEventRule
Read
notifications:GetEventRule
Update
notifications:UpdateEventRule,
notifications:GetEventRule
Delete
notifications:DeleteEventRule,
notifications:GetEventRule
List
notifications:ListEventRules,
notifications:GetEventRule