// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
impl super::Client {
/// Constructs a fluent builder for the [`CreateResourcePolicyStatement`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder) operation.
///
/// - The fluent builder is configurable:
/// - [`resource_arn(impl Into<String>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::resource_arn) / [`set_resource_arn(Option<String>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::set_resource_arn):<br>required: **true**<br><p>The Amazon Resource Name (ARN) of the bot or bot alias that the resource policy is attached to.</p><br>
/// - [`statement_id(impl Into<String>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::statement_id) / [`set_statement_id(Option<String>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::set_statement_id):<br>required: **true**<br><p>The name of the statement. The ID is the same as the <code>Sid</code> IAM property. The statement name must be unique within the policy. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_sid.html">IAM JSON policy elements: Sid</a>.</p><br>
/// - [`effect(Effect)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::effect) / [`set_effect(Option<Effect>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::set_effect):<br>required: **true**<br><p>Determines whether the statement allows or denies access to the resource.</p><br>
/// - [`principal(Principal)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::principal) / [`set_principal(Option<Vec::<Principal>>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::set_principal):<br>required: **true**<br><p>An IAM principal, such as an IAM user, IAM role, or Amazon Web Services services that is allowed or denied access to a resource. For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_principal.html">Amazon Web Services JSON policy elements: Principal</a>.</p><br>
/// - [`action(impl Into<String>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::action) / [`set_action(Option<Vec::<String>>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::set_action):<br>required: **true**<br><p>The Amazon Lex action that this policy either allows or denies. The action must apply to the resource type of the specified ARN. For more information, see <a href="https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazonlexv2.html"> Actions, resources, and condition keys for Amazon Lex V2</a>.</p><br>
/// - [`condition(impl Into<String>, HashMap::<String, String>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::condition) / [`set_condition(Option<HashMap::<String, HashMap::<String, String>>>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::set_condition):<br>required: **false**<br><p>Specifies a condition when the policy is in effect. If the principal of the policy is a service principal, you must provide two condition blocks, one with a SourceAccount global condition key and one with a SourceArn global condition key.</p> <p>For more information, see <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition.html">IAM JSON policy elements: Condition </a>.</p><br>
/// - [`expected_revision_id(impl Into<String>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::expected_revision_id) / [`set_expected_revision_id(Option<String>)`](crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::set_expected_revision_id):<br>required: **false**<br><p>The identifier of the revision of the policy to edit. If this revision ID doesn't match the current revision ID, Amazon Lex throws an exception.</p> <p>If you don't specify a revision, Amazon Lex overwrites the contents of the policy with the new values.</p><br>
/// - On success, responds with [`CreateResourcePolicyStatementOutput`](crate::operation::create_resource_policy_statement::CreateResourcePolicyStatementOutput) with field(s):
/// - [`resource_arn(Option<String>)`](crate::operation::create_resource_policy_statement::CreateResourcePolicyStatementOutput::resource_arn): <p>The Amazon Resource Name (ARN) of the bot or bot alias that the resource policy is attached to.</p>
/// - [`revision_id(Option<String>)`](crate::operation::create_resource_policy_statement::CreateResourcePolicyStatementOutput::revision_id): <p>The current revision of the resource policy. Use the revision ID to make sure that you are updating the most current version of a resource policy when you add a policy statement to a resource, delete a resource, or update a resource.</p>
/// - On failure, responds with [`SdkError<CreateResourcePolicyStatementError>`](crate::operation::create_resource_policy_statement::CreateResourcePolicyStatementError)
pub fn create_resource_policy_statement(
&self,
) -> crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder {
crate::operation::create_resource_policy_statement::builders::CreateResourcePolicyStatementFluentBuilder::new(self.handle.clone())
}
}