registry_policies
Creates, updates, deletes or gets a registry_policy
resource or lists registry_policies
in a region
Overview
Name | registry_policies |
Type | Resource |
Description | Resource Type definition for AWS::EventSchemas::RegistryPolicy |
Id | aws.eventschemas.registry_policies |
Fields
Name | Datatype | Description |
---|---|---|
id | string | |
policy | object | |
registry_name | string | |
revision_id | string | |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | RegistryName, Policy, region |
delete_resource | DELETE | data__Identifier, region |
update_resource | UPDATE | data__Identifier, data__PatchDocument, region |
get_resource | SELECT | data__Identifier, region |
SELECT
examples
Gets all properties from an individual registry_policy
.
SELECT
region,
id,
policy,
registry_name,
revision_id
FROM aws.eventschemas.registry_policies
WHERE region = 'us-east-1' AND data__Identifier = '<Id>';
INSERT
example
Use the following StackQL query and manifest file to create a new registry_policy
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.eventschemas.registry_policies (
Policy,
RegistryName,
region
)
SELECT
'{{ Policy }}',
'{{ RegistryName }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.eventschemas.registry_policies (
Policy,
RegistryName,
RevisionId,
region
)
SELECT
'{{ Policy }}',
'{{ RegistryName }}',
'{{ RevisionId }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: registry_policy
props:
- name: Policy
value: {}
- name: RegistryName
value: '{{ RegistryName }}'
- name: RevisionId
value: '{{ RevisionId }}'
DELETE
example
/*+ delete */
DELETE FROM aws.eventschemas.registry_policies
WHERE data__Identifier = '<Id>'
AND region = 'us-east-1';
Permissions
To operate on the registry_policies
resource, the following permissions are required:
Create
schemas:PutResourcePolicy,
schemas:GetResourcePolicy,
schemas:DescribeRegistry
Delete
schemas:DeleteResourcePolicy,
schemas:GetResourcePolicy
Update
schemas:PutResourcePolicy,
schemas:GetResourcePolicy
Read
schemas:GetResourcePolicy