aws_sdk_vpclattice/client/put_auth_policy.rs
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
impl super::Client {
/// Constructs a fluent builder for the [`PutAuthPolicy`](crate::operation::put_auth_policy::builders::PutAuthPolicyFluentBuilder) operation.
///
/// - The fluent builder is configurable:
/// - [`resource_identifier(impl Into<String>)`](crate::operation::put_auth_policy::builders::PutAuthPolicyFluentBuilder::resource_identifier) / [`set_resource_identifier(Option<String>)`](crate::operation::put_auth_policy::builders::PutAuthPolicyFluentBuilder::set_resource_identifier):<br>required: **true**<br><p>The ID or Amazon Resource Name (ARN) of the service network or service for which the policy is created.</p><br>
/// - [`policy(impl Into<String>)`](crate::operation::put_auth_policy::builders::PutAuthPolicyFluentBuilder::policy) / [`set_policy(Option<String>)`](crate::operation::put_auth_policy::builders::PutAuthPolicyFluentBuilder::set_policy):<br>required: **true**<br><p>The auth policy. The policy string in JSON must not contain newlines or blank lines.</p><br>
/// - On success, responds with [`PutAuthPolicyOutput`](crate::operation::put_auth_policy::PutAuthPolicyOutput) with field(s):
/// - [`policy(Option<String>)`](crate::operation::put_auth_policy::PutAuthPolicyOutput::policy): <p>The auth policy. The policy string in JSON must not contain newlines or blank lines.</p>
/// - [`state(Option<AuthPolicyState>)`](crate::operation::put_auth_policy::PutAuthPolicyOutput::state): <p>The state of the auth policy. The auth policy is only active when the auth type is set to <code>AWS_IAM</code>. If you provide a policy, then authentication and authorization decisions are made based on this policy and the client's IAM policy. If the Auth type is <code>NONE</code>, then, any auth policy that you provide remains inactive. For more information, see <a href="https://docs.aws.amazon.com/vpc-lattice/latest/ug/service-networks.html#create-service-network">Create a service network</a> in the <i>Amazon VPC Lattice User Guide</i>.</p>
/// - On failure, responds with [`SdkError<PutAuthPolicyError>`](crate::operation::put_auth_policy::PutAuthPolicyError)
pub fn put_auth_policy(&self) -> crate::operation::put_auth_policy::builders::PutAuthPolicyFluentBuilder {
crate::operation::put_auth_policy::builders::PutAuthPolicyFluentBuilder::new(self.handle.clone())
}
}