updateMyUserProfile method
Updates a user's SSH public key.
Required Permissions: To use this action, an IAM user must have self-management enabled or an attached policy that explicitly grants permissions. For more information about user permissions, see Managing User Permissions.
May throw ValidationException.
Parameter sshPublicKey
:
The user's SSH public key.
Implementation
Future<void> updateMyUserProfile({
String? sshPublicKey,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'OpsWorks_20130218.UpdateMyUserProfile'
};
await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
if (sshPublicKey != null) 'SshPublicKey': sshPublicKey,
},
);
}