| Copyright | (c) 2013-2023 Brendan Hay |
|---|---|
| License | Mozilla Public License, v. 2.0. |
| Maintainer | Brendan Hay |
| Stability | auto-generated |
| Portability | non-portable (GHC extensions) |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
Amazonka.IoT.CreateKeysAndCertificate
Description
Creates a 2048-bit RSA key pair and issues an X.509 certificate using
the issued public key. You can also call CreateKeysAndCertificate over
MQTT from a device, for more information, see
Provisioning MQTT API.
Note This is the only time IoT issues the private key for this certificate, so it is important to keep it in a secure location.
Requires permission to access the CreateKeysAndCertificate action.
Synopsis
- data CreateKeysAndCertificate = CreateKeysAndCertificate' {
- setAsActive :: Maybe Bool
- newCreateKeysAndCertificate :: CreateKeysAndCertificate
- createKeysAndCertificate_setAsActive :: Lens' CreateKeysAndCertificate (Maybe Bool)
- data CreateKeysAndCertificateResponse = CreateKeysAndCertificateResponse' {}
- newCreateKeysAndCertificateResponse :: Int -> CreateKeysAndCertificateResponse
- createKeysAndCertificateResponse_certificateArn :: Lens' CreateKeysAndCertificateResponse (Maybe Text)
- createKeysAndCertificateResponse_certificateId :: Lens' CreateKeysAndCertificateResponse (Maybe Text)
- createKeysAndCertificateResponse_certificatePem :: Lens' CreateKeysAndCertificateResponse (Maybe Text)
- createKeysAndCertificateResponse_keyPair :: Lens' CreateKeysAndCertificateResponse (Maybe KeyPair)
- createKeysAndCertificateResponse_httpStatus :: Lens' CreateKeysAndCertificateResponse Int
Creating a Request
data CreateKeysAndCertificate Source #
The input for the CreateKeysAndCertificate operation.
Requires permission to access the CreateKeysAndCertificateRequest action.
See: newCreateKeysAndCertificate smart constructor.
Constructors
| CreateKeysAndCertificate' | |
Fields
| |
Instances
newCreateKeysAndCertificate :: CreateKeysAndCertificate Source #
Create a value of CreateKeysAndCertificate with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:setAsActive:CreateKeysAndCertificate', createKeysAndCertificate_setAsActive - Specifies whether the certificate is active.
Request Lenses
createKeysAndCertificate_setAsActive :: Lens' CreateKeysAndCertificate (Maybe Bool) Source #
Specifies whether the certificate is active.
Destructuring the Response
data CreateKeysAndCertificateResponse Source #
The output of the CreateKeysAndCertificate operation.
See: newCreateKeysAndCertificateResponse smart constructor.
Constructors
| CreateKeysAndCertificateResponse' | |
Fields
| |
Instances
newCreateKeysAndCertificateResponse Source #
Create a value of CreateKeysAndCertificateResponse with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
CreateKeysAndCertificateResponse, createKeysAndCertificateResponse_certificateArn - The ARN of the certificate.
CreateKeysAndCertificateResponse, createKeysAndCertificateResponse_certificateId - The ID of the certificate. IoT issues a default subject name for the
certificate (for example, IoT Certificate).
CreateKeysAndCertificateResponse, createKeysAndCertificateResponse_certificatePem - The certificate data, in PEM format.
$sel:keyPair:CreateKeysAndCertificateResponse', createKeysAndCertificateResponse_keyPair - The generated key pair.
$sel:httpStatus:CreateKeysAndCertificateResponse', createKeysAndCertificateResponse_httpStatus - The response's http status code.
Response Lenses
createKeysAndCertificateResponse_certificateArn :: Lens' CreateKeysAndCertificateResponse (Maybe Text) Source #
The ARN of the certificate.
createKeysAndCertificateResponse_certificateId :: Lens' CreateKeysAndCertificateResponse (Maybe Text) Source #
The ID of the certificate. IoT issues a default subject name for the certificate (for example, IoT Certificate).
createKeysAndCertificateResponse_certificatePem :: Lens' CreateKeysAndCertificateResponse (Maybe Text) Source #
The certificate data, in PEM format.
createKeysAndCertificateResponse_keyPair :: Lens' CreateKeysAndCertificateResponse (Maybe KeyPair) Source #
The generated key pair.
createKeysAndCertificateResponse_httpStatus :: Lens' CreateKeysAndCertificateResponse Int Source #
The response's http status code.