template_shares
Creates, updates, deletes, gets or lists a template_shares resource.
Overview
| Name | template_shares |
| Type | Resource |
| Id | aws.wellarchitected.template_shares |
Fields
The following fields are returned by SELECT queries:
- list_template_shares
| Name | Datatype | Description |
|---|---|---|
next_token | string | The token to use to retrieve the next set of results. (pattern: <code>[A-Za-z0-9+/=_-]+</code>) |
template_arn | string | The review template ARN. (pattern: <code>arn:aws(-us-gov|-iso(-[a-z])?|-cn)?:wellarchitected:[a-z]{2}(-gov|-iso([a-z])?)?-[a-z]+-\d:\d{12}:(review-template)/[a-f0-9]{32}</code>) |
template_share_summaries | array | A review template share summary return object. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list_template_shares | select | template_arn, region | SharedWithPrefix, NextToken, MaxResults, Status | List review template shares. |
create_template_share | insert | template_arn, region, SharedWith, ClientRequestToken | Create a review template share. The owner of a review template can share it with other Amazon Web Services accounts, users, an organization, and organizational units (OUs) in the same Amazon Web Services Region. Shared access to a review template is not removed until the review template share invitation is deleted. If you share a review template with an organization or OU, all accounts in the organization or OU are granted access to the review template. Disclaimer By sharing your review template with other Amazon Web Services accounts, you acknowledge that Amazon Web Services will make your review template available to those other accounts. | |
delete_template_share | delete | share_id, template_arn, ClientRequestToken, region | Delete a review template share. After the review template share is deleted, Amazon Web Services accounts, users, organizations, and organizational units (OUs) that you shared the review template with will no longer be able to apply it to new workloads. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
ClientRequestToken | string | |
region | string | AWS region (default: us-east-1) |
share_id | string | |
template_arn | string | The review template ARN. |
MaxResults | integer | The maximum number of results to return for this request. |
NextToken | string | |
SharedWithPrefix | string | The Amazon Web Services account ID, organization ID, or organizational unit (OU) ID with which the profile is shared. |
Status | string |
SELECT examples
- list_template_shares
List review template shares.
SELECT
next_token,
template_arn,
template_share_summaries
FROM aws.wellarchitected.template_shares
WHERE template_arn = '{{ template_arn }}' -- required
AND region = '{{ region }}' -- required
AND SharedWithPrefix = '{{ SharedWithPrefix }}'
AND NextToken = '{{ NextToken }}'
AND MaxResults = '{{ MaxResults }}'
AND Status = '{{ Status }}'
;
INSERT examples
- create_template_share
- Manifest
Create a review template share. The owner of a review template can share it with other Amazon Web Services accounts, users, an organization, and organizational units (OUs) in the same Amazon Web Services Region. Shared access to a review template is not removed until the review template share invitation is deleted. If you share a review template with an organization or OU, all accounts in the organization or OU are granted access to the review template. Disclaimer By sharing your review template with other Amazon Web Services accounts, you acknowledge that Amazon Web Services will make your review template available to those other accounts.
INSERT INTO aws.wellarchitected.template_shares (
SharedWith,
ClientRequestToken,
template_arn,
region
)
SELECT
'{{ SharedWith }}' /* required */,
'{{ ClientRequestToken }}' /* required */,
'{{ template_arn }}',
'{{ region }}'
RETURNING
share_id,
template_arn
;
# Description fields are for documentation purposes
- name: template_shares
props:
- name: template_arn
value: "{{ template_arn }}"
description: Required parameter for the template_shares resource.
- name: region
value: "{{ region }}"
description: Required parameter for the template_shares resource.
- name: SharedWith
value: "{{ SharedWith }}"
description: |
The Amazon Web Services account ID, organization ID, or organizational unit (OU) ID with which the workload, lens, profile, or review template is shared.
- name: ClientRequestToken
value: "{{ ClientRequestToken }}"
description: |
A unique case-sensitive string used to ensure that this request is idempotent (executes only once). You should not reuse the same token for other requests. If you retry a request with the same client request token and the same parameters after the original request has completed successfully, the result of the original request is returned. This token is listed as required, however, if you do not specify it, the Amazon Web Services SDKs automatically generate one for you. If you are not using the Amazon Web Services SDK or the CLI, you must provide this token or the request will fail.
DELETE examples
- delete_template_share
Delete a review template share. After the review template share is deleted, Amazon Web Services accounts, users, organizations, and organizational units (OUs) that you shared the review template with will no longer be able to apply it to new workloads.
DELETE FROM aws.wellarchitected.template_shares
WHERE share_id = '{{ share_id }}' --required
AND template_arn = '{{ template_arn }}' --required
AND ClientRequestToken = '{{ ClientRequestToken }}' --required
AND region = '{{ region }}' --required
;