---
title: "Update auth configuration"
method: PUT
path: "/projects/{id}/auth/config"
tags: ["Auth Configuration"]
---

# Update auth configuration

`PUT /projects/{id}/auth/config`

## Request

- Base URL: `https://api.volcano.dev`
- URL: `https://api.volcano.dev/projects/{id}/auth/config`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

Updates the project's auth configuration. Only the fields present in
the body are changed.

## Path parameters

- `id` string, uuid, required

## Request body

- UpdateAuthConfigRequest: All fields optional - only include fields you want to update. Validation rule: require_email_confirmation=true requires email_enabled=true.
  - `access_token_lifetime` integer
  - `refresh_token_lifetime` integer
  - `refresh_token_reuse_interval` integer
  - `inactivity_timeout` integer
  - `max_session_duration` integer
  - `platform_token_ttl` integer: TTL in seconds for platform tokens minted via `/auth/platform/exchange`. From 3600 (1 hour) to 31536000 (365 days).
  - `min_password_length` integer
  - `require_uppercase` boolean
  - `require_lowercase` boolean
  - `require_numbers` boolean
  - `require_special_chars` boolean
  - `enable_signup` boolean: Master switch for signups across ALL providers
  - `enable_email_password` boolean: Enable/disable email/password provider
  - `rate_limit_signup` integer
  - `rate_limit_signin` integer
  - `rate_limit_token_refresh` integer
  - `rate_limit_password_reset` integer: Password reset requests per hour per IP. Unlike the other limits, 0 applies the default of 10 instead of turning the limit off.
  - `cors_enabled` boolean
  - `cors_allowed_origins` string[]: Replaces the allowed origins list.
  - `cors_allow_credentials` boolean
  - `cors_max_age` integer
  - `enable_anonymous_signins` boolean
  - `allowed_email_domains` string[]: Replaces the email domain allowlist. Empty array removes the restriction so any domain can sign up. Entries must be bare domains such as `domain1.com` and are stored normalized (lowercase, no `@` prefix); matching is exact, so subdomains need their own entry. At most 100 entries. Restricting signups is a SUPERAGENT feature to configure and to enforce: a HOBBY project can only remove the restriction and gets 403 for any other change, and the list it keeps is parked until it upgrades.
  - `allowed_email_domains_mode` 'disabled' | 'signup' | 'signup_and_signin': How far `allowed_email_domains` reaches. `signup` gates account creation only. `signup_and_signin` also blocks sign-in for accounts outside the list; switching to it, or narrowing the list while in it, deletes the sessions of every account it locks out. `disabled` keeps the list without enforcing it.
  - `allow_password_reset` boolean
  - `password_reset_timeout` integer
  - `max_password_history` integer
  - `require_email_confirmation` boolean: Require users to confirm email before sign-in. Can only be true when email_enabled is true.
  - `email_confirmation_timeout` integer: Email confirmation token expiry in seconds.
  - `auto_link_verified_oauth` boolean: Link a verified OAuth identity to an existing confirmed account with the same email instead of returning a conflict. Requires require_email_confirmation to be true.
  - `email_enabled` boolean: Enable transactional email sending. Cannot be false while require_email_confirmation is true.
  - `email_from_address` string: Sender email address. New or changed values containing carriage returns or newlines return 400. Unchanged stored or exported values are preserved. Leading and trailing whitespace in previously saved settings is ignored when sending.
  - `email_from_name` string: Sender display name; supports punctuation and Unicode. New or changed values containing carriage returns or newlines return 400. Unchanged stored or exported values are preserved. Leading and trailing whitespace in previously saved settings is ignored when sending.
  - `smtp_host` string
  - `smtp_port` integer
  - `smtp_username` string
  - `smtp_password` string, password: Replacement SMTP password. Omit this field to preserve the configured password. The value is encrypted at rest and never returned.
  - `smtp_use_tls` boolean
  - `email_confirmation_subject` string: Subject template. For new or changed values, literal interior carriage returns or newlines after Go template whitespace trimming return 400. Outer whitespace and trailing block-scalar newlines are allowed. Unchanged stored subjects are preserved.
  - `email_password_reset_subject` string: Subject template. For new or changed values, literal interior carriage returns or newlines after Go template whitespace trimming return 400. Outer whitespace and trailing block-scalar newlines are allowed. Unchanged stored subjects are preserved.
  - `email_password_changed_subject` string: Subject template. For new or changed values, literal interior carriage returns or newlines after Go template whitespace trimming return 400. Outer whitespace and trailing block-scalar newlines are allowed. Unchanged stored subjects are preserved.
  - `managed_auth_enabled` boolean: Enable or disable managed auth hosted pages for the project.
  - `post_auth_redirect_url` string: Must be included in allowed_redirect_urls when set.
  - `allowed_redirect_urls` string[]: Redirect allowlist. Every entry must be a valid http/https URL.
  - `post_logout_redirect_url` string: Must be included in allowed_redirect_urls when set.
  - `device_verification_url` string: Optional custom device-authorization verification page. Must be a valid http/https URL (not tied to allowed_redirect_urls). When set, device-code logins return this URL (with user_code) instead of the managed device page. Send an empty string to clear the override.

## Response `200`

Configuration updated

- AuthConfig
  - `project_id` string, uuid
  - `access_token_lifetime` integer: Access token lifetime in seconds
  - `refresh_token_lifetime` integer: Refresh token lifetime in seconds
  - `refresh_token_reuse_interval` integer: A refresh within this many seconds of the refresh token being issued returns the same refresh token instead of rotating it, so concurrent refreshes from several tabs all succeed
  - `inactivity_timeout` integer: Force re-login after inactivity (seconds, 0=never)
  - `max_session_duration` integer: Force re-login after duration (seconds, 0=never)
  - `min_password_length` integer: Configured minimum password length in Unicode characters.
  - `password_policy` AuthPasswordPolicy, required: Effective backend-enforced password policy.
    - `effective_min_length` integer, required: Effective minimum password length in Unicode characters.
    - `min_configurable_length` integer, required: Lowest minimum password length accepted by the auth configuration endpoint.
    - `max_length` integer, required: Maximum password length in Unicode characters.
    - `require_uppercase` boolean, required: Whether passwords must contain an ASCII uppercase letter (A-Z).
    - `require_lowercase` boolean, required: Whether passwords must contain an ASCII lowercase letter (a-z).
    - `require_numbers` boolean, required: Whether passwords must contain an ASCII digit (0-9).
    - `require_special_chars` boolean, required: Whether passwords must contain one of the backend-supported special characters.
    - `compromised_passwords_rejected` boolean, required: Whether common and known-compromised passwords are rejected by the backend.
  - `require_uppercase` boolean
  - `require_lowercase` boolean
  - `require_numbers` boolean
  - `require_special_chars` boolean
  - `enable_signup` boolean: Master switch - allow new user signups via ANY provider
  - `enable_email_password` boolean: Enable email/password authentication as a provider
  - `rate_limit_signup` integer: Signups per hour per IP
  - `rate_limit_signin` integer: Signins per hour per IP
  - `rate_limit_token_refresh` integer: Refreshes per hour per IP
  - `rate_limit_password_reset` integer: Password reset requests per hour per IP. Unlike the other limits, 0 applies the default of 10 instead of turning the limit off.
  - `cors_enabled` boolean
  - `cors_allowed_origins` string[]
  - `enable_anonymous_signins` boolean: Allow creating users without email/password
  - `allowed_email_domains` string[]: Email domains allowed to create users in this project. Applies to email/password signup, OAuth/SSO signup, anonymous conversion, and email changes. Empty (the default) allows every domain. Entries are stored normalized (lowercase, no `@` prefix) and match the domain part exactly: `domain1.com` does not cover `mail.domain1.com`. Signups from other domains are rejected with 403, and `allowed_email_domains_mode` decides whether sign-in is covered as well. The allowlist is a SUPERAGENT feature to configure and to enforce. A downgrade parks it: the domains are still returned here and stop being applied until the project is back on SUPERAGENT.
  - `allowed_email_domains_mode` 'disabled' | 'signup' | 'signup_and_signin': How far `allowed_email_domains` reaches. `signup` only gates account creation, so accounts that predate the list keep signing in. `signup_and_signin` also refuses to issue a session to an account whose domain is not listed. `disabled` keeps the list without enforcing it.
  - `platform_token_ttl` integer: TTL in seconds for platform tokens minted via `/auth/platform/exchange`
  - `allow_password_reset` boolean: Enable forgot password flow
  - `password_reset_timeout` integer: Recovery token expiry in seconds
  - `max_password_history` integer: Number of previous passwords to remember (0=disabled)
  - `cors_allow_credentials` boolean: Allow credentials in CORS requests
  - `cors_max_age` integer: CORS preflight cache duration (seconds)
  - `require_email_confirmation` boolean: Require users to confirm email before sign-in. Can only be true when email_enabled is true.
  - `email_confirmation_timeout` integer: Email confirmation token expiry in seconds.
  - `auto_link_verified_oauth` boolean: Link a verified OAuth identity to an existing confirmed account with the same email instead of returning a conflict. Requires require_email_confirmation to be true.
  - `email_enabled` boolean: Enable transactional email sending (confirmation, reset, change notifications). Must be true when require_email_confirmation is true.
  - `email_from_address` string: Sender email address. New or changed values containing carriage returns or newlines return 400. Unchanged stored or exported values are preserved. Leading and trailing whitespace in previously saved settings is trimmed in responses and exports, and ignored when sending.
  - `email_from_name` string: Sender display name; supports punctuation and Unicode. New or changed values containing carriage returns or newlines return 400. Unchanged stored or exported values are preserved. Leading and trailing whitespace in previously saved settings is trimmed in responses and exports, and ignored when sending.
  - `smtp_host` string
  - `smtp_port` integer
  - `smtp_username` string
  - `smtp_password_configured` boolean: Whether an SMTP password is configured. The password itself is never returned.
  - `smtp_use_tls` boolean
  - `email_confirmation_subject` string
  - `email_password_reset_subject` string
  - `email_password_changed_subject` string
  - `managed_auth_enabled` boolean: Enables project-hosted managed auth pages.
  - `post_auth_redirect_url` string: Default redirect target after successful hosted auth.
  - `allowed_redirect_urls` string[]: Redirect allowlist used to validate post_auth_redirect_url and post_logout_redirect_url.
  - `post_logout_redirect_url` string: Redirect target after logout from hosted pages.
  - `device_verification_url` string: Optional override for the device-authorization verification page. When set, POST /auth/device/authorize returns this URL (with the user_code) as verification_uri/verification_uri_complete instead of the built-in managed device page. Lets a CLI surface the project's own RFC 8628 approval page. Empty falls back to the managed page.
  - `created_at` string, date-time
  - `updated_at` string, date-time

## Other responses

- `400`: Invalid auth configuration, including a subject with a literal interior carriage return or newline
- `403`: The update would turn on, widen, or otherwise edit the email domain allowlist (`allowed_email_domains`, `allowed_email_domains_mode`) for a project that is not on the SUPERAGENT plan. A HOBBY project keeps whatever allowlist it already has — parked, enforcing nothing until it upgrades — and may still remove it, so a downgrade never leaves a project locked out of its own signups.

## Changes

- **2026-10-26** `4b0676e06128`: 1 info
  - added the non-success response with the status `400`
- **2026-10-14** `d8d8f53d847b`: 9 info
  - added the new optional request property `cors_allowed_origins`
  - added the new optional request property `cors_enabled`
  - added the new optional request property `platform_token_ttl`
  - added the new optional request property `rate_limit_password_reset`
  - …5 more
- **2026-10-07** `23e7875e7c4c`: 1 info
  - the endpoint scheme security `ProjectAccessToken` was added to the API
- **2026-09-19** `3a6f365f3f35`: 4 breaking, 89 info
  - added the new path request parameter `id`
  - the request's body type changed from no type to `object`
  - the response's body type changed from no type to `object` for status `200`
  - the response's body type changed from no type to `object` for status `403`
  - …89 more
- **2026-08-27** `bb44e98aba2e`: 2 breaking, 83 warning, 1 info
  - the request's body type changed from `object` to no type
  - the response's body type changed from `object` to no type for status `200`
  - deleted the `path` request parameter `id`
  - removed the request property `access_token_lifetime`
  - …82 more

[Operation history](https://skmtc.dev/kong/apis/volcano-api/changes/projects/:id/auth/config/put.md)

---

[API](https://skmtc.dev/kong/apis/volcano-api.md) - [All operations](https://skmtc.dev/kong/apis/volcano-api/llms.txt) - [OpenAPI document](https://skmtc.dev/kong/apis/volcano-api/revisions/84c4488f91e9?raw)
