api_destinations
Creates, updates, deletes or gets an api_destination
resource or lists api_destinations
in a region
Overview
Name | api_destinations |
Type | Resource |
Description | Resource Type definition for AWS::Events::ApiDestination. |
Id | aws.events.api_destinations |
Fields
Name | Datatype | Description |
---|---|---|
name | string | Name of the apiDestination. |
description | string | |
connection_arn | string | The arn of the connection. |
arn | string | The arn of the api destination. |
invocation_rate_limit_per_second | integer | |
invocation_endpoint | string | Url endpoint to invoke. |
http_method | string | |
region | string | AWS region. |
Methods
Name | Accessible by | Required Params |
---|---|---|
create_resource | INSERT | ConnectionArn, InvocationEndpoint, HttpMethod, 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 api_destinations
in a region.
SELECT
region,
name,
description,
connection_arn,
arn,
invocation_rate_limit_per_second,
invocation_endpoint,
http_method
FROM aws.events.api_destinations
WHERE region = 'us-east-1';
Gets all properties from an individual api_destination
.
SELECT
region,
name,
description,
connection_arn,
arn,
invocation_rate_limit_per_second,
invocation_endpoint,
http_method
FROM aws.events.api_destinations
WHERE region = 'us-east-1' AND data__Identifier = '<Name>';
INSERT
example
Use the following StackQL query and manifest file to create a new api_destination
resource, using stack-deploy
.
- Required Properties
- All Properties
- Manifest
/*+ create */
INSERT INTO aws.events.api_destinations (
ConnectionArn,
InvocationEndpoint,
HttpMethod,
region
)
SELECT
'{{ ConnectionArn }}',
'{{ InvocationEndpoint }}',
'{{ HttpMethod }}',
'{{ region }}';
/*+ create */
INSERT INTO aws.events.api_destinations (
Name,
Description,
ConnectionArn,
InvocationRateLimitPerSecond,
InvocationEndpoint,
HttpMethod,
region
)
SELECT
'{{ Name }}',
'{{ Description }}',
'{{ ConnectionArn }}',
'{{ InvocationRateLimitPerSecond }}',
'{{ InvocationEndpoint }}',
'{{ HttpMethod }}',
'{{ region }}';
version: 1
name: stack name
description: stack description
providers:
- aws
globals:
- name: region
value: '{{ vars.AWS_REGION }}'
resources:
- name: api_destination
props:
- name: Name
value: '{{ Name }}'
- name: Description
value: '{{ Description }}'
- name: ConnectionArn
value: '{{ ConnectionArn }}'
- name: InvocationRateLimitPerSecond
value: '{{ InvocationRateLimitPerSecond }}'
- name: InvocationEndpoint
value: '{{ InvocationEndpoint }}'
- name: HttpMethod
value: '{{ HttpMethod }}'
DELETE
example
/*+ delete */
DELETE FROM aws.events.api_destinations
WHERE data__Identifier = '<Name>'
AND region = 'us-east-1';
Permissions
To operate on the api_destinations
resource, the following permissions are required:
Create
events:CreateApiDestination,
events:DescribeApiDestination
Read
events:DescribeApiDestination
Update
events:UpdateApiDestination,
events:DescribeApiDestination
Delete
events:DeleteApiDestination,
events:DescribeApiDestination
List
events:ListApiDestinations