Assurance / Client / accept_invitation

accept_invitation

Assurance.Client.accept_invitation(**kwargs)

Accepts a pending invitation to connect your account to an environment. To use this operation, you must have permission to call iam:CreateServiceLinkedRole.

The invitation becomes ACTIVE when AWS Assurance can assume its service-linked role in your account. If AWS Assurance can’t create or assume the role, the request fails and the invitation stays PENDING.

See also: AWS API Documentation

Request Syntax

response = client.accept_invitation(
    environmentArn='string'
)
Parameters:

environmentArn (string) –

[REQUIRED]

The ARN of the environment that sent the invitation. At most one active or pending invitation exists for a given account and environment at a time.

Return type:

dict

Returns:

Response Syntax

{
    'status': 'PENDING'|'ACTIVE'|'REJECTED'|'REVOKED'|'EXPIRED'
}

Response Structure

  • (dict) –

    • status (string) –

      The lifecycle state of the invitation. ACTIVE when the connection is live.

Exceptions