# Update authentication options (/docs/apis/management/options/PatchAuthenticationOptions)

`PATCH /options/authentication`

Applies a partial update to the authentication configuration, including internal and external authenticators, sign-in behavior, and provider-specific settings. Only fields included in the request are updated.

Base URL: `https://{tenant}.{region}.monocloud.com/api`, where `{tenant}`, `{region}` (one of us, eu, in) come from your tenant. Authentication: send your Management API key in the `X-API-KEY` header.

## Request body

JSON, required. The request payload used to update the authentication options.

- `pushed_authorization` (PatchPushedAuthorizationOptionsRequest) Pushed Authorization Request Options
  - `enable_pushed_authorization_requests` (boolean) Specifies whether Pushed Authorization Requests (PAR) are enabled for the tenant. Secure+ subscription required to use Pushed Authorization Requests (PAR).
  - `require_pushed_authorization_requests` (boolean) Specifies whether Pushed Authorization Requests (PAR) are required tenant-wide for all authorization requests. When enabled, this setting overrides any client-specific PAR configuration and enforces PAR usage for all clients within the tenant. Secure+ subscription required to use Pushed Authorization Requests (PAR).
- `account_protection` (PatchAccountProtectionOptionsRequest) Account Protection Options
  - `user_lockout` (PatchAccountProtectionUserLockoutOptionsRequest) User account protection settings used to safeguard accounts from abuse.
    - `enabled` (boolean) Enables user lockout protection.
    - `max_failed_access_attempts` (integer, int32) Maximum failed sign-in attempts allowed before lockout (inclusive).
    - `user_lockout_time_span` (integer, int32) User account lockout duration (in minutes).
    - `ip_lockout_time_span` (integer, int32) IP lockout duration (in minutes).
    - `allowed_ips` (string[]) Allowlisted IP addresses that are exempt from lockout enforcement.
    - `lockout_type` (string) The lockout enforcement mode (IP-based or user-account-based). One of: `ip`, `user_account`.
    - `user_unblock` (PatchAccountProtectionUserUnblockOptionsRequest) The user unblock configuration.
- `authenticators` (PatchAuthenticatorOptionsRequest) Authenticators Options
  - `external_sign_in_methods_first` (boolean) Determines whether external authentication providers are prioritized over other authenticators during sign-in.
  - `password` (PatchPasswordAuthenticatorOptionsRequest) Password authenticator configuration.
    - `enable_sign_in` (boolean) Specifies whether users can sign in using password-based authentication.
    - `enable_sign_up` (boolean) Specifies whether new users can sign up using password-based authentication.
    - `prompt_password_on_initial_screen` (boolean) Specifies whether the password is collected on the initial sign-in screen alongside the identifier.
    - `expiry` (integer, int32) Specifies the password expiration interval (in days). When empty, passwords do not expire.
    - `strength` (PatchPasswordStrengthOptionsRequest) Password strength policy configuration. Pro plan required to customize password strength options.
    - `reuse` (PatchPasswordReuseOptionsRequest) Password reuse policy configuration. Pro plan required to customize password history options.
  - `passkey` (PatchPasskeyAuthenticatorOptionsRequest) Passkey authenticator configuration.
    - `enable_sign_in` (boolean) Specifies whether users can sign in using passkeys.
    - `enable_sign_up` (boolean) Specifies whether new users can sign up using passkeys.
    - `prompt_enrollment` (boolean) Specifies whether users should be prompted to enroll a passkey if none exists.
    - `prompt_device_enrollment` (boolean) Specifies whether users should be prompted to enroll a passkey for the current device if no device-specific passkey exists.
    - `enable_auto_complete` (boolean) Specifies whether passkeys can be auto-filled using the identifier field on the sign-in page.
    - `show_passkey_button` (boolean) Specifies whether the “Continue with Passkey” button is shown on the sign-in page.
  - `email` (PatchEmailAuthenticatorOptionsRequest) Email authenticator configuration.
    - `enable_sign_in` (boolean) Specifies whether users can sign in using email-based authentication.
    - `enable_sign_up` (boolean) Specifies whether new users can sign up using email-based authentication.
    - `enable_jit_provisioning` (boolean) Specifies whether users can be automatically provisioned on first successful email authentication (Just-In-Time provisioning).
    - `verification_type` (string) Specifies the verification mechanism used for email authentication (link, code, or both). One of: `code`, `link`, `both`.
    - `allow_cross_browser` (boolean) Specifies whether the authentication flow can be resumed in a different browser or device than where it was initiated.
    - `expiry` (integer, int32) Specifies the validity period of the email verification link or code (in seconds). Pro plan required to customize the expiry.
    - `code_length` (integer, int32) Specifies the number of digits in the email verification code. Only applicable when the verification type includes code-based verification. Pro plan required to customize the code length.
  - `phone` (PatchPhoneAuthenticatorOptionsRequest) Phone authenticator configuration.
    - `enable_sign_in` (boolean) Specifies whether users can sign in using phone-based authentication.
    - `enable_sign_up` (boolean) Specifies whether new users can sign up using phone-based authentication.
    - `enable_jit_provisioning` (boolean) Specifies whether users can be automatically provisioned on first successful phone authentication (Just-In-Time provisioning).
    - `expiry` (integer, int32) Specifies the validity period of the phone verification code (in seconds). Pro plan required to customize the expiry.
    - `code_length` (integer, int32) Specifies the number of digits in the phone verification code. Pro plan required to customize the code length.
