1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
impl super::Client {
    /// Constructs a fluent builder for the [`CreatePolicy`](crate::operation::create_policy::builders::CreatePolicyFluentBuilder) operation.
    ///
    /// - The fluent builder is configurable:
    ///   - [`policy_name(impl Into<String>)`](crate::operation::create_policy::builders::CreatePolicyFluentBuilder::policy_name) / [`set_policy_name(Option<String>)`](crate::operation::create_policy::builders::CreatePolicyFluentBuilder::set_policy_name): <p>The policy name.</p>
    ///   - [`policy_document(impl Into<String>)`](crate::operation::create_policy::builders::CreatePolicyFluentBuilder::policy_document) / [`set_policy_document(Option<String>)`](crate::operation::create_policy::builders::CreatePolicyFluentBuilder::set_policy_document): <p>The JSON document that describes the policy. <b>policyDocument</b> must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.</p>
    ///   - [`tags(Vec<Tag>)`](crate::operation::create_policy::builders::CreatePolicyFluentBuilder::tags) / [`set_tags(Option<Vec<Tag>>)`](crate::operation::create_policy::builders::CreatePolicyFluentBuilder::set_tags): <p>Metadata which can be used to manage the policy.</p> <note>   <p>For URI Request parameters use format: ...key1=value1&amp;key2=value2...</p>   <p>For the CLI command-line parameter use format: &amp;&amp;tags "key1=value1&amp;key2=value2..."</p>   <p>For the cli-input-json file use format: "tags": "key1=value1&amp;key2=value2..."</p>  </note>
    /// - On success, responds with [`CreatePolicyOutput`](crate::operation::create_policy::CreatePolicyOutput) with field(s):
    ///   - [`policy_name(Option<String>)`](crate::operation::create_policy::CreatePolicyOutput::policy_name): <p>The policy name.</p>
    ///   - [`policy_arn(Option<String>)`](crate::operation::create_policy::CreatePolicyOutput::policy_arn): <p>The policy ARN.</p>
    ///   - [`policy_document(Option<String>)`](crate::operation::create_policy::CreatePolicyOutput::policy_document): <p>The JSON document that describes the policy.</p>
    ///   - [`policy_version_id(Option<String>)`](crate::operation::create_policy::CreatePolicyOutput::policy_version_id): <p>The policy version ID.</p>
    /// - On failure, responds with [`SdkError<CreatePolicyError>`](crate::operation::create_policy::CreatePolicyError)
    pub fn create_policy(
        &self,
    ) -> crate::operation::create_policy::builders::CreatePolicyFluentBuilder {
        crate::operation::create_policy::builders::CreatePolicyFluentBuilder::new(
            self.handle.clone(),
        )
    }
}