aws_sdk_lightsail/client/
import_key_pair.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`ImportKeyPair`](crate::operation::import_key_pair::builders::ImportKeyPairFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`key_pair_name(impl Into<String>)`](crate::operation::import_key_pair::builders::ImportKeyPairFluentBuilder::key_pair_name) / [`set_key_pair_name(Option<String>)`](crate::operation::import_key_pair::builders::ImportKeyPairFluentBuilder::set_key_pair_name):<br>required: **true**<br><p>The name of the key pair for which you want to import the public key.</p><br>
7    ///   - [`public_key_base64(impl Into<String>)`](crate::operation::import_key_pair::builders::ImportKeyPairFluentBuilder::public_key_base64) / [`set_public_key_base64(Option<String>)`](crate::operation::import_key_pair::builders::ImportKeyPairFluentBuilder::set_public_key_base64):<br>required: **true**<br><p>A base64-encoded public key of the <code>ssh-rsa</code> type.</p><br>
8    /// - On success, responds with [`ImportKeyPairOutput`](crate::operation::import_key_pair::ImportKeyPairOutput) with field(s):
9    ///   - [`operation(Option<Operation>)`](crate::operation::import_key_pair::ImportKeyPairOutput::operation): <p>An array of objects that describe the result of the action, such as the status of the request, the timestamp of the request, and the resources affected by the request.</p>
10    /// - On failure, responds with [`SdkError<ImportKeyPairError>`](crate::operation::import_key_pair::ImportKeyPairError)
11    pub fn import_key_pair(&self) -> crate::operation::import_key_pair::builders::ImportKeyPairFluentBuilder {
12        crate::operation::import_key_pair::builders::ImportKeyPairFluentBuilder::new(self.handle.clone())
13    }
14}