updateThemePermissions method
Updates the resource permissions for a theme. Permissions apply to the
action to grant or revoke permissions on, for example
"quicksight:DescribeTheme".
Theme permissions apply in groupings. Valid groupings include the following for the three levels of permissions, which are user, owner, or no permissions:
-
User
-
"quicksight:DescribeTheme" -
"quicksight:DescribeThemeAlias" -
"quicksight:ListThemeAliases" -
"quicksight:ListThemeVersions"
-
-
Owner
-
"quicksight:DescribeTheme" -
"quicksight:DescribeThemeAlias" -
"quicksight:ListThemeAliases" -
"quicksight:ListThemeVersions" -
"quicksight:DeleteTheme" -
"quicksight:UpdateTheme" -
"quicksight:CreateThemeAlias" -
"quicksight:DeleteThemeAlias" -
"quicksight:UpdateThemeAlias" -
"quicksight:UpdateThemePermissions" -
"quicksight:DescribeThemePermissions"
-
- To specify no permissions, omit the permissions list.
May throw AccessDeniedException.
May throw InternalFailureException.
May throw InvalidParameterValueException.
May throw LimitExceededException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw UnsupportedUserEditionException.
Parameter awsAccountId :
The ID of the Amazon Web Services account that contains the theme.
Parameter themeId :
The ID for the theme.
Parameter grantPermissions :
A list of resource permissions to be granted for the theme.
Parameter revokePermissions :
A list of resource permissions to be revoked from the theme.
Implementation
Future<UpdateThemePermissionsResponse> updateThemePermissions({
required String awsAccountId,
required String themeId,
List<ResourcePermission>? grantPermissions,
List<ResourcePermission>? revokePermissions,
}) async {
final $payload = <String, dynamic>{
if (grantPermissions != null) 'GrantPermissions': grantPermissions,
if (revokePermissions != null) 'RevokePermissions': revokePermissions,
};
final response = await _protocol.send(
payload: $payload,
method: 'PUT',
requestUri:
'/accounts/${Uri.encodeComponent(awsAccountId)}/themes/${Uri.encodeComponent(themeId)}/permissions',
exceptionFnMap: _exceptionFns,
);
return UpdateThemePermissionsResponse.fromJson(response);
}