Skip to main content

instances

Creates, updates, deletes or gets an instance resource or lists instances in a region

Overview

Nameinstances
TypeResource
DescriptionResource Type definition for Identity Center (SSO) Instance
Idawscc.sso.instances

Fields

NameDatatypeDescription
namestringThe name you want to assign to this Identity Center (SSO) Instance
instance_arnstringThe SSO Instance ARN that is returned upon creation of the Identity Center (SSO) Instance
owner_account_idstringThe AWS accountId of the owner of the Identity Center (SSO) Instance
identity_store_idstringThe ID of the identity store associated with the created Identity Center (SSO) Instance
statusstringThe status of the Identity Center (SSO) Instance, create_in_progress/delete_in_progress/active
tagsarray
regionstringAWS region.

For more information, see AWS::SSO::Instance.

Methods

NameResourceAccessible byRequired Params
create_resourceinstancesINSERTregion
delete_resourceinstancesDELETEIdentifier, region
update_resourceinstancesUPDATEIdentifier, PatchDocument, region
list_resourcesinstances_list_onlySELECTregion
get_resourceinstancesSELECTIdentifier, region

SELECT examples

Gets all properties from an individual instance.

SELECT
region,
name,
instance_arn,
owner_account_id,
identity_store_id,
status,
tags
FROM awscc.sso.instances
WHERE
region = '{{ region }}' AND
Identifier = '{{ instance_arn }}';

INSERT example

Use the following StackQL query and manifest file to create a new instance resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.sso.instances (
Name,
Tags,
region
)
SELECT
'{{ name }}',
'{{ tags }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

UPDATE example

Use the following StackQL query and manifest file to update a instance resource, using stack-deploy.

/*+ update */
UPDATE awscc.sso.instances
SET PatchDocument = string('{{ {
"Name": name,
"Tags": tags
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ instance_arn }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

DELETE example

/*+ delete */
DELETE FROM awscc.sso.instances
WHERE
Identifier = '{{ instance_arn }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

Additional Parameters

Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:

ParameterDescription
ClientToken
A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.
A client token is valid for 36 hours once used.
After that, a resource request with the same client token is treated as a new request.
If you do not specify a client token, one is generated for inclusion in the request.
RoleArn
The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.
If you do not specify a role, a temporary session is created using your AWS user credentials.
TypeVersionId
For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used.

Permissions

To operate on the instances resource, the following permissions are required:

sso:CreateInstance,
sso:DescribeInstance,
sso:TagResource,
iam:CreateServiceLinkedRole,
sso:TagInstance,
sso:ListTagsForResource