- `identifiers` (PatchIdentifierOptionsRequest) Identifiers Options
  - `email` (PatchEmailIdentifierOptionsRequest) Email Identifier Options
    - `enable_sign_in` (boolean) Specifies whether users can sign in using an email address.
    - `show_at_sign_up` (boolean) Specifies whether an email address can be collected during sign-up.
    - `required_at_sign_up` (boolean) Specifies whether an email address is required during sign-up.
    - `verification` (PatchEmailIdentifierVerificationOptionsRequest) Email verification configuration applied during sign-up.
  - `phone` (PatchPhoneIdentifierOptionsRequest) Phone Identifier Options
    - `enable_sign_in` (boolean) Specifies whether users can sign in using a phone number.
    - `show_at_sign_up` (boolean) Specifies whether a phone number can be collected during sign-up.
    - `required_at_sign_up` (boolean) Specifies whether a phone number is required during sign-up.
    - `verification` (PatchPhoneIdentifierVerificationOptionsRequest) Phone verification configuration applied during sign-up.
  - `username` (PatchUsernameIdentifierOptionsRequest) Username Identifier Options
    - `enable_sign_in` (boolean) Specifies whether users can sign in using a username.
    - `show_at_sign_up` (boolean) Specifies whether a username can be collected during sign-up.
    - `required_at_sign_up` (boolean) Specifies whether a username is required during sign-up.
    - `minimum_length` (integer, int32) Specifies the minimum length required for the username.
- `recovery_methods` (PatchRecoveryMethodsOptionsRequest) Recovery Methods Options
  - `email` (PatchRecoveryMethodsEmailOptionsRequest) Recovery Methods Email Options
    - `enabled` (boolean) Enables account and password recovery using email-based verification.
    - `verification_type` (string) Specifies the verification mechanism used for email password recovery (link, code, or both). One of: `code`, `link`, `both`.
    - `allow_cross_browser` (boolean) Specifies whether the password recovery flow can be resumed in a different browser or device than where it was initiated.
    - `expiry` (integer, int32) Specifies the validity period of the email recovery verification link or code (in seconds). Pro plan required to customize the expiry.
    - `code_length` (integer, int32) Specifies the number of digits in the email recovery verification code. Only applicable when the verification type includes code-based recovery. Pro plan required to customize the code length.
  - `phone` (PatchRecoveryMethodsPhoneOptionsRequest) Recovery Methods Phone Options
    - `enabled` (boolean) Enables account and password recovery using a phone-based verification code.
    - `expiry` (integer, int32) Specifies the validity period of the recovery verification code (in seconds). Pro plan required to customize the expiry.
    - `code_length` (integer, int32) Specifies the number of digits in the recovery verification code. Pro plan required to customize the code length.
