DeleteSSHPublicKey - Amazon Identity and Access Management
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

DeleteSSHPublicKey

Deletes the specified SSH public key.

The SSH public key deleted by this operation is used only for authenticating the associated IAM user to an CodeCommit repository. For more information about using SSH keys to authenticate to an CodeCommit repository, see Set up CodeCommit for SSH connections in the CodeCommit User Guide.

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

SSHPublicKeyId

The unique identifier for the SSH public key.

This parameter allows (through its regex pattern) a string of characters that can consist of any upper or lowercased letter or digit.

Type: String

Length Constraints: Minimum length of 20. Maximum length of 128.

Pattern: [\w]+

Required: Yes

UserName

The name of the IAM user associated with the SSH public key.

This parameter allows (through its regex pattern) a string of characters consisting of upper and lowercase alphanumeric characters with no spaces. You can also include any of the following characters: _+=,.@-

Type: String

Length Constraints: Minimum length of 1. Maximum length of 64.

Pattern: [\w+=,.@-]+

Required: Yes

Errors

For information about the errors that are common to all actions, see Common Errors.

NoSuchEntity

The request was rejected because it referenced a resource entity that does not exist. The error message describes the resource.

HTTP Status Code: 404

Examples

Example

This example illustrates one usage of DeleteSSHPublicKey.

Sample Request

https://iam.amazonaws.com/?Action=DeleteSSHPublicKey &SSHPublicKeyId=APKAEIVFHP46CEXAMPLE &UserName=Jane &Version=2010-05-08 &AUTHPARAMS

Sample Response

<DeleteSSHPublicKeyResponse xmlns="https://iam.amazonaws.com/doc/2010-05-08/"> <ResponseMetadata> <RequestId>1a21282e-f36e-11e4-a53b-6b544EXAMPLE</RequestId> </ResponseMetadata> </DeleteSSHPublicKeyResponse>

See Also

For more information about using this API in one of the language-specific Amazon SDKs, see the following: