updatePermissionSet method

Future<void> updatePermissionSet({
  1. required String instanceArn,
  2. required String permissionSetArn,
  3. String? description,
  4. String? relayState,
  5. String? sessionDuration,
})

Updates an existing permission set.

May throw AccessDeniedException. May throw ConflictException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Parameter instanceArn : The ARN of the IAM Identity Center instance under which the operation will be executed. For more information about ARNs, see Amazon Resource Names (ARNs) and Amazon Web Services Service Namespaces in the Amazon Web Services General Reference.

Parameter permissionSetArn : The ARN of the permission set.

Parameter description : The description of the PermissionSet.

Parameter relayState : Used to redirect users within the application during the federation authentication process.

Parameter sessionDuration : The length of time that the application user sessions are valid for in the ISO-8601 standard.

Implementation

Future<void> updatePermissionSet({
  required String instanceArn,
  required String permissionSetArn,
  String? description,
  String? relayState,
  String? sessionDuration,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'SWBExternalService.UpdatePermissionSet'
  };
  await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'InstanceArn': instanceArn,
      'PermissionSetArn': permissionSetArn,
      if (description != null) 'Description': description,
      if (relayState != null) 'RelayState': relayState,
      if (sessionDuration != null) 'SessionDuration': sessionDuration,
    },
  );
}