- `session` (PatchSessionOptionsRequest) Session Options
  - `persistence_mode` (string) Determines whether the user session is persisted across browser restarts, expires on browser close, or is decided by the user. One of: `persistent`, `non_persistent`, `user_selected`.
  - `expiration_type` (string) Determines whether the session expiration is extended on activity (sliding) or expires at a fixed time (absolute). One of: `sliding`, `absolute`.
  - `sliding_session_lifetime` (integer, int32) The session lifetime applied when using sliding expiration (in minutes). Each qualifying user interaction renews the session up to the absolute limit.
  - `absolute_session_lifetime` (integer, int32) The maximum session lifetime after which the session expires regardless of activity or expiration type (in minutes).
- `logout` (PatchLogoutOptionsRequest) Logout Options
  - `automatic_redirect_after_logout` (boolean) Specifies whether the user is automatically redirected to the client’s configured post-logout redirect URL after signing out.
  - `show_logout_prompt` (boolean) Specifies whether the user is prompted for confirmation before signing out.
- `sign_up` (PatchSignUpOptionsRequest) Sign-up Options
  - `show_terms_and_privacy_policy` (boolean) Show Terms and/or Privacy Policy on the sign-up screen. Pro plan required to enable Terms and/or Privacy Policy.
  - `require_explicit_user_agreement` (boolean) Require the user to explicitly agree to the Terms and/or Privacy Policy. Pro plan required to enable Terms and Privacy Policy.
  - `privacy_url` (string, uri) The URL of the Privacy Policy shown during sign-up. Pro plan required to enable Terms and Privacy Policy.
  - `terms_url` (string, uri) The URL of the Terms of Service shown during sign-up. Pro plan required to enable Terms and Privacy Policy.
  - `allowlist` (PatchSignUpRestrictionsOptionsRequest) Allowlist of identifiers permitted during sign-up.
    - `enabled` (boolean) Indicates whether the identifier restriction list is active. Pro plan subscription required to use sign-up restrictions.
    - `identifiers` (string[]) A set of identifiers (email addresses, phone numbers, or domains) used for sign-up access control. Pro plan subscription required to use sign-up restrictions.
  - `blocklist` (PatchSignUpRestrictionsOptionsRequest) Blocklist of identifiers disallowed during sign-up.
    - `enabled` (boolean) Indicates whether the identifier restriction list is active. Pro plan subscription required to use sign-up restrictions.
    - `identifiers` (string[]) A set of identifiers (email addresses, phone numbers, or domains) used for sign-up access control. Pro plan subscription required to use sign-up restrictions.

## Response body

`200`, JSON. The authentication options were updated successfully

Returns `AuthenticationOptions`.

- `pushed_authorization` (PushedAuthorizationOptions, required) Pushed Authorization Request Options
  - `enable_pushed_authorization_requests` (boolean, required) Specifies whether Pushed Authorization Requests (PAR) are enabled for the tenant.
  - `require_pushed_authorization_requests` (boolean, required) Specifies whether Pushed Authorization Requests (PAR) are required tenant-wide for all authorization requests. When enabled, this setting overrides any client-specific PAR configuration and enforces PAR usage for all clients within the tenant.
- `account_protection` (AccountProtectionOptions, required) Account Protection Options
  - `user_lockout` (AccountProtectionUserLockoutOptions, required) User account protection settings used to safeguard accounts from abuse.
    - `enabled` (boolean, required) Enables user lockout protection.
    - `max_failed_access_attempts` (integer, required, int32) Maximum failed sign-in attempts allowed before lockout (inclusive).
    - `user_lockout_time_span` (integer, required, int32) User account lockout duration (in minutes).
    - `ip_lockout_time_span` (integer, required, int32) IP lockout duration (in minutes).
    - `allowed_ips` (string[], required) Allowlisted IP addresses that are exempt from lockout enforcement.
    - `lockout_type` (string, required) The lockout enforcement mode (IP-based or user-account-based). One of: `ip`, `user_account`.
    - `user_unblock` (AccountProtectionUserUnblockOptions, required) The user unblock configuration.
- `authenticators` (AuthenticatorOptions, required) Authenticators Options
  - `external_sign_in_methods_first` (boolean, required) Determines whether external authentication providers are prioritized over other authenticators during sign-in.
  - `password` (PasswordAuthenticatorOptions, required) Password authenticator configuration.
    - `enable_sign_in` (boolean, required) Specifies whether users can sign in using password-based authentication.
    - `enable_sign_up` (boolean, required) Specifies whether new users can sign up using password-based authentication.
    - `prompt_password_on_initial_screen` (boolean, required) Specifies whether the password is collected on the initial sign-in screen alongside the identifier.
    - `expiry` (integer, int32) Specifies the password expiration interval (in days). When empty, passwords do not expire.
    - `strength` (PasswordStrengthOptions, required) Password strength policy configuration.
    - `reuse` (PasswordReuseOptions, required) Password reuse policy configuration.
  - `passkey` (PasskeyAuthenticatorOptions, required) Passkey authenticator configuration.
    - `enable_sign_in` (boolean, required) Specifies whether users can sign in using passkeys.
    - `enable_sign_up` (boolean, required) Specifies whether new users can sign up using passkeys.
    - `prompt_enrollment` (boolean, required) Specifies whether users should be prompted to enroll a passkey if none exists.
    - `prompt_device_enrollment` (boolean, required) Specifies whether users should be prompted to enroll a passkey for the current device if no device-specific passkey exists.
    - `enable_auto_complete` (boolean, required) Specifies whether passkeys can be auto-filled using the identifier field on the sign-in page.
    - `show_passkey_button` (boolean, required) Specifies whether the “Continue with Passkey” button is shown on the sign-in page.
  - `email` (EmailAuthenticatorOptions, required) Email authenticator configuration.
    - `enable_sign_in` (boolean, required) Specifies whether users can sign in using email-based authentication.
    - `enable_sign_up` (boolean, required) Specifies whether new users can sign up using email-based authentication.
    - `enable_jit_provisioning` (boolean, required) Specifies whether users can be automatically provisioned on first successful email authentication (Just-In-Time provisioning).
    - `verification_type` (string, required) Specifies the verification mechanism used for email authentication (link, code, or both). One of: `code`, `link`, `both`.
    - `allow_cross_browser` (boolean, required) Specifies whether the authentication flow can be resumed in a different browser or device than where it was initiated.
    - `expiry` (integer, required, int32) Specifies the validity period of the email verification link or code (in seconds).
    - `code_length` (integer, required, int32) Specifies the number of digits in the email verification code. Only applicable when the verification type includes code-based verification.
  - `phone` (PhoneAuthenticatorOptions, required) Phone authenticator configuration.
    - `enable_sign_in` (boolean, required) Specifies whether users can sign in using phone-based authentication.
    - `enable_sign_up` (boolean, required) Specifies whether new users can sign up using phone-based authentication.
    - `enable_jit_provisioning` (boolean, required) Specifies whether users can be automatically provisioned on first successful phone authentication (Just-In-Time provisioning).
    - `expiry` (integer, required, int32) Specifies the validity period of the phone verification code (in seconds).
    - `code_length` (integer, required, int32) Specifies the number of digits in the phone verification code.
- `identifiers` (IdentifierOptions, required) Identifiers Options
  - `email` (EmailIdentifierOptions, required) Email Identifier Options
    - `enable_sign_in` (boolean, required) Specifies whether users can sign in using an email address.
    - `show_at_sign_up` (boolean, required) Specifies whether an email address can be collected during sign-up.
    - `required_at_sign_up` (boolean, required) Specifies whether an email address is required during sign-up.
    - `verification` (EmailIdentifierVerificationOptions, required) Email verification configuration applied during sign-up.
  - `phone` (PhoneIdentifierOptions, required) Phone Identifier Options
    - `enable_sign_in` (boolean, required) Specifies whether users can sign in using a phone number.
    - `show_at_sign_up` (boolean, required) Specifies whether a phone number can be collected during sign-up.
    - `required_at_sign_up` (boolean, required) Specifies whether a phone number is required during sign-up.
    - `verification` (PhoneIdentifierVerificationOptions, required) Phone verification configuration applied during sign-up.
  - `username` (UsernameIdentifierOptions, required) Username Identifier Options
    - `enable_sign_in` (boolean, required) Specifies whether users can sign in using a username.
    - `show_at_sign_up` (boolean, required) Specifies whether a username can be collected during sign-up.
    - `required_at_sign_up` (boolean, required) Specifies whether a username is required during sign-up.
    - `minimum_length` (integer, required, int32) Specifies the minimum length required for the username.
- `recovery_methods` (RecoveryMethodsOptions, required) Recovery Methods Options
  - `email` (RecoveryMethodsEmailOptions, required) Recovery Methods Email Options
    - `enabled` (boolean, required) Enables account and password recovery using email-based verification.
    - `verification_type` (string, required) Specifies the verification mechanism used for email password recovery (link, code, or both). One of: `code`, `link`, `both`.
    - `allow_cross_browser` (boolean, required) Specifies whether the password recovery flow can be resumed in a different browser or device than where it was initiated.
    - `expiry` (integer, required, int32) Specifies the validity period of the email recovery verification link or code (in seconds).
    - `code_length` (integer, required, int32) Specifies the number of digits in the email recovery verification code. Only applicable when the verification type includes code-based recovery.
  - `phone` (RecoveryMethodsPhoneOptions, required) Recovery Methods Phone Options
    - `enabled` (boolean, required) Enables account and password recovery using a phone-based verification code.
    - `expiry` (integer, required, int32) Specifies the validity period of the recovery verification code (in seconds).
    - `code_length` (integer, required, int32) Specifies the number of digits in the recovery verification code.
- `session` (SessionOptions, required) Session Options
  - `persistence_mode` (string, required) Determines whether the user session is persisted across browser restarts, expires on browser close, or is decided by the user. One of: `persistent`, `non_persistent`, `user_selected`.
  - `expiration_type` (string, required) Determines whether the session expiration is extended on activity (sliding) or expires at a fixed time (absolute). One of: `sliding`, `absolute`.
  - `sliding_session_lifetime` (integer, required, int32) The session lifetime applied when using sliding expiration (in minutes). Each qualifying user interaction renews the session up to the absolute limit.
  - `absolute_session_lifetime` (integer, required, int32) The maximum session lifetime after which the session expires regardless of activity or expiration type (in minutes).
- `logout` (LogoutOptions, required) Logout Options
  - `automatic_redirect_after_logout` (boolean, required) Specifies whether the user is automatically redirected to the client’s configured post-logout redirect URL after signing out.
  - `show_logout_prompt` (boolean, required) Specifies whether the user is prompted for confirmation before signing out.
- `sign_up` (SignUpOptions, required) Sign-up Options
  - `show_terms_and_privacy_policy` (boolean, required) Show Terms and/or Privacy Policy on the sign-up screen.
  - `require_explicit_user_agreement` (boolean, required) Require the user to explicitly agree to the Terms and/or Privacy Policy.
  - `privacy_url` (string) The URL of the Privacy Policy shown during sign-up.
  - `terms_url` (string) The URL of the Terms of Service shown during sign-up.
  - `allowlist` (SignUpRestrictionsOptions, required) Allowlist of identifiers permitted during sign-up.
    - `enabled` (boolean, required) Indicates whether the identifier restriction list is active. Pro plan subscription required to use sign-up restrictions.
    - `identifiers` (string[], required) A set of identifiers (email addresses, phone numbers, or domains) used for sign-up access control. Pro plan subscription required to use sign-up restrictions.
  - `blocklist` (SignUpRestrictionsOptions, required) Blocklist of identifiers disallowed during sign-up.
    - `enabled` (boolean, required) Indicates whether the identifier restriction list is active. Pro plan subscription required to use sign-up restrictions.
    - `identifiers` (string[], required) A set of identifiers (email addresses, phone numbers, or domains) used for sign-up access control. Pro plan subscription required to use sign-up restrictions.

## Errors

- `400` Bad Request
  - `type` (string, required) A URI reference that identifies the error type. When accessed, it may provide human-readable documentation.
  - `title` (string, required) A short, human-readable summary of the error.
  - `status` (integer, required, int32) The HTTP status code associated with this error response.
  - `trace_id` (string, required) A unique identifier for the request, used for tracing and diagnostics.
  - `detail` (string) A human-readable explanation specific to this occurrence of the error.
  - `instance` (string) A URI reference that identifies the specific occurrence of the error.
- `401` Unauthorized
- `402` Payment Required
  Same body as `400`.
- `403` Forbidden
- `404` Not Found
  Same body as `400`.
- `422` Unprocessable Entity
  - `type` (string, required) A URI reference that identifies the error type. When accessed, it may provide human-readable documentation.
  - `title` (string, required) A short, human-readable summary of the error.
  - `status` (integer, required, int32) The HTTP status code associated with this error response.
  - `trace_id` (string, required) A unique identifier for the request, used for tracing and diagnostics.
  - `detail` (string) A human-readable explanation specific to this occurrence of the error.
  - `instance` (string) A URI reference that identifies the specific occurrence of the error.
  - `errors` (Record<string, string[]>, required) A key-value map of validation errors, where each key represents a request field and the value contains one or more messages describing why the request could not be processed.

## Example (MonoCloud .NET SDK)

```csharp
using MonoCloud.Management;
using MonoCloud.Management.Models;
using MonoCloud.Management.Core.Base;

var apiClient = new MonoCloudManagementClient(new MonoCloudConfig("<your-domain>", "[[API-Key]]"));


var requestBody = new PatchAuthenticationOptionsRequest
  {
    PushedAuthorization = new PatchPushedAuthorizationOptionsRequest
    {
      EnablePushedAuthorizationRequests = false,
      RequirePushedAuthorizationRequests = false,
    },
    AccountProtection = new PatchAccountProtectionOptionsRequest
    {
      UserLockout = new PatchAccountProtectionUserLockoutOptionsRequest
      {
        Enabled = true,
        MaxFailedAccessAttempts = 5,
        UserLockoutTimeSpan = 5,
        IpLockoutTimeSpan = 43200,
        AllowedIps = new List<string>
        {
          "156.3.59.5",
          "184.220.154.65",
        },
        LockoutType = UserLockoutTypes.Ip,
        UserUnblock = new PatchAccountProtectionUserUnblockOptionsRequest
        {
          Email = new PatchAccountProtectionUserUnblockEmailOptionsRequest
          {
            Expiry = 300,
          },
        },
      },
    },
    Authenticators = new PatchAuthenticatorOptionsRequest
    {
      ExternalSignInMethodsFirst = true,
      Password = new PatchPasswordAuthenticatorOptionsRequest
      {
        EnableSignIn = true,
        EnableSignUp = true,
        PromptPasswordOnInitialScreen = false,
        Expiry = 30,
        Strength = new PatchPasswordStrengthOptionsRequest
        {
          MinimumLength = 16,
          RequireNonAlphanumericCharacter = true,
          RequireDigit = true,
          RequireLowercaseCharacter = true,
          RequireUppercaseCharacter = true,
          RequiredUniqueCharactersCount = 4,
        },
        Reuse = new PatchPasswordReuseOptionsRequest
        {
          RestrictionMode = PasswordRestrictionModes.Off,
          RestrictionPeriod = 43200,
          RestrictionCount = 5,
        },
      },
      Passkey = new PatchPasskeyAuthenticatorOptionsRequest
      {
        EnableSignIn = false,
        EnableSignUp = false,
        PromptEnrollment = true,
        PromptDeviceEnrollment = true,
        EnableAutoComplete = true,
        ShowPasskeyButton = true,
      },
      Email = new PatchEmailAuthenticatorOptionsRequest
      {
        EnableSignIn = true,
        EnableSignUp = true,
        EnableJitProvisioning = true,
        VerificationType = VerificationTypes.Link,
        AllowCrossBrowser = true,
        Expiry = 30,
        CodeLength = 6,
      },
      Phone = new PatchPhoneAuthenticatorOptionsRequest
      {
        EnableSignIn = true,
        EnableSignUp = true,
        EnableJitProvisioning = true,
        Expiry = 30,
        CodeLength = 6,
      },
    },
    Identifiers = new PatchIdentifierOptionsRequest
    {
      Email = new PatchEmailIdentifierOptionsRequest
      {
        EnableSignIn = true,
        ShowAtSignUp = true,
        RequiredAtSignUp = true,
        Verification = new PatchEmailIdentifierVerificationOptionsRequest
        {
          VerifyAtSignUp = true,
          VerificationType = VerificationTypes.Link,
          AllowCrossBrowser = true,
          Expiry = 300,
          CodeLength = 6,
        },
      },
      Phone = new PatchPhoneIdentifierOptionsRequest
      {
        EnableSignIn = true,
        ShowAtSignUp = true,
        RequiredAtSignUp = true,
        Verification = new PatchPhoneIdentifierVerificationOptionsRequest
        {
          VerifyAtSignUp = true,
          Expiry = 300,
          CodeLength = 6,
        },
      },
      Username = new PatchUsernameIdentifierOptionsRequest
      {
        EnableSignIn = true,
        ShowAtSignUp = true,
        RequiredAtSignUp = true,
        MinimumLength = 3,
      },
    },
    RecoveryMethods = new PatchRecoveryMethodsOptionsRequest
    {
      Email = new PatchRecoveryMethodsEmailOptionsRequest
      {
        Enabled = true,
        VerificationType = VerificationTypes.Link,
        AllowCrossBrowser = false,
        Expiry = 300,
        CodeLength = 6,
      },
      Phone = new PatchRecoveryMethodsPhoneOptionsRequest
      {
        Enabled = true,
        Expiry = 300,
        CodeLength = 6,
      },
    },
    Session = new PatchSessionOptionsRequest
    {
      PersistenceMode = SessionPersistenceModes.UserSelected,
      ExpirationType = SessionExpirationTypes.Sliding,
      SlidingSessionLifetime = 1440,
      AbsoluteSessionLifetime = 14400,
    },
    Logout = new PatchLogoutOptionsRequest
    {
      AutomaticRedirectAfterLogout = true,
      ShowLogoutPrompt = true,
    },
    SignUp = new PatchSignUpOptionsRequest
    {
      ShowTermsAndPrivacyPolicy = true,
      RequireExplicitUserAgreement = true,
      PrivacyUrl = "https://acme.com/privacy",
      TermsUrl = "https://acme.com/terms",
      Allowlist = new PatchSignUpRestrictionsOptionsRequest
      {
        Enabled = true,
        Identifiers = new List<string>
        {
          "organization.com",
          "example@organization.com",
          "+1234567890",
        },
      },
      Blocklist = new PatchSignUpRestrictionsOptionsRequest
      {
        Enabled = true,
        Identifiers = new List<string>
        {
          "organization.com",
          "example@organization.com",
          "+1234567890",
        },
      },
    },
  };


var result = await apiClient.Options.PatchAuthenticationOptionsAsync(requestBody);
```

## Example (MonoCloud Javascript SDK)

```javascript
import { MonoCloudManagementClient } from '@monocloud/management';

const apiClient = MonoCloudManagementClient.init({ domain: '<your-domain>', apiKey: '[[API-Key]]' });

const requestBody = {
  pushed_authorization: {
    enable_pushed_authorization_requests: false,
    require_pushed_authorization_requests: false
  },
  account_protection: {
    user_lockout: {
      enabled: true,
      max_failed_access_attempts: 5,
      user_lockout_time_span: 5,
      ip_lockout_time_span: 43200,
      allowed_ips: [
        '156.3.59.5',
        '184.220.154.65'
      ],
      lockout_type: 'ip',
      user_unblock: {
        email: {
          expiry: 300
        }
      }
    }
  },
  authenticators: {
    external_sign_in_methods_first: true,
    password: {
      enable_sign_in: true,
      enable_sign_up: true,
      prompt_password_on_initial_screen: false,
      expiry: 30,
      strength: {
        minimum_length: 16,
        require_non_alphanumeric_character: true,
        require_digit: true,
        require_lowercase_character: true,
        require_uppercase_character: true,
        required_unique_characters_count: 4
      },
      reuse: {
        restriction_mode: 'off',
        restriction_period: 43200,
        restriction_count: 5
      }
    },
    passkey: {
      enable_sign_in: false,
      enable_sign_up: false,
      prompt_enrollment: true,
      prompt_device_enrollment: true,
      enable_auto_complete: true,
      show_passkey_button: true
    },
    email: {
      enable_sign_in: true,
      enable_sign_up: true,
      enable_jit_provisioning: true,
      verification_type: 'link',
      allow_cross_browser: true,
      expiry: 30,
      code_length: 6
    },
    phone: {
      enable_sign_in: true,
      enable_sign_up: true,
      enable_jit_provisioning: true,
      expiry: 30,
      code_length: 6
    }
  },
  identifiers: {
    email: {
      enable_sign_in: true,
      show_at_sign_up: true,
      required_at_sign_up: true,
      verification: {
        verify_at_sign_up: true,
        verification_type: 'link',
        allow_cross_browser: true,
        expiry: 300,
        code_length: 6
      }
    },
    phone: {
      enable_sign_in: true,
      show_at_sign_up: true,
      required_at_sign_up: true,
      verification: {
        verify_at_sign_up: true,
        expiry: 300,
        code_length: 6
      }
    },
    username: {
      enable_sign_in: true,
      show_at_sign_up: true,
      required_at_sign_up: true,
      minimum_length: 3
    }
  },
  recovery_methods: {
    email: {
      enabled: true,
      verification_type: 'link',
      allow_cross_browser: false,
      expiry: 300,
      code_length: 6
    },
    phone: {
      enabled: true,
      expiry: 300,
      code_length: 6
    }
  },
  session: {
    persistence_mode: 'user_selected',
    expiration_type: 'sliding',
    sliding_session_lifetime: 1440,
    absolute_session_lifetime: 14400
  },
  logout: {
    automatic_redirect_after_logout: true,
    show_logout_prompt: true
  },
  sign_up: {
    show_terms_and_privacy_policy: true,
    require_explicit_user_agreement: true,
    privacy_url: 'https://acme.com/privacy',
    terms_url: 'https://acme.com/terms',
    allowlist: {
      enabled: true,
      identifiers: [
        'organization.com',
        'example@organization.com',
        '+1234567890'
      ]
    },
    blocklist: {
      enabled: true,
      identifiers: [
        'organization.com',
        'example@organization.com',
        '+1234567890'
      ]
    }
  }
};

const result = apiClient.options.patchAuthenticationOptions(requestBody);
```