{"openapi":"3.1.0","info":{"title":"OEC.sh","description":"Platform for deploying Odoo Community Edition","version":"1.88.14"},"paths":{"/health":{"get":{"summary":"Health Check","description":"Health check with actual DB and Redis connectivity checks.","operationId":"health_check_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Health Check Health Get"}}}}}}},"/ready":{"get":{"summary":"Readiness Probe","description":"Lightweight readiness probe — no DB/Redis calls.\n\nUse this for load balancer health checks and high-frequency polling.\nReserve /health for deep diagnostics.","operationId":"readiness_probe_ready_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object","title":"Response Readiness Probe Ready Get"}}}}}}},"/":{"get":{"summary":"Root","description":"Root endpoint","operationId":"root__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v1/auth/providers":{"get":{"tags":["Authentication"],"summary":"Get Auth Providers","description":"Get list of enabled authentication providers.\n\nReturns which OAuth providers and email/password auth are enabled\nfor this deployment. Frontend uses this to show/hide login options.","operationId":"get_auth_providers_api_v1_auth_providers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthProvidersResponse"}}}}}}},"/api/v1/auth/register":{"post":{"tags":["Authentication"],"summary":"Register","description":"Register a new user with email and password.\n\nCreates a new user account. The user will need to verify their email\nto access all features.","operationId":"register_api_v1_auth_register_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/login":{"post":{"tags":["Authentication"],"summary":"Login","description":"Login with email and password.\n\nReturns JWT tokens on successful authentication.\nIf 2FA is enabled, returns a temporary token that must be verified.\n\nQuery param ``fallback=password`` (committee S5): allows an SSO-only org\nOWNER to bypass the IdP. The owner-membership check runs BEFORE password\nverification to avoid leaking a timing oracle on user existence /\npassword correctness for non-owners. Spec §5.11.","operationId":"login_api_v1_auth_login_post","parameters":[{"name":"fallback","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fallback"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserLogin"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TokenResponse"},{"$ref":"#/components/schemas/TwoFactorRequiredResponse"},{"$ref":"#/components/schemas/TokenResponse"},{"$ref":"#/components/schemas/TwoFactorRequiredResponse"}],"title":"Response 200 Login Api V1 Auth Login Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/refresh":{"post":{"tags":["Authentication"],"summary":"Refresh Token","description":"Refresh access token using refresh token.\n\nThe refresh token can be provided either:\n1. In the request body (for backward compatibility with localStorage-based auth)\n2. In an httpOnly cookie (preferred, more secure)\n\nSecurity: Validates that the refresh token was issued after the user's last password change.\n\nArgs:\n    request: FastAPI request object (for reading cookies)\n    response: FastAPI response object (for setting new cookies)\n    refresh_token: Valid refresh token (optional if using cookies)\n\nReturns:\n    New access and refresh tokens (also sets httpOnly cookies)","operationId":"refresh_token_api_v1_auth_refresh_post","parameters":[{"name":"refresh_token","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/me":{"get":{"tags":["Authentication"],"summary":"Get Current User Info","description":"Get current authenticated user's information.\n\nReachable by a staff session that is not yet MFA-verified, so the frontend\ncan show the forced \"Set up two-factor authentication\" step\n(``staff_mfa_required``).","operationId":"get_current_user_info_api_v1_auth_me_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/me/sign-ins":{"get":{"tags":["Authentication"],"summary":"List My Sign Ins","description":"#1431 (DPA): the caller's last 50 sign-in, failed sign-in, two-factor and\npassword events. Self-service: only rows whose user_id is the caller, so\nno org permission applies (these rows are written without an org).","operationId":"list_my_sign_ins_api_v1_auth_me_sign_ins_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SignInListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/logout":{"post":{"tags":["Authentication"],"summary":"Logout","description":"Logout current user.\n\nOWASP A07:2021 - Proper session invalidation:\n1. Adds the access token to Redis blacklist (prevents reuse)\n2. Clears httpOnly authentication cookies from the browser\n\nThe token remains in the blacklist until its natural expiration time.","operationId":"logout_api_v1_auth_logout_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Logout Api V1 Auth Logout Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/onboarding-status":{"get":{"tags":["Authentication"],"summary":"Get Onboarding Status","description":"Get the current user's onboarding status.\n\nReturns information about:\n- Whether user needs to complete onboarding (no organizations)\n- List of user's organizations\n- Pending invitations for the user's email","operationId":"get_onboarding_status_api_v1_auth_onboarding_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OnboardingStatus"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/change-password":{"post":{"tags":["Authentication"],"summary":"Change Password","description":"Change password for the current user.\n\nRequires the current password for verification.","operationId":"change_password_api_v1_auth_change_password_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordChange"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Change Password Api V1 Auth Change Password Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/set-password":{"post":{"tags":["Authentication"],"summary":"Set Password","description":"Set a password for a social login user.\n\nAllows users who signed up via OAuth to set a password\nfor email/password login as an alternative.","operationId":"set_password_api_v1_auth_set_password_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Set Password Api V1 Auth Set Password Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/forgot-password":{"post":{"tags":["Authentication"],"summary":"Forgot Password","description":"Request a password reset email.\n\nAlways returns success to prevent email enumeration.\nGenerates a JWT token valid for 60 minutes and sends it via email.","operationId":"forgot_password_api_v1_auth_forgot_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordReset"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Forgot Password Api V1 Auth Forgot Password Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/reset-password":{"post":{"tags":["Authentication"],"summary":"Reset Password","description":"Reset password using reset token.\n\nThe token is a JWT received via email after requesting password reset.","operationId":"reset_password_api_v1_auth_reset_password_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasswordResetConfirm"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Reset Password Api V1 Auth Reset Password Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/verify-email":{"post":{"tags":["Authentication"],"summary":"Verify Email","description":"Verify user email using verification token.\n\nMarks the user as verified and invalidates the token.","operationId":"verify_email_api_v1_auth_verify_email_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailVerificationRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Verify Email Api V1 Auth Verify Email Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/login-email-change/preview":{"post":{"tags":["Authentication"],"summary":"Preview Login Email Change","description":"Read-only: the masked new address and whether a 2FA code is needed.","operationId":"preview_login_email_change_api_v1_auth_login_email_change_preview_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginEmailChangePreviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"anyOf":[{"type":"string"},{"type":"boolean"}]},"title":"Response Preview Login Email Change Api V1 Auth Login Email Change Preview Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/login-email-change/confirm":{"post":{"tags":["Authentication"],"summary":"Confirm Login Email Change","description":"Apply a login email change started by support (#1175). Step-up as\n/auth/change-password (current password), plus the 2FA code when 2FA is on.\nSigns the user out everywhere.","operationId":"confirm_login_email_change_api_v1_auth_login_email_change_confirm_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginEmailChangeConfirmRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Confirm Login Email Change Api V1 Auth Login Email Change Confirm Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/resend-verification":{"post":{"tags":["Authentication"],"summary":"Resend Verification Email","description":"Resend verification email to user.\n\nRate-limited to prevent spam. Always returns success to prevent email enumeration.","operationId":"resend_verification_email_api_v1_auth_resend_verification_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ResendVerificationRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Resend Verification Email Api V1 Auth Resend Verification Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/verify-2fa":{"post":{"tags":["Authentication"],"summary":"Verify 2Fa","description":"Verify 2FA code and complete login.\n\nAfter successful email/password login when 2FA is enabled,\nthis endpoint verifies the TOTP code and returns final tokens.\nAlso sets httpOnly cookies for XSS protection.","operationId":"verify_2fa_api_v1_auth_verify_2fa_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TwoFactorVerify"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/2fa/step-up":{"post":{"tags":["Authentication"],"summary":"Step Up 2Fa","description":"Upgrade the current session to MFA-verified with a TOTP or backup code.\n\nUsed when a staff member signed in without the second factor (GitHub /\nGoogle / SSO login, or a session from before staff MFA enforcement):\nplatform staff capabilities need an MFA-verified session (core.staff_mfa).\nIssues new tokens (httpOnly cookies) carrying the MFA claim.","operationId":"step_up_2fa_api_v1_auth_2fa_step_up_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TOTPEnableRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/2fa/setup":{"post":{"tags":["Authentication"],"summary":"Setup 2Fa","description":"Generate a new TOTP secret for 2FA setup.\n\nReturns the secret, QR code URI, and backup codes.\nThe user must verify with /2fa/enable to actually enable 2FA.","operationId":"setup_2fa_api_v1_auth_2fa_setup_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TOTPSetupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/2fa/enable":{"post":{"tags":["Authentication"],"summary":"Enable 2Fa","description":"Enable 2FA by verifying a TOTP code.\n\nMust be called after /2fa/setup with a valid code from the authenticator app.\nThe code just proved possession of the factor, so the current session is\nupgraded to MFA-verified (new httpOnly cookies); a staff member completing\nthe forced setup step can continue without signing in again.","operationId":"enable_2fa_api_v1_auth_2fa_enable_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TOTPEnableRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Enable 2Fa Api V1 Auth 2Fa Enable Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/2fa/disable":{"post":{"tags":["Authentication"],"summary":"Disable 2Fa","description":"Disable 2FA.\n\nRequires both a valid TOTP code and the account password for security.","operationId":"disable_2fa_api_v1_auth_2fa_disable_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TOTPDisableRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Disable 2Fa Api V1 Auth 2Fa Disable Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/2fa/backup-codes":{"get":{"tags":["Authentication"],"summary":"Get Backup Codes","description":"Get remaining backup codes.\n\nReturns the current backup codes and how many are remaining.","operationId":"get_backup_codes_api_v1_auth_2fa_backup_codes_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"integer"}]},"title":"Response Get Backup Codes Api V1 Auth 2Fa Backup Codes Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/2fa/regenerate-backup-codes":{"post":{"tags":["Authentication"],"summary":"Regenerate Backup Codes","description":"Regenerate backup codes.\n\nRequires a valid TOTP code. Previous backup codes will be invalidated.","operationId":"regenerate_backup_codes_api_v1_auth_2fa_regenerate_backup_codes_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TOTPEnableRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"array","items":{"type":"string"}},"title":"Response Regenerate Backup Codes Api V1 Auth 2Fa Regenerate Backup Codes Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/2fa/status":{"get":{"tags":["Authentication"],"summary":"Get 2Fa Status","description":"Get 2FA status for current user.","operationId":"get_2fa_status_api_v1_auth_2fa_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"anyOf":[{"type":"boolean"},{"type":"integer"}]},"title":"Response Get 2Fa Status Api V1 Auth 2Fa Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/mfa/setup":{"post":{"tags":["Authentication","MFA"],"summary":"Setup Mfa","description":"Generate a new TOTP secret for MFA setup.\n\nThis endpoint initiates the MFA setup process by:\n1. Generating a new TOTP secret key\n2. Creating a QR code URI for authenticator apps\n3. Storing the secret temporarily (not enabled yet)\n\nThe secret will only be activated after verification via /mfa/verify.\n\nReturns:\n    MFASetupResponse: Contains secret, QR URI (backup codes only after verification)","operationId":"setup_mfa_api_v1_auth_mfa_setup_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MFASetupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/mfa/verify":{"post":{"tags":["Authentication","MFA"],"summary":"Verify Mfa","description":"Verify MFA code during login or for MFA operations.\n\nThis endpoint can be used for:\n1. Verifying TOTP code during login (when MFA is enabled)\n2. Verifying backup code as fallback\n3. Testing MFA setup before enabling\n\nArgs:\n    data: Contains the TOTP code or backup code\n\nReturns:\n    MFAVerifyResponse: Verification result with success message","operationId":"verify_mfa_api_v1_auth_mfa_verify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MFAVerifyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MFAVerifyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/mfa/enable":{"post":{"tags":["Authentication","MFA"],"summary":"Enable Mfa","description":"Enable MFA by verifying a TOTP code.\n\nThis endpoint:\n1. Verifies the provided TOTP code\n2. Enables MFA on the account\n3. Generates backup codes for recovery\n4. Returns backup codes (SAVE THESE SECURELY!)\n\nArgs:\n    data: Contains the TOTP code for verification\n\nReturns:\n    MFAEnableResponse: Success status, message, and backup codes","operationId":"enable_mfa_api_v1_auth_mfa_enable_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MFAEnableRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MFAEnableResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/mfa/disable":{"post":{"tags":["Authentication","MFA"],"summary":"Disable Mfa","description":"Disable MFA for the current user.\n\nThis endpoint:\n1. Disables MFA on the account\n2. Removes TOTP secret and backup codes\n3. Logs the security event\n\nArgs:\n    data: Optional password for additional verification\n\nReturns:\n    MFADisableResponse: Success status and message","operationId":"disable_mfa_api_v1_auth_mfa_disable_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MFADisableRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MFADisableResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/mfa/status":{"get":{"tags":["Authentication","MFA"],"summary":"Get Mfa Status","description":"Get MFA status for the current user.\n\nReturns:\n    MFAStatusResponse: Whether MFA is enabled and backup codes remaining","operationId":"get_mfa_status_api_v1_auth_mfa_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MFAStatusResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/mfa/backup-codes/regenerate":{"post":{"tags":["Authentication","MFA"],"summary":"Regenerate Backup Codes","description":"Regenerate backup codes for MFA recovery.\n\nThis endpoint:\n1. Generates new backup codes\n2. Invalidates all previous backup codes\n3. Resets the used codes list\n\nReturns:\n    RegenerateBackupCodesResponse: New backup codes (SAVE THESE!)","operationId":"regenerate_backup_codes_api_v1_auth_mfa_backup_codes_regenerate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegenerateBackupCodesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/mfa/backup-codes/remaining":{"get":{"tags":["Authentication","MFA"],"summary":"Get Backup Codes Remaining","description":"Get the number of remaining backup codes.\n\nReturns:\n    dict: Number of unused backup codes remaining","operationId":"get_backup_codes_remaining_api_v1_auth_mfa_backup_codes_remaining_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"integer"},"title":"Response Get Backup Codes Remaining Api V1 Auth Mfa Backup Codes Remaining Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/github/login":{"get":{"tags":["Authentication"],"summary":"Github Login Url","description":"Get GitHub OAuth login URL.\n\nReturns:\n    URL to redirect user to for GitHub authentication","operationId":"github_login_url_api_v1_auth_github_login_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Github Login Url Api V1 Auth Github Login Get"}}}}}}},"/api/v1/auth/gitlab/login":{"get":{"tags":["Authentication"],"summary":"Gitlab Login Url","description":"Get GitLab OAuth login URL.\n\nReturns:\n    URL to redirect user to for GitLab authentication","operationId":"gitlab_login_url_api_v1_auth_gitlab_login_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Gitlab Login Url Api V1 Auth Gitlab Login Get"}}}}}}},"/api/v1/auth/google/login":{"get":{"tags":["Authentication"],"summary":"Google Login Url","description":"Get Google OAuth login URL.\n\nReturns:\n    URL to redirect user to for Google authentication","operationId":"google_login_url_api_v1_auth_google_login_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Google Login Url Api V1 Auth Google Login Get"}}}}}}},"/api/v1/auth/microsoft/login":{"get":{"tags":["Authentication"],"summary":"Microsoft Login Url","description":"Get Microsoft OAuth login URL.\n\nReturns:\n    URL to redirect user to for Microsoft authentication","operationId":"microsoft_login_url_api_v1_auth_microsoft_login_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Microsoft Login Url Api V1 Auth Microsoft Login Get"}}}}}}},"/api/v1/auth/bitbucket/login":{"get":{"tags":["Authentication"],"summary":"Bitbucket Login Url","description":"Get Bitbucket OAuth login URL.\n\nReturns:\n    URL to redirect user to for Bitbucket authentication","operationId":"bitbucket_login_url_api_v1_auth_bitbucket_login_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":{"type":"string"},"type":"object","title":"Response Bitbucket Login Url Api V1 Auth Bitbucket Login Get"}}}}}}},"/api/v1/auth/github/connect":{"get":{"tags":["Authentication"],"summary":"Github Connect Url","description":"Get GitHub OAuth URL to connect account to existing user.\n\nRequires: User must be logged in.","operationId":"github_connect_url_api_v1_auth_github_connect_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Github Connect Url Api V1 Auth Github Connect Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/gitlab/connect":{"get":{"tags":["Authentication"],"summary":"Gitlab Connect Url","description":"Get GitLab OAuth URL to connect account to existing user.\n\nRequires: User must be logged in.","operationId":"gitlab_connect_url_api_v1_auth_gitlab_connect_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Gitlab Connect Url Api V1 Auth Gitlab Connect Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/google/connect":{"get":{"tags":["Authentication"],"summary":"Google Connect Url","description":"Get Google OAuth URL to connect account to existing user.\n\nRequires: User must be logged in.","operationId":"google_connect_url_api_v1_auth_google_connect_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Google Connect Url Api V1 Auth Google Connect Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/microsoft/connect":{"get":{"tags":["Authentication"],"summary":"Microsoft Connect Url","description":"Get Microsoft OAuth URL to connect account to existing user.\n\nRequires: User must be logged in.","operationId":"microsoft_connect_url_api_v1_auth_microsoft_connect_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Microsoft Connect Url Api V1 Auth Microsoft Connect Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/bitbucket/connect":{"get":{"tags":["Authentication"],"summary":"Bitbucket Connect Url","description":"Get Bitbucket OAuth URL to connect account to existing user.\n\nRequires: User must be logged in.","operationId":"bitbucket_connect_url_api_v1_auth_bitbucket_connect_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Bitbucket Connect Url Api V1 Auth Bitbucket Connect Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/github/callback":{"get":{"tags":["Authentication"],"summary":"Github Callback","description":"Handle GitHub OAuth callback.\n\nHandles multiple flows based on state parameter:\n- No state or empty: Login flow (creates/updates user)\n- state=\"connect:{user_id}\": Connect flow (links account to existing user)\n- state=base64_json with \"level\": Git connection flow (creates Git connection)\n\nAlso sets httpOnly cookies for XSS protection on login flow.","operationId":"github_callback_api_v1_auth_github_callback_get","parameters":[{"name":"code","in":"query","required":true,"schema":{"type":"string","description":"OAuth authorization code","title":"Code"},"description":"OAuth authorization code"},{"name":"state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"OAuth state parameter","title":"State"},"description":"OAuth state parameter"},{"name":"error","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error from GitHub","title":"Error"},"description":"Error from GitHub"},{"name":"error_description","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error description","title":"Error Description"},"description":"Error description"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TokenResponse"},{"type":"object"}],"title":"Response Github Callback Api V1 Auth Github Callback Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/gitlab/callback":{"get":{"tags":["Authentication"],"summary":"Gitlab Callback","description":"Handle GitLab OAuth callback.\n\nHandles multiple flows based on state parameter:\n- No state or empty: Login flow (creates/updates user)\n- state=\"connect:{user_id}\": Connect flow (links account to existing user)\n- state=base64_json with \"level\": Git connection flow (creates Git connection)\n\nAlso sets httpOnly cookies for XSS protection on login flow.","operationId":"gitlab_callback_api_v1_auth_gitlab_callback_get","parameters":[{"name":"code","in":"query","required":true,"schema":{"type":"string","description":"OAuth authorization code","title":"Code"},"description":"OAuth authorization code"},{"name":"state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"OAuth state parameter","title":"State"},"description":"OAuth state parameter"},{"name":"error","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error from GitLab","title":"Error"},"description":"Error from GitLab"},{"name":"error_description","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error description","title":"Error Description"},"description":"Error description"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TokenResponse"},{"type":"object"}],"title":"Response Gitlab Callback Api V1 Auth Gitlab Callback Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/google/callback":{"get":{"tags":["Authentication"],"summary":"Google Callback","description":"Handle Google OAuth callback.\n\nHandles both login and connect flows based on state parameter.\n- No state or empty: Login flow (creates/updates user)\n- state=\"connect:{user_id}\": Connect flow (links account to existing user)\n\nAlso sets httpOnly cookies for XSS protection on login flow.","operationId":"google_callback_api_v1_auth_google_callback_get","parameters":[{"name":"code","in":"query","required":true,"schema":{"type":"string","description":"OAuth authorization code","title":"Code"},"description":"OAuth authorization code"},{"name":"state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"OAuth state parameter","title":"State"},"description":"OAuth state parameter"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TokenResponse"},{"type":"object"}],"title":"Response Google Callback Api V1 Auth Google Callback Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/microsoft/callback":{"get":{"tags":["Authentication"],"summary":"Microsoft Callback","description":"Handle Microsoft OAuth callback.\n\nHandles both login and connect flows based on state parameter.\n- No state or empty: Login flow (creates/updates user)\n- state=\"connect:{user_id}\": Connect flow (links account to existing user)\n\nAlso sets httpOnly cookies for XSS protection on login flow.","operationId":"microsoft_callback_api_v1_auth_microsoft_callback_get","parameters":[{"name":"code","in":"query","required":true,"schema":{"type":"string","description":"OAuth authorization code","title":"Code"},"description":"OAuth authorization code"},{"name":"state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"OAuth state parameter","title":"State"},"description":"OAuth state parameter"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TokenResponse"},{"type":"object"}],"title":"Response Microsoft Callback Api V1 Auth Microsoft Callback Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/bitbucket/callback":{"get":{"tags":["Authentication"],"summary":"Bitbucket Callback","description":"Handle Bitbucket OAuth callback.\n\nHandles multiple flows based on state parameter:\n- No state or empty: Login flow (creates/updates user)\n- state=\"connect:{user_id}\": Connect flow (links account to existing user)\n- state=base64_json with \"level\": Git connection flow (creates Git connection)\n\nAlso sets httpOnly cookies for XSS protection on login flow.","operationId":"bitbucket_callback_api_v1_auth_bitbucket_callback_get","parameters":[{"name":"code","in":"query","required":true,"schema":{"type":"string","description":"OAuth authorization code","title":"Code"},"description":"OAuth authorization code"},{"name":"state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"OAuth state parameter","title":"State"},"description":"OAuth state parameter"},{"name":"error","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error from Bitbucket","title":"Error"},"description":"Error from Bitbucket"},{"name":"error_description","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error description","title":"Error Description"},"description":"Error description"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TokenResponse"},{"type":"object"}],"title":"Response Bitbucket Callback Api V1 Auth Bitbucket Callback Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/connected-accounts":{"get":{"tags":["Authentication"],"summary":"List Connected Accounts","description":"List all connected OAuth accounts for the current user.","operationId":"list_connected_accounts_api_v1_auth_connected_accounts_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ConnectedAccount"},"title":"Response List Connected Accounts Api V1 Auth Connected Accounts Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/connected-accounts/{provider}":{"delete":{"tags":["Authentication"],"summary":"Disconnect Account","description":"Disconnect an OAuth account.\n\nCannot disconnect the last remaining account.","operationId":"disconnect_account_api_v1_auth_connected_accounts__provider__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Disconnect Account Api V1 Auth Connected Accounts  Provider  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/sso/discover":{"get":{"tags":["Authentication","SSO"],"summary":"Sso Discover","description":"Email-routed discovery. Returns {auth_url} or 404 (password fallback).","operationId":"sso_discover_api_v1_auth_sso_discover_get","parameters":[{"name":"email","in":"query","required":true,"schema":{"type":"string","description":"User email","title":"Email"},"description":"User email"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/sso/login":{"get":{"tags":["Authentication","SSO"],"summary":"Sso Login","description":"Direct SSO flow. Resolves org via ?org_id=... OR Host header (agency_domain).","operationId":"sso_login_api_v1_auth_sso_login_get","parameters":[{"name":"org_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Org Id"}},{"name":"test","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Test"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/sso/callback":{"get":{"tags":["Authentication","SSO"],"summary":"Sso Callback","description":"Handle IdP redirect. On success, set auth cookie + 302 to dashboard.","operationId":"sso_callback_api_v1_auth_sso_callback_get","parameters":[{"name":"state","in":"query","required":true,"schema":{"type":"string","title":"State"}},{"name":"code","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"}},{"name":"error","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},{"name":"error_description","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Description"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/users/me":{"get":{"tags":["Users"],"summary":"Get Current User","description":"Get current authenticated user's profile.","operationId":"get_current_user_api_v1_users_me_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Users"],"summary":"Update Current User","description":"Update current user's profile.","operationId":"update_current_user_api_v1_users_me_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/users/me/avatar":{"post":{"tags":["Users"],"summary":"Upload Avatar","description":"Upload avatar image for current user.\n\nAccepts image files (JPEG, PNG, GIF, WebP) up to 5MB.\nStores the file in /static/avatars/ directory.","operationId":"upload_avatar_api_v1_users_me_avatar_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_avatar_api_v1_users_me_avatar_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Users"],"summary":"Delete Avatar","description":"Delete current user's avatar.","operationId":"delete_avatar_api_v1_users_me_avatar_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/users/me/organizations":{"get":{"tags":["Users"],"summary":"Get User Organizations","description":"Get all organizations the current user is a member of.","operationId":"get_user_organizations_api_v1_users_me_organizations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object"},"title":"Response Get User Organizations Api V1 Users Me Organizations Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/users":{"get":{"tags":["Users"],"summary":"List Users","description":"List all users (superuser only).","operationId":"list_users_api_v1_users_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UserResponse"},"title":"Response List Users Api V1 Users Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/users/count":{"get":{"tags":["Users"],"summary":"Get Users Count","description":"Get total user count (superuser only).","operationId":"get_users_count_api_v1_users_count_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"integer"},"title":"Response Get Users Count Api V1 Users Count Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/users/{user_id}":{"get":{"tags":["Users"],"summary":"Get User","description":"Get a specific user by ID (superuser only).","operationId":"get_user_api_v1_users__user_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Users"],"summary":"Update User","description":"Update a user (user manager only - portal admin or manager).\n\nNote: Only portal admins can change the portal_role field.","operationId":"update_user_api_v1_users__user_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Users"],"summary":"Deactivate User","description":"Deactivate a user (superuser only).\n\nNote: This soft-deletes the user by setting is_active=False.","operationId":"deactivate_user_api_v1_users__user_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Deactivate User Api V1 Users  User Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/by-platform-hostname":{"get":{"tags":["Platform Hostname Resolver"],"summary":"Resolve a Host header to an org id (Next.js middleware).","description":"Resolve a custom platform hostname to org metadata.\n\nUsed by the Next.js middleware to attach theme-hint headers to\ndownstream requests. NOT an authorization endpoint — see spec §5.5.1\n+ core.security.auth_header_guard for why backend authn never trusts\nthe headers this resolver populates.","operationId":"resolve_by_platform_hostname_api_v1_organizations_by_platform_hostname_get","parameters":[{"name":"host","in":"query","required":true,"schema":{"type":"string","maxLength":253,"description":"The Host header value to resolve. Matched case-insensitively against organization_platform_hostnames.hostname.","title":"Host"},"description":"The Host header value to resolve. Matched case-insensitively against organization_platform_hostnames.hostname."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Resolve By Platform Hostname Api V1 Organizations By Platform Hostname Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations":{"post":{"tags":["Organizations"],"summary":"Create Organization","description":"Create a new organization.\n\nThe creating user automatically becomes the owner.\nSlug is automatically generated and made unique (no user-facing errors).","operationId":"create_organization_api_v1_organizations_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Organizations"],"summary":"List Organizations","description":"List organizations the current user can access.\n\nPortal staff (admin, manager, executive) can view all organizations.\nRegular customers only see organizations they're members of.","operationId":"list_organizations_api_v1_organizations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OrganizationResponse"},"title":"Response List Organizations Api V1 Organizations Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{org_id}":{"get":{"tags":["Organizations"],"summary":"Get Organization","description":"Get organization details.\n\nUser must be a member of the organization.","operationId":"get_organization_api_v1_organizations__org_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Organizations"],"summary":"Update Organization","description":"Update organization details.\n\nRequires admin or owner role.","operationId":"update_organization_api_v1_organizations__org_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Organizations"],"summary":"Delete Organization","description":"Delete (deactivate) an organization.\n\nRequires owner role. This is a soft delete.","operationId":"delete_organization_api_v1_organizations__org_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Delete Organization Api V1 Organizations  Org Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{org_id}/members":{"get":{"tags":["Organizations"],"summary":"List Members","description":"List all members of an organization.\n\nUses the new two-tier role system - portal staff can view any org's members.","operationId":"list_members_api_v1_organizations__org_id__members_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OrganizationMemberResponse"},"title":"Response List Members Api V1 Organizations  Org Id  Members Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Organizations"],"summary":"Add Member","description":"Add a member to the organization.\n\nRequires permission to invite members.","operationId":"add_member_api_v1_organizations__org_id__members_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationMemberCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationMemberResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{org_id}/members/{user_id}":{"patch":{"tags":["Organizations"],"summary":"Update Member Role","description":"Update a member's role.\n\nRequires permission to update member roles.\nCannot change the owner's role.","operationId":"update_member_role_api_v1_organizations__org_id__members__user_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationMemberUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationMemberResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Organizations"],"summary":"Remove Member","description":"Remove a member from the organization.\n\nRequires permission to remove members.\nCannot remove the owner.","operationId":"remove_member_api_v1_organizations__org_id__members__user_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Remove Member Api V1 Organizations  Org Id  Members  User Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{org_id}/servers":{"get":{"tags":["Organizations"],"summary":"List Organization Servers","description":"List servers for an organization (mode-aware).\n\nBYOS Mode: Returns full server list with SSH credentials\nShared Mode: Returns empty list with quota info message\n\nRequires org.servers.list permission.","operationId":"list_organization_servers_api_v1_organizations__org_id__servers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response List Organization Servers Api V1 Organizations  Org Id  Servers Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{org_id}/switch-mode":{"post":{"tags":["Organizations"],"summary":"Switch Server Mode","description":"Switch organization server mode (BYOS <-> Shared).\n\nShared -> BYOS: Requires portal admin approval\nBYOS -> Shared: Auto-approved if within limits\n\nRequires org.settings.update permission.","operationId":"switch_server_mode_api_v1_organizations__org_id__switch_mode_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Switch Server Mode Api V1 Organizations  Org Id  Switch Mode Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/impersonation-settings":{"get":{"tags":["Organizations"],"summary":"Get organization Connect As settings","description":"Return org-level Connect As config. Lazy-creates with all-OFF defaults on first access.","operationId":"get_impersonation_settings_api_v1_organizations__organization_id__impersonation_settings_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationImpersonationSettingsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Organizations"],"summary":"Update organization Connect As settings","description":"Update org-level Connect As config. Lazy-creates on first PATCH if row doesn't exist.","operationId":"update_impersonation_settings_api_v1_organizations__organization_id__impersonation_settings_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationImpersonationSettingsUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationImpersonationSettingsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/migration-allowed-domains":{"get":{"tags":["Organizations"],"summary":"List per-org trusted download domains for the migration validator","description":"Return the org-managed list of trusted download domains.\n\nCombined with the global allow-list at SSRF-validation time\n(services/migration_cloud_importer.py:is_safe_url). Read-access is\ngated to the same role that can write (org.settings.update) so the\ndomain set isn't enumerable by Developer/Viewer roles — even though\nit's low-sensitivity, it reveals org-specific topology.","operationId":"get_migration_allowed_domains_api_v1_organizations__organization_id__migration_allowed_domains_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Migration Allowed Domains Api V1 Organizations  Organization Id  Migration Allowed Domains Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Organizations"],"summary":"Replace the per-org trusted download domains list","description":"Replace the org's trusted download domains list (PUT semantics).\n\nBody shape: {\"domains\": [\"foo.example.com\", \"bar.example.org\"]}\n\nEach entry is normalised (lowercase, trimmed) and validated; duplicates\nafter normalisation are deduped. Errors return 400 with a per-entry\nmessage so the UI can highlight the bad row.","operationId":"set_migration_allowed_domains_api_v1_organizations__organization_id__migration_allowed_domains_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Set Migration Allowed Domains Api V1 Organizations  Organization Id  Migration Allowed Domains Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invitations/organizations/{organization_id}":{"post":{"tags":["Invitations"],"summary":"Create Invitation","description":"Create a new organization invitation.\n\nRequires org.members.invite permission in the organization.\nReturns the invitation with the link_token (only shown once on creation).\nSends an email invitation if an email is provided and email service is configured.\n\nSupports two scopes:\n- organization: User gets org-wide access with specified role\n- project: User gets access only to specified projects","operationId":"create_invitation_api_v1_invitations_organizations__organization_id__post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Invitations"],"summary":"List Invitations","description":"List all invitations for an organization.\n\nRequires org.invitations.list permission in the organization.","operationId":"list_invitations_api_v1_invitations_organizations__organization_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"include_expired","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Expired"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invitations/organizations/{organization_id}/{invitation_id}":{"get":{"tags":["Invitations"],"summary":"Get Invitation","description":"Get a specific invitation by ID.\n\nRequires org.invitations.list permission in the organization.","operationId":"get_invitation_api_v1_invitations_organizations__organization_id___invitation_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"invitation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invitation Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Invitations"],"summary":"Revoke Invitation","description":"Revoke an invitation.\n\nRequires org.invitations.revoke permission in the organization.\nOnly pending invitations can be revoked.","operationId":"revoke_invitation_api_v1_invitations_organizations__organization_id___invitation_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"invitation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invitation Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invitations/organizations/{organization_id}/cleanup":{"delete":{"tags":["Invitations"],"summary":"Cleanup Expired Invitations","description":"Delete all expired and revoked invitations from an organization.\n\nRequires org.invitations.revoke permission in the organization.\nReturns the count of deleted invitations.","operationId":"cleanup_expired_invitations_api_v1_invitations_organizations__organization_id__cleanup_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Cleanup Expired Invitations Api V1 Invitations Organizations  Organization Id  Cleanup Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invitations/organizations/{organization_id}/{invitation_id}/resend":{"post":{"tags":["Invitations"],"summary":"Resend Invitation","description":"Resend invitation email.\n\nRequires org.members.invite permission in the organization.\nOnly pending invitations can be resent.","operationId":"resend_invitation_api_v1_invitations_organizations__organization_id___invitation_id__resend_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"invitation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invitation Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invitations/validate":{"post":{"tags":["Invitations"],"summary":"Validate Invitation","description":"Validate an invitation code or token (public endpoint).\n\nDoes not require authentication. Returns invitation details if valid.\nIncludes scope and project info for project-scoped invitations.\n\nThe invited email address (``restricted_email``) is personal data, so it is\nreturned only for a valid invitation looked up by its long link token. A\n6-character code is short enough to guess, so a code lookup never reveals\nit; the accept step still enforces the restriction server-side.","operationId":"validate_invitation_api_v1_invitations_validate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationValidate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationValidateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invitations/accept":{"post":{"tags":["Invitations"],"summary":"Accept Invitation","description":"Accept an invitation and join the organization.\n\nRequires authentication. The authenticated user will be added to the organization.\n\nFor organization-scoped invitations: User becomes org member with full access.\nFor project-scoped invitations: User gets access only to specified projects.","operationId":"accept_invitation_api_v1_invitations_accept_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationAccept"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationAcceptResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invitations/me":{"get":{"tags":["Invitations"],"summary":"List My Invitations","description":"List pending invitations for the current user's email.\n\nReturns invitations that are:\n- Restricted to the user's email\n- Still valid (pending, not expired, not maxed out)","operationId":"list_my_invitations_api_v1_invitations_me_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects":{"post":{"tags":["Projects"],"summary":"Create Project","description":"Create a new project.\n\nUser must be a member of the organization.\nIf no organization_id is provided, uses the user's first organization or creates one.","operationId":"create_project_api_v1_projects_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectCreateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Projects"],"summary":"List Projects","description":"List projects the user has access to.\n\nOptionally filter by organization or status.\nPortal admins/managers have access to all organizations.\n\nAccess control (team-based):\n- Portal staff: See all projects\n- Org Owners and Admins: See all projects in their organizations (safety net)\n- Developers / Viewers: See only projects assigned to their teams","operationId":"list_projects_api_v1_projects_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization","title":"Organization Id"},"description":"Filter by organization"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/ProjectStatus"},{"type":"null"}],"title":"Status"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProjectListItemResponse"},"title":"Response List Projects Api V1 Projects Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}":{"get":{"tags":["Projects"],"summary":"Get Project","description":"Get project details.\n\nAccess control (team-based):\n- Portal admins/managers: Access to all projects\n- Org owners: Access to all projects in their organizations\n- Team members: Access only to projects assigned to their teams","operationId":"get_project_api_v1_projects__project_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Projects"],"summary":"Update Project","description":"Update project details.\n\nRequires 'admin' role within the project's team assignment.","operationId":"update_project_api_v1_projects__project_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Projects"],"summary":"Delete Project","description":"Delete (deactivate) a project.\n\nRequires 'admin' role within the project's team assignment.","operationId":"delete_project_api_v1_projects__project_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Delete Project Api V1 Projects  Project Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/regenerate-webhook-secret":{"post":{"tags":["Projects"],"summary":"Regenerate Webhook Secret","description":"Regenerate the webhook secret for a project.\n\nThis will invalidate the existing webhook configuration in GitHub/GitLab.\nAfter calling this endpoint, you'll need to update the webhook secret\nin your repository settings.\n\nRequires 'admin' role within the project's team assignment.\n\nReturns:\n    dict with new webhook_secret and webhook_url","operationId":"regenerate_webhook_secret_api_v1_projects__project_id__regenerate_webhook_secret_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Regenerate Webhook Secret Api V1 Projects  Project Id  Regenerate Webhook Secret Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/setup-webhook":{"post":{"tags":["Projects"],"summary":"Setup Webhook","description":"Setup or repair webhook for a project.\n\nAutomatically registers the webhook with GitHub/GitLab using the user's\nOAuth token. This is useful when:\n- Webhook wasn't set up during project creation (no OAuth at that time)\n- Webhook was deleted from the repository\n- Webhook needs to be re-registered with correct secret\n\nRequires 'admin' role within the project's team assignment.\n\nReturns:\n    dict with success status, webhook_id, webhook_url, and message","operationId":"setup_webhook_api_v1_projects__project_id__setup_webhook_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"anyOf":[{"type":"string"},{"type":"boolean"},{"type":"null"}]},"title":"Response Setup Webhook Api V1 Projects  Project Id  Setup Webhook Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments":{"get":{"tags":["Projects"],"summary":"List Environments","description":"List all environments for a project.\n\nIncludes clone information for environments that were created via cloning.","operationId":"list_environments_api_v1_projects__project_id__environments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProjectEnvironmentResponse"},"title":"Response List Environments Api V1 Projects  Project Id  Environments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Projects"],"summary":"Create Environment","description":"Create a new environment for a project.","operationId":"create_environment_api_v1_projects__project_id__environments_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectEnvironmentCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectEnvironmentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}":{"get":{"tags":["Projects"],"summary":"Get Environment","description":"Get a specific environment for a project.\n\nIncludes clone information if the environment was created via cloning.","operationId":"get_environment_api_v1_projects__project_id__environments__env_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectEnvironmentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Projects"],"summary":"Update Environment","description":"Update a project environment.\n\nUse this to assign a VM to an environment or update other settings.","operationId":"update_environment_api_v1_projects__project_id__environments__env_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectEnvironmentUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectEnvironmentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Projects"],"summary":"Delete Environment","description":"Delete a project environment.\n\nIf the environment has backups, you must specify `backup_action`:\n- `keep_all`: Keep all backups (they become orphaned but still downloadable)\n- `delete_all`: Delete all backups from storage\n- `keep_latest`: Keep only the most recent completed backup\n\nUse GET /{project_id}/environments/{env_id}/backup-info to check for backups first.","operationId":"delete_environment_api_v1_projects__project_id__environments__env_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"backup_action","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/BackupHandlingAction"},{"type":"null"}],"description":"What to do with existing backups. Required if environment has backups.","title":"Backup Action"},"description":"What to do with existing backups. Required if environment has backups."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Delete Environment Api V1 Projects  Project Id  Environments  Env Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/admin-password/reveal":{"post":{"tags":["Projects"],"summary":"Reveal Environment Admin Password","description":"#966: show the generated Odoo admin password (login ``admin``).\n\nOnly once it is confirmed in the database (pending: 404). The audit row is\ncommitted before the password is returned. POST + no-store, so nothing\ncaches it.","operationId":"reveal_environment_admin_password_api_v1_projects__project_id__environments__env_id__admin_password_reveal_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/admin-password/acknowledge":{"post":{"tags":["Projects"],"summary":"Acknowledge Environment Admin Password","description":"#966: the owner saved the admin password; delete our copy.\n\nOne conditional UPDATE on ``set_at IS NOT NULL AND encrypted IS NOT NULL``,\nso a pending password can never be cleared here (404). Idempotent on an\nacknowledged row: 204 with no write and no audit row.","operationId":"acknowledge_environment_admin_password_api_v1_projects__project_id__environments__env_id__admin_password_acknowledge_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/backup-info":{"get":{"tags":["Projects"],"summary":"Get Environment Backup Info","description":"Get backup information for an environment before deletion.\n\nThis endpoint helps the user understand what backups exist before deleting an environment.","operationId":"get_environment_backup_info_api_v1_projects__project_id__environments__env_id__backup_info_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentBackupInfo"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/webhook-deliveries":{"get":{"tags":["Projects"],"summary":"List Webhook Deliveries","description":"List recent webhook deliveries for a project.\n\n#1306: ``branch`` narrows the list to one branch before the limit applies,\nso an environment's \"Recent pushes\" shows its own branch's last N pushes,\nnot whatever survives of the project-wide last N.","operationId":"list_webhook_deliveries_api_v1_projects__project_id__webhook_deliveries_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"branch","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Branch"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/schemas__webhook_delivery__WebhookDeliveryResponse"},"title":"Response List Webhook Deliveries Api V1 Projects  Project Id  Webhook Deliveries Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{environment_id}/webhook-health":{"get":{"tags":["Projects"],"summary":"Get Webhook Health","description":"Get webhook health summary for an environment.","operationId":"get_webhook_health_api_v1_projects__project_id__environments__environment_id__webhook_health_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookHealthResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/auto-tune":{"get":{"tags":["Projects"],"summary":"Get Environment Auto Tune","description":"What Auto-Tune applied when odoo.conf was last generated, and what it\nwould produce for ``cpu_cores``/``ram_mb`` (defaults to the environment's\ncurrent allocation). Same split, same Odoo version resolution and same\ngenerator as the deployer (#1029). The preview is computed before any\n``custom_params`` overrides.","operationId":"get_environment_auto_tune_api_v1_projects__project_id__environments__env_id__auto_tune_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"cpu_cores","in":"query","required":false,"schema":{"anyOf":[{"type":"number","maximum":64.0,"minimum":0.25},{"type":"null"}],"title":"Cpu Cores"}},{"name":"ram_mb","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":262144,"minimum":256},{"type":"null"}],"title":"Ram Mb"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentAutoTuneResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/image/freeze":{"post":{"tags":["Projects"],"summary":"Freeze Environment Build","description":"Keep this environment on the exact Odoo build it runs now, on every deploy.","operationId":"freeze_environment_build_api_v1_projects__project_id__environments__env_id__image_freeze_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooImageInfo"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/image/unfreeze":{"post":{"tags":["Projects"],"summary":"Unfreeze Environment Build","description":"Follow the stable image of this Odoo version again, from the next deploy.","operationId":"unfreeze_environment_build_api_v1_projects__project_id__environments__env_id__image_unfreeze_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooImageInfo"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/image/builds":{"get":{"tags":["Projects"],"summary":"List Environment Builds","description":"Dated builds of this environment's Odoo version, newest first (OEC-10213).\nEmpty when the image is not one Docker Hub lists by date.","operationId":"list_environment_builds_api_v1_projects__project_id__environments__env_id__image_builds_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DatedBuildResponse"},"title":"Response List Environment Builds Api V1 Projects  Project Id  Environments  Env Id  Image Builds Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/image/pin":{"post":{"tags":["Projects"],"summary":"Pin Environment Build Route","description":"Freeze this environment on a specific dated build. The next deploy or\nUpdate now runs it.","operationId":"pin_environment_build_route_api_v1_projects__project_id__environments__env_id__image_pin_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PinBuildRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooImageInfo"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/deploy":{"post":{"tags":["Projects"],"summary":"Deploy Environment","description":"Deploy a specific environment.\n\nThis creates the Docker containers (PostgreSQL + Odoo) on the assigned VM\nand configures Traefik for routing.\n\nFor migration environments where restore has already completed:\n- By default, redeployment preserves the existing database\n- Use force_restore=true to re-download and restore the original migration backup\n  WARNING: This will DESTROY all data added since the initial restore!","operationId":"deploy_environment_api_v1_projects__project_id__environments__env_id__deploy_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","description":"Force redeploy even if already running","default":false,"title":"Force"},"description":"Force redeploy even if already running"},{"name":"force_restore","in":"query","required":false,"schema":{"type":"boolean","description":"Force re-restore migration backup (WARNING: destroys current database!)","default":false,"title":"Force Restore"},"description":"Force re-restore migration backup (WARNING: destroys current database!)"},{"name":"neutralize","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Migration restores only: neutralize the restored database (turn off scheduled jobs, outgoing mail and integrations). Default: on unless the environment is production or the migration was set not to neutralize.","title":"Neutralize"},"description":"Migration restores only: neutralize the restored database (turn off scheduled jobs, outgoing mail and integrations). Default: on unless the environment is production or the migration was set not to neutralize."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Deploy Environment Api V1 Projects  Project Id  Environments  Env Id  Deploy Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/stop":{"post":{"tags":["Projects"],"summary":"Stop Environment","description":"Stop a running environment.\n\nThis enqueues an ARQ task to stop the Odoo and PostgreSQL containers\non the assigned VM. The operation returns immediately with a task ID\nfor tracking progress.","operationId":"stop_environment_api_v1_projects__project_id__environments__env_id__stop_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Stop Environment Api V1 Projects  Project Id  Environments  Env Id  Stop Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/start":{"post":{"tags":["Projects"],"summary":"Start Environment","description":"Start a stopped environment.\n\nThis enqueues an ARQ task to start the existing containers without\nredeploying. The operation returns immediately with a task ID for\ntracking progress.","operationId":"start_environment_api_v1_projects__project_id__environments__env_id__start_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Start Environment Api V1 Projects  Project Id  Environments  Env Id  Start Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/deploy":{"post":{"tags":["Projects"],"summary":"Deploy Project","description":"Trigger a deployment for a project's environments.\n\nIf an environment name is specified, only that environment is deployed.\nOtherwise, all active environments with VMs assigned are deployed.","operationId":"deploy_project_api_v1_projects__project_id__deploy_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"environment","in":"query","required":false,"schema":{"type":"string","description":"Environment to deploy to","default":"production","title":"Environment"},"description":"Environment to deploy to"},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","description":"Force redeploy even if already running","default":false,"title":"Force"},"description":"Force redeploy even if already running"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Deploy Project Api V1 Projects  Project Id  Deploy Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/stop":{"post":{"tags":["Projects"],"summary":"Stop Project","description":"Stop a running project.\n\nEnqueues ARQ tasks to stop all running environments belonging to the project.","operationId":"stop_project_api_v1_projects__project_id__stop_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Stop Project Api V1 Projects  Project Id  Stop Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/start":{"post":{"tags":["Projects"],"summary":"Start Project","description":"Start a stopped project.\n\nEnqueues ARQ tasks to start all stopped environments belonging to the project.","operationId":"start_project_api_v1_projects__project_id__start_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Start Project Api V1 Projects  Project Id  Start Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/deployments":{"get":{"tags":["Projects"],"summary":"List Project Deployments","description":"List deployments for a project.","operationId":"list_project_deployments_api_v1_projects__project_id__deployments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":20,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object"},"title":"Response List Project Deployments Api V1 Projects  Project Id  Deployments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/deployments":{"get":{"tags":["Projects"],"summary":"List Environment Deployments","description":"List deployments for a specific environment.","operationId":"list_environment_deployments_api_v1_projects__project_id__environments__env_id__deployments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":10,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object"},"title":"Response List Environment Deployments Api V1 Projects  Project Id  Environments  Env Id  Deployments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/clear-assets":{"post":{"tags":["Projects"],"summary":"Clear Environment Assets","description":"Clear compiled CSS/JS asset bundles for an environment.\n\nThis forces Odoo to regenerate assets on next page load.\nUseful after cloning or when assets become corrupted.","operationId":"clear_environment_assets_api_v1_projects__project_id__environments__env_id__clear_assets_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/subdomains/preview":{"post":{"tags":["Projects"],"summary":"Preview Subdomain Endpoint","description":"Preview what subdomain would be generated for a given environment name.\n\nUses the same generation logic as environment creation, including\ndeduplication, reserved name handling, and collision resolution.\nDoes not create or modify anything.","operationId":"preview_subdomain_endpoint_api_v1_projects__project_id__subdomains_preview_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubdomainPreviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubdomainPreviewResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/subdomain/regenerate":{"post":{"tags":["Projects"],"summary":"Regenerate Subdomain","description":"Regenerate subdomain for an environment.\n\nThis allows users to generate a new subdomain if they're not satisfied with the auto-generated one.\nThe new subdomain will still follow the pattern: {project-slug}-{env-name}[-{suffix}]","operationId":"regenerate_subdomain_api_v1_projects__project_id__environments__env_id__subdomain_regenerate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"suffix","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"description":"Optional suffix for disambiguation","title":"Suffix"},"description":"Optional suffix for disambiguation"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectEnvironmentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/custom-domain":{"post":{"tags":["Projects"],"summary":"Set Custom Domain","description":"Set a custom domain for an environment.\n\nAccepts both plain ('erp.acme.com') and wildcard ('*.acme.com')\ndomains. Plain domains follow the existing CNAME -> verify flow;\nwildcards trigger a Let's Encrypt DNS-01 cert issuance against the\norg's Cloudflare cloud_account in the background and return\nimmediately. Client polls `GET /custom-domain/status` for the cert\ntransition pending -> active.\n\nWildcards require the Pro plan or higher. The org must also have an\nactive Cloudflare cloud account on the apex zone (422 otherwise).","operationId":"set_custom_domain_api_v1_projects__project_id__environments__env_id__custom_domain_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomDomainRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomDomainVerificationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Projects"],"summary":"Remove Custom Domain","description":"Remove custom domain from an environment.\n\nAfter removal, the environment will revert to using the system subdomain.","operationId":"remove_custom_domain_api_v1_projects__project_id__environments__env_id__custom_domain_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Remove Custom Domain Api V1 Projects  Project Id  Environments  Env Id  Custom Domain Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/custom-domain/verify":{"post":{"tags":["Projects"],"summary":"Verify Custom Domain","description":"Verify the environment's legacy single custom domain.\n\n#771 added a `_oecsh-verify.<domain>` TXT proof here; #882 (product\ndecision, 2026-08-04) turned that check into a logged no-op, so this\nmarks `custom_domain_verified = True` for any caller with `org.dns.manage`.","operationId":"verify_custom_domain_api_v1_projects__project_id__environments__env_id__custom_domain_verify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomDomainStatus"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/domains":{"post":{"tags":["Projects"],"summary":"Add Domain","description":"Add a custom domain to an environment.\n\nReturns DNS verification instructions. Domain must be verified\nbefore Traefik will route traffic to it.","operationId":"add_domain_api_v1_projects__project_id__environments__env_id__domains_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectDomainCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Projects"],"summary":"List Domains","description":"List all custom domains for an environment.","operationId":"list_domains_api_v1_projects__project_id__environments__env_id__domains_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectDomainListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/domains/{domain_id}/verify":{"post":{"tags":["Projects"],"summary":"Verify Domain","description":"Verify ownership of a custom domain.\n\nRequires the `_oecsh-verify.<domain>` TXT proof (#771). On success,\ntriggers a container label update so Traefik starts routing traffic\nto this domain.","operationId":"verify_domain_api_v1_projects__project_id__environments__env_id__domains__domain_id__verify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/domains/{domain_id}":{"delete":{"tags":["Projects"],"summary":"Remove Domain","description":"Remove a custom domain from an environment.\n\nDeletes the domain record and triggers a container label update\nto stop routing traffic for this domain.","operationId":"remove_domain_api_v1_projects__project_id__environments__env_id__domains__domain_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Remove Domain Api V1 Projects  Project Id  Environments  Env Id  Domains  Domain Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/domains/{domain_id}/primary":{"patch":{"tags":["Projects"],"summary":"Set Primary Domain","description":"Set a domain as the primary domain for the environment.\n\nThe primary domain is used for Odoo's web.base.url setting.\nOnly one domain can be primary at a time.","operationId":"set_primary_domain_api_v1_projects__project_id__environments__env_id__domains__domain_id__primary_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{env_id}/logs":{"get":{"tags":["Projects"],"summary":"Get Environment Logs","description":"Get logs for an environment.\n\nlog_type options:\n- deployment: Logs from deployment process (stored in DB)\n- container: Live Docker container logs\n- odoo: Odoo application logs from container\n- postgres: PostgreSQL database logs from container","operationId":"get_environment_logs_api_v1_projects__project_id__environments__env_id__logs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"log_type","in":"query","required":false,"schema":{"type":"string","description":"Type of logs: deployment, container, odoo, postgres","default":"deployment","title":"Log Type"},"description":"Type of logs: deployment, container, odoo, postgres"},{"name":"lines","in":"query","required":false,"schema":{"type":"integer","maximum":5000,"minimum":10,"description":"Number of lines to fetch","default":100,"title":"Lines"},"description":"Number of lines to fetch"},{"name":"deployment_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Specific deployment ID for deployment logs","title":"Deployment Id"},"description":"Specific deployment ID for deployment logs"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Environment Logs Api V1 Projects  Project Id  Environments  Env Id  Logs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{environment_id}/impersonation/users":{"get":{"tags":["Connect As"],"summary":"List active Odoo users available for Connect As","description":"Return active non-portal Odoo users for an environment.\n\nQueries the environment's Postgres container directly via SSH+psql.\nRequires the env.impersonation.list_users permission.","operationId":"list_users_api_v1_projects__project_id__environments__environment_id__impersonation_users_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"query","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Query"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}},{"name":"include_portal","in":"query","required":false,"schema":{"type":"boolean","description":"Include portal (share=true) users in the result set","default":false,"title":"Include Portal"},"description":"Include portal (share=true) users in the result set"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImpersonationUserListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{environment_id}/impersonation/initiate":{"post":{"tags":["Connect As"],"summary":"Initiate a Connect As session for an Odoo user","description":"Mint a single-use Connect As token for the given Odoo user.\n\nRuns all preflight gates, looks up the target user via SSH+psql,\nwrites an audit row, and returns a one-time redirect URL.\nRequires the env.impersonation.initiate permission.","operationId":"initiate_api_v1_projects__project_id__environments__environment_id__impersonation_initiate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImpersonationInitiateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImpersonationInitiateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{environment_id}/impersonation/audit":{"get":{"tags":["Connect As"],"summary":"List Connect As audit events for an environment","description":"Return paginated audit log for Connect As events on this environment.\n\nOrdered by timestamp descending (most recent first).\nRequires the env.impersonation.view_audit permission.","operationId":"list_audit_api_v1_projects__project_id__environments__environment_id__impersonation_audit_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImpersonationAuditListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/environments/{environment_id}/impersonation/revoke":{"post":{"tags":["Connect As"],"summary":"Revoke an active Connect As token and kill the session","description":"Revoke a Connect As token and forcibly kill the injected Odoo session.\n\nIdempotent if the token is already expired. Returns 409 if already revoked.\nRequires the env.impersonation.revoke permission.","operationId":"revoke_api_v1_projects__project_id__environments__environment_id__impersonation_revoke_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImpersonationRevokeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImpersonationRevokeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/impersonation/redeem":{"get":{"tags":["Connect As"],"summary":"Public — redeem a Connect As token and create the Odoo session","description":"Public endpoint — no auth header. JWT signature is the auth.\n\nOn success: HTTP 302 to env's /odoo path with Set-Cookie: session_id={sid}.\nOn failure: 4xx/5xx with error_code in body.","operationId":"redeem_api_v1_impersonation_redeem_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","minLength":20,"maxLength":2048,"title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/install.sh":{"get":{"tags":["Server Registration"],"summary":"Get Install Script","description":"Download the Quick Connect install script.\n\nPublic endpoint — the script is generic. The token is passed\nvia OECSH_TOKEN environment variable at runtime.","operationId":"get_install_script_api_v1_install_sh_get","responses":{"200":{"description":"Successful Response","content":{"text/plain":{"schema":{"type":"string"}}}}}}},"/api/v1/vms/registration-tokens":{"post":{"tags":["Server Registration"],"summary":"Create Registration Token","description":"Create a new registration token for Quick Connect server setup.","operationId":"create_registration_token_api_v1_vms_registration_tokens_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":true,"schema":{"type":"string","format":"uuid","title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRegistrationTokenRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRegistrationTokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Server Registration"],"summary":"List Registration Tokens","description":"List all registration tokens for the organization.","operationId":"list_registration_tokens_api_v1_vms_registration_tokens_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":true,"schema":{"type":"string","format":"uuid","title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListRegistrationTokensResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/registration-tokens/{token_id}":{"delete":{"tags":["Server Registration"],"summary":"Revoke Registration Token","description":"Revoke a registration token (and clean up VM if partially set up).","operationId":"revoke_registration_token_api_v1_vms_registration_tokens__token_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"token_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Token Id"}},{"name":"X-Organization-ID","in":"header","required":true,"schema":{"type":"string","format":"uuid","title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/register":{"post":{"tags":["Server Registration"],"summary":"Register Server","description":"Server self-registration endpoint.\n\nCalled by the install script running on the customer's server.\nAuthenticated via registration token (not JWT).","operationId":"register_server_api_v1_vms_register_post","parameters":[{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerRegistrationRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerRegistrationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{server_id}/setup-progress":{"post":{"tags":["Server Registration"],"summary":"Report Setup Progress","description":"Report setup progress from the install script.\n\nAuthenticated via progress token (issued during registration).","operationId":"report_setup_progress_api_v1_vms__server_id__setup_progress_post","parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetupProgressRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetupProgressResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{server_id}/setup-complete":{"post":{"tags":["Server Registration"],"summary":"Complete Setup","description":"Mark server setup as complete.\n\nCalled by the install script after all services are verified.","operationId":"complete_setup_api_v1_vms__server_id__setup_complete_post","parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetupCompleteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetupCompleteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{server_id}/test-connectivity":{"post":{"tags":["Server Registration"],"summary":"Test Connectivity","description":"Test if oec.sh can reach the server via SSH.\n\nReturns connectivity status and recommendations (e.g., use CF Tunnel).","operationId":"test_connectivity_api_v1_vms__server_id__test_connectivity_post","parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"authorization","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorization"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectivityTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms":{"post":{"tags":["Servers"],"summary":"Create Vm","description":"Create/Register a new Server.\n\nFor BYOS (Bring Your Own Server), provide IP and SSH credentials.\nFor cloud-provisioned, the VM will be created via provider API.\n\nRequires admin or owner role in the organization.","operationId":"create_vm_api_v1_vms_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Servers"],"summary":"List Vms","description":"List VMs the user has access to.","operationId":"list_vms_api_v1_vms_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization","title":"Organization Id"},"description":"Filter by organization"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/VMStatus"},{"type":"null"}],"title":"Status"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}},{"name":"include_demo","in":"query","required":false,"schema":{"type":"boolean","description":"When true, demo VMs are included in the response. Used by the env-create form on the demo flow so it can pre-select the per-org demo marker. The customer Servers page never passes this. Demo VMs returned here are still gated for terminal/manage.","default":false,"title":"Include Demo"},"description":"When true, demo VMs are included in the response. Used by the env-create form on the demo flow so it can pre-select the per-org demo marker. The customer Servers page never passes this. Demo VMs returned here are still gated for terminal/manage."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/VMResponse"},"title":"Response List Vms Api V1 Vms Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}":{"get":{"tags":["Servers"],"summary":"Get Vm","description":"Get VM details.","operationId":"get_vm_api_v1_vms__vm_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"include_demo","in":"query","required":false,"schema":{"type":"boolean","description":"When true, demo VMs return their public metadata (id, name, cpu, memory, disk, status). The env detail page passes this so it can render the assigned-server section for demo envs. Terminal/manage routes still refuse demo VMs.","default":false,"title":"Include Demo"},"description":"When true, demo VMs return their public metadata (id, name, cpu, memory, disk, status). The env detail page passes this so it can render the assigned-server section for demo envs. Terminal/manage routes still refuse demo VMs."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Servers"],"summary":"Update Vm","description":"Update VM details.\n\nRequires admin or owner role.\nIf changing organization, requires admin access to both old and new organization.","operationId":"update_vm_api_v1_vms__vm_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Servers"],"summary":"Delete Vm","description":"Delete (deactivate) a Server.\n\nRequires admin or owner role.\nWill fail if there are active environments deployed on the server.\n\nArgs:\n    delete_from_cloud: If True, also deletes the server from the cloud provider.\n                      Only applicable to cloud-provisioned servers.","operationId":"delete_vm_api_v1_vms__vm_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"delete_from_cloud","in":"query","required":false,"schema":{"type":"boolean","description":"If true, also delete the server from the cloud provider (DigitalOcean, Hetzner, etc.)","default":false,"title":"Delete From Cloud"},"description":"If true, also delete the server from the cloud provider (DigitalOcean, Hetzner, etc.)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Delete Vm Api V1 Vms  Vm Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/ssh-public-key":{"get":{"tags":["Servers"],"summary":"Get Vm Ssh Public Key","description":"Return the platform's SSH PUBLIC key for this BYOS server.\n\nLets a BYOS owner re-add the platform key to their server's\n``authorized_keys`` if they've reset SSH access. Returns the PUBLIC key\nonly (OpenSSH authorized_keys form) — never any private key material.\n\nGated identically to editing the server (PATCH /{vm_id}):\n  - can_manage_server() (shared servers -> 403, BYOS only)\n  - org membership (BYOS)\n  - org.servers.update permission","operationId":"get_vm_ssh_public_key_api_v1_vms__vm_id__ssh_public_key_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMPublicKeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/provision":{"post":{"tags":["Servers"],"summary":"Provision Vm","description":"Provision a pending VM.\n\nThis creates the actual cloud resource. For cloud-provisioned servers,\nit enqueues the server_auto_fix background task which handles Docker\ninstallation, Netdata setup, Traefik configuration, etc.","operationId":"provision_vm_api_v1_vms__vm_id__provision_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Provision Vm Api V1 Vms  Vm Id  Provision Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/stop":{"post":{"tags":["Servers"],"summary":"Stop Vm","description":"Stop a running VM.\n\nFor BYOS servers, sends `shutdown -h now` via SSH.\nFor cloud-provisioned servers, uses the cloud provider API (graceful shutdown).","operationId":"stop_vm_api_v1_vms__vm_id__stop_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Stop Vm Api V1 Vms  Vm Id  Stop Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/start":{"post":{"tags":["Servers"],"summary":"Start Vm","description":"Start a stopped VM.\n\nFor cloud-provisioned servers, uses the cloud provider API to power on.\nFor BYOS servers, this cannot be done via SSH (machine is off) and requires\nmanual intervention via the hosting provider's control panel.","operationId":"start_vm_api_v1_vms__vm_id__start_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Start Vm Api V1 Vms  Vm Id  Start Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/reboot":{"post":{"tags":["Servers"],"summary":"Reboot Vm","description":"Reboot a running VM.\n\nFor BYOS servers, sends `shutdown -r now` via SSH.\nFor cloud-provisioned servers, uses the cloud provider API (graceful reboot).\nThe server status remains RUNNING since it will come back up after reboot.","operationId":"reboot_vm_api_v1_vms__vm_id__reboot_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Reboot Vm Api V1 Vms  Vm Id  Reboot Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/environments":{"get":{"tags":["Servers"],"summary":"Get Vm Environments","description":"Get all environments deployed on this server.\n\nEnvironments (not projects) are now assigned to servers.\nA project can have multiple environments on different servers.","operationId":"get_vm_environments_api_v1_vms__vm_id__environments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{},"title":"Response Get Vm Environments Api V1 Vms  Vm Id  Environments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/projects":{"get":{"tags":["Servers"],"summary":"Get Vm Projects","description":"DEPRECATED: Use GET /{vm_id}/environments instead.\n\nGet projects with environments on this server.","operationId":"get_vm_projects_api_v1_vms__vm_id__projects_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{},"title":"Response Get Vm Projects Api V1 Vms  Vm Id  Projects Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/stats":{"get":{"tags":["Servers"],"summary":"Get Vm Stats","description":"Get server resource statistics.","operationId":"get_vm_stats_api_v1_vms__vm_id__stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Vm Stats Api V1 Vms  Vm Id  Stats Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/test-connection":{"post":{"tags":["Servers"],"summary":"Test Server Connection","description":"Test SSH connection to the server.\n\nVerifies that the stored SSH credentials work and detects server info.\nUpdates the VM record with detected OS, hostname, and Docker status.","operationId":"test_server_connection_api_v1_vms__vm_id__test_connection_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Test Server Connection Api V1 Vms  Vm Id  Test Connection Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/ssh-password":{"put":{"tags":["Servers"],"summary":"Update Ssh Password","description":"Update SSH password for a server.\n\nOptionally tests the connection with the new password before saving.\nChanges auth method to PASSWORD if currently using SSH_KEY.","operationId":"update_ssh_password_api_v1_vms__vm_id__ssh_password_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHPasswordUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Update Ssh Password Api V1 Vms  Vm Id  Ssh Password Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/ssh-key":{"put":{"tags":["Servers"],"summary":"Update Ssh Key","description":"Update SSH private key for a server.\n\nOptionally tests the connection with the new key before saving.\nChanges auth method to SSH_KEY if currently using PASSWORD.","operationId":"update_ssh_key_api_v1_vms__vm_id__ssh_key_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Update Ssh Key Api V1 Vms  Vm Id  Ssh Key Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/secure":{"post":{"tags":["Servers"],"summary":"Secure Server","description":"One-click secure: Convert server from password auth to SSH key auth.\n\nThis is the core of the progressive security model:\n1. Generates a new Ed25519 SSH key pair\n2. Connects to server via current password authentication\n3. Deploys the public key to ~/.ssh/authorized_keys\n4. Verifies key-based authentication works\n5. Updates VM record to use SSH key auth\n6. Clears password from database\n\nNOTE: Password login on the server itself is left as it is; this route never\nedits sshd_config.\n\nPrerequisites:\n- Server must currently use password authentication\n- Password must be stored in the database\n\nReturns:\n    Success response with security upgrade details\n\nRaises:\n    400: If server already uses SSH key auth\n    400: If no password is configured\n    400: If key deployment fails\n    404: If server not found","operationId":"secure_server_api_v1_vms__vm_id__secure_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Secure Server Api V1 Vms  Vm Id  Secure Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/cleanup/status":{"get":{"tags":["Servers"],"summary":"Get Cleanup Status","description":"Get cleanup status for a VM.\n\nReturns:\n- Last cleanup timestamp\n- Active environments count (protected from cleanup)\n- Total Docker disk usage","operationId":"get_cleanup_status_api_v1_vms__vm_id__cleanup_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Cleanup Status Api V1 Vms  Vm Id  Cleanup Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/cleanup/history":{"get":{"tags":["Servers"],"summary":"Get Cleanup History","description":"Get cleanup history for a VM.","operationId":"get_cleanup_history_api_v1_vms__vm_id__cleanup_history_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":10,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Cleanup History Api V1 Vms  Vm Id  Cleanup History Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/cleanup/preview":{"post":{"tags":["Servers"],"summary":"Preview Cleanup","description":"Preview cleanup (dry run) without actually deleting anything.\n\nReturns what would be deleted if cleanup were executed.","operationId":"preview_cleanup_api_v1_vms__vm_id__cleanup_preview_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Preview Cleanup Api V1 Vms  Vm Id  Cleanup Preview Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/cleanup/execute":{"post":{"tags":["Servers"],"summary":"Execute Cleanup","description":"Execute cleanup operation on a VM.\n\nDeletes Docker resources based on cleanup options.","operationId":"execute_cleanup_api_v1_vms__vm_id__cleanup_execute_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Execute Cleanup Api V1 Vms  Vm Id  Cleanup Execute Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/tunnel/enable":{"post":{"tags":["Servers"],"summary":"Enable Tunnel","description":"Enable Cloudflare Tunnel for a server.\n\nCreates a new CF Tunnel, configures SSH ingress, and returns an install\nscript that the user must run on the target VM to start the cloudflared\nconnector.\n\nRequires org.servers.update and a Pro plan or above. #1234 (D1) opened\ntunnels to every plan through Add Server, which provisions fully. This older\nroute creates no DNS record or Access app and cannot be undone (disable then\nrefuses), so it keeps the Pro gate until plan row 2.10 replaces it.","operationId":"enable_tunnel_api_v1_vms__vm_id__tunnel_enable_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Enable Tunnel Api V1 Vms  Vm Id  Tunnel Enable Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/tunnel":{"delete":{"tags":["Servers"],"summary":"Disable Tunnel","description":"Disable and delete the Cloudflare Tunnel for a server.\n\nRemoves the tunnel from Cloudflare and clears all tunnel fields on the VM,\nreverting to direct SSH connection.\n\nRequires org.servers.manage permission.","operationId":"disable_tunnel_api_v1_vms__vm_id__tunnel_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Disable Tunnel Api V1 Vms  Vm Id  Tunnel Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/tunnel/status":{"get":{"tags":["Servers"],"summary":"Get Tunnel Status","description":"Get the current Cloudflare Tunnel status for a server.\n\nPolls the Cloudflare API for live connector status and updates the VM record.\n\nRequires org.servers.view permission.","operationId":"get_tunnel_status_api_v1_vms__vm_id__tunnel_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Tunnel Status Api V1 Vms  Vm Id  Tunnel Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/tunnel/install-script":{"get":{"tags":["Servers"],"summary":"Get Tunnel Install Script","description":"Get the install script for the Cloudflare Tunnel connector.\n\nReturns a bash script that installs cloudflared and registers the tunnel\nconnector on the target VM. The script embeds the connector token, so every\nfetch is audited (#1240). The token is NOT rotated on fetch: rotating would\ncut the connector already running on the server until it is reinstalled.\n\nRequires org.servers.update in the server's organization.","operationId":"get_tunnel_install_script_api_v1_vms__vm_id__tunnel_install_script_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Get Tunnel Install Script Api V1 Vms  Vm Id  Tunnel Install Script Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/qualify":{"post":{"tags":["Servers"],"summary":"Qualify Vm Tunnel","description":"Trigger async E2E qualification of a VM's Cloudflare Tunnel.\n\nEnqueues the ``qualify_cloudflare_tunnel`` ARQ task which opens SSH through\nthe tunnel, runs a cheap probe, and records the result on the VM.\n\nRequires org.servers.update permission. Returns 400 if the server is not\ntunnel-managed.","operationId":"qualify_vm_tunnel_api_v1_vms__vm_id__qualify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QualifyTunnelResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/tunnel/diagnostics":{"get":{"tags":["Servers"],"summary":"Get Vm Tunnel Diagnostics","description":"Return CF tunnel diagnostic snapshot for a VM (org-scoped).\n\nReturns all non-sensitive tunnel state: hostname, resource IDs, status,\nqualification timestamps, failure counters, and circuit state. Safe for\norg admins — no tokens, no credentials.\n\nRequires ``org.servers.update`` (same as qualify endpoint). 404 if VM\nnot found; 403 for cross-org access.","operationId":"get_vm_tunnel_diagnostics_api_v1_vms__vm_id__tunnel_diagnostics_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TunnelDiagnosticsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/os-auto-update":{"post":{"tags":["Servers"],"summary":"Set Os Auto Update","description":"Toggle automatic host-OS security updates for a server (task #709).\n\nWhen enabled, the platform SSHes to the server and configures Ubuntu\n``unattended-upgrades`` for SECURITY origins only, with automatic reboot\ndisabled. When disabled, it turns the unattended-upgrade run off.\n\nThe remote configuration is applied BEFORE persisting the flag, so on SSH\nfailure we surface a clear error and leave the DB flag unchanged (never a\nstate that contradicts the server).","operationId":"set_os_auto_update_api_v1_vms__vm_id__os_auto_update_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OSAutoUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Set Os Auto Update Api V1 Vms  Vm Id  Os Auto Update Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/preflight":{"post":{"tags":["Preflight Checks"],"summary":"Run Preflight Checks","description":"Run preflight checks on a server.\n\nReturns a Server-Sent Events (SSE) stream with real-time updates.\n\nEvents:\n- `status`: Connection status (connecting, connected)\n- `progress`: Progress update with step and message\n- `os_info`: Detected operating system information\n- `check`: Individual check result\n- `complete`: Final summary and qualification status\n- `error`: Error message if something fails","operationId":"run_preflight_checks_api_v1_vms__vm_id__preflight_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PreflightRunRequest"},{"type":"null"}],"title":"Request"}}}},"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Preflight Checks"],"summary":"Cancel Preflight Check","description":"Cancel a running preflight check.\n\nReturns success if a check was running and was signaled to stop.","operationId":"cancel_preflight_check_api_v1_vms__vm_id__preflight_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Cancel Preflight Check Api V1 Vms  Vm Id  Preflight Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/preflight/install-docker":{"post":{"tags":["Preflight Checks"],"summary":"Install Docker","description":"Install Docker on a server.\n\nReturns a Server-Sent Events (SSE) stream with installation progress.\nAfter successful installation, automatically runs preflight checks.\n\nEvents:\n- `status`: Connection status\n- `progress`: Installation progress\n- `install_step`: Individual installation step\n- `install_result`: Installation result\n- `rerun`: Notification that preflight is being re-run\n- `check`, `complete`: Preflight check results (after install)\n- `error`: Error message if something fails","operationId":"install_docker_api_v1_vms__vm_id__preflight_install_docker_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/preflight/install-netdata":{"post":{"tags":["Preflight Checks"],"summary":"Install Netdata","description":"Install Netdata monitoring on a server.\n\nReturns a Server-Sent Events (SSE) stream with installation progress.\nAfter successful installation, automatically runs preflight checks.\n\nEvents:\n- `status`: Connection status\n- `progress`: Installation progress\n- `install_step`: Individual installation step\n- `install_result`: Installation result\n- `credentials`: Dashboard URL\n- `rerun`: Notification that preflight is being re-run\n- `check`, `complete`: Preflight check results (after install)\n- `error`: Error message if something fails","operationId":"install_netdata_api_v1_vms__vm_id__preflight_install_netdata_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/preflight/auto-fix-all":{"post":{"tags":["Preflight Checks"],"summary":"Auto Fix All","description":"Auto-fix all fixable issues on a server.\n\nReturns a Server-Sent Events (SSE) stream with progress for each fix action.\nExecutes fixes in optimal order and re-runs preflight checks at the end.\n\nEvents:\n- `status`: Connection status\n- `progress`: Overall progress\n- `auto_fix_plan`: Summary of fixes that will be applied\n- `fix_result`: Result of each individual fix\n- `install_step`, `install_result`: Installation progress (if needed)\n- `check`, `complete`: Final preflight check results\n- `error`: Error message if something fails","operationId":"auto_fix_all_api_v1_vms__vm_id__preflight_auto_fix_all_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/preflight/status":{"get":{"tags":["Preflight Checks"],"summary":"Get Preflight Status","description":"Get current preflight status of a server.\n\nReturns qualification status, last check time, detected OS info, and last check results.","operationId":"get_preflight_status_api_v1_vms__vm_id__preflight_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreflightStatusResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/preflight/history":{"get":{"tags":["Preflight Checks"],"summary":"Get Preflight History","description":"Get preflight check history for a server.\n\nReturns paginated list of past preflight runs.","operationId":"get_preflight_history_api_v1_vms__vm_id__preflight_history_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":10,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreflightHistoryListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/preflight/history/{history_id}":{"get":{"tags":["Preflight Checks"],"summary":"Get Preflight History Detail","description":"Get detailed preflight history record.\n\nReturns full report including all check results.","operationId":"get_preflight_history_detail_api_v1_vms__vm_id__preflight_history__history_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"history_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"History Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreflightHistoryDetail"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/vms/{vm_id}/preflight/fix":{"post":{"tags":["Preflight Checks"],"summary":"Fix Preflight Issue","description":"Execute a fix action for a preflight issue.\n\nAvailable actions:\n- `start_docker`: Start Docker daemon\n- `restart_docker`: Restart Docker daemon\n\nFor Docker installation, use the /install-docker endpoint instead.","operationId":"fix_preflight_issue_api_v1_vms__vm_id__preflight_fix_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreflightFixRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PreflightFixResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments":{"post":{"tags":["Deployments"],"summary":"Create Deployment","description":"Create a new deployment.\n\nThis triggers a deployment for a project environment.\nIf environment_id is provided, triggers actual container deployment.","operationId":"create_deployment_api_v1_deployments_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Deployments"],"summary":"List Deployments","description":"List deployments the user has access to.","operationId":"list_deployments_api_v1_deployments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by project","title":"Project Id"},"description":"Filter by project"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/DeploymentStatus"},{"type":"null"}],"title":"Status"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DeploymentResponse"},"title":"Response List Deployments Api V1 Deployments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/{deployment_id}":{"get":{"tags":["Deployments"],"summary":"Get Deployment","description":"Get deployment details.","operationId":"get_deployment_api_v1_deployments__deployment_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deployment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deployment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/{deployment_id}/logs":{"get":{"tags":["Deployments"],"summary":"Get Deployment Logs","description":"Get deployment logs.","operationId":"get_deployment_logs_api_v1_deployments__deployment_id__logs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deployment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deployment Id"}},{"name":"level","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/LogLevel"},{"type":"null"}],"description":"Filter by log level","title":"Level"},"description":"Filter by log level"},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":500,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Deployment Logs Api V1 Deployments  Deployment Id  Logs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/{deployment_id}/cancel":{"post":{"tags":["Deployments"],"summary":"Cancel Deployment","description":"Cancel a pending or running deployment.","operationId":"cancel_deployment_api_v1_deployments__deployment_id__cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deployment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deployment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"string"},"title":"Response Cancel Deployment Api V1 Deployments  Deployment Id  Cancel Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/{deployment_id}/retry":{"post":{"tags":["Deployments"],"summary":"Retry Deployment","description":"Retry a failed deployment.\n\nCreates a new deployment with the same configuration.","operationId":"retry_deployment_api_v1_deployments__deployment_id__retry_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deployment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deployment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/{deployment_id}/rollback":{"post":{"tags":["Deployments"],"summary":"Rollback Deployment","description":"Not implemented: always 501 (#1170).\n\nThis used to insert a PENDING Deployment row with no environment_id that no\nworker ever picked up; it sat there until the stuck-deploy reaper failed it.\nKept as a route (not removed) so existing callers get a clear answer instead\nof a 404. Creates nothing.","operationId":"rollback_deployment_api_v1_deployments__deployment_id__rollback_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deployment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deployment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"501":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/project/{project_id}/latest":{"get":{"tags":["Deployments"],"summary":"Get Latest Deployment","description":"Get the latest deployment for a project.","operationId":"get_latest_deployment_api_v1_deployments_project__project_id__latest_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Response Get Latest Deployment Api V1 Deployments Project  Project Id  Latest Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/project/{project_id}/stats":{"get":{"tags":["Deployments"],"summary":"Get Deployment Stats","description":"Get deployment statistics for a project.","operationId":"get_deployment_stats_api_v1_deployments_project__project_id__stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Deployment Stats Api V1 Deployments Project  Project Id  Stats Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/{deployment_id}/progress":{"get":{"tags":["Deployments"],"summary":"Get Deployment Progress","description":"Get deployment progress with step-by-step status.","operationId":"get_deployment_progress_api_v1_deployments__deployment_id__progress_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"deployment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Deployment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Deployment Progress Api V1 Deployments  Deployment Id  Progress Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/environment/{environment_id}/destroy":{"delete":{"tags":["Deployments"],"summary":"Destroy Environment","description":"Destroy an environment: stop and remove containers, networks, and volumes.\n\nThis is a destructive operation that:\n- Stops the Odoo container\n- Stops the PostgreSQL container\n- Removes both containers\n- Removes the Docker network\n- Removes PostgreSQL volume (always - required for clean redeployment)\n- Optionally removes Odoo data directory (addons, filestore, config)\n\nThe PostgreSQL volume is always removed to ensure clean redeployment\nwith fresh database credentials.","operationId":"destroy_environment_api_v1_deployments_environment__environment_id__destroy_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"delete_data","in":"query","required":false,"schema":{"type":"boolean","description":"Also delete Odoo data directory (custom addons, filestore)","default":false,"title":"Delete Data"},"description":"Also delete Odoo data directory (custom addons, filestore)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Destroy Environment Api V1 Deployments Environment  Environment Id  Destroy Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/deployments/environment/{environment_id}/latest":{"get":{"tags":["Deployments"],"summary":"Get Latest Deployment For Environment","description":"Get the latest deployment for an environment.\nUseful for tracking active deployments.","operationId":"get_latest_deployment_for_environment_api_v1_deployments_environment__environment_id__latest_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Latest Deployment For Environment Api V1 Deployments Environment  Environment Id  Latest Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/webhooks/github":{"post":{"tags":["Webhooks"],"summary":"Github Webhook","description":"Handle incoming GitHub webhooks.\n\nSupported events:\n- push: Trigger deployment on push to default branch\n- pull_request: Create preview environment (future)\n- release: Tag-based deployment (future)\n\nSecurity:\n- Validates HMAC-SHA256 signature using per-project webhook secret\n- Rejects invalid/missing signatures","operationId":"github_webhook_api_v1_webhooks_github_post","parameters":[{"name":"x-hub-signature-256","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Hub-Signature-256"}},{"name":"x-github-event","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Github-Event"}},{"name":"x-github-delivery","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Github-Delivery"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Github Webhook Api V1 Webhooks Github Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/webhooks/gitlab":{"post":{"tags":["Webhooks"],"summary":"Gitlab Webhook","description":"Handle incoming GitLab webhooks.\n\nSupported events:\n- Push Hook: Trigger deployment on push to default branch\n- Merge Request Hook: Create preview environment (future)\n- Tag Push Hook: Tag-based deployment (future)\n\nSecurity:\n- Validates secret token using per-project webhook secret\n- Rejects invalid/missing tokens","operationId":"gitlab_webhook_api_v1_webhooks_gitlab_post","parameters":[{"name":"x-gitlab-token","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Gitlab-Token"}},{"name":"x-gitlab-event","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Gitlab-Event"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Gitlab Webhook Api V1 Webhooks Gitlab Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/webhooks/status":{"get":{"tags":["Webhooks"],"summary":"Webhook Status","description":"Get webhook configuration status.\n\nReturns whether webhooks are properly configured.","operationId":"webhook_status_api_v1_webhooks_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Webhook Status Api V1 Webhooks Status Get"}}}}}}},"/api/v1/git/github/orgs":{"get":{"tags":["Git Providers"],"summary":"List Github Orgs","description":"List user's GitHub organizations (including personal account).","operationId":"list_github_orgs_api_v1_git_github_orgs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GitOrganization"},"title":"Response List Github Orgs Api V1 Git Github Orgs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/github/repos":{"get":{"tags":["Git Providers"],"summary":"List Github Repos","description":"List repositories for a GitHub organization or user.","operationId":"list_github_repos_api_v1_git_github_repos_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org","in":"query","required":true,"schema":{"type":"string","description":"Organization login or username","title":"Org"},"description":"Organization login or username"},{"name":"org_type","in":"query","required":false,"schema":{"type":"string","description":"Type: 'user' or 'organization'","default":"user","title":"Org Type"},"description":"Type: 'user' or 'organization'"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GitRepository"},"title":"Response List Github Repos Api V1 Git Github Repos Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Git Providers"],"summary":"Create Github Repo","description":"Create a new GitHub repository.","operationId":"create_github_repo_api_v1_git_github_repos_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRepoRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/github/branches":{"get":{"tags":["Git Providers"],"summary":"List Github Branches","description":"List branches for a GitHub repository.","operationId":"list_github_branches_api_v1_git_github_branches_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"repo","in":"query","required":true,"schema":{"type":"string","description":"Repository full name (owner/repo)","title":"Repo"},"description":"Repository full name (owner/repo)"},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization whose git connections should be used. Required when a portal admin browses another org's environment — without it the endpoint falls back to the caller's own orgs and may pick a token that has no access to the target repo.","title":"Organization Id"},"description":"Organization whose git connections should be used. Required when a portal admin browses another org's environment — without it the endpoint falls back to the caller's own orgs and may pick a token that has no access to the target repo."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GitBranch"},"title":"Response List Github Branches Api V1 Git Github Branches Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/github/webhooks":{"post":{"tags":["Git Providers"],"summary":"Setup Github Webhook","description":"Setup webhook for a GitHub repository.","operationId":"setup_github_webhook_api_v1_git_github_webhooks_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookSetupRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookSetupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/gitlab/orgs":{"get":{"tags":["Git Providers"],"summary":"List Gitlab Orgs","description":"List user's GitLab groups (including personal namespace).","operationId":"list_gitlab_orgs_api_v1_git_gitlab_orgs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GitOrganization"},"title":"Response List Gitlab Orgs Api V1 Git Gitlab Orgs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/gitlab/repos":{"get":{"tags":["Git Providers"],"summary":"List Gitlab Repos","description":"List projects for a GitLab group or user.","operationId":"list_gitlab_repos_api_v1_git_gitlab_repos_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org","in":"query","required":true,"schema":{"type":"string","description":"Group path or username","title":"Org"},"description":"Group path or username"},{"name":"org_type","in":"query","required":false,"schema":{"type":"string","description":"Type: 'user' or 'organization'","default":"user","title":"Org Type"},"description":"Type: 'user' or 'organization'"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GitRepository"},"title":"Response List Gitlab Repos Api V1 Git Gitlab Repos Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Git Providers"],"summary":"Create Gitlab Repo","description":"Create a new GitLab project.","operationId":"create_gitlab_repo_api_v1_git_gitlab_repos_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRepoRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/gitlab/branches":{"get":{"tags":["Git Providers"],"summary":"List Gitlab Branches","description":"List branches for a GitLab project.","operationId":"list_gitlab_branches_api_v1_git_gitlab_branches_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"repo","in":"query","required":true,"schema":{"type":"string","description":"Project path (namespace/project)","title":"Repo"},"description":"Project path (namespace/project)"},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization whose git connections should be used. Required when a portal admin browses another org's environment — without it the endpoint falls back to the caller's own orgs and may pick a token that has no access to the target repo.","title":"Organization Id"},"description":"Organization whose git connections should be used. Required when a portal admin browses another org's environment — without it the endpoint falls back to the caller's own orgs and may pick a token that has no access to the target repo."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GitBranch"},"title":"Response List Gitlab Branches Api V1 Git Gitlab Branches Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/gitlab/webhooks":{"post":{"tags":["Git Providers"],"summary":"Setup Gitlab Webhook","description":"Setup webhook for a GitLab project.","operationId":"setup_gitlab_webhook_api_v1_git_gitlab_webhooks_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookSetupRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookSetupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/connections/{connection_id}/orgs":{"get":{"tags":["Git Providers"],"summary":"List Connection Orgs","description":"List organizations/users from a Git connection.","operationId":"list_connection_orgs_api_v1_git_connections__connection_id__orgs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"connection_type","in":"query","required":true,"schema":{"type":"string","description":"Connection type: 'platform' or 'organization'","title":"Connection Type"},"description":"Connection type: 'platform' or 'organization'"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GitOrganization"},"title":"Response List Connection Orgs Api V1 Git Connections  Connection Id  Orgs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git/connections/{connection_id}/repos":{"get":{"tags":["Git Providers"],"summary":"List Connection Repos","description":"List repositories from a Git connection.","operationId":"list_connection_repos_api_v1_git_connections__connection_id__repos_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"connection_type","in":"query","required":true,"schema":{"type":"string","description":"Connection type: 'platform' or 'organization'","title":"Connection Type"},"description":"Connection type: 'platform' or 'organization'"},{"name":"org","in":"query","required":true,"schema":{"type":"string","description":"Organization login or username","title":"Org"},"description":"Organization login or username"},{"name":"org_type","in":"query","required":false,"schema":{"type":"string","description":"Type: 'user' or 'organization'","default":"user","title":"Org Type"},"description":"Type: 'user' or 'organization'"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/GitRepository"},"title":"Response List Connection Repos Api V1 Git Connections  Connection Id  Repos Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/terminal/access/{environment_id}":{"get":{"tags":["Terminal"],"summary":"Get Terminal Access","description":"Get terminal access information for an environment.\n\nReturns a temporary token for WebSocket connection.","operationId":"get_terminal_access_api_v1_terminal_access__environment_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/terminal/server/{vm_id}/access":{"get":{"tags":["Terminal"],"summary":"Get Server Terminal Access","description":"Get terminal access information for a server (direct SSH).\n\nReturns a temporary token for WebSocket connection to server shell.","operationId":"get_server_terminal_access_api_v1_terminal_server__vm_id__access_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/terminal/environment/{environment_id}/access":{"get":{"tags":["Terminal"],"summary":"Get Environment Terminal Access","description":"Get terminal access information for an environment container.\n\nTarget can be 'odoo' or 'postgres' container.\nReturns a temporary token for WebSocket connection.","operationId":"get_environment_terminal_access_api_v1_terminal_environment__environment_id__access_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"target","in":"query","required":false,"schema":{"$ref":"#/components/schemas/TerminalTarget","description":"Terminal target: odoo or postgres container","default":"odoo"},"description":"Terminal target: odoo or postgres container"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/terminal/project/{project_id}/access":{"get":{"tags":["Terminal"],"summary":"Get Project Terminal Access","description":"Get terminal access information for a project's dev sidecar container.\n\nRequires AI Coding feature and dev mode to be enabled on the project.\nSupports multi-VM projects: pass vm_id to target a specific server,\nor omit to auto-select the first VM with a running sidecar.\nReturns a temporary token for WebSocket connection.","operationId":"get_project_terminal_access_api_v1_terminal_project__project_id__access_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"target","in":"query","required":false,"schema":{"$ref":"#/components/schemas/TerminalTarget","description":"Terminal target for project dev sidecar","default":"dev"},"description":"Terminal target for project dev sidecar"},{"name":"vm_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Specific VM to connect to (for multi-VM projects). If omitted, auto-selects first available.","title":"Vm Id"},"description":"Specific VM to connect to (for multi-VM projects). If omitted, auto-selects first available."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shell/environments/{environment_id}/access":{"post":{"tags":["Shell Access"],"summary":"Setup Shell Access","description":"Set up secure shell access to an environment container.\n\nThis configures SSH ForceCommand access that:\n- Drops user directly into the container\n- Prevents ANY access to the host machine\n- Auto-disconnects when user exits container\n\nRequired: User must have access to the environment's project.","operationId":"setup_shell_access_api_v1_shell_environments__environment_id__access_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShellAccessRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShellAccessResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Shell Access"],"summary":"Revoke Shell Access","description":"Revoke shell access to an environment container.\n\nThis removes the SSH user and kills any active sessions.","operationId":"revoke_shell_access_api_v1_shell_environments__environment_id__access_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"container_type","in":"query","required":false,"schema":{"$ref":"#/components/schemas/ShellAccessType","default":"odoo"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevokeAccessResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shell/generate-key":{"post":{"tags":["Shell Access"],"summary":"Generate Ssh Key","description":"Generate a new SSH key pair for shell access.\n\nThe private key is returned ONCE - save it securely!\nThe public key should be used when setting up shell access.","operationId":"generate_ssh_key_api_v1_shell_generate_key_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateKeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit-logs/actions":{"get":{"tags":["Audit Logs"],"summary":"List Audit Actions","description":"List all available audit action types.\n\nReturns categorized list of audit actions for filtering.","operationId":"list_audit_actions_api_v1_audit_logs_actions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditActionsListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit-logs":{"get":{"tags":["Audit Logs"],"summary":"List Audit Logs","description":"List audit logs with filtering and pagination.\n\nAccess control (#1431, DPA): ``org.audit.view`` in the organization\n(Owner, Admin, Developer). Without ``organization_id`` the check runs at\nportal scope, which only platform admins pass (the admin audit page).","operationId":"list_audit_logs_api_v1_audit_logs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization","title":"Organization Id"},"description":"Filter by organization"},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by user","title":"User Id"},"description":"Filter by user"},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by action type","title":"Action"},"description":"Filter by action type"},{"name":"resource_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by resource type","title":"Resource Type"},"description":"Filter by resource type"},{"name":"resource_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by resource ID","title":"Resource Id"},"description":"Filter by resource ID"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search in user email and resource name","title":"Search"},"description":"Search in user email and resource name"},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Filter from date","title":"Start Date"},"description":"Filter from date"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Filter to date","title":"End Date"},"description":"Filter to date"},{"name":"staff_access_only","in":"query","required":false,"schema":{"type":"boolean","description":"Only oec.sh staff access rows","default":false,"title":"Staff Access Only"},"description":"Only oec.sh staff access rows"},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Pagination offset","default":0,"title":"Skip"},"description":"Pagination offset"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Pagination limit","default":50,"title":"Limit"},"description":"Pagination limit"},{"name":"sort_by","in":"query","required":false,"schema":{"type":"string","description":"Sort by: created_at, action","default":"created_at","title":"Sort By"},"description":"Sort by: created_at, action"},{"name":"sort_order","in":"query","required":false,"schema":{"type":"string","description":"Sort order: asc or desc","default":"desc","title":"Sort Order"},"description":"Sort order: asc or desc"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditLogListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit-logs/filters":{"get":{"tags":["Audit Logs"],"summary":"Get Audit Filter Options","description":"#1431: actions, resource types and people present in the org's audit log.","operationId":"get_audit_filter_options_api_v1_audit_logs_filters_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Organization whose log to describe","title":"Organization Id"},"description":"Organization whose log to describe"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditFilterOptionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit-logs/export/csv":{"get":{"tags":["Audit Logs"],"summary":"Export Audit Logs Csv","description":"Export the audit log matching the current filters as CSV (#1431, DPA).\n\n``org.audit.view`` in the organization (Owner, Admin, Developer); without\n``organization_id`` only platform admins pass (admin page). With an\norganization, the export also carries the sign-in events of the org's\ncurrent members (written without an organization), from when they joined,\nif the caller also has ``org.members.remove`` (Owner, Admin).\nCapped at 10,000 rows, newest first; ``X-Export-Truncated: true`` says the\ncap was hit.","operationId":"export_audit_logs_csv_api_v1_audit_logs_export_csv_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"}},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"}},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"}},{"name":"resource_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"staff_access_only","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Staff Access Only"}},{"name":"include_sign_ins","in":"query","required":false,"schema":{"type":"boolean","description":"Add the org's current members' sign-in events (organization_id given; Owner/Admin only, silently left out otherwise)","default":true,"title":"Include Sign Ins"},"description":"Add the org's current members' sign-in events (organization_id given; Owner/Admin only, silently left out otherwise)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit-logs/export/xlsx":{"get":{"tags":["Audit Logs"],"summary":"Export Audit Logs Xlsx","description":"Export audit logs to XLSX format.\n\nOnly available to portal staff (admin, manager, executive).\nLimited to 10,000 records per export.\nRequires openpyxl package.","operationId":"export_audit_logs_xlsx_api_v1_audit_logs_export_xlsx_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"}},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"}},{"name":"action","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"}},{"name":"resource_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/audit-logs/{log_id}":{"get":{"tags":["Audit Logs"],"summary":"Get Audit Log","description":"Get a specific audit log by ID.\n\nThe organization comes from the row, so the ``org.audit.view`` check runs\ninline (not the decorator, which reads it from the request): an org row\nneeds ``org.audit.view`` in that org; a row without an org (sign-in\nevents) is visible to the person it belongs to and to platform admins.","operationId":"get_audit_log_api_v1_audit_logs__log_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"log_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Log Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuditLogResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/providers":{"get":{"tags":["DNS Management"],"summary":"List Dns Providers","description":"List all DNS providers and their credential schemas.\n\nReturns information about supported providers including:\n- Provider ID and display name\n- Whether the provider is currently supported (code exists)\n- Whether the provider is enabled on this platform (platform setting)\n- Credential input field schemas\n\nOnly providers enabled at platform level will be shown as available.","operationId":"list_dns_providers_api_v1_dns_providers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProvidersListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/verify-credentials":{"post":{"tags":["DNS Management"],"summary":"Verify Credentials And List Zones","description":"Verify DNS provider credentials and return available zones.\n\nUse this endpoint BEFORE creating a DNS config to:\n1. Validate that the API token/credentials work\n2. Fetch available DNS zones for user selection\n\nThis allows the user to select a zone from a dropdown rather than typing it manually.","operationId":"verify_credentials_and_list_zones_api_v1_dns_verify_credentials_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyCredentialsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyCredentialsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/cloud-accounts/{cloud_account_id}/zones":{"get":{"tags":["DNS Management"],"summary":"List Zones From Cloud Account","description":"Fetch DNS zones from a cloud account.\n\nThis endpoint uses the cloud account's credentials to query the DNS provider\nand return available zones. Used for auto-discovery when linking a cloud\naccount to DNS configuration.","operationId":"list_zones_from_cloud_account_api_v1_dns_cloud_accounts__cloud_account_id__zones_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"cloud_account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Cloud Account Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ZoneListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/configs":{"post":{"tags":["DNS Management"],"summary":"Create Dns Config","description":"Create a new DNS provider configuration.\n\nRequires OWNER/ADMIN role in the organization.\nCredentials are encrypted before storage.\nRequires PRO plan or higher.","operationId":"create_dns_config_api_v1_dns_configs_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSConfigCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/configs/org/{organization_id}":{"get":{"tags":["DNS Management"],"summary":"List Dns Configs","description":"List DNS configurations for an organization.\n\nReturns all active DNS provider configurations.","operationId":"list_dns_configs_api_v1_dns_configs_org__organization_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DNSConfigResponse"},"title":"Response List Dns Configs Api V1 Dns Configs Org  Organization Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/configs/{config_id}":{"get":{"tags":["DNS Management"],"summary":"Get Dns Config","description":"Get a specific DNS configuration.","operationId":"get_dns_config_api_v1_dns_configs__config_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["DNS Management"],"summary":"Update Dns Config","description":"Update a DNS configuration.\n\nRequires OWNER/ADMIN role.\nRequires PRO plan or higher.","operationId":"update_dns_config_api_v1_dns_configs__config_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSConfigUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["DNS Management"],"summary":"Delete Dns Config","description":"Delete a DNS configuration.\n\nRequires OWNER/ADMIN role.\nRequires PRO plan or higher.\nThis will NOT delete DNS records from the provider.","operationId":"delete_dns_config_api_v1_dns_configs__config_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/configs/{config_id}/verify":{"post":{"tags":["DNS Management"],"summary":"Verify Dns Config","description":"Verify DNS configuration credentials.\n\nTests that the credentials can connect to the DNS provider.","operationId":"verify_dns_config_api_v1_dns_configs__config_id__verify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/configs/{config_id}/request-wildcard-ssl":{"post":{"tags":["DNS Management"],"summary":"Request Wildcard Ssl","description":"Request/issue a wildcard SSL certificate for the configured domain.\n\nThis triggers the DNS-01 challenge to obtain a wildcard certificate\nfrom Let's Encrypt. The certificate covers all subdomains of the\nconfigured wildcard_domain.\n\nRequirements:\n- DNS config must have enable_wildcard_ssl=True\n- wildcard_domain must be configured\n- DNS credentials must be valid\n- PRO plan or higher\n\nThe process:\n1. Creates a TXT record for ACME challenge\n2. Let's Encrypt validates domain ownership\n3. Certificate is issued\n4. Config status updated to 'active' or 'error'","operationId":"request_wildcard_ssl_api_v1_dns_configs__config_id__request_wildcard_ssl_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Request Wildcard Ssl Api V1 Dns Configs  Config Id  Request Wildcard Ssl Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/configs/{config_id}/zones":{"get":{"tags":["DNS Management"],"summary":"List Dns Zones","description":"List available DNS zones for a configuration.\n\nReturns all zones accessible with the configured credentials.","operationId":"list_dns_zones_api_v1_dns_configs__config_id__zones_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ZoneListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/domains":{"post":{"tags":["DNS Management"],"summary":"Create Domain","description":"Add a domain to a project environment.\n\nIf dns_config_id is provided and auto_configure is true,\na DNS record will be created automatically -- or, if a record for this\nhostname already exists in the target zone, it is adopted/updated to\nmatch rather than causing a failure. If an existing record has a\ndifferent type/content that couldn't be reconciled, the domain stays\nunverified with a resolution_note explaining what to fix manually.\nRequires PRO plan or higher.\n\n#718: if the new domain is a strict subdomain of an org wildcard config\nwhose cert is active, the domain is auto-linked to that config\n(dns_config_id + auto_configure) and, after commit, the org wildcard cert\nis pushed to the env's VM (cert-only) + the env is relabelled so the\nper-subdomain router serves the wildcard cert by SNI — no per-domain LE.","operationId":"create_domain_api_v1_dns_domains_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/domains/environment/{environment_id}":{"get":{"tags":["DNS Management"],"summary":"List Environment Domains","description":"List domains for a project environment.","operationId":"list_environment_domains_api_v1_dns_domains_environment__environment_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DomainResponse"},"title":"Response List Environment Domains Api V1 Dns Domains Environment  Environment Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/domains/{domain_id}":{"get":{"tags":["DNS Management"],"summary":"Get Domain","description":"Get a specific domain.","operationId":"get_domain_api_v1_dns_domains__domain_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["DNS Management"],"summary":"Update Domain","description":"Update a domain configuration.\n\nRequires PRO plan or higher.","operationId":"update_domain_api_v1_dns_domains__domain_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["DNS Management"],"summary":"Delete Domain","description":"Delete a domain.\n\nIf delete_dns_record is true (default), the DNS record will also be deleted\nfrom the provider.\nRequires PRO plan or higher.","operationId":"delete_domain_api_v1_dns_domains__domain_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"delete_dns_record","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Delete Dns Record"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/domains/{domain_id}/verify":{"post":{"tags":["DNS Management"],"summary":"Verify Domain","description":"Verify domain DNS configuration.\n\nRequires the `_oecsh-verify.<domain>` TXT proof (#771 R2) before anything\nis marked verified. Until this fix the route asked one question — \"does a\nDNS record for this name exist in a zone I can reach?\" — and a caller\nsupplies both the hostname and the zone, so the answer was always yes for\na hostname they do not own. `is_verified` is what `traefik_service`\n(`:124`, `:386`) routes on, which made this a second, unguarded takeover\npath alongside the one closed in `domains_routes`.\n\nIf no DNS record exists yet for this domain, this retries the same\nadopt-or-update logic as domain creation: an existing record with the\nright content is adopted as-is (which can mean actively rewriting its\ncontent/proxy setting to match if it had drifted), and an existing\nrecord of a different type/content is left untouched with the domain\nstaying unverified.","operationId":"verify_domain_api_v1_dns_domains__domain_id__verify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/configs/{config_id}/records":{"post":{"tags":["DNS Management"],"summary":"Create Dns Record","description":"Create a DNS record directly via the provider.\n\nFor advanced users who want to manage DNS records without domain tracking.\nRequires PRO plan or higher.\n\nUnlike the domain-management endpoints (POST /domains and\n/domains/{id}/verify), this is a STRICT create: it fails with an error if\na record for this name/type already exists, rather than adopting or\nupdating it. That's deliberate here -- an explicit, user-directed \"create\na record\" call should never silently mutate a record the caller didn't\nreference.","operationId":"create_dns_record_api_v1_dns_configs__config_id__records_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSRecordCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSRecordResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dns/configs/{config_id}/zones/{zone_id}/records":{"get":{"tags":["DNS Management"],"summary":"List Dns Records","description":"List DNS records in a zone.","operationId":"list_dns_records_api_v1_dns_configs__config_id__zones__zone_id__records_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"zone_id","in":"path","required":true,"schema":{"type":"string","title":"Zone Id"}},{"name":"record_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/DNSRecordType"},{"type":"null"}],"title":"Record Type"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DNSRecordResponse"},"title":"Response List Dns Records Api V1 Dns Configs  Config Id  Zones  Zone Id  Records Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agency-domain/organizations/{organization_id}/config":{"get":{"tags":["Agency Domain"],"summary":"Get agency domain configuration","description":"Get the agency domain configuration for an organization.","operationId":"get_agency_domain_config_api_v1_agency_domain_organizations__organization_id__config_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencyDomainConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Agency Domain"],"summary":"Configure agency domain","description":"Set up the agency domain for white-label URLs. Requires AGENCY plan.","operationId":"configure_agency_domain_api_v1_agency_domain_organizations__organization_id__config_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencyDomainConfigRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencyDomainConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Agency Domain"],"summary":"Remove agency domain","description":"Remove the agency domain configuration. Existing subdomains become orphaned.","operationId":"remove_agency_domain_api_v1_agency_domain_organizations__organization_id__config_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agency-domain/organizations/{organization_id}/cert/repush":{"post":{"tags":["Agency Domain"],"summary":"Re-push agency domain cert to all VMs","description":"Manually push the currently-active agency wildcard cert to all BYOS VMs hosting this org's environments. Useful for recovering stuck VMs. Requires AGENCY plan.","operationId":"repush_agency_cert_api_v1_agency_domain_organizations__organization_id__cert_repush_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Repush Agency Cert Api V1 Agency Domain Organizations  Organization Id  Cert Repush Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agency-domain/organizations/{organization_id}/subdomains":{"get":{"tags":["Agency Domain"],"summary":"List agency subdomains","description":"List all agency subdomains configured for the organization's environments.","operationId":"list_agency_subdomains_api_v1_agency_domain_organizations__organization_id__subdomains_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencySubdomainListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/agency-domain/environments/{environment_id}/subdomain":{"put":{"tags":["Agency Domain"],"summary":"Set agency subdomain","description":"Set the agency subdomain for an environment. Creates DNS record automatically. Requires AGENCY plan.","operationId":"set_agency_subdomain_api_v1_agency_domain_environments__environment_id__subdomain_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencySubdomainRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencySubdomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Agency Domain"],"summary":"Remove agency subdomain","description":"Remove the agency subdomain from an environment. Deletes DNS record.","operationId":"remove_agency_subdomain_api_v1_agency_domain_environments__environment_id__subdomain_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Agency Domain"],"summary":"Get agency subdomain","description":"Get the agency subdomain configuration for an environment.","operationId":"get_agency_subdomain_api_v1_agency_domain_environments__environment_id__subdomain_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencySubdomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/theme":{"get":{"tags":["Theme"],"summary":"Get organization theme (Phase 2.5)","operationId":"get_theme_api_v1_organizations__organization_id__theme_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThemeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Theme"],"summary":"Update theme colours (Agency)","operationId":"patch_theme_api_v1_organizations__organization_id__theme_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThemePatchRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThemeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Theme"],"summary":"Reset theme to platform defaults (Agency)","operationId":"delete_theme_api_v1_organizations__organization_id__theme_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/theme/upload/{asset_type}":{"post":{"tags":["Theme"],"summary":"Upload a branding asset (Agency)","operationId":"upload_asset_api_v1_organizations__organization_id__theme_upload__asset_type__post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"asset_type","in":"path","required":true,"schema":{"type":"string","pattern":"^(logo|favicon|login_bg)$","title":"Asset Type"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_asset_api_v1_organizations__organization_id__theme_upload__asset_type__post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThemeUploadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/theme/by-domain":{"get":{"tags":["Theme (public)"],"summary":"Resolve theme by host (unauth, anti-enumeration)","operationId":"theme_by_domain_api_v1_theme_by_domain_get","parameters":[{"name":"host","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":253,"title":"Host"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicThemeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/sender-domain":{"post":{"tags":["Sender Domain"],"summary":"Configure custom sender domain (BYO-SMTP)","description":"Create a new SMTP sender configuration.\n\nThe service runs a pre-save `test_connection` BEFORE persisting.\nOn test failure, returns 400 with the SMTP error message — no row\nis created. On success, the row is saved with status `pending_test`\nand will flip to `active` on the first outbound message.","operationId":"create_sender_domain_api_v1_organizations__organization_id__sender_domain_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SenderDomainCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SenderDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Sender Domain"],"summary":"Get sender domain configuration","description":"Return the org's current configuration, or 404 if none.","operationId":"get_sender_domain_api_v1_organizations__organization_id__sender_domain_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SenderDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Sender Domain"],"summary":"Update sender domain configuration","description":"Patch the configuration. Re-tests SMTP on credential change.","operationId":"update_sender_domain_api_v1_organizations__organization_id__sender_domain_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SenderDomainUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SenderDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Sender Domain"],"summary":"Remove sender domain (hard delete)","description":"Hard-delete the configuration. UNIQUE(org_id) means re-add is just a POST.","operationId":"delete_sender_domain_api_v1_organizations__organization_id__sender_domain_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/sender-domain/test-connection":{"post":{"tags":["Sender Domain"],"summary":"Test current saved SMTP credentials (no message sent)","description":"Re-test the saved credentials. EHLO + STARTTLS + AUTH, no DATA.","operationId":"test_connection_api_v1_organizations__organization_id__sender_domain_test_connection_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TestConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/sender-domain/test-send":{"post":{"tags":["Sender Domain"],"summary":"Send a test email via the customer's SMTP","description":"Send a hard-coded test message via the customer's SMTP.\n\nSends directly via `SMTPSenderService` (not through EmailService's\nfallback path) so the customer sees the exact result of their\nconfiguration, not a silent fallback.\n\nOn send failure, returns 502 with a generic detail (committee S1,\nv1.38.1). The raw SMTP error lives in the server-side log and the\nSENDER_DOMAIN_SEND_FAILED audit row, never in the API response.","operationId":"test_send_api_v1_organizations__organization_id__sender_domain_test_send_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TestSendRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SenderDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/client-domains":{"get":{"tags":["Agency Client Domains"],"summary":"List Client Domains","description":"List client domains attached to a project — spec §6.2.","operationId":"list_client_domains_api_v1_projects__project_id__client_domains_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencyClientDomainListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Agency Client Domains"],"summary":"Add Client Domain","description":"Register a new client apex domain — spec §6.1.","operationId":"add_client_domain_api_v1_projects__project_id__client_domains_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencyClientDomainAddRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencyClientDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/client-domains/{domain_id}":{"delete":{"tags":["Agency Client Domains"],"summary":"Remove Client Domain","description":"Remove a client apex domain — spec §6.3.","operationId":"remove_client_domain_api_v1_projects__project_id__client_domains__domain_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/client-domains/{domain_id}/verify":{"post":{"tags":["Agency Client Domains"],"summary":"Verify Client Domain","description":"Re-trigger CF validation; non-blocking (committee S4) — spec §6.4.","operationId":"verify_client_domain_api_v1_projects__project_id__client_domains__domain_id__verify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencyClientDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/client-domains/{domain_id}/cname-info":{"get":{"tags":["Agency Client Domains"],"summary":"Get Cname Info","description":"Share-with-client payload — spec §6.5.","operationId":"get_cname_info_api_v1_projects__project_id__client_domains__domain_id__cname_info_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AgencyClientDomainCnameInfoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/platform-hostname":{"post":{"tags":["Custom Platform URL"],"summary":"Add Platform Hostname","description":"Register a custom platform hostname for the organization.\n\nDecorator order matters: plan-gate runs FIRST so non-Agency orgs hit\n402 before any permission check fires (spec §5.4 numbered list).","operationId":"add_platform_hostname_api_v1_organizations__organization_id__platform_hostname_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformHostnameAddRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformHostnameResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Custom Platform URL"],"summary":"Get Platform Hostname","description":"Get the org's platform hostname row (404 if not configured).","operationId":"get_platform_hostname_api_v1_organizations__organization_id__platform_hostname_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformHostnameResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Custom Platform URL"],"summary":"Delete Platform Hostname","description":"Soft-delete the platform hostname + unregister at CF.","operationId":"delete_platform_hostname_api_v1_organizations__organization_id__platform_hostname_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/platform-hostname/verify":{"post":{"tags":["Custom Platform URL"],"summary":"Verify Platform Hostname","description":"Re-trigger CF validation; non-blocking — frontend polls afterwards.","operationId":"verify_platform_hostname_api_v1_organizations__organization_id__platform_hostname_verify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformHostnameResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/platform-hostname/cname":{"get":{"tags":["Custom Platform URL"],"summary":"Get Platform Hostname Cname","description":"Return the DNS-record instructions the Agency shares with their\nnetwork admin.","operationId":"get_platform_hostname_cname_api_v1_organizations__organization_id__platform_hostname_cname_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformHostnameCnameInfoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments":{"get":{"tags":["environment-actions"],"summary":"List All Environments","description":"List all environments the user has access to across all projects.\n\nPortal admins can see all environments across all organizations.\nRegular users can only see environments in organizations they are members of.\nOptionally filter by organization.","operationId":"list_all_environments_api_v1_environments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization","title":"Organization Id"},"description":"Filter by organization"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProjectEnvironmentResponse"},"title":"Response List All Environments Api V1 Environments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}":{"get":{"tags":["environment-actions"],"summary":"Get Environment","description":"Get a single environment by ID.\n\nUser must have VIEW access to the environment (Viewers can see environments).\nThis is a read-only endpoint - use POST /actions for modifications.","operationId":"get_environment_api_v1_environments__environment_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectEnvironmentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/actions":{"post":{"tags":["environment-actions"],"summary":"Execute Action","description":"Execute an action on an environment.\n\nThis endpoint handles synchronous actions (start, stop, pause, resume, restart, sync)\nand queues asynchronous actions (deploy, redeploy, destroy, clone).\n\nArgs:\n    environment_id: Environment UUID\n    request: Action request with action type and optional parameters\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    ActionResponse with execution result\n\nRaises:\n    HTTPException: If environment not found, action invalid, a deployment is already active (409), or execution fails","operationId":"execute_action_api_v1_environments__environment_id__actions_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/lifecycle":{"get":{"tags":["environment-actions"],"summary":"Get Environment Lifecycle","description":"#1431 review: the environment page's Lifecycle panel.\n\nSame gate as the environment page itself (``_verify_environment_view_access``:\nproject.environments.list, or any active org member read-only), so Viewers\nkeep the panel now that /audit-logs needs org.audit.view. Returns only\nlifecycle actions and the actor's email: no IP, user agent or details.","operationId":"get_environment_lifecycle_api_v1_environments__environment_id__lifecycle_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":8,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LifecycleListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/running-operation":{"get":{"tags":["environment-actions"],"summary":"Get Running Operation","description":"#1390: the operation that would refuse a deploy now, for the environment page.\n\nA Quick Update (a zip module change starts one) is not a deployment row and\nleaves the environment's status alone, so the page can't tell from those.","operationId":"get_running_operation_api_v1_environments__environment_id__running_operation_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunningOperationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/available-actions":{"get":{"tags":["environment-actions"],"summary":"Get Available Actions Endpoint","description":"Get available actions for an environment based on its current status.\n\nThis endpoint returns a list of actions that can be performed on the environment\ngiven its current state, along with metadata about each action (label, description,\nwhether it's destructive, requires confirmation, or is async).\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    AvailableActionsResponse with list of available actions\n\nRaises:\n    HTTPException: If environment not found or user lacks access","operationId":"get_available_actions_endpoint_api_v1_environments__environment_id__available_actions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailableActionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/sync-status":{"post":{"tags":["environment-actions"],"summary":"Sync Environment Status","description":"Sync environment status with actual container state.\n\nThis is a convenience endpoint that wraps the SYNC action.\nIt checks the actual container state on the VM and updates the\nenvironment status in the database accordingly.\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    ActionResponse with sync result\n\nRaises:\n    HTTPException: If environment not found or sync fails","operationId":"sync_environment_status_api_v1_environments__environment_id__sync_status_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/setup-dns":{"post":{"tags":["environment-actions"],"summary":"Setup Environment Dns","description":"Setup DNS record for an environment.\n\nCreates or updates a DNS A record pointing the environment's subdomain\nto the server's IP address. Uses the organization's configured DNS provider.\n\nThis is useful for:\n- Fixing DNS issues on existing deployments\n- Manually triggering DNS setup after deployment\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    ActionResponse with DNS setup result\n\nRaises:\n    HTTPException: If environment not found or DNS setup fails","operationId":"setup_environment_dns_api_v1_environments__environment_id__setup_dns_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Setup Environment Dns Api V1 Environments  Environment Id  Setup Dns Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/size":{"get":{"tags":["environment-actions"],"summary":"Get Environment Size","description":"Get the current size information for an environment.\n\nReturns cached size information from the database. To recalculate,\nuse POST /{environment_id}/size/calculate.\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    EnvironmentSizeResponse with size breakdown\n\nRaises:\n    HTTPException: If environment not found","operationId":"get_environment_size_api_v1_environments__environment_id__size_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Environment Size Api V1 Environments  Environment Id  Size Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/size/calculate":{"post":{"tags":["environment-actions"],"summary":"Calculate Environment Size","description":"Calculate and update the size of an environment.\n\nConnects to the server and calculates:\n- Database size (PostgreSQL pg_database_size)\n- Filestore size (/var/lib/odoo/filestore/{db_name})\n- Custom addons size (/mnt/extra-addons)\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    EnvironmentSizeResponse with updated size breakdown\n\nRaises:\n    HTTPException: If environment not found or calculation fails","operationId":"calculate_environment_size_api_v1_environments__environment_id__size_calculate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Calculate Environment Size Api V1 Environments  Environment Id  Size Calculate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/clone-estimate":{"get":{"tags":["environment-actions"],"summary":"Get Clone Time Estimate","description":"Get estimated time to clone an environment.\n\nBased on the environment's size, estimates the time needed to:\n- Backup and restore the database\n- Copy filestore and addons (if included)\n- Container and infrastructure setup overhead\n\nArgs:\n    environment_id: Environment UUID\n    include_filestore: Whether filestore will be copied (default True)\n    include_addons: Whether addons will be copied (default True)\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    CloneTimeEstimate with time breakdown\n\nRaises:\n    HTTPException: If environment not found or size not calculated","operationId":"get_clone_time_estimate_api_v1_environments__environment_id__clone_estimate_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"include_filestore","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Filestore"}},{"name":"include_addons","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Addons"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Clone Time Estimate Api V1 Environments  Environment Id  Clone Estimate Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/quick-update":{"post":{"tags":["environment-actions"],"summary":"Quick Update Environment","description":"Perform a quick update on an environment (development mode).\n\nThis is designed for rapid development cycles:\n- restart_only: Just restart the container (fastest)\n- pull_restart: Git pull + restart (for code changes, uses dev hot reload)\n- update_all: Git pull + update all modules + restart (full module update)\n\nNote: For pull_restart and update_all modes, the environment should have\ndev_mode configured for best results.\n\nArgs:\n    environment_id: Environment UUID\n    request: QuickUpdateRequest with mode\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    QuickUpdateResponse with result\n\nRaises:\n    HTTPException: If environment not found, not running, or update fails","operationId":"quick_update_environment_api_v1_environments__environment_id__quick_update_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuickUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuickUpdateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/addons-path":{"get":{"tags":["environment-actions"],"summary":"Get Environment Addons Path","description":"Get the addons path configuration for an environment.\n\nReturns the auto-discovered addons paths from the last deploy scan,\nany user-specified custom override, and the effective path currently in use.\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    EnvironmentAddonsPathResponse with resolved, custom, and effective paths\n\nRaises:\n    HTTPException: If environment not found or user lacks view access","operationId":"get_environment_addons_path_api_v1_environments__environment_id__addons_path_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentAddonsPathResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["environment-actions"],"summary":"Update Environment Addons Path","description":"Update the custom addons path for an environment.\n\nSet custom_addons_path to a string to override auto-detected paths.\nSet to null to revert to the auto-detected addons path.\n\nNote: Changes take effect on next deployment/restart.\n\nArgs:\n    environment_id: Environment UUID\n    data: UpdateAddonsPathRequest with new custom_addons_path\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    EnvironmentAddonsPathResponse with updated paths\n\nRaises:\n    HTTPException: If environment not found or user lacks action access","operationId":"update_environment_addons_path_api_v1_environments__environment_id__addons_path_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateAddonsPathRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentAddonsPathResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tasks":{"get":{"tags":["Tasks"],"summary":"List Tasks","description":"List all tasks in the selected organization.\n\nSupports filtering by status and task type with pagination.\n\n**Security**: Filters tasks by organization to prevent cross-org data leaks.\nUsers can see all tasks in their organization (not just their own).","operationId":"list_tasks_api_v1_tasks_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TaskStatus"},{"type":"null"}],"title":"Status"}},{"name":"task_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TaskType"},{"type":"null"}],"title":"Task Type"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tasks/{task_id}":{"get":{"tags":["Tasks"],"summary":"Get Task","description":"Get task details by ID.\n\nUsers can view any task in their organization.","operationId":"get_task_api_v1_tasks__task_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Task Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tasks/{task_id}/cancel":{"post":{"tags":["Tasks"],"summary":"Cancel Task","description":"Cancel a pending, queued, or running task.\n\nPortal admins can cancel any task. Regular users can only cancel their own.","operationId":"cancel_task_api_v1_tasks__task_id__cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Task Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskCancelResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tasks/environment/{environment_id}":{"get":{"tags":["Tasks"],"summary":"List Environment Tasks","description":"List all tasks for a specific environment.","operationId":"list_environment_tasks_api_v1_tasks_environment__environment_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TaskStatus"},{"type":"null"}],"title":"Status"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/clone/compatible-servers":{"get":{"tags":["clone"],"summary":"Get compatible servers for cross-server clone","description":"Get list of servers compatible for cross-server clone.\n\nReturns servers in the same organization that have enough resources\nto clone the specified environment.\n\nNote: This feature requires the PRO plan or higher.\n\nArgs:\n    environment_id: Source environment UUID\n    db: Database session\n    current_user: Authenticated user\n\nReturns:\n    List of compatible servers with resource availability information","operationId":"get_compatible_servers_for_clone_api_v1_environments__environment_id__clone_compatible_servers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CompatibleServerResponse"},"title":"Response Get Compatible Servers For Clone Api V1 Environments  Environment Id  Clone Compatible Servers Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/clone":{"post":{"tags":["clone"],"summary":"Clone Environment","description":"Start cloning an environment with optional neutralization.\n\nCreates a CloneOperation record and queues a background task\nfor the actual clone operation. Uses Odoo's native neutralize\ncommand to disable emails, crons, payments, webhooks, etc.\n\nArgs:\n    request: Starlette HTTP request (for rate limiting)\n    environment_id: Source environment UUID\n    clone_request: Clone configuration (target, neutralize flag)\n    db: Database session\n    current_user: Authenticated user\n\nReturns:\n    CloneOperationResponse with operation ID and initial status","operationId":"clone_environment_api_v1_environments__environment_id__clone_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneEnvironmentRequest"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneOperationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clone-operations/{clone_op_id}":{"get":{"tags":["clone"],"summary":"Get Clone Operation","description":"Get the status of a clone operation.\n\nArgs:\n    clone_op_id: Clone operation UUID\n    db: Database session\n    current_user: Authenticated user\n\nReturns:\n    Current status and progress of the clone operation","operationId":"get_clone_operation_api_v1_clone_operations__clone_op_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"clone_op_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Clone Op Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloneOperationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/clone-operations":{"get":{"tags":["clone"],"summary":"List Clone Operations","description":"List clone operations for an environment.\n\nReturns operations where this environment was either source or target.\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Authenticated user\n    limit: Maximum number of operations to return\n\nReturns:\n    List of clone operations","operationId":"list_clone_operations_api_v1_environments__environment_id__clone_operations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":10,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CloneOperationListItem"},"title":"Response List Clone Operations Api V1 Environments  Environment Id  Clone Operations Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/clone-status":{"get":{"tags":["clone"],"summary":"Get latest active clone operation for environment","description":"Get the latest active clone operation for an environment (as target).\n\nThis endpoint is used by the frontend to display clone progress\nwhen an environment is being cloned to.\n\nArgs:\n    environment_id: Target environment UUID\n    db: Database session\n    current_user: Authenticated user\n\nReturns:\n    Dictionary with has_clone flag, operation_id, and optionally the operation details","operationId":"get_environment_clone_status_api_v1_environments__environment_id__clone_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Environment Clone Status Api V1 Environments  Environment Id  Clone Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clone-operations/{clone_op_id}/cancel":{"post":{"tags":["clone"],"summary":"Cancel Clone Operation","description":"Cancel a running clone operation.\n\nArgs:\n    clone_op_id: Clone operation UUID\n    db: Database session\n    current_user: Authenticated user\n\nReturns:\n    Cancellation status","operationId":"cancel_clone_operation_api_v1_clone_operations__clone_op_id__cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"clone_op_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Clone Op Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Cancel Clone Operation Api V1 Clone Operations  Clone Op Id  Cancel Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications":{"get":{"tags":["Notifications"],"summary":"List Notifications","description":"List notifications for the current user.\n\nReturns paginated notifications with total count and unread count.","operationId":"list_notifications_api_v1_notifications_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"unread_only","in":"query","required":false,"schema":{"type":"boolean","description":"Only return unread notifications","default":false,"title":"Unread Only"},"description":"Only return unread notifications"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Maximum number of notifications to return","default":50,"title":"Limit"},"description":"Maximum number of notifications to return"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Number of notifications to skip","default":0,"title":"Offset"},"description":"Number of notifications to skip"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/unread-count":{"get":{"tags":["Notifications"],"summary":"Get Unread Count","description":"Get count of unread notifications for the current user.\n\nUseful for displaying notification badges in the UI.","operationId":"get_unread_count_api_v1_notifications_unread_count_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnreadCountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/{notification_id}/read":{"post":{"tags":["Notifications"],"summary":"Mark As Read","description":"Mark a specific notification as read.\n\nReturns success status.","operationId":"mark_as_read_api_v1_notifications__notification_id__read_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"notification_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Notification Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Mark As Read Api V1 Notifications  Notification Id  Read Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/mark-all-read":{"post":{"tags":["Notifications"],"summary":"Mark All As Read","description":"Mark all notifications as read for the current user.\n\nReturns the number of notifications that were marked as read.","operationId":"mark_all_as_read_api_v1_notifications_mark_all_read_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Mark All As Read Api V1 Notifications Mark All Read Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/notifications/preferences":{"get":{"tags":["Notifications"],"summary":"Get Preferences","description":"Get notification preferences for the current user.\n\nReturns current settings for notification delivery channels.","operationId":"get_preferences_api_v1_notifications_preferences_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationPreferenceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Notifications"],"summary":"Update Preferences","description":"Update notification preferences for the current user.\n\nOnly provided fields will be updated. Omitted fields remain unchanged.","operationId":"update_preferences_api_v1_notifications_preferences_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationPreferenceUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationPreferenceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/repositories":{"post":{"tags":["module-repositories"],"summary":"Add module repository to project","description":"Connect an external Git repository containing Odoo modules to the project.","operationId":"create_repository_api_v1_projects__project_id__repositories_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModuleRepositoryCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModuleRepositoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["module-repositories"],"summary":"List project module repositories","description":"List all module repositories connected to the project.","operationId":"list_repositories_api_v1_projects__project_id__repositories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/ModuleRepositoryStatus"},{"type":"null"}],"description":"Filter by status","title":"Status"},"description":"Filter by status"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModuleRepositoryListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/repositories/{repository_id}":{"get":{"tags":["module-repositories"],"summary":"Get module repository","description":"Get details of a specific module repository.","operationId":"get_repository_api_v1_projects__project_id__repositories__repository_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"repository_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repository Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModuleRepositoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["module-repositories"],"summary":"Update module repository","description":"Update settings for a module repository.","operationId":"update_repository_api_v1_projects__project_id__repositories__repository_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"repository_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repository Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModuleRepositoryUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModuleRepositoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["module-repositories"],"summary":"Remove module repository","description":"Remove a module repository from the project.","operationId":"delete_repository_api_v1_projects__project_id__repositories__repository_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"repository_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repository Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/modules":{"get":{"tags":["module-repositories"],"summary":"List module deployments for environment","description":"List deployment status of all project repositories for this environment.","operationId":"list_environment_modules_api_v1_environments__environment_id__modules_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ModuleDeploymentListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/modules/deploy":{"post":{"tags":["module-repositories"],"summary":"Deploy repository to environment","description":"Deploy modules from a repository to this environment.","operationId":"deploy_to_environment_api_v1_environments__environment_id__modules_deploy_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeployRepositoryRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeployRepositoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/modules/deploy-all":{"post":{"tags":["module-repositories"],"summary":"Deploy all repositories to environment","description":"Deploy modules from all active project repositories to this environment.","operationId":"deploy_all_to_environment_api_v1_environments__environment_id__modules_deploy_all_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeployAllRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeployRepositoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/modules/{repository_id}/sync":{"post":{"tags":["module-repositories"],"summary":"Sync repository for environment","description":"Pull latest changes from the repository for this environment.","operationId":"sync_repository_api_v1_environments__environment_id__modules__repository_id__sync_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"repository_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repository Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SyncRepositoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-versions":{"get":{"tags":["Odoo Versions"],"summary":"List Odoo Versions","description":"List available Odoo versions for project creation.\n\nReturns only active and beta versions by default.\nDeprecated versions can be optionally included.\nEOL versions are never shown.","operationId":"list_odoo_versions_api_v1_odoo_versions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_deprecated","in":"query","required":false,"schema":{"type":"boolean","description":"Include deprecated versions","default":false,"title":"Include Deprecated"},"description":"Include deprecated versions"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooVersionUserListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-versions/default":{"get":{"tags":["Odoo Versions"],"summary":"Get Default Odoo Version","description":"Get the default Odoo version for new projects.\n\nThis is the version that will be pre-selected when creating a new project.","operationId":"get_default_odoo_version_api_v1_odoo_versions_default_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooVersionUserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-versions/{version_id}":{"get":{"tags":["Odoo Versions"],"summary":"Get Odoo Version","description":"Get details for a specific Odoo version.\n\nReturns 404 if version is EOL or not found.","operationId":"get_odoo_version_api_v1_odoo_versions__version_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooVersionUserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/parameters/{version}":{"get":{"tags":["odoo-config"],"summary":"Get Odoo Parameters","description":"Get Odoo configuration parameters available for a specific version.\n\nBy default, returns only user-configurable parameters. Platform-locked parameters\n(database connection, network ports, paths, etc.) are excluded unless\n`include_locked=True` is specified.\n\nReturns parameters grouped by category with full metadata including:\n- Type, default value, min/max constraints\n- Deprecation status and replacement parameter\n- Pro feature flags\n- user_configurable: Whether users can modify this parameter","operationId":"get_odoo_parameters_api_v1_odoo_config_parameters__version__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version","in":"path","required":true,"schema":{"type":"string","title":"Version"}},{"name":"include_deprecated","in":"query","required":false,"schema":{"type":"boolean","description":"Include deprecated parameters","default":false,"title":"Include Deprecated"},"description":"Include deprecated parameters"},{"name":"include_locked","in":"query","required":false,"schema":{"type":"boolean","description":"Include platform-locked parameters (for admin/debugging only)","default":false,"title":"Include Locked"},"description":"Include platform-locked parameters (for admin/debugging only)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/recommend":{"get":{"tags":["odoo-config"],"summary":"Get Recommended Config","description":"Get recommended Odoo configuration based on version, environment type, and resources.\n\nCalculates optimal values for:\n- Worker count based on CPU cores\n- Memory limits based on RAM\n- Logging levels based on environment\n- Version-specific features (WebSocket for Odoo 18+)\n\nReturns a complete configuration preset with explanations.","operationId":"get_recommended_config_api_v1_odoo_config_recommend_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version","in":"query","required":true,"schema":{"type":"string","description":"Odoo version (e.g., '18.0')","title":"Version"},"description":"Odoo version (e.g., '18.0')"},{"name":"env_type","in":"query","required":true,"schema":{"enum":["development","staging","production"],"type":"string","description":"Environment type","title":"Env Type"},"description":"Environment type"},{"name":"cpu_cores","in":"query","required":true,"schema":{"type":"number","maximum":32.0,"minimum":0.5,"description":"CPU cores allocated","title":"Cpu Cores"},"description":"CPU cores allocated"},{"name":"ram_mb","in":"query","required":true,"schema":{"type":"integer","maximum":65536,"minimum":512,"description":"RAM in megabytes","title":"Ram Mb"},"description":"RAM in megabytes"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/validate":{"post":{"tags":["odoo-config"],"summary":"Validate Config","description":"Validate an Odoo configuration against version constraints.\n\nChecks for:\n- Parameters not available in the version\n- Deprecated parameters with suggested replacements\n- Value constraints (min/max violations)\n- Platform-locked parameters (adds warnings, strips from validation)\n\nReturns validation result with errors and warnings.","operationId":"validate_config_api_v1_odoo_config_validate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version","in":"query","required":true,"schema":{"type":"string","description":"Odoo version to validate against","title":"Version"},"description":"Odoo version to validate against"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Config"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/locked-parameters":{"get":{"tags":["odoo-config"],"summary":"Get Locked Parameters","description":"Get list of parameters that are locked by the platform.\n\nThese parameters are managed by the platform for Docker/Traefik integration\nand security. Users cannot override these values - they are automatically\nconfigured during deployment based on environment settings.\n\nReturns:\n    - locked_parameters: List of parameter names that are locked\n    - reason: Explanation of why these parameters are locked\n    - categories: Parameters grouped by functional category","operationId":"get_locked_parameters_api_v1_odoo_config_locked_parameters_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/presets":{"get":{"tags":["odoo-config"],"summary":"Get Preset List","description":"Get list of available configuration presets.\n\nReturns preset names with descriptions for UI display.","operationId":"get_preset_list_api_v1_odoo_config_presets_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/categories":{"get":{"tags":["odoo-config"],"summary":"Get Parameter Categories","description":"Get list of parameter categories with display metadata.\n\nReturns category info for building the UI.","operationId":"get_parameter_categories_api_v1_odoo_config_categories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/generate":{"post":{"tags":["odoo-config"],"summary":"Generate Conf File","description":"Generate a complete odoo.conf file for a specific version.\n\nHandles:\n- Version-specific parameter filtering\n- Deprecated parameter migration\n- Environment-based defaults\n- User customizations\n\nReturns the conf file content and metadata.","operationId":"generate_conf_file_api_v1_odoo_config_generate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateConfRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateConfResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/versions":{"get":{"tags":["odoo-config"],"summary":"Get Supported Versions","description":"Get information about supported Odoo versions and their features.\n\nReturns:\n- List of supported versions\n- Feature availability per version (replica support, websocket, etc.)","operationId":"get_supported_versions_api_v1_odoo_config_versions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odoo-config/available-parameters/{version}":{"get":{"tags":["odoo-config"],"summary":"Get Version Available Parameters","description":"Get all parameters available for a specific Odoo version.\n\nReturns parameters grouped by category with full metadata.\nExcludes deprecated and removed parameters.","operationId":"get_version_available_parameters_api_v1_odoo_config_available_parameters__version__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version","in":"path","required":true,"schema":{"type":"string","title":"Version"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/settings":{"get":{"tags":["Platform Administration"],"summary":"Get All Platform Settings","description":"Get all platform settings.\n\nRequires PORTAL_ADMIN role.","operationId":"get_all_platform_settings_api_v1_admin_settings_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllPlatformSettingsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/settings/dns":{"get":{"tags":["Platform Administration"],"summary":"Get Dns Platform Settings","description":"Get DNS platform settings.\n\nRequires PORTAL_ADMIN role.","operationId":"get_dns_platform_settings_api_v1_admin_settings_dns_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSPlatformSettingsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/settings/dns/providers":{"post":{"tags":["Platform Administration"],"summary":"Set Dns Provider Enabled","description":"Enable or disable a DNS provider.\n\nRequires PORTAL_ADMIN role.\n\nNote: The provider must be in the DNS_PROVIDERS_AVAILABLE environment\nvariable to be enabled. This ENV variable is the master switch.","operationId":"set_dns_provider_enabled_api_v1_admin_settings_dns_providers_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetProviderEnabledRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetProviderEnabledResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/settings/dns/limits":{"patch":{"tags":["Platform Administration"],"summary":"Update Dns Limits","description":"Update DNS limits (TTL, max domains, etc.).\n\nRequires PORTAL_ADMIN role.\nThese settings are stored in the database and override ENV defaults.","operationId":"update_dns_limits_api_v1_admin_settings_dns_limits_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateDNSLimitsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DNSPlatformSettingsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/settings/dns/providers/available":{"get":{"tags":["Platform Administration"],"summary":"Get Available Dns Providers","description":"Get DNS providers available on this platform.\n\nThis returns the ENV-configured list of providers.\nTo add more providers, update DNS_PROVIDERS_AVAILABLE env var.","operationId":"get_available_dns_providers_api_v1_admin_settings_dns_providers_available_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"array","items":{"type":"string"}},"title":"Response Get Available Dns Providers Api V1 Admin Settings Dns Providers Available Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/stats":{"get":{"tags":["Platform Administration"],"summary":"Get Platform Stats","description":"Get platform-wide statistics.\n\nRequires PORTAL_ADMIN role.","operationId":"get_platform_stats_api_v1_admin_stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformStatsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/stats/enhanced":{"get":{"tags":["Platform Administration"],"summary":"Get Enhanced Platform Stats","description":"Get enhanced platform-wide statistics for admin dashboard.\n\nResults are cached in Redis for 60 seconds to avoid hitting the DB\nwith 30+ queries on every dashboard refresh.\n\nRequires PORTAL_ADMIN role.","operationId":"get_enhanced_platform_stats_api_v1_admin_stats_enhanced_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnhancedPlatformStatsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/users":{"get":{"tags":["Platform Administration"],"summary":"List Users","description":"List all platform users with pagination.\n\nRequires PORTAL_ADMIN role.","operationId":"list_users_api_v1_admin_users_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":20,"title":"Per Page"},"description":"Items per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search by email or name","title":"Search"},"description":"Search by email or name"},{"name":"role","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by portal role","title":"Role"},"description":"Filter by portal role"},{"name":"is_active","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Filter by active status","title":"Is Active"},"description":"Filter by active status"},{"name":"sort_by","in":"query","required":false,"schema":{"type":"string","description":"Sort by: email, name, portal_role, created_at, last_login_at, is_active","default":"created_at","title":"Sort By"},"description":"Sort by: email, name, portal_role, created_at, last_login_at, is_active"},{"name":"sort_order","in":"query","required":false,"schema":{"type":"string","description":"Sort order: asc or desc","default":"desc","title":"Sort Order"},"description":"Sort order: asc or desc"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/users/{user_id}":{"get":{"tags":["Platform Administration"],"summary":"Get User Detail","description":"Get detailed user information.\n\nRequires PORTAL_ADMIN role.","operationId":"get_user_detail_api_v1_admin_users__user_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/users/{user_id}/role":{"patch":{"tags":["Platform Administration"],"summary":"Update User Role","description":"Update a user's portal role.\n\nRequires PORTAL_ADMIN role.\nCannot demote yourself from admin.","operationId":"update_user_role_api_v1_admin_users__user_id__role_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateUserRoleRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/users/{user_id}/login-email-change":{"post":{"tags":["Platform Administration"],"summary":"Start Login Email Change","description":"Start a support-run login email change (#1175).\n\nEmails a single-use link to the new address; the user confirms it while\nsigned in. Nothing changes until then. Requires PORTAL_ADMIN role.","operationId":"start_login_email_change_api_v1_admin_users__user_id__login_email_change_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartLoginEmailChangeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StartLoginEmailChangeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/users/{user_id}/status":{"patch":{"tags":["Platform Administration"],"summary":"Update User Status","description":"Activate or deactivate a user account.\n\nRequires PORTAL_ADMIN role.\nCannot deactivate yourself.","operationId":"update_user_status_api_v1_admin_users__user_id__status_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateUserStatusRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/organizations":{"get":{"tags":["Platform Administration"],"summary":"List Organizations","description":"List all organizations with pagination.\n\nRequires PORTAL_ADMIN role.","operationId":"list_organizations_api_v1_admin_organizations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":20,"title":"Per Page"},"description":"Items per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search by name or slug","title":"Search"},"description":"Search by name or slug"},{"name":"is_active","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Filter by active status","title":"Is Active"},"description":"Filter by active status"},{"name":"plan","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by plan (comma-separated): free,starter,pro,agency","title":"Plan"},"description":"Filter by plan (comma-separated): free,starter,pro,agency"},{"name":"sort_by","in":"query","required":false,"schema":{"type":"string","description":"Sort by: name, slug, created_at, is_active","default":"created_at","title":"Sort By"},"description":"Sort by: name, slug, created_at, is_active"},{"name":"sort_order","in":"query","required":false,"schema":{"type":"string","description":"Sort order: asc or desc","default":"desc","title":"Sort Order"},"description":"Sort order: asc or desc"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/organizations/{org_id}":{"get":{"tags":["Platform Administration"],"summary":"Get Organization Detail","description":"Get detailed organization information.\n\nRequires PORTAL_ADMIN role.","operationId":"get_organization_detail_api_v1_admin_organizations__org_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/organizations/{org_id}/status":{"patch":{"tags":["Platform Administration"],"summary":"Update Organization Status","description":"Activate or deactivate an organization.\n\nRequires PORTAL_ADMIN role.","operationId":"update_organization_status_api_v1_admin_organizations__org_id__status_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateOrganizationStatusRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/organizations/{org_id}/plan":{"patch":{"tags":["Platform Administration"],"summary":"Update Organization Plan","description":"Admin override: change an organization's plan.\n\nUpdates subscription base_plan and syncs quota limits.\nRequires PORTAL_ADMIN role.","operationId":"update_organization_plan_api_v1_admin_organizations__org_id__plan_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateOrganizationPlanRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/projects":{"get":{"tags":["Platform Administration"],"summary":"List All Projects","description":"List all projects across all organizations with pagination.\n\nRequires PORTAL_ADMIN role. Optimized single-query endpoint.","operationId":"list_all_projects_api_v1_admin_projects_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":50,"title":"Per Page"},"description":"Items per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search by project name or org name","title":"Search"},"description":"Search by project name or org name"},{"name":"sort_by","in":"query","required":false,"schema":{"type":"string","description":"Sort by: name, organization_name, created_at","default":"created_at","title":"Sort By"},"description":"Sort by: name, organization_name, created_at"},{"name":"sort_order","in":"query","required":false,"schema":{"type":"string","description":"Sort order: asc or desc","default":"desc","title":"Sort Order"},"description":"Sort order: asc or desc"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminProjectListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/odoo-versions":{"get":{"tags":["Platform Administration"],"summary":"List Odoo Versions","description":"List all Odoo versions (admin view with full details).\n\nRequires PORTAL_ADMIN role.","operationId":"list_odoo_versions_api_v1_admin_odoo_versions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by status","title":"Status"},"description":"Filter by status"},{"name":"include_eol","in":"query","required":false,"schema":{"type":"boolean","description":"Include end-of-life versions","default":false,"title":"Include Eol"},"description":"Include end-of-life versions"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response List Odoo Versions Api V1 Admin Odoo Versions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Administration"],"summary":"Create Odoo Version","description":"Create a new Odoo version.\n\nRequires PORTAL_ADMIN role.","operationId":"create_odoo_version_api_v1_admin_odoo_versions_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Create Odoo Version Api V1 Admin Odoo Versions Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/odoo-versions/{version_id}":{"get":{"tags":["Platform Administration"],"summary":"Get Odoo Version","description":"Get detailed Odoo version information.\n\nRequires PORTAL_ADMIN role.","operationId":"get_odoo_version_api_v1_admin_odoo_versions__version_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Odoo Version Api V1 Admin Odoo Versions  Version Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Platform Administration"],"summary":"Update Odoo Version","description":"Update an Odoo version.\n\nRequires PORTAL_ADMIN role.","operationId":"update_odoo_version_api_v1_admin_odoo_versions__version_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooVersionUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Update Odoo Version Api V1 Admin Odoo Versions  Version Id  Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Platform Administration"],"summary":"Delete Odoo Version","description":"Soft delete an Odoo version (mark as EOL).\n\nRequires PORTAL_ADMIN role.\nDoes not actually delete - marks as end-of-life instead.","operationId":"delete_odoo_version_api_v1_admin_odoo_versions__version_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Delete Odoo Version Api V1 Admin Odoo Versions  Version Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/odoo-versions/{version_id}/set-default":{"post":{"tags":["Platform Administration"],"summary":"Set Default Odoo Version","description":"Set an Odoo version as the default for new projects.\n\nRequires PORTAL_ADMIN role.\nOnly active/beta versions can be set as default.","operationId":"set_default_odoo_version_api_v1_admin_odoo_versions__version_id__set_default_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Set Default Odoo Version Api V1 Admin Odoo Versions  Version Id  Set Default Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/odoo-versions/{version_id}/deprecate":{"post":{"tags":["Platform Administration"],"summary":"Deprecate Odoo Version","description":"Mark an Odoo version as deprecated.\n\nRequires PORTAL_ADMIN role.\nDeprecated versions are hidden from new project creation but existing projects can still use them.","operationId":"deprecate_odoo_version_api_v1_admin_odoo_versions__version_id__deprecate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"reason","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Reason for deprecation","title":"Reason"},"description":"Reason for deprecation"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Deprecate Odoo Version Api V1 Admin Odoo Versions  Version Id  Deprecate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/odoo-versions/{version_id}/test-pull":{"post":{"tags":["Platform Administration"],"summary":"Test Odoo Version Pull","description":"Test pulling the Docker image for an Odoo version.\n\nRequires PORTAL_ADMIN role.\nThis tests that the configured image can be pulled from the registry.","operationId":"test_odoo_version_pull_api_v1_admin_odoo_versions__version_id__test_pull_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Test Odoo Version Pull Api V1 Admin Odoo Versions  Version Id  Test Pull Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/storage-configs":{"get":{"tags":["Platform Administration"],"summary":"List Platform Storage Configs","description":"List platform-level storage configurations (available to all orgs).","operationId":"list_platform_storage_configs_api_v1_admin_storage_configs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StorageConfigResponse"},"title":"Response List Platform Storage Configs Api V1 Admin Storage Configs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Administration"],"summary":"Create Platform Storage Config","description":"Create a platform-level storage configuration.","operationId":"create_platform_storage_config_api_v1_admin_storage_configs_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/storage-configs/{config_id}":{"get":{"tags":["Platform Administration"],"summary":"Get Platform Storage Config","description":"Get a platform storage configuration by ID.","operationId":"get_platform_storage_config_api_v1_admin_storage_configs__config_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Platform Administration"],"summary":"Update Platform Storage Config","description":"Update a platform storage configuration.","operationId":"update_platform_storage_config_api_v1_admin_storage_configs__config_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Platform Administration"],"summary":"Delete Platform Storage Config","description":"Delete a platform storage configuration.","operationId":"delete_platform_storage_config_api_v1_admin_storage_configs__config_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/storage-configs/{config_id}/test":{"post":{"tags":["Platform Administration"],"summary":"Test Platform Storage Config","description":"Test a platform storage configuration connection.","operationId":"test_platform_storage_config_api_v1_admin_storage_configs__config_id__test_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/storage-configs/test-connection":{"post":{"tags":["Platform Administration"],"summary":"Test Storage Connection Raw","description":"Test storage connection with raw credentials (before saving).\n\nAllows testing S3, SFTP, FTP connections before creating the config.","operationId":"test_storage_connection_raw_api_v1_admin_storage_configs_test_connection_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/storage-configs/{config_id}/set-default":{"post":{"tags":["Platform Administration"],"summary":"Set Platform Storage Default","description":"Set a platform storage configuration as default.","operationId":"set_platform_storage_default_api_v1_admin_storage_configs__config_id__set_default_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/compliance/overview":{"get":{"tags":["Platform Administration"],"summary":"Get compliance overview","description":"Get ForceCommand security compliance overview across all VMs (Portal Admin only)","operationId":"get_compliance_overview_api_v1_admin_compliance_overview_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ComplianceOverview"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/compliance/check/{vm_id}":{"post":{"tags":["Platform Administration"],"summary":"Run compliance check on VM","description":"Trigger on-demand ForceCommand compliance check on a specific VM (Portal Admin only)","operationId":"check_vm_compliance_api_v1_admin_compliance_check__vm_id__post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Check Vm Compliance Api V1 Admin Compliance Check  Vm Id  Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/compliance/vm/{vm_id}":{"get":{"tags":["Platform Administration"],"summary":"Get VM compliance status","description":"Get ForceCommand compliance status for a specific VM (Portal Admin only)","operationId":"get_vm_compliance_status_api_v1_admin_compliance_vm__vm_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMComplianceStatus"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/compliance/check-all":{"post":{"tags":["Platform Administration"],"summary":"Run compliance check on all VMs","description":"Trigger compliance check on all active VMs (Portal Admin only)","operationId":"check_all_vms_compliance_api_v1_admin_compliance_check_all_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Check All Vms Compliance Api V1 Admin Compliance Check All Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/servers":{"get":{"tags":["Platform Administration"],"summary":"List All Servers","description":"List all servers across the platform with pagination.\n\nShows both shared (portal-managed) and BYOS (org-owned) servers.\nRequires PORTAL_ADMIN role.","operationId":"list_all_servers_api_v1_admin_servers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":50,"title":"Per Page"},"description":"Items per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search by name, IP, or org name","title":"Search"},"description":"Search by name, IP, or org name"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by status","title":"Status"},"description":"Filter by status"},{"name":"provider","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by provider","title":"Provider"},"description":"Filter by provider"},{"name":"server_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter: shared, byos, or all","title":"Server Type"},"description":"Filter: shared, byos, or all"},{"name":"sort_by","in":"query","required":false,"schema":{"type":"string","description":"Sort by: name, provider, status, created_at","default":"created_at","title":"Sort By"},"description":"Sort by: name, provider, status, created_at"},{"name":"sort_order","in":"query","required":false,"schema":{"type":"string","description":"Sort order: asc or desc","default":"desc","title":"Sort Order"},"description":"Sort order: asc or desc"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminServerListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons":{"get":{"tags":["Platform Administration","Cron Jobs"],"summary":"List Cron Jobs","description":"List all registered cron jobs.\n\nReturns all cron jobs with their current status, last execution time,\nand next scheduled run.\n\nRequires portal admin permission.","operationId":"list_cron_jobs_api_v1_admin_crons_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CronJobListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons/summary":{"get":{"tags":["Platform Administration","Cron Jobs"],"summary":"Get Cron Summary","description":"Get summary statistics for all cron jobs.\n\nReturns counts of active/disabled/error jobs and execution stats.\n\nRequires portal admin permission.","operationId":"get_cron_summary_api_v1_admin_crons_summary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CronJobsSummary"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons/{job_id}":{"get":{"tags":["Platform Administration","Cron Jobs"],"summary":"Get Cron Job","description":"Get a specific cron job by ID.\n\nRequires portal admin permission.","operationId":"get_cron_job_api_v1_admin_crons__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CronJobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons/{job_id}/toggle":{"patch":{"tags":["Platform Administration","Cron Jobs"],"summary":"Toggle Cron Job","description":"Enable or disable a cron job.\n\nWhen disabled, the job will not execute at its scheduled times.\nThe job can be re-enabled at any time.\n\nRequires portal admin permission.","operationId":"toggle_cron_job_api_v1_admin_crons__job_id__toggle_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CronJobToggleRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CronJobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons/{job_id}/executions":{"get":{"tags":["Platform Administration","Cron Jobs"],"summary":"Get Cron Job Executions","description":"Get execution history for a specific cron job.\n\nReturns the most recent executions with details about success/failure\nand execution duration.\n\nRequires portal admin permission.","operationId":"get_cron_job_executions_api_v1_admin_crons__job_id__executions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CronJobExecutionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons/executions/all":{"get":{"tags":["Platform Administration","Cron Jobs"],"summary":"Get All Executions","description":"Get execution history for all cron jobs.\n\nReturns the most recent executions across all jobs.\n\nRequires portal admin permission.","operationId":"get_all_executions_api_v1_admin_crons_executions_all_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CronJobExecutionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons/sync":{"post":{"tags":["Platform Administration","Cron Jobs"],"summary":"Sync Cron Jobs","description":"Sync cron job definitions from code to database.\n\nThis ensures all defined cron jobs are registered in the database.\nUsually called automatically on worker startup.\n\nRequires portal admin permission.","operationId":"sync_cron_jobs_api_v1_admin_crons_sync_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Sync Cron Jobs Api V1 Admin Crons Sync Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons/{job_id}/trigger":{"post":{"tags":["Platform Administration","Cron Jobs"],"summary":"Trigger Cron Job","description":"Manually trigger a cron job to run immediately.\n\nThe job will be executed asynchronously by a worker.\nThis bypasses the normal schedule.\n\nRequires portal admin permission.","operationId":"trigger_cron_job_api_v1_admin_crons__job_id__trigger_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CronJobTriggerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/crons/executions/cleanup":{"delete":{"tags":["Platform Administration","Cron Jobs"],"summary":"Cleanup Old Executions","description":"Delete old execution records.\n\nCleans up execution history older than the specified number of days.\n\nRequires portal admin permission.","operationId":"cleanup_old_executions_api_v1_admin_crons_executions_cleanup_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":365,"minimum":1,"default":30,"title":"Days"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Cleanup Old Executions Api V1 Admin Crons Executions Cleanup Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/email-blocklist":{"get":{"tags":["Platform Administration"],"summary":"List Blocked Domains","description":"List all blocked email domains. Requires PORTAL_ADMIN role.","operationId":"list_blocked_domains_api_v1_admin_email_blocklist_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Per Page"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockedDomainListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Administration"],"summary":"Add Blocked Domain","description":"Add a domain to the email blocklist. Requires PORTAL_ADMIN role.","operationId":"add_blocked_domain_api_v1_admin_email_blocklist_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddBlockedDomainRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BlockedDomainResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/email-blocklist/{domain_id}":{"delete":{"tags":["Platform Administration"],"summary":"Remove Blocked Domain","description":"Remove a domain from the email blocklist. Requires PORTAL_ADMIN role.","operationId":"remove_blocked_domain_api_v1_admin_email_blocklist__domain_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"domain_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Domain Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Remove Blocked Domain Api V1 Admin Email Blocklist  Domain Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/announcements":{"get":{"tags":["Platform Administration"],"summary":"List Announcements","description":"List all announcements. Requires PORTAL_ADMIN.","operationId":"list_announcements_api_v1_admin_announcements_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Per Page"}},{"name":"active_only","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Active Only"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnouncementListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Administration"],"summary":"Create Announcement","description":"Create a new announcement. Requires PORTAL_ADMIN.","operationId":"create_announcement_api_v1_admin_announcements_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAnnouncementRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnouncementResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/announcements/{announcement_id}":{"get":{"tags":["Platform Administration"],"summary":"Get Announcement","description":"Get a single announcement. Requires PORTAL_ADMIN.","operationId":"get_announcement_api_v1_admin_announcements__announcement_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"announcement_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Announcement Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnouncementResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Platform Administration"],"summary":"Update Announcement","description":"Update an announcement. Requires PORTAL_ADMIN.","operationId":"update_announcement_api_v1_admin_announcements__announcement_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"announcement_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Announcement Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateAnnouncementRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnouncementResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Platform Administration"],"summary":"Delete Announcement","description":"Delete an announcement. Requires PORTAL_ADMIN.","operationId":"delete_announcement_api_v1_admin_announcements__announcement_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"announcement_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Announcement Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Delete Announcement Api V1 Admin Announcements  Announcement Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/environments":{"get":{"tags":["Platform Administration"],"summary":"List All Environments","description":"List all environments across the platform with pagination.\n\nShows environments from all organizations with project and server details.\nRequires PORTAL_ADMIN role.","operationId":"list_all_environments_api_v1_admin_environments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":50,"title":"Per Page"},"description":"Items per page"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search by env name, project name, or org name","title":"Search"},"description":"Search by env name, project name, or org name"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by status","title":"Status"},"description":"Filter by status"},{"name":"environment_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by environment type","title":"Environment Type"},"description":"Filter by environment type"},{"name":"sort_by","in":"query","required":false,"schema":{"type":"string","description":"Sort by: name, status, environment_type, project_name, organization_name, created_at","default":"created_at","title":"Sort By"},"description":"Sort by: name, status, environment_type, project_name, organization_name, created_at"},{"name":"sort_order","in":"query","required":false,"schema":{"type":"string","description":"Sort order: asc or desc","default":"desc","title":"Sort Order"},"description":"Sort order: asc or desc"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminEnvironmentListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/templates":{"get":{"tags":["Platform Administration"],"summary":"List Admin Templates","description":"List all templates (including inactive) for admin management.","operationId":"list_admin_templates_api_v1_admin_templates_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},{"name":"odoo_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version"}},{"name":"is_active","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DeploymentTemplateListResponse"},"title":"Response List Admin Templates Api V1 Admin Templates Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Administration"],"summary":"Create Template","description":"Create a new deployment template.","operationId":"create_template_api_v1_admin_templates_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/templates/{template_id}":{"get":{"tags":["Platform Administration"],"summary":"Get Admin Template","description":"Get template detail for admin editing.","operationId":"get_admin_template_api_v1_admin_templates__template_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Platform Administration"],"summary":"Update Template","description":"Update a deployment template.","operationId":"update_template_api_v1_admin_templates__template_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Platform Administration"],"summary":"Delete Template","description":"Soft-delete a template (set is_active=False).","operationId":"delete_template_api_v1_admin_templates__template_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/templates/{template_id}/repos":{"post":{"tags":["Platform Administration"],"summary":"Add Template Repo","description":"Add an addon repo to a template.","operationId":"add_template_repo_api_v1_admin_templates__template_id__repos_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateRepoCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/templates/{template_id}/repos/{repo_id}":{"delete":{"tags":["Platform Administration"],"summary":"Remove Template Repo","description":"Remove an addon repo from a template.","operationId":"remove_template_repo_api_v1_admin_templates__template_id__repos__repo_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/templates/{template_id}/duplicate":{"post":{"tags":["Platform Administration"],"summary":"Duplicate Template","description":"Duplicate a template with all its repos.","operationId":"duplicate_template_api_v1_admin_templates__template_id__duplicate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"template_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Template Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/queues/overview":{"get":{"tags":["Platform Administration","Queue Monitor"],"summary":"Get Queue Overview","description":"Get queue depths, running task counts, DLQ stats, and 24h metrics.","operationId":"get_queue_overview_api_v1_admin_queues_overview_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Queue Overview Api V1 Admin Queues Overview Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/queues/tasks":{"get":{"tags":["Platform Administration","Queue Monitor"],"summary":"List All Tasks","description":"List ALL tasks cross-org with pagination and filters.","operationId":"list_all_tasks_api_v1_admin_queues_tasks_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TaskStatus"},{"type":"null"}],"title":"Status"}},{"name":"task_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TaskType"},{"type":"null"}],"title":"Task Type"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response List All Tasks Api V1 Admin Queues Tasks Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/queues/tasks/{task_id}/retry":{"post":{"tags":["Platform Administration","Queue Monitor"],"summary":"Retry Task","description":"Re-enqueue a failed or cancelled task as a new task.","operationId":"retry_task_api_v1_admin_queues_tasks__task_id__retry_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Task Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Retry Task Api V1 Admin Queues Tasks  Task Id  Retry Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/queues/tasks/{task_id}/cancel":{"post":{"tags":["Platform Administration","Queue Monitor"],"summary":"Admin Cancel Task","description":"Cancel a pending, queued, or running task (admin-only, no org check).","operationId":"admin_cancel_task_api_v1_admin_queues_tasks__task_id__cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Task Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Admin Cancel Task Api V1 Admin Queues Tasks  Task Id  Cancel Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/analytics/deployments":{"get":{"tags":["Platform Administration"],"summary":"Get Deployment Analytics","description":"Get deployment analytics for the admin dashboard.\n\nReturns KPIs, trigger breakdown, daily trend, top organizations,\nand task type breakdown for the specified period.\n\nCached in Redis for 5 minutes per period value.\nRequires PORTAL_ADMIN role.","operationId":"get_deployment_analytics_api_v1_admin_analytics_deployments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"period","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":7,"description":"Period in days","default":30,"title":"Period"},"description":"Period in days"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentAnalyticsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/lifecycle/stats":{"get":{"tags":["Platform Administration"],"summary":"Get Lifecycle Stats","description":"Get email lifecycle and checkout recovery KPI stats for admin dashboard.","operationId":"get_lifecycle_stats_api_v1_admin_lifecycle_stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LifecycleStatsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/retention/dashboard":{"get":{"tags":["Platform Administration"],"summary":"Get Retention Dashboard","description":"Get churn/retention analytics for the admin dashboard.","operationId":"get_retention_dashboard_api_v1_admin_retention_dashboard_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetentionDashboardResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/tickets":{"get":{"tags":["Platform Administration"],"summary":"List All Tickets","description":"List ALL support tickets across all organizations.\n\nRequires portal admin permission. Supports filtering by status, priority,\ncategory, assigned admin, and free-text search.","operationId":"list_all_tickets_api_v1_admin_support_tickets_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Pagination offset","default":0,"title":"Skip"},"description":"Pagination offset"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Pagination page size","default":20,"title":"Limit"},"description":"Pagination page size"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by ticket status","title":"Status"},"description":"Filter by ticket status"},{"name":"priority","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by priority","title":"Priority"},"description":"Filter by priority"},{"name":"category_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by category ID","title":"Category Id"},"description":"Filter by category ID"},{"name":"assigned_to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by assigned admin","title":"Assigned To"},"description":"Filter by assigned admin"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search subject and description","title":"Search"},"description":"Search subject and description"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminTicketListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/tickets/{ticket_id}":{"get":{"tags":["Platform Administration"],"summary":"Get Ticket Detail","description":"Get full ticket detail for admin view.\n\nIncludes internal notes, SLA information, watchers, assignment history,\nand all comments (public + internal).","operationId":"get_ticket_detail_api_v1_admin_support_tickets__ticket_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketResponseAdmin"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Platform Administration"],"summary":"Update Ticket","description":"Update a ticket's status, priority, assignment, or tags.\n\nRecords audit history for all field changes.","operationId":"update_ticket_api_v1_admin_support_tickets__ticket_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminTicketUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketResponseAdmin"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/tickets/{ticket_id}/comments":{"post":{"tags":["Platform Administration"],"summary":"Add Admin Comment","description":"Add a comment to a ticket (public or internal note).\n\nAdmin can create both public comments (visible to customer) and\ninternal notes (visible only to portal admins).","operationId":"add_admin_comment_api_v1_admin_support_tickets__ticket_id__comments_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketCommentCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketCommentResponseFull"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/tickets/{ticket_id}/merge":{"post":{"tags":["Platform Administration"],"summary":"Merge Tickets","description":"Merge a source ticket into this (target) ticket.\n\nMoves all comments and attachments from the source to the target,\ncloses the source ticket, and records history on both tickets.","operationId":"merge_tickets_api_v1_admin_support_tickets__ticket_id__merge_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketMergeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketResponseAdmin"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/tickets/bulk-update":{"post":{"tags":["Platform Administration"],"summary":"Bulk Update Tickets","description":"Bulk update multiple tickets (status and/or assignment).\n\nApplies the same status and/or assignment change to all specified tickets.\nSkips tickets that are not found.","operationId":"bulk_update_tickets_api_v1_admin_support_tickets_bulk_update_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkTicketUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Bulk Update Tickets Api V1 Admin Support Tickets Bulk Update Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/tickets/{ticket_id}/attachments":{"post":{"tags":["Platform Administration"],"summary":"Admin Upload Attachment","description":"Upload a file attachment to a ticket (admin).\n\nNo org restriction — admins can upload to any ticket.\nMax 10MB per file. Allowed types: images, PDF, text, CSV, ZIP, GZIP.","operationId":"admin_upload_attachment_api_v1_admin_support_tickets__ticket_id__attachments_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"comment_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Optional: link to specific comment","title":"Comment Id"},"description":"Optional: link to specific comment"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_admin_upload_attachment_api_v1_admin_support_tickets__ticket_id__attachments_post"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttachmentUploadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/tickets/{ticket_id}/attachments/{attachment_id}/download":{"get":{"tags":["Platform Administration"],"summary":"Admin Download Attachment","description":"Download a ticket attachment (admin). No org restriction.","operationId":"admin_download_attachment_api_v1_admin_support_tickets__ticket_id__attachments__attachment_id__download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"attachment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Attachment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/canned-responses":{"get":{"tags":["Platform Administration"],"summary":"List Canned Responses","description":"List all canned response templates.","operationId":"list_canned_responses_api_v1_admin_support_canned_responses_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"category_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by category","title":"Category Id"},"description":"Filter by category"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CannedResponseResponse"},"title":"Response List Canned Responses Api V1 Admin Support Canned Responses Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Administration"],"summary":"Create Canned Response","description":"Create a new canned response template.","operationId":"create_canned_response_api_v1_admin_support_canned_responses_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CannedResponseCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CannedResponseResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/canned-responses/{response_id}":{"patch":{"tags":["Platform Administration"],"summary":"Update Canned Response","description":"Update an existing canned response template.","operationId":"update_canned_response_api_v1_admin_support_canned_responses__response_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"response_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Response Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CannedResponseUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CannedResponseResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Platform Administration"],"summary":"Delete Canned Response","description":"Delete a canned response template.","operationId":"delete_canned_response_api_v1_admin_support_canned_responses__response_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"response_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Response Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/canned-responses/{response_id}/preview":{"post":{"tags":["Platform Administration"],"summary":"Preview Canned Response","description":"Preview a canned response with variable substitution.\n\nSupported variables: {ticket_number}, {user_name},\n{organization_name}, {sla_hours}.","operationId":"preview_canned_response_api_v1_admin_support_canned_responses__response_id__preview_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"response_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Response Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CannedResponsePreviewRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Preview Canned Response Api V1 Admin Support Canned Responses  Response Id  Preview Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/categories":{"get":{"tags":["Platform Administration"],"summary":"List All Categories","description":"List all ticket categories including inactive ones.\n\nUnlike the customer endpoint, this returns both active and inactive categories.","operationId":"list_all_categories_api_v1_admin_support_categories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TicketCategoryResponse"},"title":"Response List All Categories Api V1 Admin Support Categories Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Administration"],"summary":"Create Category","description":"Create a new ticket category.","operationId":"create_category_api_v1_admin_support_categories_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketCategoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/categories/{category_id}":{"patch":{"tags":["Platform Administration"],"summary":"Update Category","description":"Update a ticket category.","operationId":"update_category_api_v1_admin_support_categories__category_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"category_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Category Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CategoryUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketCategoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/support/stats":{"get":{"tags":["Platform Administration"],"summary":"Get Support Stats","description":"Get helpdesk dashboard statistics.\n\nReturns aggregate metrics: open ticket count, average response/resolution\ntimes, CSAT average, monthly totals, and SLA breach count.","operationId":"get_support_stats_api_v1_admin_support_stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupportStatsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/impersonation/audit":{"get":{"tags":["Platform Administration","Admin","Connect As"],"summary":"Cross-org Connect As audit (portal admins only)","operationId":"admin_list_audit_api_v1_admin_impersonation_audit_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImpersonationAuditListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/tunnel-vms":{"get":{"tags":["Platform Administration"],"summary":"List Tunnel Vms For Admin","description":"List all VMs using Cloudflare Tunnel across every organization.\n\nReturns per-VM tunnel diagnostics (status, qualification timestamps,\nconsecutive failures, circuit state) joined with organization name.\nNo secrets are exposed — only IDs and status fields.\n\nNo pagination (SP6 note: as of today there is ~1 tunnel VM; revisit\nwhen count exceeds ~100).","operationId":"list_tunnel_vms_for_admin_api_v1_admin_tunnel_vms_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AdminTunnelVmRow"},"title":"Response List Tunnel Vms For Admin Api V1 Admin Tunnel Vms Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/incidents/checks":{"get":{"tags":["Platform Administration","Admin","Incidents"],"summary":"List Registered Checks","description":"Return registered checks joined with their heartbeat state.","operationId":"list_registered_checks_api_v1_admin_incidents_checks_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisteredChecksResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/incidents":{"get":{"tags":["Platform Administration","Admin","Incidents"],"summary":"List Incidents","description":"List incidents. Sort: severity ASC (critical < high < medium < low in enum\nsort order — Spec asks for severity DESC by *importance*, which matches\nascending enum sort order because of the enum order), last_seen DESC.","operationId":"list_incidents_api_v1_admin_incidents_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/PlatformIncidentStatus"},{"type":"null"}],"title":"Status"}},{"name":"severity","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/PlatformIncidentSeverity"},{"type":"null"}],"title":"Severity"}},{"name":"check_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Check Id"}},{"name":"scope_prefix","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope Prefix"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncidentListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/incidents/{incident_id}":{"get":{"tags":["Platform Administration","Admin","Incidents"],"summary":"Get Incident","operationId":"get_incident_api_v1_admin_incidents__incident_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"incident_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Incident Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncidentDetail"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/incidents/{incident_id}/acknowledge":{"post":{"tags":["Platform Administration","Admin","Incidents"],"summary":"Acknowledge Incident","operationId":"acknowledge_incident_api_v1_admin_incidents__incident_id__acknowledge_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"incident_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Incident Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncidentActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/incidents/{incident_id}/resolve":{"post":{"tags":["Platform Administration","Admin","Incidents"],"summary":"Resolve Incident","operationId":"resolve_incident_api_v1_admin_incidents__incident_id__resolve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"incident_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Incident Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncidentActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/incidents/{incident_id}/suppress":{"post":{"tags":["Platform Administration","Admin","Incidents"],"summary":"Suppress Incident","operationId":"suppress_incident_api_v1_admin_incidents__incident_id__suppress_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"incident_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Incident Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IncidentActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/demos/live":{"get":{"tags":["Platform Administration","Demo Admin"],"summary":"List Live Demos","description":"Demos currently running or still deploying. One row per env.","operationId":"list_live_demos_api_v1_admin_demos_live_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response List Live Demos Api V1 Admin Demos Live Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/demos/funnel":{"get":{"tags":["Platform Administration","Demo Admin"],"summary":"Get Funnel","description":"Funnel counts per lifecycle step over the requested range.\n\nDrops are computed off ``demo_started`` as the baseline. A demo that\nerrored at any step still counts toward ``demo_started`` but does NOT\nadvance to subsequent steps.","operationId":"get_funnel_api_v1_admin_demos_funnel_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"range","in":"query","required":false,"schema":{"type":"string","description":"24h, 7d, 30d, 90d","default":"24h","title":"Range"},"description":"24h, 7d, 30d, 90d"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Funnel Api V1 Admin Demos Funnel Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/demos/failures":{"get":{"tags":["Platform Administration","Demo Admin"],"summary":"List Failures","description":"Recent demo failure events with user + org context.","operationId":"list_failures_api_v1_admin_demos_failures_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":90,"minimum":1,"default":7,"title":"Days"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response List Failures Api V1 Admin Demos Failures Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/demos/top-users":{"get":{"tags":["Platform Administration","Demo Admin"],"summary":"Top Users","description":"Emails with the most ``demo_started`` events in the window.\n\nEach row carries a ``converted`` flag — true if the same user has a\n``demo_converted`` event in the window (set by Deliverable C). Until\nC ships, ``converted`` is always false.","operationId":"top_users_api_v1_admin_demos_top_users_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":365,"minimum":1,"default":30,"title":"Days"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Top Users Api V1 Admin Demos Top Users Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/demos/events/{env_id}":{"get":{"tags":["Platform Administration","Demo Admin"],"summary":"List Events For Env","description":"Full event timeline for a single demo env.","operationId":"list_events_for_env_api_v1_admin_demos_events__env_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response List Events For Env Api V1 Admin Demos Events  Env Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/demos/details/{env_id}":{"get":{"tags":["Platform Administration","Demo Admin"],"summary":"Get Demo Details","description":"Everything a portal admin needs to debug or maintain one demo.\n\nReturns the env row + VM row + Hetzner live state + DNS subdomain +\nfull event timeline + the ops_helper.vm-exec command primed for this\ndemo's VM. Sensitive fields (SSH private key, password) are NEVER\nreturned — ops uses ops_helper.py, which has the credentials internally.","operationId":"get_demo_details_api_v1_admin_demos_details__env_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Demo Details Api V1 Admin Demos Details  Env Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/events/stream":{"get":{"tags":["events"],"summary":"Event Stream","description":"SSE endpoint for real-time updates using Redis pub/sub.\n\nClients connect to this endpoint to receive real-time updates about:\n- Environment status changes (deploying, running, error, etc.)\n- Deployment progress\n- Webhook-triggered events\n\n**Authentication**: Supports two methods:\n1. Query parameter `token` - for API clients\n2. httpOnly cookie `access_token` - for browser-based EventSource (preferred)","operationId":"event_stream_api_v1_events_stream_get","parameters":[{"name":"token","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"JWT access token (optional, can use cookie)","title":"Token"},"description":"JWT access token (optional, can use cookie)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/quotas/usage":{"get":{"tags":["Quotas"],"summary":"Get Quota Usage","description":"Get current quota usage for an organization (mode-aware).\n\nBYOS Mode: Shows subscription quotas (existing behavior)\nShared Mode: Shows allocation quotas with expiration warnings\n\nShows current resource consumption vs limits for:\n- Projects, environments, servers, members (entity counts)\n- CPU, RAM, disk (resource totals)\n\nRequires org.quotas.view permission.","operationId":"get_quota_usage_api_v1_organizations__organization_id__quotas_usage_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/QuotaUsage"},{"type":"object"}],"title":"Response Get Quota Usage Api V1 Organizations  Organization Id  Quotas Usage Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/quotas":{"get":{"tags":["Quotas"],"summary":"Get Quota Limits","description":"Get quota limits for an organization.\n\nReturns the configured limits (not usage) for:\n- Entity counts (max_projects, max_environments, etc.)\n- Per-environment limits (max_cpu_per_env, etc.)\n- Total quotas (total_cpu_quota, etc.)\n\nRequires org.quotas.view permission.","operationId":"get_quota_limits_api_v1_organizations__organization_id__quotas_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationQuotaLimits"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Quotas"],"summary":"Update Quota Limits","description":"Update quota limits for an organization.\n\n**Admin only.** Updates resource quotas for an organization.\nThis is a dangerous operation that can affect resource availability.\n\nPlatform admins only (#1124). This used to check org.quotas.update, which\nthe org OWNER role holds, so any owner could set their own limits to\nunlimited -- a self-serve plan upgrade. The only UI caller is the\nplatform-admin organization page.","operationId":"update_quota_limits_api_v1_organizations__organization_id__quotas_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationQuotaUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationQuotaLimits"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/quotas/check/project":{"post":{"tags":["Quotas"],"summary":"Check Can Create Project","description":"Check if organization can create a new project.\n\nValidates against the max_projects quota limit.\nReturns allowed=True/False with reason if denied.\n\nRequires org.quotas.view permission.","operationId":"check_can_create_project_api_v1_organizations__organization_id__quotas_check_project_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuotaCheckResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/quotas/check/environment":{"post":{"tags":["Quotas"],"summary":"Check Can Create Environment","description":"Check if organization can create environment with given resources.\n\nValidates against:\n1. Environment count limit (max_environments)\n2. Per-environment resource limits (max_cpu_per_env, etc.)\n3. Total organization quotas (total_cpu_quota, etc.)\n\nIf no resources specified, uses defaults (1 CPU, 2GB RAM, 10GB disk).\n\nRequires org.quotas.view permission.","operationId":"check_can_create_environment_api_v1_organizations__organization_id__quotas_check_environment_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/EnvironmentResources"},{"type":"null"}],"title":"Resources"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuotaCheckResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/quotas/check/server":{"post":{"tags":["Quotas"],"summary":"Check Can Add Server","description":"Check if organization can add a new server.\n\nValidates against the max_servers quota limit.\nReturns allowed=True/False with reason if denied.\n\nRequires org.quotas.view permission.","operationId":"check_can_add_server_api_v1_organizations__organization_id__quotas_check_server_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuotaCheckResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/quotas/check/member":{"post":{"tags":["Quotas"],"summary":"Check Can Add Member","description":"Check if organization can add a new member.\n\nValidates against the max_members quota limit.\nReturns allowed=True/False with reason if denied.\n\nRequires org.quotas.view permission.","operationId":"check_can_add_member_api_v1_organizations__organization_id__quotas_check_member_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuotaCheckResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/storage-settings":{"get":{"tags":["Backups"],"summary":"Get Storage Settings","description":"Get storage platform settings (enabled providers, BYOS policy).","operationId":"get_storage_settings_api_v1_backups_storage_settings_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Storage Settings Api V1 Backups Storage Settings Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/storage-configs":{"get":{"tags":["Backups"],"summary":"List Storage Configs","description":"List storage configurations for an organization.\n\nRequires X-Organization-ID header. User membership is validated by ValidatedOrgID dependency.","operationId":"list_storage_configs_api_v1_backups_storage_configs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StorageConfigResponse"},"title":"Response List Storage Configs Api V1 Backups Storage Configs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Backups"],"summary":"Create Storage Config","description":"Create a new storage configuration for an organization (BYOS).\n\nRequires X-Organization-ID header and org.storage.create permission.","operationId":"create_storage_config_api_v1_backups_storage_configs_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/storage-configs/{config_id}":{"get":{"tags":["Backups"],"summary":"Get Storage Config","description":"Get a storage configuration by ID.","operationId":"get_storage_config_api_v1_backups_storage_configs__config_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Backups"],"summary":"Update Storage Config","description":"Update a storage configuration.","operationId":"update_storage_config_api_v1_backups_storage_configs__config_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Backups"],"summary":"Delete Storage Config","description":"Delete a storage configuration.","operationId":"delete_storage_config_api_v1_backups_storage_configs__config_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/storage-configs/{config_id}/test":{"post":{"tags":["Backups"],"summary":"Test Storage Config","description":"Test storage configuration connectivity.","operationId":"test_storage_config_api_v1_backups_storage_configs__config_id__test_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"config_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Config Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/storage-configs/test-connection":{"post":{"tags":["Backups"],"summary":"Test Storage Connection Raw","description":"Test storage connection with raw credentials (before saving).\n\nAllows testing S3, SFTP, FTP connections before creating the config.\nRequires X-Organization-ID header and org.storage.create permission.","operationId":"test_storage_connection_raw_api_v1_backups_storage_configs_test_connection_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageConfigCreate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StorageTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/storage-configs/list-buckets":{"post":{"tags":["Backups"],"summary":"List Storage Buckets","description":"List all buckets accessible with the provided credentials.\n\nThis allows users to discover existing buckets when setting up storage,\nrather than having to manually enter bucket names.\n\nFor S3-compatible services like Hetzner Object Storage where credentials\nare per-bucket, this may only return the bucket(s) accessible with those\nspecific credentials.\n\nRequires X-Organization-ID header and org.storage.create permission.","operationId":"list_storage_buckets_api_v1_backups_storage_configs_list_buckets_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBucketsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListBucketsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/organization/{organization_id}/backups":{"get":{"tags":["Backups"],"summary":"List Organization Backups","description":"List all backups across all environments in an organization.","operationId":"list_organization_backups_api_v1_backups_organization__organization_id__backups_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/BackupStatus"},{"type":"null"}],"title":"Status"}},{"name":"backup_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/BackupType"},{"type":"null"}],"title":"Backup Type"}},{"name":"environment_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by environment","title":"Environment Id"},"description":"Filter by environment"},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/environments/{environment_id}/backups":{"get":{"tags":["Backups"],"summary":"List Environment Backups","description":"List backups for an environment.","operationId":"list_environment_backups_api_v1_backups_environments__environment_id__backups_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/BackupStatus"},{"type":"null"}],"title":"Status"}},{"name":"backup_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/BackupType"},{"type":"null"}],"title":"Backup Type"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Backups"],"summary":"Create Backup","description":"Create a new backup for an environment (queued for async processing).","operationId":"create_backup_api_v1_backups_environments__environment_id__backups_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/{backup_id}":{"get":{"tags":["Backups"],"summary":"Get Backup","description":"Get backup details by ID.","operationId":"get_backup_api_v1_backups__backup_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Backups"],"summary":"Update Backup","description":"Update mutable backup metadata (currently only `notes`).","operationId":"update_backup_api_v1_backups__backup_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Backups"],"summary":"Delete Backup","description":"Delete a backup.","operationId":"delete_backup_api_v1_backups__backup_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/{backup_id}/cancel":{"post":{"tags":["Backups"],"summary":"Cancel Backup","description":"Cancel a pending, in-progress, or uploading backup.","operationId":"cancel_backup_api_v1_backups__backup_id__cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/{backup_id}/retry":{"post":{"tags":["Backups"],"summary":"Retry Backup","description":"Retry a failed or cancelled backup by creating a new one with the same parameters.","operationId":"retry_backup_api_v1_backups__backup_id__retry_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/{backup_id}/download":{"get":{"tags":["Backups"],"summary":"Get Download Urls","description":"Get presigned download URLs for backup files.","operationId":"get_download_urls_api_v1_backups__backup_id__download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"expires_in","in":"query","required":false,"schema":{"type":"integer","maximum":86400,"minimum":300,"description":"URL validity in seconds","default":3600,"title":"Expires In"},"description":"URL validity in seconds"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupDownloadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/{backup_id}/stream/{file_type}":{"get":{"tags":["Backups"],"summary":"Stream Backup File","description":"Stream backup file directly through backend.\n\nUsed as fallback when storage provider cannot generate signed URLs\n(e.g., GCP with OAuth credentials).\n\nArgs:\n    backup_id: Backup ID\n    file_type: One of \"database\", \"filestore\", \"manifest\"\n\nReturns:\n    StreamingResponse with the backup file","operationId":"stream_backup_file_api_v1_backups__backup_id__stream__file_type__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"file_type","in":"path","required":true,"schema":{"type":"string","title":"File Type"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/environments/{environment_id}/policy":{"get":{"tags":["Backups"],"summary":"Get Backup Policy","description":"Get backup policy for an environment.","operationId":"get_backup_policy_api_v1_backups_environments__environment_id__policy_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/BackupPolicyResponse"},{"type":"null"}],"title":"Response Get Backup Policy Api V1 Backups Environments  Environment Id  Policy Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Backups"],"summary":"Create Backup Policy","description":"Create backup policy for an environment.","operationId":"create_backup_policy_api_v1_backups_environments__environment_id__policy_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupPolicyCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupPolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Backups"],"summary":"Update Backup Policy","description":"Update backup policy for an environment.","operationId":"update_backup_policy_api_v1_backups_environments__environment_id__policy_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupPolicyUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupPolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Backups"],"summary":"Delete Backup Policy","description":"Delete backup policy for an environment.","operationId":"delete_backup_policy_api_v1_backups_environments__environment_id__policy_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/restore":{"post":{"tags":["Backups"],"summary":"Restore From Backup","description":"Restore an environment from a backup (queued for async processing).\n\n.. deprecated::\n    Use POST /restore/v2 instead, which supports creating new environments,\n    cross-server restore, and database neutralization.","operationId":"restore_from_backup_api_v1_backups_restore_post","deprecated":true,"security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestoreRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestorePointResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/environments/{environment_id}/restore-points":{"get":{"tags":["Backups"],"summary":"List Restore Points","description":"List restore points for an environment.","operationId":"list_restore_points_api_v1_backups_environments__environment_id__restore_points_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/RestoreStatus"},{"type":"null"}],"title":"Status"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RestorePointResponse"},"title":"Response List Restore Points Api V1 Backups Environments  Environment Id  Restore Points Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/restore/{restore_id}":{"get":{"tags":["Backups"],"summary":"Get Restore Point","description":"Get restore point details by ID.","operationId":"get_restore_point_api_v1_backups_restore__restore_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"restore_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Restore Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestorePointResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/restore/{restore_id}/cancel":{"post":{"tags":["Backups"],"summary":"Cancel Restore","description":"Cancel a pending or in-progress restore.","operationId":"cancel_restore_api_v1_backups_restore__restore_id__cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"restore_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Restore Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestorePointResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/restore/v2":{"post":{"tags":["Backups"],"summary":"Restore From Backup V2","description":"Restore an environment from a backup with target options (Sprint 2E19).\n\nTarget modes:\n- original: Restore to the environment where backup was taken (default)\n- existing: Restore to a different existing environment\n- new: Create a new environment and restore to it","operationId":"restore_from_backup_v2_api_v1_backups_restore_v2_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestoreRequestV2"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestoreResponseV2"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/{backup_id}/compatible-environments":{"get":{"tags":["Backups"],"summary":"Get Compatible Environments","description":"Get list of environments compatible with a backup for restore.\n\nReturns environments in the same project (excluding the source environment)\nthat can be used as restore targets.","operationId":"get_compatible_environments_api_v1_backups__backup_id__compatible_environments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CompatibleEnvironmentSummary"},"title":"Response Get Compatible Environments Api V1 Backups  Backup Id  Compatible Environments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/{backup_id}/compatible-servers":{"get":{"tags":["Backups"],"summary":"Get compatible servers for cross-server restore","description":"Get list of servers compatible for cross-server restore.\n\nReturns servers in the same organization that have enough resources\nto host the restored environment.","operationId":"get_compatible_servers_api_v1_backups__backup_id__compatible_servers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CompatibleServerResponse"},"title":"Response Get Compatible Servers Api V1 Backups  Backup Id  Compatible Servers Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/backups/environments/{environment_id}/summary":{"get":{"tags":["Backups"],"summary":"Get Environment Backup Summary","description":"Get backup summary statistics for an environment.","operationId":"get_environment_backup_summary_api_v1_backups_environments__environment_id__summary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupSummary"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/servers/{server_id}/summary":{"get":{"tags":["Monitoring"],"summary":"Get server metrics summary","description":"Level 1: Quick metrics summary for cards.\n\nReturns minimal metrics for server list views:\nCPU, memory, disk, network, container counts, and health status.","operationId":"get_server_summary_api_v1_monitoring_servers__server_id__summary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MetricsSummary"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/servers/{server_id}/metrics":{"get":{"tags":["Monitoring"],"summary":"Get full server metrics","description":"Level 2: Full server metrics with containers.\n\nReturns complete server metrics including per-container stats.\nOptionally includes time-series data for charts.","operationId":"get_server_metrics_api_v1_monitoring_servers__server_id__metrics_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"include_timeseries","in":"query","required":false,"schema":{"type":"boolean","description":"Include chart data","default":false,"title":"Include Timeseries"},"description":"Include chart data"},{"name":"time_range","in":"query","required":false,"schema":{"type":"string","description":"Time range: 1h, 24h, 7d, 30d","default":"24h","title":"Time Range"},"description":"Time range: 1h, 24h, 7d, 30d"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerMetricsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/servers/{server_id}/containers":{"get":{"tags":["Monitoring"],"summary":"Get container metrics","description":"Get metrics for all containers on a server.\n\nReturns empty list if server is unreachable or Netdata is not responding.","operationId":"get_container_metrics_api_v1_monitoring_servers__server_id__containers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ContainerMetrics"},"title":"Response Get Container Metrics Api V1 Monitoring Servers  Server Id  Containers Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/environments/{environment_id}/metrics":{"get":{"tags":["Monitoring"],"summary":"Get environment container metrics","description":"Get metrics filtered to environment's containers.\n\nOnly returns containers that belong to the specified environment.","operationId":"get_environment_metrics_api_v1_monitoring_environments__environment_id__metrics_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ContainerMetrics"},"title":"Response Get Environment Metrics Api V1 Monitoring Environments  Environment Id  Metrics Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/servers/{server_id}/dashboard-url":{"get":{"tags":["Monitoring"],"summary":"Get Netdata dashboard URL","description":"Level 3: Get signed URL for full Netdata dashboard.\n\nReturns a time-limited URL for embedding or opening\nthe full Netdata monitoring dashboard.","operationId":"get_monitoring_dashboard_url_api_v1_monitoring_servers__server_id__dashboard_url_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MonitoringUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/servers/{server_id}/health":{"get":{"tags":["Monitoring"],"summary":"Quick server health check","description":"Quick health check for server list.\n\nReturns basic health status without full metrics query.","operationId":"check_server_health_api_v1_monitoring_servers__server_id__health_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerHealthResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/servers/{server_id}/streaming-status":{"get":{"tags":["Monitoring"],"summary":"Get Netdata streaming status","description":"Get Netdata streaming configuration status for a server.\n\nReturns streaming enabled state, machine GUID, version, and installation time.","operationId":"get_streaming_status_api_v1_monitoring_servers__server_id__streaming_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Streaming Status Api V1 Monitoring Servers  Server Id  Streaming Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/dashboard":{"get":{"tags":["Monitoring"],"summary":"Get monitoring dashboard data","description":"Get unified monitoring dashboard with servers health for selected organization.\n\nReturns health status for all servers in the SELECTED organization\nalong with aggregate metrics.\n\n**Security**: Respects organization switcher - shows only data from selected org.\n\nQueries all servers in parallel with timeout handling for offline servers.","operationId":"get_monitoring_dashboard_api_v1_monitoring_dashboard_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MonitoringDashboardResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/environments":{"get":{"tags":["Monitoring"],"summary":"Get environment-level monitoring data","description":"Get monitoring data for all active environments in the organization.\n\nReturns a list of all active environments with their container metrics,\nincluding CPU/memory usage, uptime, and status information.\n\n**Security**: Respects organization switcher - shows only data from selected org.\n\nImplementation approach:\n1. Query all active environments for the organization (is_active=True)\n2. Group by server\n3. For each server with netdata configured, fetch container metrics\n4. Match containers to environments by container_name pattern ({env_id}_odoo)\n5. Return combined data","operationId":"get_environments_monitoring_api_v1_monitoring_environments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentMonitoringResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/alerts":{"get":{"tags":["Monitoring"],"summary":"List alerts","description":"List alerts for current user's organization.\n\nSupports filtering by status, severity, and server.\n\n**Access Control:**\n- Portal admins: Can view platform-wide alerts (no X-Organization-ID) OR org-specific alerts\n- Regular users: MUST have organization context via X-Organization-ID header","operationId":"list_alerts_api_v1_monitoring_alerts_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/AlertStatus"},{"type":"null"}],"description":"Filter by status","title":"Status"},"description":"Filter by status"},{"name":"severity","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/AlertSeverity"},{"type":"null"}],"description":"Filter by severity","title":"Severity"},"description":"Filter by severity"},{"name":"server_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by server","title":"Server Id"},"description":"Filter by server"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Maximum results","default":50,"title":"Limit"},"description":"Maximum results"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Offset for pagination","default":0,"title":"Offset"},"description":"Offset for pagination"},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/alerts/count":{"get":{"tags":["Monitoring"],"summary":"Get alert counts by status","description":"Get count of alerts by status.\n\nUseful for dashboard badges showing active alert count.\n\n**Access Control:**\n- Portal admins: Can view platform-wide counts (no X-Organization-ID) OR org-specific counts\n- Regular users: MUST have organization context via X-Organization-ID header","operationId":"get_alert_counts_api_v1_monitoring_alerts_count_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","additionalProperties":{"type":"integer"},"title":"Response Get Alert Counts Api V1 Monitoring Alerts Count Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/alerts/rules":{"get":{"tags":["Monitoring"],"summary":"List alert rules","description":"List alert rules for organization.\n\nIncludes both organization-specific and global default rules.","operationId":"list_alert_rules_api_v1_monitoring_alerts_rules_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AlertRuleResponse"},"title":"Response List Alert Rules Api V1 Monitoring Alerts Rules Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Monitoring"],"summary":"Create alert rule","description":"Create custom alert rule for organization.","operationId":"create_alert_rule_api_v1_monitoring_alerts_rules_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertRuleCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertRuleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/alerts/rules/{rule_id}":{"put":{"tags":["Monitoring"],"summary":"Update alert rule","description":"Update existing alert rule.\n\nOnly organization-owned rules can be updated (not global defaults).","operationId":"update_alert_rule_api_v1_monitoring_alerts_rules__rule_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertRuleUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertRuleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Monitoring"],"summary":"Delete alert rule","description":"Delete alert rule.\n\nOnly organization-owned rules can be deleted (not global defaults).","operationId":"delete_alert_rule_api_v1_monitoring_alerts_rules__rule_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/alerts/{alert_id}":{"get":{"tags":["Monitoring"],"summary":"Get alert details","description":"Get full details for a specific alert.","operationId":"get_alert_api_v1_monitoring_alerts__alert_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"alert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Alert Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertEventResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/alerts/{alert_id}/acknowledge":{"post":{"tags":["Monitoring"],"summary":"Acknowledge alert","description":"Mark an alert as acknowledged.\n\nAcknowledging indicates someone is aware and investigating.","operationId":"acknowledge_alert_api_v1_monitoring_alerts__alert_id__acknowledge_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"alert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Alert Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertAcknowledgeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertEventResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/alerts/{alert_id}/resolve":{"post":{"tags":["Monitoring"],"summary":"Resolve alert","description":"Mark an alert as resolved.\n\nResolving indicates the issue has been fixed.","operationId":"resolve_alert_api_v1_monitoring_alerts__alert_id__resolve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"alert_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Alert Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertEventResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/monitoring/webhooks/netdata/{server_id}":{"post":{"tags":["Monitoring"],"summary":"Receive Netdata alert webhook","description":"Receive alert webhook from Netdata on a server.\n\nNetdata can be configured to send webhooks when alerts trigger.\nThis endpoint creates alert events from those webhooks.\n\nSecurity:\n- Validates HMAC-SHA256 signature using server's webhook secret\n- Rejects requests with invalid/missing signatures\n- Logs failed authentication attempts","operationId":"receive_netdata_alert_api_v1_monitoring_webhooks_netdata__server_id__post","parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}},{"name":"x-netdata-signature","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Netdata-Signature"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Receive Netdata Alert Api V1 Monitoring Webhooks Netdata  Server Id  Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/me/abilities":{"get":{"tags":["Permissions"],"summary":"Get My Abilities","description":"Get current user's effective permissions (abilities).\n\nThis is the primary endpoint for frontend to check what the user can do.\nReturns abilities in format: { \"resource\": [\"action1\", \"action2\"] }\n\nExample response:\n```json\n{\n    \"abilities\": {\n        \"members\": [\"list\", \"invite\"],\n        \"projects\": [\"list\", \"create\", \"update\"],\n        \"servers\": [\"list\"]\n    },\n    \"scope\": \"organization\",\n    \"cached_at\": \"2024-12-05T10:00:00Z\"\n}\n```","operationId":"get_my_abilities_api_v1_permissions_me_abilities_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context","title":"Organization Id"},"description":"Organization context"},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Project context","title":"Project Id"},"description":"Project context"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserAbilities"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/me/abilities/refresh":{"post":{"tags":["Permissions"],"summary":"Refresh My Abilities","description":"Force refresh of current user's abilities (bypass cache).\n\nUse this when you expect permissions to have changed.","operationId":"refresh_my_abilities_api_v1_permissions_me_abilities_refresh_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context","title":"Organization Id"},"description":"Organization context"},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Project context","title":"Project Id"},"description":"Project context"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserAbilities"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/check":{"post":{"tags":["Permissions"],"summary":"Check Permission","description":"Check if current user has a specific permission.\n\nReturns whether the permission is granted and the source (role).","operationId":"check_permission_api_v1_permissions_check_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"permission_code","in":"query","required":true,"schema":{"type":"string","description":"Permission code to check","title":"Permission Code"},"description":"Permission code to check"},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context","title":"Organization Id"},"description":"Organization context"},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Project context","title":"Project Id"},"description":"Project context"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PermissionCheckResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/permissions":{"get":{"tags":["Permissions"],"summary":"List Permissions","description":"List all permissions.\n\nPortal admins can access without organization context.\nOrganization admins/owners need to provide organization_id.\n\nSupports filtering by scope and category.","operationId":"list_permissions_api_v1_permissions_admin_permissions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"scope","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/PermissionScope"},{"type":"null"}],"description":"Filter by scope","title":"Scope"},"description":"Filter by scope"},{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by category","title":"Category"},"description":"Filter by category"},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context for non-portal-admins","title":"Organization Id"},"description":"Organization context for non-portal-admins"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PermissionResponse"},"title":"Response List Permissions Api V1 Permissions Admin Permissions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/permissions/categories":{"get":{"tags":["Permissions"],"summary":"List Permission Categories","description":"Get permission categories with counts.\n\nPortal admins can access without organization context.\nOrganization admins/owners need to provide organization_id.\n\nUseful for building filter UI.","operationId":"list_permission_categories_api_v1_permissions_admin_permissions_categories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"scope","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/PermissionScope"},{"type":"null"}],"description":"Filter by scope","title":"Scope"},"description":"Filter by scope"},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context for non-portal-admins","title":"Organization Id"},"description":"Organization context for non-portal-admins"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/roles":{"get":{"tags":["Permissions"],"summary":"List Roles","description":"List all roles.\n\nPortal admins can access without organization context.\nOrganization admins/owners need to provide organization_id.\n\nIncludes system roles and optionally organization custom roles.","operationId":"list_roles_api_v1_permissions_admin_roles_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"scope","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/PermissionScope"},{"type":"null"}],"description":"Filter by scope","title":"Scope"},"description":"Filter by scope"},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Include org's custom roles (required for non-portal-admins)","title":"Organization Id"},"description":"Include org's custom roles (required for non-portal-admins)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RoleResponse"},"title":"Response List Roles Api V1 Permissions Admin Roles Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Permissions"],"summary":"Create Role","description":"Create a new custom role.\n\nPortal admins can create roles without organization context.\nOrganization admins/owners can create custom roles for their organization.\n\nCustom roles can be created at organization level.\nSystem roles cannot be created via API.","operationId":"create_role_api_v1_permissions_admin_roles_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/roles/{role_id}":{"get":{"tags":["Permissions"],"summary":"Get Role","description":"Get role details with permissions.\n\nPortal admins can access without organization context.\nOrganization admins/owners need to provide organization_id.","operationId":"get_role_api_v1_permissions_admin_roles__role_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"role_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Role Id"}},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context for non-portal-admins","title":"Organization Id"},"description":"Organization context for non-portal-admins"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleWithPermissions"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Permissions"],"summary":"Update Role","description":"Update a custom role.\n\nPortal admins can update any custom role.\nOrganization admins/owners can update their organization's custom roles.\n\nSystem roles cannot be modified.","operationId":"update_role_api_v1_permissions_admin_roles__role_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"role_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Role Id"}},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context for non-portal-admins","title":"Organization Id"},"description":"Organization context for non-portal-admins"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Permissions"],"summary":"Delete Role","description":"Delete a custom role.\n\nPortal admins can delete any custom role.\nOrganization admins/owners can delete their organization's custom roles.\n\nSystem roles cannot be deleted.","operationId":"delete_role_api_v1_permissions_admin_roles__role_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"role_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Role Id"}},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context for non-portal-admins","title":"Organization Id"},"description":"Organization context for non-portal-admins"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/roles/{role_id}/clone":{"post":{"tags":["Permissions"],"summary":"Clone Role","description":"Clone a role with all its permissions.\n\nPortal admins can clone any role.\nOrganization admins/owners can clone roles for their organization.\n\nCreates a new custom role based on an existing role.","operationId":"clone_role_api_v1_permissions_admin_roles__role_id__clone_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"role_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Role Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleClone"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/matrix":{"get":{"tags":["Permissions"],"summary":"Get Permission Matrix","description":"Get the permission matrix for a scope.\n\nPortal admins can access without organization context.\nOrganization admins/owners need to provide organization_id.\n\nReturns all roles and permissions with their mappings for the UI matrix view.","operationId":"get_permission_matrix_api_v1_permissions_admin_matrix_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"scope","in":"query","required":true,"schema":{"$ref":"#/components/schemas/PermissionScope","description":"Scope to view"},"description":"Scope to view"},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context (required for non-portal-admins)","title":"Organization Id"},"description":"Organization context (required for non-portal-admins)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/matrix/toggle":{"post":{"tags":["Permissions"],"summary":"Toggle Permission","description":"Toggle a single permission for a role.\n\nPortal admins can toggle permissions on any role.\nOrganization admins/owners can toggle permissions for their organization's roles.\n\nUse this for single-click toggles in the permission matrix UI.","operationId":"toggle_permission_api_v1_permissions_admin_matrix_toggle_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RolePermissionToggle"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/matrix/bulk":{"put":{"tags":["Permissions"],"summary":"Bulk Update Permissions","description":"Bulk update role permissions.\n\nPortal admins can update permissions on any role.\nOrganization admins/owners can update permissions for their organization's roles.\n\nUse this for applying multiple permission changes at once.","operationId":"bulk_update_permissions_api_v1_permissions_admin_matrix_bulk_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RolePermissionBulkUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/users/{user_id}/permissions":{"get":{"tags":["Permissions"],"summary":"Get User Effective Permissions","description":"Get a user's effective permissions.\n\nPortal admins can access without organization context.\nOrganization admins/owners need to provide organization_id.\n\nShows all permissions the user has from their role.","operationId":"get_user_effective_permissions_api_v1_permissions_admin_users__user_id__permissions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context (required for non-portal-admins)","title":"Organization Id"},"description":"Organization context (required for non-portal-admins)"},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Project context","title":"Project Id"},"description":"Project context"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/audit":{"get":{"tags":["Permissions"],"summary":"List Permission Audit Logs","description":"Get permission audit logs.\n\nPortal admins can access without organization context.\nOrganization admins/owners need to provide organization_id.\n\nReturns a timeline of permission changes for review.","operationId":"list_permission_audit_logs_api_v1_permissions_admin_audit_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization (required for non-portal-admins)","title":"Organization Id"},"description":"Filter by organization (required for non-portal-admins)"},{"name":"actor_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by actor","title":"Actor Id"},"description":"Filter by actor"},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Filter by start date","title":"Start Date"},"description":"Filter by start date"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Filter by end date","title":"End Date"},"description":"Filter by end date"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"description":"Number of records","default":50,"title":"Limit"},"description":"Number of records"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Offset for pagination","default":0,"title":"Offset"},"description":"Offset for pagination"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/users/{user_id}/roles":{"post":{"tags":["Permissions"],"summary":"Assign role to user","description":"Assign a custom role to a user. Portal admins or organization admins can perform this action.","operationId":"assign_role_to_user_api_v1_permissions_admin_users__user_id__roles_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AssignRoleRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserRoleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Permissions"],"summary":"List user's role assignments","description":"Get all role assignments for a user. Portal admins or organization admins can perform this action.","operationId":"list_user_roles_api_v1_permissions_admin_users__user_id__roles_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization (required for non-portal-admins)","title":"Organization Id"},"description":"Filter by organization (required for non-portal-admins)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UserRoleResponse"},"title":"Response List User Roles Api V1 Permissions Admin Users  User Id  Roles Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/users/{user_id}/roles/{role_id}":{"delete":{"tags":["Permissions"],"summary":"Unassign role from user","description":"Remove a role assignment from a user. Portal admins or organization admins can perform this action.","operationId":"unassign_role_from_user_api_v1_permissions_admin_users__user_id__roles__role_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"role_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Role Id"}},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization context (required for non-portal-admins)","title":"Organization Id"},"description":"Organization context (required for non-portal-admins)"},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Project context","title":"Project Id"},"description":"Project context"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/permissions/admin/roles/{role_id}/users":{"get":{"tags":["Permissions"],"summary":"List users assigned to role","description":"Get all users who have been assigned this role. Portal admins or organization admins can perform this action.","operationId":"list_role_users_api_v1_permissions_admin_roles__role_id__users_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"role_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Role Id"}},{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization (required for non-portal-admins)","title":"Organization Id"},"description":"Filter by organization (required for non-portal-admins)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UserRoleResponse"},"title":"Response List Role Users Api V1 Permissions Admin Roles  Role Id  Users Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/platform/git-connections":{"get":{"tags":["Platform Git Connections"],"summary":"List Platform Connections","description":"List all platform Git connections.\n\nRequires portal admin privileges.","operationId":"list_platform_connections_api_v1_platform_git_connections_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"active_only","in":"query","required":false,"schema":{"type":"boolean","description":"Only return active connections","default":true,"title":"Active Only"},"description":"Only return active connections"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PlatformGitConnectionResponse"},"title":"Response List Platform Connections Api V1 Platform Git Connections Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Git Connections"],"summary":"Create Platform Connection","description":"Create a new platform Git connection.\n\nRequires portal admin privileges.\nTokens will be encrypted before storage.","operationId":"create_platform_connection_api_v1_platform_git_connections_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformGitConnectionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformGitConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/platform/git-connections/{connection_id}":{"get":{"tags":["Platform Git Connections"],"summary":"Get Platform Connection","description":"Get a specific platform Git connection.\n\nRequires portal admin privileges.","operationId":"get_platform_connection_api_v1_platform_git_connections__connection_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformGitConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Platform Git Connections"],"summary":"Update Platform Connection","description":"Update a platform Git connection.\n\nRequires portal admin privileges.\nToken fields will be encrypted if provided.","operationId":"update_platform_connection_api_v1_platform_git_connections__connection_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformGitConnectionUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformGitConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Platform Git Connections"],"summary":"Delete Platform Connection","description":"Delete a platform Git connection.\n\nRequires portal admin privileges.","operationId":"delete_platform_connection_api_v1_platform_git_connections__connection_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/platform/git-connections/{connection_id}/validate":{"post":{"tags":["Platform Git Connections"],"summary":"Validate Platform Connection","description":"Validate a platform Git connection.\n\nTests the connection by making an API call to the Git provider.\nRequires portal admin privileges.","operationId":"validate_platform_connection_api_v1_platform_git_connections__connection_id__validate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionValidationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/platform/git-connections/{connection_id}/repositories":{"get":{"tags":["Platform Git Connections"],"summary":"List Platform Connection Repositories","description":"List repositories accessible through a platform Git connection.\n\nRequires portal admin privileges.","operationId":"list_platform_connection_repositories_api_v1_platform_git_connections__connection_id__repositories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":30,"title":"Per Page"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RepositoryListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/platform/git-connections/{connection_id}/branches":{"get":{"tags":["Platform Git Connections"],"summary":"List Platform Connection Branches","description":"List branches for a repository via a platform Git connection.\n\nRequires portal admin privileges.","operationId":"list_platform_connection_branches_api_v1_platform_git_connections__connection_id__branches_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"repo","in":"query","required":true,"schema":{"type":"string","description":"Repository full name (e.g., owner/repo)","title":"Repo"},"description":"Repository full name (e.g., owner/repo)"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search filter for branch names","title":"Search"},"description":"Search filter for branch names"},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":100,"title":"Per Page"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BranchListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/git-connections":{"get":{"tags":["Organization Git Connections"],"summary":"List Org Connections","description":"List all Git connections for an organization.\n\nRequires organization membership.","operationId":"list_org_connections_api_v1_organizations__organization_id__git_connections_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"active_only","in":"query","required":false,"schema":{"type":"boolean","description":"Only return active connections","default":true,"title":"Active Only"},"description":"Only return active connections"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OrgGitConnectionResponse"},"title":"Response List Org Connections Api V1 Organizations  Organization Id  Git Connections Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Organization Git Connections"],"summary":"Create Org Connection","description":"Create a new Git connection for an organization.\n\nRequires organization admin privileges.\nTokens will be encrypted before storage.","operationId":"create_org_connection_api_v1_organizations__organization_id__git_connections_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgGitConnectionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgGitConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/git-connections/{connection_id}":{"get":{"tags":["Organization Git Connections"],"summary":"Get Org Connection","description":"Get a specific Git connection for an organization.\n\nRequires organization membership.","operationId":"get_org_connection_api_v1_organizations__organization_id__git_connections__connection_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgGitConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Organization Git Connections"],"summary":"Update Org Connection","description":"Update an organization Git connection.\n\nRequires organization admin privileges.\nToken fields will be encrypted if provided.","operationId":"update_org_connection_api_v1_organizations__organization_id__git_connections__connection_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgGitConnectionUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgGitConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Organization Git Connections"],"summary":"Delete Org Connection","description":"Delete an organization Git connection.\n\nRequires organization admin privileges.","operationId":"delete_org_connection_api_v1_organizations__organization_id__git_connections__connection_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/git-connections/{connection_id}/validate":{"post":{"tags":["Organization Git Connections"],"summary":"Validate Org Connection","description":"Validate an organization Git connection.\n\nTests the connection by making an API call to the Git provider.\nRequires organization admin privileges.","operationId":"validate_org_connection_api_v1_organizations__organization_id__git_connections__connection_id__validate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionValidationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/git-connections/{connection_id}/repositories":{"get":{"tags":["Organization Git Connections"],"summary":"List Org Connection Repositories","description":"List repositories accessible through an organization Git connection.\n\nRequires organization membership.","operationId":"list_org_connection_repositories_api_v1_organizations__organization_id__git_connections__connection_id__repositories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":30,"title":"Per Page"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RepositoryListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/git-connections/{connection_id}/branches":{"get":{"tags":["Organization Git Connections"],"summary":"List Org Connection Branches","description":"List branches for a repository via an organization Git connection.\n\nRequires organization membership.","operationId":"list_org_connection_branches_api_v1_organizations__organization_id__git_connections__connection_id__branches_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"repo","in":"query","required":true,"schema":{"type":"string","description":"Repository full name (e.g., owner/repo)","title":"Repo"},"description":"Repository full name (e.g., owner/repo)"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search filter for branch names","title":"Search"},"description":"Search filter for branch names"},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":100,"title":"Per Page"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BranchListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git-oauth/status":{"get":{"tags":["Git OAuth"],"summary":"Get Oauth Status","description":"Get OAuth configuration status.\n\nReturns which Git providers have OAuth configured.","operationId":"get_oauth_status_api_v1_git_oauth_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OAuthStatusResponse"}}}}}}},"/api/v1/git-oauth/authorize":{"post":{"tags":["Git OAuth"],"summary":"Initiate Oauth","description":"Initiate OAuth flow for connecting a Git provider.\n\nReturns the authorization URL to redirect the user to.\n\nFor platform-level connections, requires portal admin privileges.\nFor organization-level connections, requires organization admin privileges.","operationId":"initiate_oauth_api_v1_git_oauth_authorize_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OAuthAuthorizeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OAuthAuthorizeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git-oauth/refresh/{connection_id}":{"post":{"tags":["Git OAuth"],"summary":"Refresh Connection Token","description":"Manually refresh OAuth token for a connection.\n\nUseful when token is expired or about to expire.","operationId":"refresh_connection_token_api_v1_git_oauth_refresh__connection_id__post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git-oauth/connections":{"get":{"tags":["Git OAuth"],"summary":"List Available Connections","description":"List all Git connections available to the current user.\n\nReturns platform connections (if allow_org_usage or user is admin)\nand organization connections for user's organizations.\n\nWhen `organization_id` is provided, the caller must be a member of that\norg OR be a portal admin. In that case org connections are scoped to\nthat single org instead of the caller's own memberships — this is what\nlets a portal admin see a customer org's PAT when browsing the\ncustomer's project repo picker.","operationId":"list_available_connections_api_v1_git_oauth_connections_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Scope the org connections returned to a specific organization. When provided, the response includes that org's connections instead of iterating over the caller's own memberships. Required when a portal admin browses another org's project — without it, UnifiedRepoSelector would show the portal admin's own orgs' connections instead of the target org's (see fix 2026-04-15).","title":"Organization Id"},"description":"Scope the org connections returned to a specific organization. When provided, the response includes that org's connections instead of iterating over the caller's own memberships. Required when a portal admin browses another org's project — without it, UnifiedRepoSelector would show the portal admin's own orgs' connections instead of the target org's (see fix 2026-04-15)."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailableConnectionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git-oauth/connections/{connection_id}/repositories":{"get":{"tags":["Git OAuth"],"summary":"List Connection Repositories","description":"List repositories accessible via a Git connection.\n\nWorks with both platform and organization connections.","operationId":"list_connection_repositories_api_v1_git_oauth_connections__connection_id__repositories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","default":50,"title":"Per Page"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RepositoriesListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/git-oauth/connections/{connection_id}/branches":{"get":{"tags":["Git OAuth"],"summary":"List Connection Branches","description":"List branches for a repository via a Git connection.\n\nWorks with both platform and organization connections.","operationId":"list_connection_branches_api_v1_git_oauth_connections__connection_id__branches_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"repo","in":"query","required":true,"schema":{"type":"string","title":"Repo"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Per Page"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BranchesListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/platform-addon-repos":{"get":{"tags":["Platform Addon Repos"],"summary":"List Platform Addon Repos","description":"List all platform addon repositories.","operationId":"list_platform_addon_repos_api_v1_admin_platform_addon_repos_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PlatformAddonRepoResponse"},"title":"Response List Platform Addon Repos Api V1 Admin Platform Addon Repos Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Platform Addon Repos"],"summary":"Create Platform Addon Repo","description":"Create a new platform addon repository.","operationId":"create_platform_addon_repo_api_v1_admin_platform_addon_repos_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformAddonRepoCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformAddonRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/platform-addon-repos/{repo_id}":{"get":{"tags":["Platform Addon Repos"],"summary":"Get Platform Addon Repo","description":"Get a platform addon repository by ID.","operationId":"get_platform_addon_repo_api_v1_admin_platform_addon_repos__repo_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformAddonRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Platform Addon Repos"],"summary":"Update Platform Addon Repo","description":"Update a platform addon repository.","operationId":"update_platform_addon_repo_api_v1_admin_platform_addon_repos__repo_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformAddonRepoUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformAddonRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Platform Addon Repos"],"summary":"Delete Platform Addon Repo","description":"Delete a platform addon repository (soft delete).","operationId":"delete_platform_addon_repo_api_v1_admin_platform_addon_repos__repo_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/platform-addon-repos/{repo_id}/versions":{"post":{"tags":["Platform Addon Repos"],"summary":"Add Version Mapping","description":"Add a version mapping to a platform addon repository.","operationId":"add_version_mapping_api_v1_admin_platform_addon_repos__repo_id__versions_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformAddonRepoVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlatformAddonRepoVersionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/platform-addon-repos/{repo_id}/versions/{version_id}":{"delete":{"tags":["Platform Addon Repos"],"summary":"Remove Version Mapping","description":"Remove a version mapping from a platform addon repository.","operationId":"remove_version_mapping_api_v1_admin_platform_addon_repos__repo_id__versions__version_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/addon-repos":{"get":{"tags":["Organization Addon Repos"],"summary":"List Org Addon Repos","description":"List all addon repositories for an organization.","operationId":"list_org_addon_repos_api_v1_organizations__organization_id__addon_repos_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OrgAddonRepoResponse"},"title":"Response List Org Addon Repos Api V1 Organizations  Organization Id  Addon Repos Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Organization Addon Repos"],"summary":"Create Org Addon Repo","description":"Create a new addon repository for an organization.","operationId":"create_org_addon_repo_api_v1_organizations__organization_id__addon_repos_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgAddonRepoCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgAddonRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/addon-repos/{repo_id}":{"get":{"tags":["Organization Addon Repos"],"summary":"Get Org Addon Repo","description":"Get an organization addon repository by ID.","operationId":"get_org_addon_repo_api_v1_organizations__organization_id__addon_repos__repo_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgAddonRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Organization Addon Repos"],"summary":"Update Org Addon Repo","description":"Update an organization addon repository.","operationId":"update_org_addon_repo_api_v1_organizations__organization_id__addon_repos__repo_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","description":"Force update even if repo is in use","default":false,"title":"Force"},"description":"Force update even if repo is in use"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgAddonRepoUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgAddonRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Organization Addon Repos"],"summary":"Delete Org Addon Repo","description":"Delete an organization addon repository (soft delete).","operationId":"delete_org_addon_repo_api_v1_organizations__organization_id__addon_repos__repo_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","description":"Force delete even if repo is in use","default":false,"title":"Force"},"description":"Force delete even if repo is in use"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/addon-repos/{repo_id}/usage":{"get":{"tags":["Organization Addon Repos"],"summary":"Get Org Addon Repo Usage","description":"Check which projects and active environments are using this addon repo.","operationId":"get_org_addon_repo_usage_api_v1_organizations__organization_id__addon_repos__repo_id__usage_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/addon-repos/{repo_id}/versions":{"post":{"tags":["Organization Addon Repos"],"summary":"Add Org Version Mapping","description":"Map an Odoo version to a specific Git branch for an org addon repo.","operationId":"add_org_version_mapping_api_v1_organizations__organization_id__addon_repos__repo_id__versions_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgAddonRepoVersionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgAddonRepoVersionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/addon-repos/{repo_id}/versions/{version_id}":{"delete":{"tags":["Organization Addon Repos"],"summary":"Remove Org Version Mapping","description":"Remove an Odoo-version branch mapping from an org addon repo.","operationId":"remove_org_version_mapping_api_v1_organizations__organization_id__addon_repos__repo_id__versions__version_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"version_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Version Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/addon-repos/reorder":{"post":{"tags":["Organization Addon Repos"],"summary":"Reorder Org Addon Repos","description":"Reorder organization addon repositories.","operationId":"reorder_org_addon_repos_api_v1_organizations__organization_id__addon_repos_reorder_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReorderReposRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/additional-repos":{"get":{"tags":["Project Additional Repos"],"summary":"List Project Additional Repos","description":"List all additional repositories for a project.","operationId":"list_project_additional_repos_api_v1_projects__project_id__additional_repos_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProjectAdditionalRepoResponse"},"title":"Response List Project Additional Repos Api V1 Projects  Project Id  Additional Repos Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Project Additional Repos"],"summary":"Create Project Additional Repo","description":"Create a new additional repository for a project.","operationId":"create_project_additional_repo_api_v1_projects__project_id__additional_repos_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAdditionalRepoCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAdditionalRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/additional-repos/upload":{"post":{"tags":["Project Additional Repos"],"summary":"Upload Project Additional Repo","description":"Upload a custom addon module archive as a project additional repo.\n\nCustomer-facing counterpart to `create_project_additional_repo` for\n`source_type == \"upload\"` rows: validates + sanitises the archive\n(Task 4's `sanitize_and_repackage`), stores the clean archive in R2 under\na server-derived key (Task 5), and creates the `ProjectAdditionalRepo`\nrow, or reuses a DELETED row with the same slug. A row with the same slug\nthat is not deleted (active or Disabled) is a 409 (#1408).","operationId":"upload_project_additional_repo_api_v1_projects__project_id__additional_repos_upload_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_project_additional_repo_api_v1_projects__project_id__additional_repos_upload_post"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAdditionalRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/additional-repos/{repo_id}":{"get":{"tags":["Project Additional Repos"],"summary":"Get Project Additional Repo","description":"Get a project additional repository by ID.","operationId":"get_project_additional_repo_api_v1_projects__project_id__additional_repos__repo_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAdditionalRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Project Additional Repos"],"summary":"Update Project Additional Repo","description":"Update a project additional repository.","operationId":"update_project_additional_repo_api_v1_projects__project_id__additional_repos__repo_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAdditionalRepoUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAdditionalRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Project Additional Repos"],"summary":"Delete Project Additional Repo","description":"Delete a project additional repository.\n\nSoft delete: the row is kept with deleted_at set (#1408), which hides it\neverywhere (unlike Disable, which keeps it listed and its archive kept).\nIdempotent: an already-deleted row is a 204 with no write.","operationId":"delete_project_additional_repo_api_v1_projects__project_id__additional_repos__repo_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/additional-repos/{repo_id}/reupload":{"post":{"tags":["Project Additional Repos"],"summary":"Reupload Project Additional Repo","description":"Re-upload a new archive version for an existing upload-sourced repo.\n\nSame validate/sanitise/store pipeline as `upload_project_additional_repo`,\nbut scoped to an existing `repo_id` — the addon's `slug` (its identity)\ndoes not change on re-upload, only its content (`upload_r2_key`,\n`upload_original_filename`, `upload_size_bytes`, `upload_content_sha256`).\nThe old R2 object is left in place for Task 10's GC cron to reap, exactly\nlike the DELETE route above.","operationId":"reupload_project_additional_repo_api_v1_projects__project_id__additional_repos__repo_id__reupload_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_reupload_project_additional_repo_api_v1_projects__project_id__additional_repos__repo_id__reupload_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAdditionalRepoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/additional-repos/reorder":{"post":{"tags":["Project Additional Repos"],"summary":"Reorder Project Additional Repos","description":"Reorder project additional repositories.","operationId":"reorder_project_additional_repos_api_v1_projects__project_id__additional_repos_reorder_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReorderReposRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/additional-repos/{repo_id}/environments":{"put":{"tags":["Project Additional Repos"],"summary":"Set Project Additional Repo Environments","description":"Set which of a project's active environments this additional repo\napplies to (#env-scoping Task 5).\n\nThe request body is an ALLOWLIST (\"apply this repo to these\nenvironments\") — stored server-side as `EnvironmentRepoOverride`\nexclusion rows (`repo_type='project_additional'`, `is_excluded=True`)\nfor every active environment NOT selected, since a repo already applies\nto every environment by default with no row at all. See\n`_set_repo_environment_targeting` for the full translation + upsert\nsemantics.","operationId":"set_project_additional_repo_environments_api_v1_projects__project_id__additional_repos__repo_id__environments_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"repo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Repo Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetRepoEnvironmentsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SetRepoEnvironmentsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/addon-selections":{"get":{"tags":["Project Addon Selections"],"summary":"Get Project Addon Selections","description":"Get addon selections for a project.\n\nReturns all available platform and organization repos with their selection status.\nThis allows the UI to show checkboxes for each available repo.","operationId":"get_project_addon_selections_api_v1_projects__project_id__addon_selections_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAddonSelectionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Project Addon Selections"],"summary":"Update Project Addon Selections","description":"Update addon selections for a project.\n\nThis replaces all current selections with the provided lists.\nRepos not in the list will be deselected.","operationId":"update_project_addon_selections_api_v1_projects__project_id__addon_selections_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateProjectAddonSelectionsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectAddonSelectionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/repo-overrides":{"get":{"tags":["Environment Repo Overrides"],"summary":"Get Env Repo Overrides","description":"Get all project repos for this environment with override status.\n\nReturns platform (selected), organization (selected), and project additional\nrepos for the environment's project, annotated with per-environment exclusion\nand branch override state from environment_repo_overrides.","operationId":"get_env_repo_overrides_api_v1_environments__environment_id__repo_overrides_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvRepoOverridesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Environment Repo Overrides"],"summary":"Update Env Repo Overrides","description":"Replace the repo overrides of the repos this environment deploys.\n\nOnly saves rows where is_excluded=True OR branch_override is not None\n(skips no-op rows). Stored rows for repos that do not deploy here are kept\nunless listed in remove_ineffective. Returns the updated override status.","operationId":"update_env_repo_overrides_api_v1_environments__environment_id__repo_overrides_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateEnvRepoOverridesRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvRepoOverridesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dlq":{"get":{"tags":["Dead Letter Queue"],"summary":"List Failed Tasks","description":"List failed tasks in the Dead Letter Queue.\n\nRequires portal admin permission.\n\nArgs:\n    page: Page number (1-indexed)\n    page_size: Number of tasks per page\n    current_user: Authenticated user\n    db: Database session\n\nReturns:\n    List of failed tasks with pagination info","operationId":"list_failed_tasks_api_v1_dlq_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Tasks per page","default":20,"title":"Page Size"},"description":"Tasks per page"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DLQListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Dead Letter Queue"],"summary":"Purge Dlq","description":"Purge tasks from the Dead Letter Queue.\n\nRequires portal admin permission.\n\nArgs:\n    older_than_days: Only purge tasks older than N days (default: purge all)\n    current_user: Authenticated user\n    db: Database session\n\nReturns:\n    Number of tasks purged","operationId":"purge_dlq_api_v1_dlq_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"older_than_days","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"description":"Only purge tasks older than N days (default: purge all)","title":"Older Than Days"},"description":"Only purge tasks older than N days (default: purge all)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PurgeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dlq/stats":{"get":{"tags":["Dead Letter Queue"],"summary":"Get Dlq Stats","description":"Get Dead Letter Queue statistics.\n\nRequires portal admin permission.\n\nArgs:\n    current_user: Authenticated user\n    db: Database session\n\nReturns:\n    DLQ statistics (total tasks, oldest, newest)","operationId":"get_dlq_stats_api_v1_dlq_stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DLQStatsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dlq/{job_id}":{"get":{"tags":["Dead Letter Queue"],"summary":"Get Failed Task","description":"Get details of a specific failed task from DLQ.\n\nRequires portal admin permission.\n\nArgs:\n    job_id: ARQ job ID\n    current_user: Authenticated user\n    db: Database session\n\nReturns:\n    Failed task details","operationId":"get_failed_task_api_v1_dlq__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FailedTaskResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Dead Letter Queue"],"summary":"Remove Failed Task","description":"Remove a specific task from the Dead Letter Queue.\n\nRequires portal admin permission.\n\nArgs:\n    job_id: ARQ job ID to remove\n    current_user: Authenticated user\n    db: Database session\n\nReturns:\n    204 No Content on success","operationId":"remove_failed_task_api_v1_dlq__job_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dlq/{job_id}/retry":{"post":{"tags":["Dead Letter Queue"],"summary":"Retry Failed Task","description":"Retry a failed task from the Dead Letter Queue.\n\nRe-queues the task with its original arguments and removes it from DLQ.\n\nRequires portal admin permission.\n\nArgs:\n    job_id: ARQ job ID to retry\n    current_user: Authenticated user\n    db: Database session\n\nReturns:\n    Retry status and new job ID","operationId":"retry_failed_task_api_v1_dlq__job_id__retry_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","title":"Job Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetryTaskResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ssh-keys":{"post":{"tags":["SSH Keys"],"summary":"Generate new SSH key pair","description":"Generate a new SSH key pair and store it encrypted. **WARNING:** Private key is only returned once - download and store securely!","operationId":"create_ssh_key_pair_api_v1_ssh_keys_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyPairCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyPairWithPrivate"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["SSH Keys"],"summary":"List SSH key pairs","description":"List all SSH key pairs with optional filters","operationId":"list_ssh_key_pairs_api_v1_ssh_keys_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization","title":"Organization Id"},"description":"Filter by organization"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by status","title":"Status"},"description":"Filter by status"},{"name":"include_expired","in":"query","required":false,"schema":{"type":"boolean","description":"Include expired keys","default":false,"title":"Include Expired"},"description":"Include expired keys"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ssh-keys/{key_id}":{"get":{"tags":["SSH Keys"],"summary":"Get SSH key pair details","description":"Get SSH key pair details (without private key).\n\nRequired permission: org.ssh_keys.view","operationId":"get_ssh_key_pair_api_v1_ssh_keys__key_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyPairResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SSH Keys"],"summary":"Revoke SSH key","description":"Revoke an SSH key and optionally remove from servers","operationId":"revoke_ssh_key_api_v1_ssh_keys__key_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyRevokeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyRevokeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ssh-keys/{key_id}/usage":{"get":{"tags":["SSH Keys"],"summary":"Get key usage statistics","description":"Get SSH key usage statistics and server list.\n\nRequired permission: org.ssh_keys.view","operationId":"get_ssh_key_usage_api_v1_ssh_keys__key_id__usage_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyUsageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ssh-keys/deploy":{"post":{"tags":["SSH Keys"],"summary":"Deploy key to server","description":"Deploy SSH public key to a server's authorized_keys","operationId":"deploy_ssh_key_api_v1_ssh_keys_deploy_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyDeployRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyDeployResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ssh-keys/rotate":{"post":{"tags":["SSH Keys"],"summary":"Rotate SSH key","description":"Rotate SSH key with zero-downtime across all servers","operationId":"rotate_ssh_key_api_v1_ssh_keys_rotate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyRotateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSHKeyRotateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/passkeys/register/options":{"post":{"tags":["Passkeys"],"summary":"Generate passkey registration options","description":"Generate WebAuthn registration options for the current user. Requires authentication.","operationId":"register_options_api_v1_auth_passkeys_register_options_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyRegisterOptionsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyRegisterOptionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/passkeys/register/verify":{"post":{"tags":["Passkeys"],"summary":"Verify passkey registration","description":"Verify the WebAuthn registration response and store the credential.","operationId":"register_verify_api_v1_auth_passkeys_register_verify_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyRegisterVerifyRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/passkeys/login/options":{"post":{"tags":["Passkeys"],"summary":"Generate passkey login options","description":"Generate WebAuthn authentication options. No authentication required.","operationId":"login_options_api_v1_auth_passkeys_login_options_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyLoginOptionsRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyLoginOptionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/passkeys/login/verify":{"post":{"tags":["Passkeys"],"summary":"Verify passkey login","description":"Verify the WebAuthn authentication response and return tokens.","operationId":"login_verify_api_v1_auth_passkeys_login_verify_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyLoginVerifyRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyLoginResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/passkeys":{"get":{"tags":["Passkeys"],"summary":"List user's passkeys","description":"Get all passkeys registered by the current user.","operationId":"list_passkeys_api_v1_auth_passkeys_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/auth/passkeys/{passkey_id}":{"put":{"tags":["Passkeys"],"summary":"Rename a passkey","description":"Update the name of a passkey.","operationId":"rename_passkey_api_v1_auth_passkeys__passkey_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"passkey_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Passkey Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyRenameRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Passkeys"],"summary":"Delete a passkey","description":"Remove a passkey from the current user's account.","operationId":"delete_passkey_api_v1_auth_passkeys__passkey_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"passkey_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Passkey Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PasskeyDeleteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dashboard/stats":{"get":{"tags":["Dashboard"],"summary":"Get Dashboard Stats","description":"Get aggregate dashboard statistics.\n\nReturns combined statistics for servers, backups, alerts,\ndeployments, and environments.\n\n**Access Control:**\n- Portal admins: Can view stats without organization context (platform-wide) OR with selected organization\n- Regular users: MUST have organization context via X-Organization-ID header\n\n**Response includes:**\n- Server health metrics (online/total, avg CPU/memory)\n- Backup status (compliance %, failures)\n- Active alerts by severity\n- Deployment status (running, queued, recent)\n- Environment counts by status and type","operationId":"get_dashboard_stats_api_v1_dashboard_stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DashboardStatsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dashboard/backups/compliance":{"get":{"tags":["Dashboard"],"summary":"Get Backup Compliance","description":"Get detailed backup compliance information.\n\nReturns environments without recent backups and failed backup details\nfor the dashboard backup compliance widget.\n\n**Response includes:**\n- Overall compliance percentage\n- Count of compliant/total environments\n- List of non-compliant environments with details\n- List of failed backups in last 24 hours","operationId":"get_backup_compliance_api_v1_dashboard_backups_compliance_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization ID (portal admins only)","title":"Organization Id"},"description":"Filter by organization ID (portal admins only)"},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupComplianceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/dashboard/environments/stats":{"get":{"tags":["Dashboard"],"summary":"Get Environment Stats","description":"Get environment statistics.\n\nReturns counts of environments by status and type for the\ndashboard environment status widget.\n\n**Response includes:**\n- Count by status (running, stopped, error, deploying, pending)\n- Total environments\n- Count by type (development, staging, production)","operationId":"get_environment_stats_api_v1_dashboard_environments_stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization ID (portal admins only)","title":"Organization Id"},"description":"Filter by organization ID (portal admins only)"},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentStats"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations":{"get":{"tags":["Migrations"],"summary":"List Migrations","description":"List migrations for an organization with pagination.\n\nRequires X-Organization-ID header. User membership validated by ValidatedOrgID dependency.","operationId":"list_migrations_api_v1_migrations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/MigrationStatus"},{"type":"null"}],"description":"Filter by status","title":"Status"},"description":"Filter by status"},{"name":"source_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by source type","title":"Source Type"},"description":"Filter by source type"},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":20,"title":"Page Size"},"description":"Items per page"},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Migrations"],"summary":"Create Migration","description":"Initialize a new migration.","operationId":"create_migration_api_v1_migrations_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationInitRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/storage-check":{"get":{"tags":["Migrations"],"summary":"Check Storage Health","description":"Check if organization's migration storage is healthy.","operationId":"check_storage_health_api_v1_migrations_storage_check_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}":{"get":{"tags":["Migrations"],"summary":"Get Migration","description":"Get detailed migration information.","operationId":"get_migration_api_v1_migrations__migration_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Migrations"],"summary":"Delete Migration","description":"Delete a migration record (and associated R2 data).","operationId":"delete_migration_api_v1_migrations__migration_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Delete Migration Api V1 Migrations  Migration Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/upload/init":{"post":{"tags":["Migrations"],"summary":"Init Upload","description":"Initialize file upload and get tier-specific instructions.","operationId":"init_upload_api_v1_migrations__migration_id__upload_init_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"file_name","in":"query","required":true,"schema":{"type":"string","description":"File name","title":"File Name"},"description":"File name"},{"name":"file_size","in":"query","required":true,"schema":{"type":"integer","minimum":1,"description":"File size in bytes","title":"File Size"},"description":"File size in bytes"},{"name":"checksum","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"SHA256 checksum","title":"Checksum"},"description":"SHA256 checksum"},{"name":"force_platform_r2","in":"query","required":false,"schema":{"type":"boolean","description":"Force upload to platform R2 storage","default":false,"title":"Force Platform R2"},"description":"Force upload to platform R2 storage"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadInitResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/upload/direct":{"post":{"tags":["Migrations"],"summary":"Upload Direct","description":"Handle Tier 1 direct file upload (< 50MB).","operationId":"upload_direct_api_v1_migrations__migration_id__upload_direct_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_direct_api_v1_migrations__migration_id__upload_direct_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Upload Direct Api V1 Migrations  Migration Id  Upload Direct Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/upload/chunk":{"post":{"tags":["Migrations"],"summary":"Upload Chunk","description":"Handle Tier 2 chunked upload.","operationId":"upload_chunk_api_v1_migrations__migration_id__upload_chunk_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"chunk_number","in":"query","required":true,"schema":{"type":"integer","minimum":0,"description":"Chunk number (0-indexed)","title":"Chunk Number"},"description":"Chunk number (0-indexed)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_chunk_api_v1_migrations__migration_id__upload_chunk_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChunkUploadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/upload/chunk/complete":{"post":{"tags":["Migrations"],"summary":"Complete Chunked Upload","description":"Complete Tier 2 chunked upload by assembling chunks.","operationId":"complete_chunked_upload_api_v1_migrations__migration_id__upload_chunk_complete_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Complete Chunked Upload Api V1 Migrations  Migration Id  Upload Chunk Complete Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/upload/complete":{"post":{"tags":["Migrations"],"summary":"Complete Multipart Upload","description":"Complete Tier 3/4 multipart upload.","operationId":"complete_multipart_upload_api_v1_migrations__migration_id__upload_complete_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MultipartCompleteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Complete Multipart Upload Api V1 Migrations  Migration Id  Upload Complete Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/check-url":{"post":{"tags":["Migrations"],"summary":"Check Migration Url","description":"Check a cloud URL's file size and recommend servers for large files.","operationId":"check_migration_url_api_v1_migrations__migration_id__check_url_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckUrlRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckUrlResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/import-url":{"post":{"tags":["Migrations"],"summary":"Import From Url","description":"Start import from cloud URL (Google Drive, Dropbox, direct URL).","operationId":"import_from_url_api_v1_migrations__migration_id__import_url_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudUrlImportRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Import From Url Api V1 Migrations  Migration Id  Import Url Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/neutralize":{"patch":{"tags":["Migrations"],"summary":"Update Migration Neutralize","description":"Update the neutralize setting on a migration.","operationId":"update_migration_neutralize_api_v1_migrations__migration_id__neutralize_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"neutralize","in":"query","required":false,"schema":{"type":"boolean","description":"Whether to neutralize the database after migration","default":true,"title":"Neutralize"},"description":"Whether to neutralize the database after migration"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/configure":{"post":{"tags":["Migrations"],"summary":"Configure Migration","description":"Configure migration target (VM, domain, etc.) before execution.","operationId":"configure_migration_api_v1_migrations__migration_id__configure_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationConfigureRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/start":{"post":{"tags":["Migrations"],"summary":"Start Migration","description":"Start the migration process (12-step deployment).","operationId":"start_migration_api_v1_migrations__migration_id__start_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Start Migration Api V1 Migrations  Migration Id  Start Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/progress":{"get":{"tags":["Migrations"],"summary":"Get Migration Progress","description":"Get current migration progress.","operationId":"get_migration_progress_api_v1_migrations__migration_id__progress_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationProgressUpdate"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/cancel":{"post":{"tags":["Migrations"],"summary":"Cancel Migration","description":"Cancel an in-progress migration.","operationId":"cancel_migration_api_v1_migrations__migration_id__cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Cancel Migration Api V1 Migrations  Migration Id  Cancel Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/retry":{"post":{"tags":["Migrations"],"summary":"Retry Migration","description":"Retry a failed migration.","operationId":"retry_migration_api_v1_migrations__migration_id__retry_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Retry Migration Api V1 Migrations  Migration Id  Retry Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/unlink-environment":{"post":{"tags":["Migrations"],"summary":"Unlink Environment","description":"Unlink environment from migration (discard environment, keep migration backup).\n\nThis allows users to discard a partially configured environment and start fresh\nwhile keeping the original migration backup data.","operationId":"unlink_environment_api_v1_migrations__migration_id__unlink_environment_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Unlink Environment Api V1 Migrations  Migration Id  Unlink Environment Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/analysis":{"get":{"tags":["Migrations"],"summary":"Get Migration Analysis","description":"Get backup analysis results.","operationId":"get_migration_analysis_api_v1_migrations__migration_id__analysis_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MigrationAnalysisResult"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/migrations/{migration_id}/available-vms":{"get":{"tags":["Migrations"],"summary":"Get Available Vms","description":"Get VMs available for this migration.","operationId":"get_available_vms_api_v1_migrations__migration_id__available_vms_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"migration_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Migration Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object"},"title":"Response Get Available Vms Api V1 Migrations  Migration Id  Available Vms Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/billing/plans":{"get":{"tags":["Billing"],"summary":"List Plans","description":"List all available subscription plans.\n\nReturns plan details including pricing, limits, and features.\nThis is a public endpoint (no auth required).","operationId":"list_plans_api_v1_billing_plans_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlanListResponse"}}}}}}},"/api/v1/billing/prices":{"get":{"tags":["Billing"],"summary":"Get Pricing","description":"Get current pricing for all products.\n\nIncludes base plans, BYOS server tiers, environment sizes, and add-ons.\nThis is a public endpoint (no auth required).","operationId":"get_pricing_api_v1_billing_prices_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PricingResponse"}}}}}}},"/api/v1/organizations/{organization_id}/billing/subscription":{"get":{"tags":["Billing"],"summary":"Get Subscription","description":"Get subscription details for an organization.\n\nRequires org.billing.view permission.","operationId":"get_subscription_api_v1_organizations__organization_id__billing_subscription_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/plan-features":{"get":{"tags":["Billing"],"summary":"Get Plan Features","description":"Get plan tier and feature availability for an organization.\n\nAccessible to ALL org members (no billing permission required).\nReturns current plan and feature flags without any billing amounts.","operationId":"get_plan_features_api_v1_organizations__organization_id__plan_features_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Plan Features Api V1 Organizations  Organization Id  Plan Features Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/summary":{"get":{"tags":["Billing"],"summary":"Get Billing Summary","description":"Get complete billing summary for an organization.\n\nIncludes subscription details, usage, costs, and billable items.\nRequires org.billing.view permission.","operationId":"get_billing_summary_api_v1_organizations__organization_id__billing_summary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BillingSummaryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/subscription/trial":{"post":{"tags":["Billing"],"summary":"Start Trial","description":"Start a 14-day trial with Professional features.\n\nRequires org.billing.manage permission.","operationId":"start_trial_api_v1_organizations__organization_id__billing_subscription_trial_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/subscription/upgrade":{"post":{"tags":["Billing"],"summary":"Upgrade Plan","description":"Upgrade subscription to a higher plan.\n\n- Takes effect immediately\n- Stripe handles proration\n- Quotas updated immediately\n\nRequires org.billing.manage permission.","operationId":"upgrade_plan_api_v1_organizations__organization_id__billing_subscription_upgrade_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlanChangeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/subscription/downgrade-impact":{"get":{"tags":["Billing"],"summary":"Get Downgrade Impact","description":"Assess what resources will be affected by downgrading to the target plan.\n\nReturns affected custom domains, replicas, PgBouncer, tuned postgres,\nand excess backup policies. Call this before confirming a downgrade\nso users understand the consequences.\n\nRequires org.billing.manage permission.","operationId":"get_downgrade_impact_api_v1_organizations__organization_id__billing_subscription_downgrade_impact_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"target_plan","in":"query","required":true,"schema":{"type":"string","title":"Target Plan"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DowngradeImpactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/subscription/downgrade":{"post":{"tags":["Billing"],"summary":"Downgrade Plan","description":"Downgrade subscription to a lower plan.\n\n- Scheduled for end of billing period\n- Usage validated against new limits\n- No immediate changes\n\nRequires org.billing.manage permission.","operationId":"downgrade_plan_api_v1_organizations__organization_id__billing_subscription_downgrade_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PlanChangeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/subscription/pause":{"post":{"tags":["Billing"],"summary":"Pause Subscription","description":"Pause subscription for up to 3 months.\n\n- Stops billing\n- Stops services\n- Preserves data\n- 6-month cooldown between pauses\n\nRequires org.billing.manage permission.","operationId":"pause_subscription_api_v1_organizations__organization_id__billing_subscription_pause_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionPauseRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/subscription/resume":{"post":{"tags":["Billing"],"summary":"Resume Subscription","description":"Resume a paused subscription.\n\nRequires org.billing.manage permission.","operationId":"resume_subscription_api_v1_organizations__organization_id__billing_subscription_resume_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/subscription/cancel":{"post":{"tags":["Billing"],"summary":"Cancel Subscription","description":"Cancel subscription.\n\nBy default, cancels at end of billing period.\nSet immediate=true for immediate cancellation (not recommended).\n\nRequires org.billing.manage permission.","operationId":"cancel_subscription_api_v1_organizations__organization_id__billing_subscription_cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionCancelRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/billing/policy-acceptance":{"post":{"tags":["Billing"],"summary":"Record Policy Acceptance","description":"Record the user's pre-checkout interstitial acceptance.\n\nReturns the ``policy_acceptance_id`` which the frontend MUST thread into\nthe subsequent ``POST /organizations/{org_id}/billing/checkout`` call.\nThe Stripe session metadata then carries it forward so webhook handlers\ncan stitch the audit log on ``checkout.session.completed``.\n\nBoth acknowledgments are required to be true — if either is false, the\ninterstitial UI should not have allowed submission and we reject here as\ndefense-in-depth (also serves as a clear server-side reason code for any\nfuture automation tests).\n\nCaptures IP + user-agent as forensic evidence for chargeback disputes.","operationId":"record_policy_acceptance_api_v1_billing_policy_acceptance_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PolicyAcceptanceCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PolicyAcceptanceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/checkout":{"post":{"tags":["Billing"],"summary":"Create Checkout Session","description":"Create a Stripe checkout session for subscription.\n\nReturns a URL to redirect the user to Stripe's hosted checkout page.\n\nRequires org.billing.manage permission.","operationId":"create_checkout_session_api_v1_organizations__organization_id__billing_checkout_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckoutSessionRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CheckoutSessionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/portal":{"post":{"tags":["Billing"],"summary":"Create Customer Portal Session","description":"Create a Stripe customer portal session.\n\nReturns a URL to redirect the user to Stripe's customer portal\nwhere they can manage payment methods, view invoices, etc.\n\nRequires org.billing.manage permission.","operationId":"create_customer_portal_session_api_v1_organizations__organization_id__billing_portal_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerPortalRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CustomerPortalResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/billing/items":{"get":{"tags":["Billing"],"summary":"List Billable Items","description":"List billable items for an organization.\n\nReturns all BYOS servers, platform environments, and add-ons\nthat are being billed.\n\nRequires org.billing.view permission.","operationId":"list_billable_items_api_v1_organizations__organization_id__billing_items_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"active_only","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Active Only"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BillableItemResponse"},"title":"Response List Billable Items Api V1 Organizations  Organization Id  Billing Items Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/webhooks/stripe":{"post":{"tags":["Webhooks"],"summary":"Stripe Webhook","description":"Handle incoming Stripe webhooks.\n\nProcesses subscription lifecycle events from Stripe:\n- checkout.session.completed: New subscription created\n- customer.subscription.updated: Subscription updated\n- customer.subscription.deleted: Subscription cancelled\n- invoice.paid: Invoice paid\n- invoice.payment_failed: Payment failed\n- customer.subscription.paused: Subscription paused\n- customer.subscription.resumed: Subscription resumed\n\nSecurity:\n- Validates webhook signature using Stripe webhook secret\n- Rejects invalid/missing signatures\n- Rate limited to 60 requests/minute\n- Idempotent via Redis-backed event ID deduplication (72h TTL)\n- Transactional: partial state is rolled back on processing errors","operationId":"stripe_webhook_api_v1_webhooks_stripe_post","parameters":[{"name":"Stripe-Signature","in":"header","required":false,"schema":{"type":"string","title":"Stripe-Signature"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/usage":{"get":{"tags":["Usage"],"summary":"Get Current Usage","description":"Get current billing period usage summary.\n\nReturns real-time usage metrics for the current billing period including:\n- CPU hours\n- Memory GB-hours\n- Storage GB average\n- Deployment count\n- Backup count\n- Active environment count\n\nRequires org.billing.view permission.","operationId":"get_current_usage_api_v1_organizations__organization_id__usage_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsageSummaryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/usage/history":{"get":{"tags":["Usage"],"summary":"Get Usage History","description":"Get historical usage data.\n\nReturns aggregated usage data for past periods.\nDefault: Last 30 days of daily aggregated data.\n\nRequires org.billing.view permission.","operationId":"get_usage_history_api_v1_organizations__organization_id__usage_history_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"period_type","in":"query","required":false,"schema":{"type":"string","pattern":"^(hourly|daily|monthly)$","default":"daily","title":"Period Type"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":30,"title":"Limit"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsageHistoryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/usage/forecast":{"get":{"tags":["Usage"],"summary":"Get Usage Forecast","description":"Get usage forecast for current billing period.\n\nProjects usage to end of period based on current trends.\nHelps predict final billing amount.\n\nRequires org.billing.view permission.","operationId":"get_usage_forecast_api_v1_organizations__organization_id__usage_forecast_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UsageForecastResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/usage":{"get":{"tags":["Usage"],"summary":"Get Environment Usage","description":"Get usage for a specific environment.\n\nReturns detailed usage metrics for a single environment.\nDefault: Current billing period.\n\nRequires org.billing.view permission.","operationId":"get_environment_usage_api_v1_environments__environment_id__usage_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"}},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentUsageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cleanup/organizations/{organization_id}/policy":{"get":{"tags":["cleanup"],"summary":"Get cleanup policy for organization","description":"Get cleanup policy settings. Creates default policy if none exists.","operationId":"get_cleanup_policy_api_v1_cleanup_organizations__organization_id__policy_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CleanupPolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["cleanup"],"summary":"Update cleanup policy","description":"Update cleanup policy settings for organization","operationId":"update_cleanup_policy_api_v1_cleanup_organizations__organization_id__policy_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CleanupPolicyUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CleanupPolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cleanup/vms/{vm_id}/cleanup-runs":{"get":{"tags":["cleanup"],"summary":"List cleanup runs for VM","description":"Get history of cleanup operations for a VM with pagination","operationId":"list_cleanup_runs_api_v1_cleanup_vms__vm_id__cleanup_runs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"description":"Page number","default":1,"title":"Page"},"description":"Page number"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Items per page","default":20,"title":"Limit"},"description":"Items per page"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CleanupRunListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cleanup/vms/{vm_id}/cleanup":{"post":{"tags":["cleanup"],"summary":"Trigger manual cleanup","description":"Manually trigger cleanup operation on a VM (queued for background execution)","operationId":"trigger_manual_cleanup_api_v1_cleanup_vms__vm_id__cleanup_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManualCleanupRequest"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CleanupRunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cleanup/vms/{vm_id}/cleanup/sync-config":{"post":{"tags":["cleanup"],"summary":"Sync cleanup config to server","description":"Queue task to sync cleanup configuration to server-side scripts","operationId":"sync_cleanup_config_api_v1_cleanup_vms__vm_id__cleanup_sync_config_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Sync Cleanup Config Api V1 Cleanup Vms  Vm Id  Cleanup Sync Config Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cleanup/vms/{vm_id}/disk-usage":{"get":{"tags":["cleanup"],"summary":"Get Docker disk usage for VM","description":"Get current Docker disk usage breakdown (images, containers, volumes, build cache)","operationId":"get_disk_usage_api_v1_cleanup_vms__vm_id__disk_usage_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DiskUsageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/webhooks/cleanup":{"post":{"tags":["webhooks"],"summary":"Receive cleanup results from server script","description":"Webhook endpoint for cleanup.sh script to report cleanup results","operationId":"receive_cleanup_webhook_api_v1_webhooks_cleanup_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Receive Cleanup Webhook Api V1 Webhooks Cleanup Post"}}}}}}},"/api/v1/webhooks/container-restart":{"post":{"tags":["webhooks"],"summary":"Receive container restart events from health check script","description":"Webhook endpoint for health-check.sh script to report container restarts","operationId":"receive_container_restart_webhook_api_v1_webhooks_container_restart_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Receive Container Restart Webhook Api V1 Webhooks Container Restart Post"}}}}}}},"/api/v1/webhooks/disk-alert":{"post":{"tags":["webhooks"],"summary":"Receive disk usage alerts from monitoring script","description":"Webhook endpoint for disk-monitor.sh script to report disk alerts","operationId":"receive_disk_alert_webhook_api_v1_webhooks_disk_alert_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Receive Disk Alert Webhook Api V1 Webhooks Disk Alert Post"}}}}}}},"/api/v1/postgres-optimization/environments/{environment_id}":{"get":{"tags":["postgres-optimization"],"summary":"Get Postgres Optimization","description":"Get PostgreSQL optimization configuration for an environment.\n\nReturns:\n- Automatic tier classification\n- PGTune configuration status\n- PgBouncer pool settings\n- Read replica status\n- Database connection parameters\n- Plan-based feature flags (pgbouncer, replica)","operationId":"get_postgres_optimization_api_v1_postgres_optimization_environments__environment_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PostgresOptimizationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/postgres-optimization/environments/{environment_id}/settings":{"put":{"tags":["postgres-optimization"],"summary":"Update Postgres Optimization Settings","description":"Update PostgreSQL optimization settings for an environment.\n\nAllows users to:\n- Override PostgreSQL version\n- Enable/disable PGTune optimization\n- Enable/disable PgBouncer connection pooling\n- Enable/disable read replica\n- Set the PgBouncer pool size by hand, or reset it to automatic (#1017)\n\nNote: Changes require redeployment to take effect.","operationId":"update_postgres_optimization_settings_api_v1_postgres_optimization_environments__environment_id__settings_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PostgresOptimizationSettingsRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PostgresOptimizationSettingsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/postgres-optimization/environments/{environment_id}/tier":{"get":{"tags":["postgres-optimization"],"summary":"Get Environment Tier","description":"Get automatic tier classification for an environment.\n\nReturns:\n- Detected tier (development/production/high_availability)\n- Optimization flags\n- Resource allocation\n- Tier description","operationId":"get_environment_tier_api_v1_postgres_optimization_environments__environment_id__tier_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TierInfoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/replicas":{"post":{"tags":["Replicas"],"summary":"Deploy Replica","description":"Deploy read replica for environment.\n\nCreates a PostgreSQL streaming replication replica that can handle read-only queries.\nRequires the environment to be in running or stopped state (not deploying/pending).\n\nArgs:\n    environment_id: Environment UUID\n    request: Deployment request with force_rebuild option\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    ReplicaDeployResponse with deployment status\n\nRaises:\n    HTTPException: If deployment fails or quota exceeded","operationId":"deploy_replica_api_v1_environments__environment_id__replicas_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReplicaDeployRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReplicaDeployResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Replicas"],"summary":"Remove Replica","description":"Remove read replica for environment.\n\nStops and removes the replica container, freeing up resources.\nPrimary database is not affected.\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    ReplicaDeployResponse with removal status\n\nRaises:\n    HTTPException: If removal fails or replica not deployed","operationId":"remove_replica_api_v1_environments__environment_id__replicas_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReplicaDeployResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/replicas/health":{"get":{"tags":["Replicas"],"summary":"Get Replica Health","description":"Get current health status of read replica.\n\nReturns replication lag metrics, connection status, and error details if unhealthy.\nUsed by monitoring dashboards and alert systems.\n\nArgs:\n    environment_id: Environment UUID\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    ReplicaHealthResponse with health metrics\n\nRaises:\n    HTTPException: If environment not found or access denied","operationId":"get_replica_health_api_v1_environments__environment_id__replicas_health_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReplicaHealthResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/replicas/rebuild":{"post":{"tags":["Replicas"],"summary":"Rebuild Replica","description":"Rebuild read replica from primary.\n\nRecreates the replica by re-syncing from the primary database.\nUseful when replica falls too far behind or encounters corruption.\n\nArgs:\n    environment_id: Environment UUID\n    request: Rebuild request with force option\n    db: Database session\n    current_user: Current authenticated user\n\nReturns:\n    ReplicaDeployResponse with rebuild status\n\nRaises:\n    HTTPException: If rebuild fails or replica not deployed","operationId":"rebuild_replica_api_v1_environments__environment_id__replicas_rebuild_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReplicaRebuildRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReplicaDeployResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/shared-servers":{"post":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"Create Shared Server","description":"Create a new portal-managed shared server.\n\nOnly portal admins can create shared servers. The server will be marked\nas shared and owned by the portal (organization_id=NULL).\n\nPermission required: portal.shared_servers.create","operationId":"create_shared_server_api_v1_portal_shared_servers_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SharedServerCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SharedServerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"List Shared Servers","description":"List all portal-managed shared servers with utilization metrics.\n\nReturns servers with allocation counts, organization counts, and utilization percentages.\nSupports filtering by status and capacity availability.\n\nPermission required: portal.shared_servers.view","operationId":"list_shared_servers_api_v1_portal_shared_servers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/VMStatus"},{"type":"null"}],"description":"Filter by status","title":"Status"},"description":"Filter by status"},{"name":"has_capacity","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Filter servers with available capacity","title":"Has Capacity"},"description":"Filter servers with available capacity"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SharedServerListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/shared-servers/{vm_id}":{"get":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"Get Shared Server","description":"Get details of a specific shared server.\n\nReturns full server configuration, utilization metrics, and allocation counts.\n\nPermission required: portal.shared_servers.view","operationId":"get_shared_server_api_v1_portal_shared_servers__vm_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SharedServerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"Update Shared Server","description":"Update a shared server's configuration.\n\nOnly metadata and capacity can be updated. Cannot change ownership or shared status.\n\nPermission required: portal.shared_servers.manage","operationId":"update_shared_server_api_v1_portal_shared_servers__vm_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SharedServerUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SharedServerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"Delete Shared Server","description":"Delete a shared server.\n\nCan only delete if there are no active allocations.\nEnvironments must be migrated or deleted before removing the server.\n\nPermission required: portal.shared_servers.manage","operationId":"delete_shared_server_api_v1_portal_shared_servers__vm_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/shared-servers/{vm_id}/allocations":{"get":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"Get Shared Server Allocations","description":"Get all allocations for a specific shared server.\n\nReturns list of organizations and their resource allocations on this server.\n\nPermission required: portal.shared_servers.view","operationId":"get_shared_server_allocations_api_v1_portal_shared_servers__vm_id__allocations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Portal Admin","Portal Admin - Allocations"],"summary":"Create Allocation","description":"Create a new allocation for an organization on a shared server.\n\nAllocates quota resources from a shared server to a specific organization.\nThe allocation defines limits for environments, CPU, RAM, and disk.\n\nPermission required: portal.shared_servers.allocate","operationId":"create_allocation_api_v1_portal_shared_servers__vm_id__allocations_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllocationCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllocationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/shared-servers/{vm_id}/test-connection":{"post":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"Test Connection","description":"Test SSH connection to a shared server.\n\nVerifies that SSH credentials work and detects server info.\nUpdates the shared server record with detected OS, hostname, and Docker status.\n\nPermission required: portal.shared_servers.manage","operationId":"test_connection_api_v1_portal_shared_servers__vm_id__test_connection_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/shared-servers/{vm_id}/utilization":{"get":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"Get Server Utilization","description":"Get detailed utilization breakdown for a shared server.\n\nShows per-organization usage, allocated vs physical capacity, and warnings.\nUseful for capacity planning and monitoring over-provisioning.\n\nPermission required: portal.shared_servers.view","operationId":"get_server_utilization_api_v1_portal_shared_servers__vm_id__utilization_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DetailedUtilizationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/shared-servers/{vm_id}/stats":{"get":{"tags":["Portal Admin","Portal Admin - Shared Servers"],"summary":"Get Shared Server Stats","description":"Get shared server resource statistics.\n\nReturns allocation counts, resource capacity, and utilization metrics.\nSimilar to BYOS server stats but for shared infrastructure.\n\nPermission required: portal.shared_servers.view","operationId":"get_shared_server_stats_api_v1_portal_shared_servers__vm_id__stats_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"vm_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Vm Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Shared Server Stats Api V1 Portal Shared Servers  Vm Id  Stats Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/allocations":{"get":{"tags":["Portal Admin","Portal Admin - Allocations"],"summary":"List All Allocations","description":"List all allocations across all shared servers.\n\nSupports filtering by organization, server, and active status.\nUseful for getting a global view of all allocations.\n\nPermission required: portal.shared_servers.view","operationId":"list_all_allocations_api_v1_portal_allocations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by organization","title":"Organization Id"},"description":"Filter by organization"},{"name":"vm_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by server","title":"Vm Id"},"description":"Filter by server"},{"name":"is_active","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Filter by active status","title":"Is Active"},"description":"Filter by active status"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"description":"Number of records","default":50,"title":"Limit"},"description":"Number of records"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Offset for pagination","default":0,"title":"Offset"},"description":"Offset for pagination"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllocationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/allocations/{allocation_id}":{"patch":{"tags":["Portal Admin","Portal Admin - Allocations"],"summary":"Update Allocation","description":"Modify an existing allocation.\n\nCan update quotas and expiration date without disrupting running environments.\nCannot change which server or organization the allocation belongs to.\n\nPermission required: portal.shared_servers.manage","operationId":"update_allocation_api_v1_portal_allocations__allocation_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"allocation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Allocation Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllocationUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllocationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Portal Admin","Portal Admin - Allocations"],"summary":"Revoke Allocation","description":"Revoke an allocation with optional grace period.\n\nMarks the allocation as inactive. If grace_period_days > 0, environments\ncontinue running until grace period ends. Otherwise, immediate suspension.\n\nPermission required: portal.shared_servers.revoke","operationId":"revoke_allocation_api_v1_portal_allocations__allocation_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"allocation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Allocation Id"}},{"name":"grace_period_days","in":"query","required":false,"schema":{"type":"integer","maximum":30,"minimum":0,"description":"Days before suspension","default":7,"title":"Grace Period Days"},"description":"Days before suspension"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllocationRevokeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/portal/allocations/expiring":{"get":{"tags":["Portal Admin","Portal Admin - Allocations"],"summary":"List Expiring Allocations","description":"List allocations expiring within the specified number of days.\n\nUseful for proactive management and sending renewal reminders.\nOnly includes active allocations with expiration dates.\n\nPermission required: portal.shared_servers.view","operationId":"list_expiring_allocations_api_v1_portal_allocations_expiring_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"days","in":"query","required":false,"schema":{"type":"integer","maximum":365,"minimum":1,"description":"Days until expiration","default":30,"title":"Days"},"description":"Days until expiration"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AllocationListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/supported":{"get":{"tags":["Cloud Providers"],"summary":"List Supported Providers","description":"List all supported cloud providers with their configuration.\n\nReturns provider information including auth type, setup steps, and regions.","operationId":"list_supported_providers_api_v1_cloud_providers_supported_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SupportedProvidersResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/connections":{"get":{"tags":["Cloud Providers"],"summary":"List Connections","description":"List cloud provider connections for an organization.\n\nRequires org membership.","operationId":"list_connections_api_v1_cloud_providers_connections_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Organization ID","title":"Organization Id"},"description":"Organization ID"},{"name":"provider","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/CloudProviderType"},{"type":"null"}],"description":"Filter by provider","title":"Provider"},"description":"Filter by provider"},{"name":"active_only","in":"query","required":false,"schema":{"type":"boolean","description":"Only show active connections","default":true,"title":"Active Only"},"description":"Only show active connections"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudConnectionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Cloud Providers"],"summary":"Create Api Key Connection","description":"Create a new cloud provider connection using API key.\n\nFor OAuth providers (DigitalOcean, Azure, GCP), use the OAuth flow instead.","operationId":"create_api_key_connection_api_v1_cloud_providers_connections_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Organization ID","title":"Organization Id"},"description":"Organization ID"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudConnectionCreateApiKey"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/connections/{connection_id}":{"get":{"tags":["Cloud Providers"],"summary":"Get Connection","description":"Get a specific cloud provider connection.","operationId":"get_connection_api_v1_cloud_providers_connections__connection_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Cloud Providers"],"summary":"Update Connection","description":"Update a cloud provider connection.\n\nCan update name, description, credentials, and status.","operationId":"update_connection_api_v1_cloud_providers_connections__connection_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudConnectionUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Cloud Providers"],"summary":"Delete Connection","description":"Delete a cloud provider connection.","operationId":"delete_connection_api_v1_cloud_providers_connections__connection_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/connections/{connection_id}/validate":{"post":{"tags":["Cloud Providers"],"summary":"Validate Connection","description":"Validate an existing connection's credentials.\n\nChecks if the credentials are still valid and updates the connection status.","operationId":"validate_connection_api_v1_cloud_providers_connections__connection_id__validate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionValidateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/validate":{"post":{"tags":["Cloud Providers"],"summary":"Validate New Credentials","description":"Validate new credentials before creating a connection.\n\nUseful for checking if credentials are valid without saving them.\nRequires org.cloud_providers.list permission.","operationId":"validate_new_credentials_api_v1_cloud_providers_validate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Organization ID (required for validating new credentials)","title":"Organization Id"},"description":"Organization ID (required for validating new credentials)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionValidateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionValidateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/oauth/authorize":{"post":{"tags":["Cloud Providers"],"summary":"Start Oauth Flow","description":"Start OAuth authorization flow for a cloud provider.\n\nReturns the authorization URL to redirect the user to.\nOnly for OAuth-supported providers (DigitalOcean, Azure, GCP).","operationId":"start_oauth_flow_api_v1_cloud_providers_oauth_authorize_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Organization ID","title":"Organization Id"},"description":"Organization ID"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/schemas__cloud_provider__OAuthAuthorizeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/schemas__cloud_provider__OAuthAuthorizeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/oauth/{provider}/callback":{"get":{"tags":["Cloud Providers"],"summary":"Oauth Callback","description":"Handle OAuth callback from cloud provider.\n\nThis endpoint receives the authorization code and exchanges it for tokens.\nRedirects to frontend with success/error status.","operationId":"oauth_callback_api_v1_cloud_providers_oauth__provider__callback_get","parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}},{"name":"code","in":"query","required":true,"schema":{"type":"string","description":"Authorization code","title":"Code"},"description":"Authorization code"},{"name":"state","in":"query","required":true,"schema":{"type":"string","description":"State token","title":"State"},"description":"State token"},{"name":"error","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error from provider","title":"Error"},"description":"Error from provider"},{"name":"error_description","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error description","title":"Error Description"},"description":"Error description"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/connections/{connection_id}/server-types":{"get":{"tags":["Cloud Providers"],"summary":"Get Server Types","description":"Get available server types/sizes from a cloud provider.\n\nReturns list of server types with specs and pricing.\nSupports filtering by CPU, RAM, and disk size.","operationId":"get_server_types_api_v1_cloud_providers_connections__connection_id__server_types_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"region","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by region","title":"Region"},"description":"Filter by region"},{"name":"min_vcpus","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"description":"Minimum CPU cores","title":"Min Vcpus"},"description":"Minimum CPU cores"},{"name":"max_vcpus","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":256},{"type":"null"}],"description":"Maximum CPU cores","title":"Max Vcpus"},"description":"Maximum CPU cores"},{"name":"min_memory_gb","in":"query","required":false,"schema":{"anyOf":[{"type":"number","minimum":0.5},{"type":"null"}],"description":"Minimum RAM in GB","title":"Min Memory Gb"},"description":"Minimum RAM in GB"},{"name":"max_memory_gb","in":"query","required":false,"schema":{"anyOf":[{"type":"number","maximum":2048.0},{"type":"null"}],"description":"Maximum RAM in GB","title":"Max Memory Gb"},"description":"Maximum RAM in GB"},{"name":"min_disk_gb","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"description":"Minimum disk in GB","title":"Min Disk Gb"},"description":"Minimum disk in GB"},{"name":"max_disk_gb","in":"query","required":false,"schema":{"anyOf":[{"type":"integer","maximum":10000},{"type":"null"}],"description":"Maximum disk in GB","title":"Max Disk Gb"},"description":"Maximum disk in GB"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Server Types Api V1 Cloud Providers Connections  Connection Id  Server Types Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/connections/{connection_id}/regions":{"get":{"tags":["Cloud Providers"],"summary":"Get Regions","description":"Get available regions from a cloud provider.\n\nReturns list of regions/datacenters.","operationId":"get_regions_api_v1_cloud_providers_connections__connection_id__regions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Regions Api V1 Cloud Providers Connections  Connection Id  Regions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/connections/{connection_id}/images":{"get":{"tags":["Cloud Providers"],"summary":"Get Images","description":"Get available OS images from a cloud provider.\n\nReturns list of OS images, with recommended images first.","operationId":"get_images_api_v1_cloud_providers_connections__connection_id__images_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"distribution","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by distribution (ubuntu, debian)","title":"Distribution"},"description":"Filter by distribution (ubuntu, debian)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Images Api V1 Cloud Providers Connections  Connection Id  Images Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/connections/{connection_id}/provision":{"post":{"tags":["Cloud Providers"],"summary":"Provision Server","description":"Provision a new server on a cloud provider (async).\n\nThis enqueues a background task to create a new server using the specified\ncloud provider connection. Progress is reported via SSE events with types:\n- server.provisioning_started\n- server.provisioning_progress\n- server.provisioning_completed\n- server.provisioning_failed\n\nAfter provisioning, the server_auto_fix task runs automatically to install\nDocker, Netdata, and configure the server.\n\nArgs:\n    connection_id: Cloud provider connection to use\n    server_name: Name for the new server\n    server_type: Provider's server type (e.g., \"s-1vcpu-1gb\", \"cx11\")\n    region: Provider's region (e.g., \"nyc1\", \"fsn1\")\n    image: Optional OS image override (wins over os_version)\n    os_version: Optional OS choice, e.g. \"26.04\" or \"debian-13\" (else provider default)\n\nReturns:\n    Response with job_id for tracking. Subscribe to SSE events for progress.","operationId":"provision_server_api_v1_cloud_providers_connections__connection_id__provision_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Organization ID","title":"Organization Id"},"description":"Organization ID"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProvisionServerRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProvisionServerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/ssh-keys":{"get":{"tags":["Cloud Providers"],"summary":"Get Platform Ssh Key","description":"Get the platform SSH key for an organization.\n\nReturns the public key and metadata. Use the download endpoint\nto get the private key for server access.","operationId":"get_platform_ssh_key_api_v1_cloud_providers_ssh_keys_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Organization ID","title":"Organization Id"},"description":"Organization ID"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Platform Ssh Key Api V1 Cloud Providers Ssh Keys Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-providers/ssh-keys/download":{"get":{"tags":["Cloud Providers"],"summary":"Download Platform Ssh Key","description":"Download the platform SSH private key for manual server access.\n\nSECURITY: This endpoint returns the decrypted private key.\nOnly users with server management permissions can access this.\nThe key should be saved securely and permissions set to 600.","operationId":"download_platform_ssh_key_api_v1_cloud_providers_ssh_keys_download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Organization ID","title":"Organization Id"},"description":"Organization ID"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Download Platform Ssh Key Api V1 Cloud Providers Ssh Keys Download Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/providers":{"get":{"tags":["Cloud Accounts"],"summary":"List Providers","description":"List all supported cloud providers with their capabilities and auth types.\n\nReturns provider information for UI display and account creation.","operationId":"list_providers_api_v1_cloud_accounts_providers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ProviderCapabilitiesResponse"},"type":"array","title":"Response List Providers Api V1 Cloud Accounts Providers Get"}}}}}}},"/api/v1/cloud-accounts/provider-mappings":{"get":{"tags":["Cloud Accounts"],"summary":"Get Provider Mappings","description":"Return the full provider-to-capability mapping table.\n\nThis is static configuration data that maps cloud account providers to\ntheir corresponding DNS and storage provider types. It also includes\ncredential field mappings and split-token provider warnings.\n\nNo authentication required - this is read-only reference data.","operationId":"get_provider_mappings_api_v1_cloud_accounts_provider_mappings_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderMappingResponse"}}}}}}},"/api/v1/cloud-accounts":{"get":{"tags":["Cloud Accounts"],"summary":"List Cloud Accounts","description":"List all cloud accounts for the organization.\n\nOptional filters:\n- provider: Filter by cloud provider type\n- capability: Filter by capability (compute, storage, dns)\n- is_active: Filter by active status","operationId":"list_cloud_accounts_api_v1_cloud_accounts_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"provider","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/CloudAccountProvider"},{"type":"null"}],"title":"Provider"}},{"name":"capability","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/CloudAccountCapability"},{"type":"null"}],"title":"Capability"}},{"name":"is_active","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudAccountList"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Cloud Accounts"],"summary":"Create Cloud Account","description":"Create a new cloud account.\n\nCredentials are encrypted before storage. The account status will be\nset to 'pending' until credentials are validated.","operationId":"create_cloud_account_api_v1_cloud_accounts_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudAccountCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudAccountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}":{"get":{"tags":["Cloud Accounts"],"summary":"Get Cloud Account","description":"Get a specific cloud account by ID.","operationId":"get_cloud_account_api_v1_cloud_accounts__account_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudAccountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Cloud Accounts"],"summary":"Update Cloud Account","description":"Update a cloud account.\n\nIf credentials are updated, the account status will be reset to 'pending'.","operationId":"update_cloud_account_api_v1_cloud_accounts__account_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudAccountUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudAccountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Cloud Accounts"],"summary":"Delete Cloud Account","description":"Delete a cloud account.\n\nWithout cascade (default):\n    - Fails with 400 Bad Request if dependencies exist\n    - User must remove dependencies first\n\nWith cascade=true:\n    - Unlinks compute connections (sets cloud_account_id to NULL)\n    - Deletes storage configurations that use this account\n    - Deletes DNS configurations that use this account\n    - Then deletes the cloud account","operationId":"delete_cloud_account_api_v1_cloud_accounts__account_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"cascade","in":"query","required":false,"schema":{"type":"boolean","description":"If true, delete all dependent configurations (storage, DNS). Compute connections will be unlinked but not deleted.","default":false,"title":"Cascade"},"description":"If true, delete all dependent configurations (storage, DNS). Compute connections will be unlinked but not deleted."},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/validate":{"post":{"tags":["Cloud Accounts"],"summary":"Validate Cloud Account","description":"Validate cloud account credentials.\n\nTests the credentials by making a simple API call to the provider.\nUpdates the account status based on the result.","operationId":"validate_cloud_account_api_v1_cloud_accounts__account_id__validate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Validate Cloud Account Api V1 Cloud Accounts  Account Id  Validate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/configurations":{"get":{"tags":["Cloud Accounts"],"summary":"Get Account Configurations","description":"Get all configurations linked to this cloud account.\n\nReturns counts and IDs of compute, storage, and DNS configurations.","operationId":"get_account_configurations_api_v1_cloud_accounts__account_id__configurations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Account Configurations Api V1 Cloud Accounts  Account Id  Configurations Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/deletion-impact":{"get":{"tags":["Cloud Accounts"],"summary":"Get Deletion Impact","description":"Get impact analysis before deleting a cloud account.\n\nReturns information about what will be affected if the account is deleted,\nincluding linked compute connections, storage configurations, and DNS configurations.","operationId":"get_deletion_impact_api_v1_cloud_accounts__account_id__deletion_impact_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeletionImpactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/oauth/authorize":{"post":{"tags":["Cloud Accounts"],"summary":"Start Oauth Flow","description":"Start OAuth authorization flow for a cloud provider.\n\nReturns the authorization URL to redirect the user to.\nOnly for OAuth-supported providers (DigitalOcean, Azure, GCP).","operationId":"start_oauth_flow_api_v1_cloud_accounts_oauth_authorize_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Organization ID","title":"Organization Id"},"description":"Organization ID"},{"name":"provider","in":"query","required":true,"schema":{"type":"string","description":"Cloud provider (digitalocean, azure, gcp)","title":"Provider"},"description":"Cloud provider (digitalocean, azure, gcp)"},{"name":"redirect_url","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Optional redirect URL after callback","title":"Redirect Url"},"description":"Optional redirect URL after callback"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Start Oauth Flow Api V1 Cloud Accounts Oauth Authorize Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/oauth/{provider}/callback":{"get":{"tags":["Cloud Accounts"],"summary":"Oauth Callback","description":"Handle OAuth callback from cloud provider.\n\nThis endpoint receives the authorization code and exchanges it for tokens.\nCreates a CloudAccount and redirects to frontend with success/error status.","operationId":"oauth_callback_api_v1_cloud_accounts_oauth__provider__callback_get","parameters":[{"name":"provider","in":"path","required":true,"schema":{"type":"string","title":"Provider"}},{"name":"code","in":"query","required":true,"schema":{"type":"string","description":"Authorization code","title":"Code"},"description":"Authorization code"},{"name":"state","in":"query","required":true,"schema":{"type":"string","description":"State token","title":"State"},"description":"State token"},{"name":"error","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error from provider","title":"Error"},"description":"Error from provider"},{"name":"error_description","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Error description","title":"Error Description"},"description":"Error description"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/oauth/gcp/pending/{pending_id}/candidates":{"get":{"tags":["Cloud Accounts"],"summary":"Get Gcp Pending Candidates","description":"Fetch the list of GCP projects available for selection after OAuth callback.\n\nCalled by the frontend project-picker page. Returns the candidate list\nsaved during the OAuth callback. Ownership is enforced by matching\n`current_user.id` against the `user_id` stamped into the pending payload\nat callback time.","operationId":"get_gcp_pending_candidates_api_v1_cloud_accounts_oauth_gcp_pending__pending_id__candidates_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pending_id","in":"path","required":true,"schema":{"type":"string","title":"Pending Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Gcp Pending Candidates Api V1 Cloud Accounts Oauth Gcp Pending  Pending Id  Candidates Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/oauth/gcp/pending/{pending_id}/finalize":{"post":{"tags":["Cloud Accounts"],"summary":"Finalize Gcp Pending","description":"Complete GCP OAuth by creating the cloud account with the chosen project_id.\n\nValidates that:\n  - The pending session exists and belongs to the current user.\n  - The chosen project_id is in the candidate list AND has status='ok'\n    (we don't allow users to pick iam_denied or billing_disabled projects;\n    they must resolve those issues in GCP first).","operationId":"finalize_gcp_pending_api_v1_cloud_accounts_oauth_gcp_pending__pending_id__finalize_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"pending_id","in":"path","required":true,"schema":{"type":"string","title":"Pending Id"}},{"name":"project_id","in":"query","required":true,"schema":{"type":"string","minLength":1,"maxLength":256,"title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloudAccountResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/compute-connection":{"post":{"tags":["Cloud Accounts"],"summary":"Get Or Create Compute Connection","description":"Get or create a CloudProviderConnection for this CloudAccount.\n\nThis endpoint bridges CloudAccounts (credentials) with CloudProviderConnections\n(compute configs). When a user selects a CloudAccount for provisioning,\nthis ensures a corresponding connection exists.\n\nReturns:\n    - connection_id: The ID of the (existing or newly created) connection\n    - created: Whether a new connection was created\n    - connection: Full connection details","operationId":"get_or_create_compute_connection_api_v1_cloud_accounts__account_id__compute_connection_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Or Create Compute Connection Api V1 Cloud Accounts  Account Id  Compute Connection Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/refresh-oauth":{"post":{"tags":["Cloud Accounts"],"summary":"Refresh Oauth Tokens","description":"Refresh OAuth tokens for a cloud account.\n\nOnly applicable for OAuth-authenticated accounts.","operationId":"refresh_oauth_tokens_api_v1_cloud_accounts__account_id__refresh_oauth_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Refresh Oauth Tokens Api V1 Cloud Accounts  Account Id  Refresh Oauth Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/gcp/change-project/start":{"post":{"tags":["Cloud Accounts"],"summary":"Start Gcp Change Project","description":"Start a \"change project\" flow for an existing GCP cloud account.\n\nLets the user pick a different GCP project without re-doing the Google\nOAuth dance. Reuses the customer's stored refresh token to build a fresh\ncandidate list, seeds a pending-OAuth record in Redis, and returns a\npending_id the frontend can use to open the existing picker page.\n\nAdded 2026-04-23 alongside B1/B2 so ops (and customers) can correct a\nwrong project_id without a full OAuth re-auth. Same picker UI — the only\ndifference is this endpoint seeds the pending record instead of the\nOAuth callback doing it.","operationId":"start_gcp_change_project_api_v1_cloud_accounts__account_id__gcp_change_project_start_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Start Gcp Change Project Api V1 Cloud Accounts  Account Id  Gcp Change Project Start Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/available-buckets":{"get":{"tags":["Cloud Accounts"],"summary":"Get Available Buckets","description":"List existing buckets from the cloud provider.\n\nRetrieves all available storage buckets from the cloud provider\nassociated with this account. Useful for selecting an existing\nbucket instead of creating a new one.\n\nFor Azure Blob Storage, the storage_account_name query parameter is required.\nFor Google Cloud Storage, the project_id query parameter is required if not stored in provider_config.\n\nOnly available for accounts with storage capability.","operationId":"get_available_buckets_api_v1_cloud_accounts__account_id__available_buckets_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"storage_account_name","in":"query","required":false,"schema":{"anyOf":[{"type":"string","minLength":3,"maxLength":24},{"type":"null"}],"description":"Azure storage account name. Required for Azure Blob Storage.","title":"Storage Account Name"},"description":"Azure storage account name. Required for Azure Blob Storage."},{"name":"project_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"GCP project ID. Required for Google Cloud Storage when not in provider_config.","title":"Project Id"},"description":"GCP project ID. Required for Google Cloud Storage when not in provider_config."},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailableBucketsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/create-bucket":{"post":{"tags":["Cloud Accounts"],"summary":"Create Bucket","description":"Create a new storage bucket with secure defaults.\n\nCreates a new bucket in the cloud provider and automatically creates\na corresponding StorageConfig record linked to this cloud account.\n\nSecure defaults applied:\n- AWS S3: Public access blocked, versioning enabled\n- Other providers: Provider-specific secure defaults\n\nOnly available for accounts with storage capability.","operationId":"create_bucket_api_v1_cloud_accounts__account_id__create_bucket_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBucketRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateBucketResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/available-zones":{"get":{"tags":["Cloud Accounts"],"summary":"Get Available Zones","description":"List available DNS zones from the cloud provider.\n\nRetrieves all available DNS zones from the cloud provider\nassociated with this account. This endpoint is used when setting up\nDNS configuration to select which zone/domain to manage.\n\nSupported providers:\n- AWS Route53: Lists all hosted zones\n- Cloudflare: Lists all zones\n- DigitalOcean: Lists all domains\n- Google Cloud DNS: Lists all managed zones\n- Azure DNS: Lists all zones in the configured resource group\n\nOnly available for accounts with DNS capability.","operationId":"get_available_zones_api_v1_cloud_accounts__account_id__available_zones_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailableZonesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/available-regions":{"get":{"tags":["Cloud Accounts"],"summary":"Get Available Regions","description":"List available storage regions from the cloud provider.\n\nRetrieves all available regions for creating storage buckets\nfrom the cloud provider associated with this account.\n\nSupported providers:\n- AWS: Lists all EC2 regions\n- Azure: Lists all subscription locations\n- GCP: Lists all Compute Engine regions\n- DigitalOcean: Lists all Spaces-enabled regions\n\nOnly available for accounts with storage capability.","operationId":"get_available_regions_api_v1_cloud_accounts__account_id__available_regions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailableRegionsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/azure/storage-accounts":{"get":{"tags":["Cloud Accounts"],"summary":"List Azure Storage Accounts","description":"List all Azure Storage Accounts in the subscription.\n\nReturns all storage accounts accessible with this Azure cloud account.\nOnly available for Azure accounts with storage capability.","operationId":"list_azure_storage_accounts_api_v1_cloud_accounts__account_id__azure_storage_accounts_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response List Azure Storage Accounts Api V1 Cloud Accounts  Account Id  Azure Storage Accounts Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Cloud Accounts"],"summary":"Create Azure Storage Account","description":"Create a new Azure Storage Account.\n\nCreates a new storage account in the Azure subscription with secure defaults:\n- Standard_LRS replication\n- StorageV2 kind\n- HTTPS only\n- TLS 1.2 minimum\n- Public blob access disabled\n\nOnly available for Azure accounts with storage capability.","operationId":"create_azure_storage_account_api_v1_cloud_accounts__account_id__azure_storage_accounts_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"name","in":"query","required":true,"schema":{"type":"string","minLength":3,"maxLength":24,"pattern":"^[a-z0-9]+$","description":"Globally unique storage account name (3-24 lowercase letters/numbers)","title":"Name"},"description":"Globally unique storage account name (3-24 lowercase letters/numbers)"},{"name":"location","in":"query","required":true,"schema":{"type":"string","minLength":1,"description":"Azure region (e.g., 'eastus', 'westeurope')","title":"Location"},"description":"Azure region (e.g., 'eastus', 'westeurope')"},{"name":"resource_group","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Resource group name. If not provided, a default will be created.","title":"Resource Group"},"description":"Resource group name. If not provided, a default will be created."},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Create Azure Storage Account Api V1 Cloud Accounts  Account Id  Azure Storage Accounts Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/azure/check-storage-name":{"get":{"tags":["Cloud Accounts"],"summary":"Check Azure Storage Account Name","description":"Check if an Azure Storage Account name is globally available.\n\nAzure storage account names are globally unique (across all Azure customers),\nso this lightweight check avoids a failed create attempt.\n\nReturns:\n    available: true/false/null (null = check failed, don't block the user)\n    reason: \"AlreadyExists\" | \"AccountNameInvalid\" | null\n    suggestion: alternative name if taken, null otherwise","operationId":"check_azure_storage_account_name_api_v1_cloud_accounts__account_id__azure_check_storage_name_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"name","in":"query","required":true,"schema":{"type":"string","minLength":3,"maxLength":24,"pattern":"^[a-z0-9]+$","description":"Storage account name to check availability for","title":"Name"},"description":"Storage account name to check availability for"},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Check Azure Storage Account Name Api V1 Cloud Accounts  Account Id  Azure Check Storage Name Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/gcp/projects":{"get":{"tags":["Cloud Accounts"],"summary":"List Gcp Projects","description":"List available GCP projects for an OAuth cloud account.\n\nReturns all active projects the user has access to, indicating which\nones have Compute Engine API enabled.\nOnly available for GCP accounts with OAuth authentication.","operationId":"list_gcp_projects_api_v1_cloud_accounts__account_id__gcp_projects_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response List Gcp Projects Api V1 Cloud Accounts  Account Id  Gcp Projects Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/cloud-accounts/{account_id}/available-services":{"get":{"tags":["Cloud Accounts"],"summary":"Get Available Services","description":"Return DNS and storage providers available for this cloud account.\n\nGiven a specific cloud account, returns which DNS and storage provider\ntypes can be set up using its credentials, including warnings for\nproviders that require separate tokens (e.g., Hetzner DNS).","operationId":"get_available_services_api_v1_cloud_accounts__account_id__available_services_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"account_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Account Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailableServicesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/ssh-keys":{"get":{"tags":["SSH Keys"],"summary":"List Ssh Keys","description":"List all server-specific SSH keys for an organization.\n\nReturns keys ordered by creation date (newest first).\nDoes not include the platform-wide auto-generated key.\n\nPermission: org.settings.view","operationId":"list_ssh_keys_api_v1_organizations__organization_id__ssh_keys_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerSSHKeyListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["SSH Keys"],"summary":"Create Ssh Key","description":"Create a new server-specific SSH key.\n\nGenerates a new Ed25519 keypair and encrypts the private key at rest.\nThe key can then be assigned to servers during provisioning.\n\nPermission: org.servers.create","operationId":"create_ssh_key_api_v1_organizations__organization_id__ssh_keys_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerSSHKeyCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerSSHKeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/ssh-keys/{key_id}":{"get":{"tags":["SSH Keys"],"summary":"Get Ssh Key","description":"Get details for a specific SSH key.\n\nReturns key metadata and public key, but NOT the private key.\nUse the download endpoint to retrieve the private key.\n\nPermission: org.settings.view","operationId":"get_ssh_key_api_v1_organizations__organization_id__ssh_keys__key_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerSSHKeyDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SSH Keys"],"summary":"Delete Ssh Key","description":"Delete a server-specific SSH key.\n\nFails if the key is currently in use by any servers.\nServers must be updated to use a different key before deletion.\n\nPermission: org.servers.delete","operationId":"delete_ssh_key_api_v1_organizations__organization_id__ssh_keys__key_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/ssh-keys/{key_id}/download":{"get":{"tags":["SSH Keys"],"summary":"Download Ssh Key","description":"Download the private key for a server SSH key.\n\nSECURITY: This endpoint returns the decrypted private key.\nOnly users with server management permissions can access this.\nThe key should be saved securely with permissions set to 600.\n\nPermission: org.servers.create","operationId":"download_ssh_key_api_v1_organizations__organization_id__ssh_keys__key_id__download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerSSHKeyDownloadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/ssh-keys/{key_id}/rotate":{"post":{"tags":["SSH Keys"],"summary":"Rotate Ssh Key","description":"Rotate a server SSH key.\n\nThis creates a new key with the same name (suffixed with '_rotated')\nand deactivates the old key. The old key is NOT deleted for audit purposes.\n\nAfter rotation, you must:\n1. Sync the new key to cloud providers if needed\n2. Update servers to use the new key\n3. Remove the old key from servers\n\nPermission: org.servers.create","operationId":"rotate_ssh_key_api_v1_organizations__organization_id__ssh_keys__key_id__rotate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServerSSHKeyRotateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/backup-policies":{"get":{"tags":["Organization Backup Policies"],"summary":"Get Org Backup Policies","description":"Get all backup policies for an organization.\n\nReturns policies for all environment types (development, staging, production).\nCreates default policies if they don't exist.","operationId":"get_org_backup_policies_api_v1_organizations__organization_id__backup_policies_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgBackupPoliciesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/backup-policies/reset-defaults":{"post":{"tags":["Organization Backup Policies"],"summary":"Reset Org Backup Policies","description":"Reset all backup policies to default values.\n\nReturns the reset policies.","operationId":"reset_org_backup_policies_api_v1_organizations__organization_id__backup_policies_reset_defaults_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgBackupPoliciesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/backup-policies/{environment_type}":{"get":{"tags":["Organization Backup Policies"],"summary":"Get Org Backup Policy","description":"Get backup policy for a specific environment type.\n\nArgs:\n    environment_type: One of: development, staging, production","operationId":"get_org_backup_policy_api_v1_organizations__organization_id__backup_policies__environment_type__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_type","in":"path","required":true,"schema":{"type":"string","title":"Environment Type"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgBackupPolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Organization Backup Policies"],"summary":"Update Org Backup Policy","description":"Update backup policy for a specific environment type.\n\nArgs:\n    environment_type: One of: development, staging, production\n    update_data: Fields to update","operationId":"update_org_backup_policy_api_v1_organizations__organization_id__backup_policies__environment_type__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_type","in":"path","required":true,"schema":{"type":"string","title":"Environment Type"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgBackupPolicyUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgBackupPolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/backup-policies/{environment_type}/environments":{"get":{"tags":["Organization Backup Policies"],"summary":"Get Environments Using Policy","description":"Get all environments using the organization's default policy for a given type.\n\nUseful for showing the impact of policy changes.","operationId":"get_environments_using_policy_api_v1_organizations__organization_id__backup_policies__environment_type__environments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_type","in":"path","required":true,"schema":{"type":"string","title":"Environment Type"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/EnvironmentPolicySourceResponse"},"title":"Response Get Environments Using Policy Api V1 Organizations  Organization Id  Backup Policies  Environment Type  Environments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/image-update-policy":{"get":{"tags":["Image Update Policy"],"summary":"Get Image Update Policy","description":"Return (or lazily create) the environment's image update policy.","operationId":"get_image_update_policy_api_v1_environments__environment_id__image_update_policy_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageUpdatePolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Image Update Policy"],"summary":"Update Image Update Policy","description":"Enable/disable auto image update and configure the schedule.\n\n``schedule_cron`` uses standard cron syntax (minute hour day month weekday).\nDefault: ``0 3 * * 0`` (Sunday 3 AM UTC).\n``run_module_upgrades`` controls whether ``odoo-bin -u all`` runs before\nthe container is recreated with the new image.","operationId":"update_image_update_policy_api_v1_environments__environment_id__image_update_policy_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageUpdatePolicyUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ImageUpdatePolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/image-update-policy/trigger":{"post":{"tags":["Image Update Policy"],"summary":"Trigger Image Update User","description":"Enqueue an immediate image update for this environment.\n\nRequires ``project.environments.deploy`` on the environment's project: it\nrecreates the container, so it is a deploy (#1018). Available on BYOS (customer-owned) servers\nas well as platform-managed ones: this endpoint IS the explicit human click,\nand #766 Phase 2 makes that the thing that distinguishes it from the hourly\ncron, which stays off BYOS. Returns 202 — the update runs in the background.","operationId":"trigger_image_update_user_api_v1_environments__environment_id__image_update_policy_trigger_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Trigger Image Update User Api V1 Environments  Environment Id  Image Update Policy Trigger Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/environments/{environment_id}/trigger-image-update":{"post":{"tags":["Admin - Image Update"],"summary":"Trigger Image Update","description":"Enqueue an immediate image update for this environment (portal admin only).\n\nOnly available for platform-managed (non-BYOS) environments.\nReturns 202 — the actual update runs in the background worker.","operationId":"trigger_image_update_api_v1_admin_environments__environment_id__trigger_image_update_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Trigger Image Update Api V1 Admin Environments  Environment Id  Trigger Image Update Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/external-database-connections":{"get":{"tags":["external-databases"],"summary":"List External Database Connections","description":"List external database connections for the organization.\n\nReturns active connections by default.  Pass ``include_inactive=true`` to\ninclude soft-deleted records (e.g. for an audit view).\n\nPermission: org.external_database.manage","operationId":"list_external_database_connections_api_v1_external_database_connections_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","description":"When true, also returns soft-deleted (is_active=False) connections.","default":false,"title":"Include Inactive"},"description":"When true, also returns soft-deleted (is_active=False) connections."},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExternalDatabaseConnectionListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["external-databases"],"summary":"Create External Database Connection","description":"Create a new external database connection.\n\nCredentials (admin password) are encrypted before storage using the same\nFernet pattern as CloudAccount.  The connection starts with\n``connection_status='untested'`` -- run the Phase 3 test endpoint to\nverify connectivity before attaching environments.\n\nPermission: org.external_database.manage","operationId":"create_external_database_connection_api_v1_external_database_connections_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExternalDatabaseConnectionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExternalDatabaseConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/external-database-connections/{connection_id}":{"get":{"tags":["external-databases"],"summary":"Get External Database Connection","description":"Retrieve a single external database connection by ID.\n\nReturns 404 when the connection does not exist or belongs to a different\norganization (prevents org enumeration).\n\nPermission: org.external_database.manage","operationId":"get_external_database_connection_api_v1_external_database_connections__connection_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExternalDatabaseConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["external-databases"],"summary":"Update External Database Connection","description":"Partially update an external database connection.\n\nOnly fields present in the payload are modified.  Sensitive fields\n(``admin_password``) are re-encrypted on update; the new value is NEVER\nrecorded in the audit log -- only the field *name* is noted.\n\nIf ``host`` or ``port`` changes the ``connection_status`` is reset to\n``untested`` (connection identity changed; customer must re-test).\n\nPermission: org.external_database.manage","operationId":"update_external_database_connection_api_v1_external_database_connections__connection_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExternalDatabaseConnectionUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExternalDatabaseConnectionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["external-databases"],"summary":"Delete External Database Connection","description":"Soft-delete an external database connection.\n\nSets ``is_active=False``; the row is retained for audit trail purposes.\nThe physical row is NOT removed.\n\nBlocked with HTTP 409 if any active environment still references this\nconnection.  The caller must detach (or delete) those environments first.\n\nPermission: org.external_database.manage","operationId":"delete_external_database_connection_api_v1_external_database_connections__connection_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/external-database-connections/{connection_id}/test":{"post":{"tags":["external-databases"],"summary":"Test Database Connection","description":"Run connectivity and privilege sub-tests against an external database connection.\n\nExecutes the sub-tests (SSRF/trust check, TCP/TLS+auth, privilege check,\nPgBouncer detection, version, replica) and records the outcome on the\nconnection row.\n\nWhere it runs (#1171), from the optional body:\n- ``vm_id``: on that server (one of the org's own; 403 otherwise).\n- ``all_env_servers``: on every server whose active environments use it.\n- ``from_platform``: from the platform.\n- nothing: the default test server, else env servers (up to 3), else the\n  platform. Servers run in parallel under a 60 s cap; the overall status\n  is the worst per-server status.\n- A server result that never reached the database (SSH failed, psql could\n  not run) is not a measurement and is left out of the worst-wins fold. If\n  no server reached it, the test falls back to the platform, which measures\n  a public host and leaves a private one's stored status alone.\n\nPersistence:\n- ``connection_status`` is updated to the overall result, except that a\n  platform test that could not test the host (private / unresolvable,\n  result UNTESTED) does not overwrite a status measured from a server.\n- ``last_tested_vm_id`` is the server the status was measured on (NULL for\n  the platform).\n- ``server_version`` is updated ONLY when the test retrieves one.\n- ``last_health_check_at`` / ``last_health_error`` follow the stored status.\n\nRate limit: 5 calls/minute per IP.\n\nPermission: org.external_database.manage","operationId":"test_database_connection_api_v1_external_database_connections__connection_id__test_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ConnectionTestRequest"},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/external-database-connections/{connection_id}/test-servers":{"get":{"tags":["external-databases"],"summary":"List Test Servers For Connection","description":"Servers a connection test may run on: the org's own (BYOS) servers (#1171).\n\nShared and demo servers are never listed. Each entry says how many active\nenvironments on that server use this connection, and which one is the\nconnection's default test server.\n\nPermission: org.external_database.manage","operationId":"list_test_servers_for_connection_api_v1_external_database_connections__connection_id__test_servers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"connection_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Connection Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TestServersResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/backup-policy-source":{"get":{"tags":["Environment Backup Policy Source"],"summary":"Get Environment Policy Source","description":"Get the backup policy source for an environment.\n\nShows whether the environment uses org_default or custom policy.","operationId":"get_environment_policy_source_api_v1_environments__environment_id__backup_policy_source_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentPolicySourceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Environment Backup Policy Source"],"summary":"Update Environment Policy Source","description":"Toggle environment's backup policy source between org_default and custom.\n\nWhen switching to 'custom' and no custom policy exists, one will need to be created.","operationId":"update_environment_policy_source_api_v1_environments__environment_id__backup_policy_source_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupPolicySourceUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EnvironmentPolicySourceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/backup-policy-source/effective":{"get":{"tags":["Environment Backup Policy Source"],"summary":"Get Effective Backup Policy","description":"Get the effective backup policy for an environment.\n\nResolves the policy based on the environment's backup_policy_source setting.","operationId":"get_effective_backup_policy_api_v1_environments__environment_id__backup_policy_source_effective_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EffectiveBackupPolicyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/departure/impact":{"get":{"tags":["Departure"],"summary":"Get Departure Impact","description":"Get the full impact report of departing.\n\nReturns information about all resources that will be affected:\n- Active environments\n- Backups and their storage\n- Cloud accounts\n- Git connections\n- DNS configurations\n- Team members\n- Billing status","operationId":"get_departure_impact_api_v1_departure_impact_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DepartureImpactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/departure/status":{"get":{"tags":["Departure"],"summary":"Get Departure Status","description":"Get current departure status.\n\nReturns the organization's departure state, grace period info,\nand export availability.","operationId":"get_departure_status_api_v1_departure_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DepartureStatusResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/departure/initiate":{"post":{"tags":["Departure"],"summary":"Initiate Departure","description":"Initiate the departure process.\n\nStarts a 30-day grace period during which:\n- You can still access and download your data\n- You can cancel the departure at any time\n- New deployments are blocked\n\nAfter the grace period, all resources will be permanently deleted.\n\nRequires typing the organization name to confirm.","operationId":"initiate_departure_api_v1_departure_initiate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InitiateDepartureRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DepartureInitiatedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/departure/cancel":{"post":{"tags":["Departure"],"summary":"Cancel Departure","description":"Cancel departure during grace period.\n\nRestores the organization to active status.\nOnly available during the grace period.","operationId":"cancel_departure_api_v1_departure_cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DepartureCancelledResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/departure/export":{"get":{"tags":["Departure"],"summary":"Get Export Download","description":"Get export download information.\n\nReturns the URL to download the data export (if available),\nalong with expiration and size information.","operationId":"get_export_download_api_v1_departure_export_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExportDownloadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/departure/admin/extend-grace-period":{"post":{"tags":["Departure"],"summary":"Extend Grace Period","description":"Extend grace period (admin only).\n\nAllows portal admins to extend the grace period for an organization\nthat has initiated departure.","operationId":"extend_grace_period_api_v1_departure_admin_extend_grace_period_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExtendGracePeriodRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GracePeriodExtendedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/departure/admin/force-purge":{"post":{"tags":["Departure"],"summary":"Force Purge","description":"Force purge an organization (admin only).\n\nImmediately begins cleanup without waiting for grace period.\nRequires typing 'FORCE PURGE' to confirm.\n\nThis is a destructive operation and cannot be undone.","operationId":"force_purge_api_v1_departure_admin_force_purge_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForcePurgeRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForcePurgeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/departure/audit-logs":{"get":{"tags":["Departure"],"summary":"List Departure Audit Logs","description":"List departure audit logs.\n\nReturns a paginated list of all departure-related actions.","operationId":"list_departure_audit_logs_api_v1_departure_audit_logs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","default":20,"title":"Per Page"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/teams":{"get":{"tags":["Teams"],"summary":"List Teams","description":"List all teams in an organization.\n\nReturns teams with member and project counts for display.\nRequires org.teams.list permission OR project.teams.manage permission on any project.\n\nThe fallback to project.teams.manage is necessary because project admins need to see\nwhich teams exist in order to assign them to their projects.","operationId":"list_teams_api_v1_organizations__organization_id__teams_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Teams"],"summary":"Create Team","description":"Create a new team in an organization.\n\nRequires org.teams.create permission.","operationId":"create_team_api_v1_organizations__organization_id__teams_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/teams/my-teams":{"get":{"tags":["Teams"],"summary":"Get My Teams","description":"Get teams the current user belongs to in this organization.\n\nUseful for filtering user's accessible projects.","operationId":"get_my_teams_api_v1_organizations__organization_id__teams_my_teams_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/teams/{team_id}":{"get":{"tags":["Teams"],"summary":"Get Team","description":"Get team details with members.\n\nRequires org.teams.list permission.","operationId":"get_team_api_v1_organizations__organization_id__teams__team_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamWithMembers"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Teams"],"summary":"Update Team","description":"Update team details.\n\nRequires org.teams.update permission.","operationId":"update_team_api_v1_organizations__organization_id__teams__team_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Teams"],"summary":"Delete Team","description":"Delete a team.\n\nThis will also remove all team memberships and project assignments.\nRequires org.teams.delete permission.","operationId":"delete_team_api_v1_organizations__organization_id__teams__team_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/teams/{team_id}/members":{"get":{"tags":["Teams"],"summary":"List Team Members","description":"List members of a team.\n\nRequires org.teams.list permission.","operationId":"list_team_members_api_v1_organizations__organization_id__teams__team_id__members_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamMemberListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Teams"],"summary":"Add Team Member","description":"Add a member to a team.\n\nThe user must be a member of the organization.\nRequires org.teams.update permission.","operationId":"add_team_member_api_v1_organizations__organization_id__teams__team_id__members_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamMemberCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamMemberResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/teams/{team_id}/members/{user_id}":{"delete":{"tags":["Teams"],"summary":"Remove Team Member","description":"Remove a member from a team.\n\nRequires org.teams.update permission.","operationId":"remove_team_member_api_v1_organizations__organization_id__teams__team_id__members__user_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"User Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/teams/{team_id}/projects":{"get":{"tags":["Teams"],"summary":"Get Team Project Details","description":"Get team details including all projects it has access to.\n\nThis is used to show warnings when adding users to teams that have\naccess to multiple projects (to avoid accidental broad access grants).\n\nRequires org.teams.list permission.","operationId":"get_team_project_details_api_v1_organizations__organization_id__teams__team_id__projects_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamWithProjectsDetail"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/templates":{"get":{"tags":["Deployment Templates"],"summary":"List Templates","description":"List active deployment templates for the catalog.","operationId":"list_templates_api_v1_templates_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"category","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by category","title":"Category"},"description":"Filter by category"},{"name":"odoo_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by Odoo version","title":"Odoo Version"},"description":"Filter by Odoo version"},{"name":"env_type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by environment type","title":"Env Type"},"description":"Filter by environment type"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search name/description","title":"Search"},"description":"Search name/description"},{"name":"featured","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Filter featured only","title":"Featured"},"description":"Filter featured only"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DeploymentTemplateListResponse"},"title":"Response List Templates Api V1 Templates Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/templates/{slug}":{"get":{"tags":["Deployment Templates"],"summary":"Get Template","description":"Get a deployment template by slug with its bundled repos.","operationId":"get_template_api_v1_templates__slug__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeploymentTemplateDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/teams":{"get":{"tags":["Project Teams"],"summary":"List Project Teams","description":"List teams assigned to a project.\n\nRequires project.view permission.","operationId":"list_project_teams_api_v1_projects__project_id__teams_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectTeamListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Project Teams"],"summary":"Assign Team To Project","description":"Assign a team to a project with a role.\n\nRequires project.teams.manage permission.","operationId":"assign_team_to_project_api_v1_projects__project_id__teams_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectTeamCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectTeamResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/teams/{team_id}":{"patch":{"tags":["Project Teams"],"summary":"Update Project Team Role","description":"Update a team's role on a project.\n\nRequires project.teams.manage permission.","operationId":"update_project_team_role_api_v1_projects__project_id__teams__team_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectTeamUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectTeamResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Project Teams"],"summary":"Unassign Team From Project","description":"Remove a team from a project.\n\nRequires project.teams.manage permission.","operationId":"unassign_team_from_project_api_v1_projects__project_id__teams__team_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"team_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Team Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/teams/members/list":{"get":{"tags":["Project Teams"],"summary":"List Project Members","description":"List all users with access to a project (flattened view).\n\nShows each user's effective role and which team(s) grant their access.\nIncludes organization owners who automatically have admin access.\n\nRequires project.view permission.","operationId":"list_project_members_api_v1_projects__project_id__teams_members_list_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectMemberListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/teams/members/quick-add":{"post":{"tags":["Project Teams"],"summary":"Quick Add User To Project","description":"Quickly add a user to a project.\n\nThis creates a dedicated team for the project+role combination (if needed)\nand adds the user to it. This is a convenience endpoint for the common case\nof wanting to give a single user access to a single project.\n\nThe team is auto-named as \"{ProjectName} {Role}s\" (e.g., \"MyProject Developers\").\n\nRequires project.teams.manage permission.","operationId":"quick_add_user_to_project_api_v1_projects__project_id__teams_members_quick_add_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuickAddUserRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuickAddUserResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/internal/wildcard-cert":{"get":{"tags":["internal"],"summary":"Get latest wildcard certificate","description":"Returns the active wildcard cert for server cert-fetch cron. Authenticated via Bearer token matching a VM's platform_api_token.","operationId":"get_wildcard_cert_api_v1_internal_wildcard_cert_get","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","description":"Bearer <platform_api_token>","title":"Authorization"},"description":"Bearer <platform_api_token>"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Wildcard Cert Api V1 Internal Wildcard Cert Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/internal/demo/v3/heartbeat":{"post":{"tags":["Demo v3 Internal"],"summary":"Heartbeat","operationId":"heartbeat_api_v1_internal_demo_v3_heartbeat_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HeartbeatRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Heartbeat Api V1 Internal Demo V3 Heartbeat Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/internal/vm-task-callback":{"post":{"tags":["internal"],"summary":"Receive a VM-runner task callback","description":"Progress/terminal callback from a detached oec-runner. Authenticated by a per-task hashed bearer token.","operationId":"vm_task_callback_api_v1_internal_vm_task_callback_post","parameters":[{"name":"authorization","in":"header","required":true,"schema":{"type":"string","description":"Bearer <OEC_CALLBACK_TOKEN>","title":"Authorization"},"description":"Bearer <OEC_CALLBACK_TOKEN>"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMTaskCallbackBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VMTaskCallbackResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/dev-mode":{"post":{"tags":["dev-mode"],"summary":"Enable Dev Mode","description":"Enable dev mode (AI coding sidecar) for a project.\n\nProvisions a dev sidecar container on the project's primary VM with\nClaude Code, Gemini CLI, and OpenAI Codex pre-installed.\n\nRequires the Pro plan or higher (ai_coding_enabled feature).","operationId":"enable_dev_mode_api_v1_projects__project_id__dev_mode_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["dev-mode"],"summary":"Disable Dev Mode","description":"Disable dev mode for a project.\n\nStops and removes the dev sidecar container. The project's home volume\nis preserved for future re-enablement.\n\nNo plan check — allows cleanup even after downgrade.","operationId":"disable_dev_mode_api_v1_projects__project_id__dev_mode_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Disable Dev Mode Api V1 Projects  Project Id  Dev Mode Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["dev-mode"],"summary":"Get Dev Mode Status","description":"Get dev mode status for a project.\n\nReturns whether dev mode is enabled, the container running state,\nand the list of mounted environments.","operationId":"get_dev_mode_status_api_v1_projects__project_id__dev_mode_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Dev Mode Status Api V1 Projects  Project Id  Dev Mode Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/dev-mode/refresh":{"post":{"tags":["dev-mode"],"summary":"Refresh Dev Mode Mounts","description":"Refresh dev mode mounts for a project.\n\nRestarts the sidecar container with updated volume mounts reflecting\nthe current set of environments on the VM. Use this after creating\nor destroying environments.","operationId":"refresh_dev_mode_mounts_api_v1_projects__project_id__dev_mode_refresh_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Refresh Dev Mode Mounts Api V1 Projects  Project Id  Dev Mode Refresh Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/dev-mode/logs":{"get":{"tags":["dev-mode"],"summary":"Get Dev Mode Logs","description":"Get dev mode deployment logs for a project.\n\nReturns log entries ordered by timestamp descending.\nOptionally filter by session_id to see logs from a single operation.","operationId":"get_dev_mode_logs_api_v1_projects__project_id__dev_mode_logs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"session_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by session","title":"Session Id"},"description":"Filter by session"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Dev Mode Logs Api V1 Projects  Project Id  Dev Mode Logs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/support/tickets":{"post":{"tags":["Support"],"summary":"Create Ticket","description":"Create a new support ticket.\n\nRequires X-Organization-ID header for org context. Ticket priority and\nSLA deadlines are auto-calculated from the organization's plan tier.\n\nRate limit: expected to be enforced via middleware.","operationId":"create_ticket_api_v1_support_tickets_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketResponseCustomer"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Support"],"summary":"List Tickets","description":"List support tickets for the current organization.\n\nPaginated and filterable by status, priority, category, and free-text search.\nRequires X-Organization-ID header.\n\nRate limit: expected to be enforced via middleware.","operationId":"list_tickets_api_v1_support_tickets_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"skip","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Pagination offset","default":0,"title":"Skip"},"description":"Pagination offset"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Pagination page size","default":20,"title":"Limit"},"description":"Pagination page size"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by ticket status","title":"Status"},"description":"Filter by ticket status"},{"name":"priority","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by priority","title":"Priority"},"description":"Filter by priority"},{"name":"category_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Filter by category ID","title":"Category Id"},"description":"Filter by category ID"},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Search subject and description","title":"Search"},"description":"Search subject and description"},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/support/tickets/{ticket_id}":{"get":{"tags":["Support"],"summary":"Get Ticket","description":"Get ticket detail for a customer.\n\nReturns ticket information with public comments only (internal notes\nare excluded). Requires X-Organization-ID header for org isolation.","operationId":"get_ticket_api_v1_support_tickets__ticket_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketResponseCustomer"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/support/tickets/{ticket_id}/comments":{"post":{"tags":["Support"],"summary":"Add Comment","description":"Add a public comment to a ticket.\n\nFor customer routes, is_internal is always forced to False regardless\nof the request payload. Customers cannot create internal notes.\n\nRate limit: expected to be enforced via middleware.","operationId":"add_comment_api_v1_support_tickets__ticket_id__comments_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketCommentCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TicketCommentResponsePublic"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/support/tickets/{ticket_id}/attachments":{"post":{"tags":["Support"],"summary":"Upload Attachment","description":"Upload a file attachment to a ticket.\n\nSaves the file to local storage and creates a TicketAttachment record.\nMax 10MB per file. Allowed types: images, PDF, text, CSV, ZIP, GZIP.","operationId":"upload_attachment_api_v1_support_tickets__ticket_id__attachments_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"comment_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Optional: link to specific comment","title":"Comment Id"},"description":"Optional: link to specific comment"},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_attachment_api_v1_support_tickets__ticket_id__attachments_post"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AttachmentUploadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/support/tickets/{ticket_id}/attachments/{attachment_id}/download":{"get":{"tags":["Support"],"summary":"Download Attachment","description":"Download a ticket attachment. Verifies ticket belongs to the user's organization.","operationId":"download_attachment_api_v1_support_tickets__ticket_id__attachments__attachment_id__download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"attachment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Attachment Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/support/tickets/{ticket_id}/rate":{"post":{"tags":["Support"],"summary":"Rate Ticket","description":"Submit a CSAT (customer satisfaction) rating for a resolved ticket.\n\nThe ticket must belong to the caller's organization; a CSAT token is\noptional and checked only when sent. Each ticket can only be rated once.","operationId":"rate_ticket_api_v1_support_tickets__ticket_id__rate_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}},{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CSATRatingRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Rate Ticket Api V1 Support Tickets  Ticket Id  Rate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/support/categories":{"get":{"tags":["Support"],"summary":"List Categories","description":"List active ticket categories.\n\nReturns only categories that are marked as active (is_active=True).\nUsed for ticket creation form dropdowns.","operationId":"list_categories_api_v1_support_categories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TicketCategoryResponse"},"title":"Response List Categories Api V1 Support Categories Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/automation-rules":{"get":{"tags":["automation-rules"],"summary":"List Automation Rules","description":"List all automation rules for a project, ordered by priority ascending.\n\nRequires org.projects.update permission.","operationId":"list_automation_rules_api_v1_projects__project_id__automation_rules_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["automation-rules"],"summary":"Create Automation Rule","description":"Create a new automation rule for a project.\n\nValidates that any environment IDs referenced in action_config belong to the project.\nRequires org.projects.update permission.","operationId":"create_automation_rule_api_v1_projects__project_id__automation_rules_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/automation-rules/{rule_id}":{"get":{"tags":["automation-rules"],"summary":"Get Automation Rule","description":"Get a single automation rule by ID.\n\nRequires org.projects.update permission.","operationId":"get_automation_rule_api_v1_projects__project_id__automation_rules__rule_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["automation-rules"],"summary":"Update Automation Rule","description":"Partially update an automation rule.\n\nOnly fields explicitly provided in the request body are modified.\nIf action_config is updated, env IDs are re-validated against the project.\nRequires org.projects.update permission.","operationId":"update_automation_rule_api_v1_projects__project_id__automation_rules__rule_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["automation-rules"],"summary":"Delete Automation Rule","description":"Delete an automation rule (hard delete).\n\nCascades to all associated run records via FK constraint.\nRequires org.projects.update permission.","operationId":"delete_automation_rule_api_v1_projects__project_id__automation_rules__rule_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/automation-rules/reorder":{"post":{"tags":["automation-rules"],"summary":"Reorder Automation Rules","description":"Bulk-update automation rule priorities for a project.\n\nValidates that all provided rule IDs belong to this project, then\nupdates their priority values in a single batch operation.\nRequires org.projects.update permission.","operationId":"reorder_automation_rules_api_v1_projects__project_id__automation_rules_reorder_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleReorderRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleReorderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/automation-rules/{rule_id}/toggle":{"patch":{"tags":["automation-rules"],"summary":"Toggle Automation Rule","description":"Toggle the is_active state of an automation rule.\n\nWhen enabling a previously-disabled rule, the consecutive failure counter\nand disabled_reason are reset so the circuit breaker starts fresh.\nRequires org.projects.update permission.","operationId":"toggle_automation_rule_api_v1_projects__project_id__automation_rules__rule_id__toggle_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/automation-rules/{rule_id}/run":{"post":{"tags":["automation-rules"],"summary":"Trigger Automation Rule","description":"Manually trigger an automation rule.\n\nOnly active rules with trigger_type=MANUAL may be triggered via this endpoint.\nDelegates execution entirely to AutomationRuleService.execute_rule, which\nhandles the PENDING→RUNNING→COMPLETED/FAILED lifecycle, audit log, SSE and\nwebhook events.\nRequires org.projects.update permission.","operationId":"trigger_automation_rule_api_v1_projects__project_id__automation_rules__rule_id__run_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleRunResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/automation-rules/{rule_id}/runs":{"get":{"tags":["automation-rules"],"summary":"List Rule Runs","description":"List execution runs for a specific automation rule.\n\nReturns runs ordered by started_at descending (most recent first).\nRequires org.projects.update permission.","operationId":"list_rule_runs_api_v1_projects__project_id__automation_rules__rule_id__runs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleRunListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/automation-rules/{rule_id}/rollback":{"post":{"tags":["automation-rules"],"summary":"Rollback Automation Rule","description":"Rollback the most recent run of an automation rule.\n\nNot yet implemented — will be wired in a future sprint.","operationId":"rollback_automation_rule_api_v1_projects__project_id__automation_rules__rule_id__rollback_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"rule_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rule Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"501":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/projects/{project_id}/automation-rule-runs":{"get":{"tags":["automation-rules"],"summary":"List Project Automation Runs","description":"List all automation rule runs across all rules for a project.\n\nReturns runs ordered by started_at descending (most recent first).\nRequires org.projects.update permission.","operationId":"list_project_automation_runs_api_v1_projects__project_id__automation_rule_runs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AutomationRuleRunListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/changelog":{"get":{"tags":["changelog"],"summary":"Get Changelog","description":"Return changelog entries, newest first (no internal changes).","operationId":"get_changelog_api_v1_changelog_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":10,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"since_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":20,"pattern":"^[vV]?\\d{1,4}(\\.\\d{1,4}){0,3}$"},{"type":"null"}],"description":"Only releases newer than this version (exclusive), e.g. 1.53.20.","title":"Since Version"},"description":"Only releases newer than this version (exclusive), e.g. 1.53.20."},{"name":"since_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"description":"Only releases on or after this date (YYYY-MM-DD).","title":"Since Date"},"description":"Only releases on or after this date (YYYY-MM-DD)."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/changelog/latest":{"get":{"tags":["changelog"],"summary":"Get Latest Version","description":"Return the latest version info.","operationId":"get_latest_version_api_v1_changelog_latest_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v1/banners/active":{"get":{"tags":["Banners"],"summary":"Get Active Banners","description":"Get currently active announcement banners for the authenticated user.","operationId":"get_active_banners_api_v1_banners_active_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Active Banners Api V1 Banners Active Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/checkout/recover":{"get":{"tags":["Checkout Recovery"],"summary":"Recover Checkout","description":"Validate recovery token and create new Stripe checkout session.\n\nPublic endpoint -- the JWT token IS the authentication.\nRate limited to 5/minute.","operationId":"recover_checkout_api_v1_checkout_recover_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","description":"Signed JWT recovery token","title":"Token"},"description":"Signed JWT recovery token"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/checkout/banner":{"get":{"tags":["Checkout Recovery"],"summary":"Get Recovery Banner","description":"Check if user has an expired checkout session for recovery banner.\n\nReturns banner info if there's an expired checkout within last 7 days.","operationId":"get_recovery_banner_api_v1_checkout_banner_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BannerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/email/preferences":{"get":{"tags":["Email Preferences"],"summary":"Get Email Preferences","description":"Get email preferences for a user via unsubscribe token.","operationId":"get_email_preferences_api_v1_email_preferences_get","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","description":"Unsubscribe token","title":"Token"},"description":"Unsubscribe token"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailPreferencesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Email Preferences"],"summary":"Update Email Preferences","description":"Update email preferences (unsubscribe from lifecycle emails).","operationId":"update_email_preferences_api_v1_email_preferences_post","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailPreferencesUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/email/unsubscribe":{"post":{"tags":["Email Preferences"],"summary":"One Click Unsubscribe","description":"RFC 8058 one-click unsubscribe (#1184).\n\nMail clients (Gmail, Outlook, Apple Mail) show an \"Unsubscribe\" button for\n``List-Unsubscribe-Post: List-Unsubscribe=One-Click`` and POST to the HTTPS\nURL in ``List-Unsubscribe``. That URL used to be the web page (newsletter) or\na mailto only (platform emails), so the button did nothing. POST only: a GET\nhere would let link scanners in mail security filters unsubscribe people.","operationId":"one_click_unsubscribe_api_v1_email_unsubscribe_post","parameters":[{"name":"token","in":"query","required":true,"schema":{"type":"string","description":"Unsubscribe token","title":"Token"},"description":"Unsubscribe token"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/email/preferences/me":{"get":{"tags":["Email Preferences"],"summary":"Get My Email Preferences","description":"Get current user's email preferences (authenticated).","operationId":"get_my_email_preferences_api_v1_email_preferences_me_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailPreferencesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Email Preferences"],"summary":"Update My Email Preferences","description":"Update current user's email preferences (authenticated, from settings page).","operationId":"update_my_email_preferences_api_v1_email_preferences_me_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthenticatedPreferencesUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailPreferencesResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/mailtest/img-proxy":{"get":{"tags":["Mailtest Image Proxy"],"summary":"SSRF-hardened image proxy for captured-email HTML bodies","description":"Fetches a remote image server-side after enforcing scheme / IP / content-type / size / redirect rules from spec §12. Used by the captured-email HTML preview so operator browsers never hit the sender's infrastructure.","operationId":"img_proxy_api_v1_mailtest_img_proxy_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"src","in":"query","required":true,"schema":{"type":"string","description":"Original image URL as it appeared in the captured HTML.","title":"Src"},"description":"Original image URL as it appeared in the captured HTML."},{"name":"msg","in":"query","required":true,"schema":{"type":"string","format":"uuid","description":"Captured message ID — must belong to an org the caller can view.","title":"Msg"},"description":"Captured message ID — must belong to an org the caller can view."},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/status":{"get":{"tags":["mailtest"],"summary":"Get the mailtest credential state for an environment","description":"Return the credential row + computed counters, or ``None``.\n\n``None`` means mailtest has never been enabled on this env. UI uses\nthat to show the \"Enable Mailtest\" CTA.","operationId":"get_mailtest_status_api_v1_environments__environment_id__mailtest_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/MailtestEnvStatusResponse"},{"type":"null"}],"title":"Response Get Mailtest Status Api V1 Environments  Environment Id  Mailtest Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/enable":{"post":{"tags":["mailtest"],"summary":"Enable mailtest on an environment; returns SMTP credentials ONCE","description":"Enable mailtest. Rejects production envs, deploying envs, plans\nwithout the feature, and DPA-signer orgs missing Exhibit M (§29.2).","operationId":"enable_mailtest_api_v1_environments__environment_id__mailtest_enable_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestEnableResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/disable":{"post":{"tags":["mailtest"],"summary":"Disable mailtest; captured messages stay for plan retention","description":"Disable mailtest on the env. Captured messages are NOT deleted.","operationId":"disable_mailtest_api_v1_environments__environment_id__mailtest_disable_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestDisableResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/rotate-credential":{"post":{"tags":["mailtest"],"summary":"Rotate the SMTP password; new plaintext shown ONCE","description":"Rotate the credential. Customer must update Odoo ir.mail_server.\n\nThe new plaintext is the ONLY copy — server-side we store only the\nargon2id hash. Subsequent GETs cannot retrieve it.","operationId":"rotate_mailtest_credential_api_v1_environments__environment_id__mailtest_rotate_credential_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestRotationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/abort-rotation":{"post":{"tags":["mailtest"],"summary":"Admin recovery — clear a stuck rotation flag","description":"Admin-only path for when the Odoo-side rotation failed and left\n``is_rotating=true`` on the credential. Clears the flag so SMTP AUTH\nresumes using the prior password.","operationId":"abort_mailtest_rotation_api_v1_environments__environment_id__mailtest_abort_rotation_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestAbortRotationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/odoo-config-status":{"get":{"tags":["mailtest"],"summary":"On-demand tamper + Odoo-side config verification","description":"Verify marker row + smtp_host on the customer's Odoo DB.\n\nBacks the settings panel's \"View Odoo config status\" button\n(Day 8 stubbed this endpoint). Calls into Day 2's\n``MailtestService.verify_tamper`` path rather than duplicating\nthe SSH plumbing.\n\nReturns ``approach``, ``marker_row_present`` + ``marker_row_active``,\n``smtp_host_matches``, ``expected_smtp_host``, ``actual_smtp_host``,\nand (Approach D only) a list of customer rows with their active +\nsmtp_host fields so admins can see drift at a glance.","operationId":"get_odoo_config_status_api_v1_environments__environment_id__mailtest_odoo_config_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Odoo Config Status Api V1 Environments  Environment Id  Mailtest Odoo Config Status Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/export":{"post":{"tags":["mailtest"],"summary":"Export an environment's captured mailtest inbox as a .zip","description":"Enqueue an async .zip export for the env's captured mail.\n\nRuns on the background queue. The result email contains a 7-day\nsigned URL. Poll via ``GET /environments/{id}/mailtest/exports/{id}``.","operationId":"export_env_inbox_api_v1_environments__environment_id__mailtest_export_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Export Env Inbox Api V1 Environments  Environment Id  Mailtest Export Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/exports/{export_id}":{"get":{"tags":["mailtest"],"summary":"Poll an export job's status","description":"Redis-backed poll. Returns queued / running / ready / failed.","operationId":"get_env_export_status_api_v1_environments__environment_id__mailtest_exports__export_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"export_id","in":"path","required":true,"schema":{"type":"string","title":"Export Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Env Export Status Api V1 Environments  Environment Id  Mailtest Exports  Export Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/messages":{"get":{"tags":["mailtest"],"summary":"List captured messages for an environment (cursor-paginated)","operationId":"list_env_messages_api_v1_environments__environment_id__mailtest_messages_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Opaque cursor from a previous response","title":"Cursor"},"description":"Opaque cursor from a previous response"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"description":"Case-insensitive subject substring (GIN-backed)","title":"Search"},"description":"Case-insensitive subject substring (GIN-backed)"},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestMessageListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/messages/{message_id}":{"get":{"tags":["mailtest"],"summary":"Full detail view for a captured message","operationId":"get_env_message_detail_api_v1_environments__environment_id__mailtest_messages__message_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"message_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Message Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestMessageDetailResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["mailtest"],"summary":"Soft-delete a captured message","operationId":"delete_env_message_api_v1_environments__environment_id__mailtest_messages__message_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"message_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Message Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/messages/{message_id}/attachments/{part_index}":{"get":{"tags":["mailtest"],"summary":"Download a single attachment from a captured message","operationId":"download_env_message_attachment_api_v1_environments__environment_id__mailtest_messages__message_id__attachments__part_index__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"message_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Message Id"}},{"name":"part_index","in":"path","required":true,"schema":{"type":"integer","title":"Part Index"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/messages/{message_id}/raw":{"get":{"tags":["mailtest"],"summary":"Download the raw .eml of a captured message","operationId":"download_env_message_raw_api_v1_environments__environment_id__mailtest_messages__message_id__raw_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"message_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Message Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/messages/{message_id}/read":{"patch":{"tags":["mailtest"],"summary":"Mark a message read or unread","operationId":"set_message_read_state_api_v1_environments__environment_id__mailtest_messages__message_id__read_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"message_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Message Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestMessageReadRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Set Message Read State Api V1 Environments  Environment Id  Mailtest Messages  Message Id  Read Patch"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/messages/bulk-mark":{"post":{"tags":["mailtest"],"summary":"Mark many messages read or unread in one call","operationId":"bulk_mark_read_state_api_v1_environments__environment_id__mailtest_messages_bulk_mark_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestBulkMarkReadRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Bulk Mark Read State Api V1 Environments  Environment Id  Mailtest Messages Bulk Mark Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/messages/bulk-delete":{"post":{"tags":["mailtest"],"summary":"Soft-delete many captured messages in one call","operationId":"bulk_delete_messages_api_v1_environments__environment_id__mailtest_messages_bulk_delete_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestBulkDeleteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Bulk Delete Messages Api V1 Environments  Environment Id  Mailtest Messages Bulk Delete Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/environments/{environment_id}/mailtest/clear":{"post":{"tags":["mailtest"],"summary":"Bulk soft-delete all captured messages for this env","operationId":"clear_env_inbox_api_v1_environments__environment_id__mailtest_clear_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestClearResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/mailtest/export":{"post":{"tags":["mailtest"],"summary":"Export all captured mailtest emails across the organisation","description":"Cross-env export — used by the plan-downgrade grace banner.","operationId":"export_org_inbox_api_v1_organizations__organization_id__mailtest_export_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Export Org Inbox Api V1 Organizations  Organization Id  Mailtest Export Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/mailtest/exports/{export_id}":{"get":{"tags":["mailtest"],"summary":"Poll an org-wide export job's status","description":"Same shape as the env-scoped poll; scope is implied by the route.","operationId":"get_org_export_status_api_v1_organizations__organization_id__mailtest_exports__export_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"export_id","in":"path","required":true,"schema":{"type":"string","title":"Export Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Get Org Export Status Api V1 Organizations  Organization Id  Mailtest Exports  Export Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/mailtest/messages":{"get":{"tags":["mailtest"],"summary":"List captured messages across every env in the org the user can view","operationId":"list_org_messages_api_v1_organizations__organization_id__mailtest_messages_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cursor"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":200,"minimum":1,"default":50,"title":"Limit"}},{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Search"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestMessageListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/mailtest/usage":{"get":{"tags":["mailtest"],"summary":"Org-wide mailtest usage counters + plan caps","operationId":"get_org_usage_api_v1_organizations__organization_id__mailtest_usage_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MailtestOrgStateResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/me/announcements/mark-seen":{"post":{"tags":["mailtest"],"summary":"Mark an in-app announcement as dismissed for the current user","operationId":"mark_announcement_seen_api_v1_me_announcements_mark_seen_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnouncementMarkSeenRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnouncementSeenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/me/announcements/unseen":{"get":{"tags":["mailtest"],"summary":"Return the keys of announcements the current user hasn't dismissed","description":"Return the set of live announcement keys the user hasn't dismissed.\n\nThe live set is sourced from ``settings.mailtest.live_announcement_keys``\nso ops can flip it via env var without a code deploy.","operationId":"list_unseen_announcements_api_v1_me_announcements_unseen_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AnnouncementUnseenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/orgs":{"get":{"tags":["admin-mailtest"],"summary":"Top-N orgs ranked by message count / bytes / cap % / AUTH-fail rate","operationId":"list_admin_orgs_api_v1_admin_mailtest_orgs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"sort","in":"query","required":false,"schema":{"type":"string","pattern":"^(messages|bytes|cap_pct|auth_fail)$","default":"messages","title":"Sort"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminOrgsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/orgs/{organization_id}/envs":{"get":{"tags":["admin-mailtest"],"summary":"Per-org drill-down of mailtest envs","operationId":"list_admin_org_envs_api_v1_admin_mailtest_orgs__organization_id__envs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AdminEnvRow"},"title":"Response List Admin Org Envs Api V1 Admin Mailtest Orgs  Organization Id  Envs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/killswitch":{"get":{"tags":["admin-mailtest"],"summary":"Current platform-wide Mailtest kill-switch state","operationId":"get_killswitch_api_v1_admin_mailtest_killswitch_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/KillSwitchStatus"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["admin-mailtest"],"summary":"Activate or deactivate the platform-wide Mailtest kill switch","operationId":"toggle_killswitch_api_v1_admin_mailtest_killswitch_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/KillSwitchAction"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/KillSwitchStatus"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/overview/service-health":{"get":{"tags":["admin-mailtest"],"summary":"Service-health snapshot for mailtest-smtp + spamc + queue + R2 uploads","description":"Lightweight health probe for all mailtest-facing services.\n\nThis is a best-effort snapshot: any individual signal that can't be\nread (Redis wobble, spamc unreachable) is reported as \"unknown\"\nrather than failing the whole endpoint — the admin UI renders each\ntile independently.","operationId":"overview_service_health_api_v1_admin_mailtest_overview_service_health_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Overview Service Health Api V1 Admin Mailtest Overview Service Health Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/overview/adoption":{"get":{"tags":["admin-mailtest"],"summary":"Adoption rollup — enabled envs / orgs + plan split + capture counts","operationId":"overview_adoption_api_v1_admin_mailtest_overview_adoption_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Overview Adoption Api V1 Admin Mailtest Overview Adoption Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/overview/storage":{"get":{"tags":["admin-mailtest"],"summary":"Storage totals + near-cap orgs + grace list + cron-run status","operationId":"overview_storage_api_v1_admin_mailtest_overview_storage_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Overview Storage Api V1 Admin Mailtest Overview Storage Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/overview/security":{"get":{"tags":["admin-mailtest"],"summary":"Security posture — rotations / tamper / IP bans / DPA coverage","operationId":"overview_security_api_v1_admin_mailtest_overview_security_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Overview Security Api V1 Admin Mailtest Overview Security Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/overview/deliverability":{"get":{"tags":["admin-mailtest"],"summary":"Fleet deliverability rollup — avg score + auth pass rates + top-10 issues (30 d)","operationId":"overview_deliverability_api_v1_admin_mailtest_overview_deliverability_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Overview Deliverability Api V1 Admin Mailtest Overview Deliverability Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/admin/mailtest/overview/timeseries":{"get":{"tags":["admin-mailtest"],"summary":"24-hour hourly buckets — captures per hour + auth failures per hour","operationId":"overview_timeseries_api_v1_admin_mailtest_overview_timeseries_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Overview Timeseries Api V1 Admin Mailtest Overview Timeseries Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/sso-config":{"post":{"tags":["SSO Config (Admin)"],"summary":"Create Sso Config","description":"Create SSO config. OWNER-only (committee S1).\n\nDefense-in-depth: the `@require_permission(\"org.sso.manage\")` decorator\nalready enforces OWNER-only (org.sso.manage is granted only to the Owner\nrole — mirrors org.billing.manage / org.quotas.update).\nThe role check below is a belt-and-suspenders re-verification against the\nOrganizationMember table.","operationId":"create_sso_config_api_v1_organizations__organization_id__sso_config_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSOConfigCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSOConfigRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["SSO Config (Admin)"],"summary":"Get Sso Config","operationId":"get_sso_config_api_v1_organizations__organization_id__sso_config_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSOConfigRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["SSO Config (Admin)"],"summary":"Patch Sso Config","description":"Update SSO config. OWNER-only (committee S1).","operationId":"patch_sso_config_api_v1_organizations__organization_id__sso_config_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSOConfigUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SSOConfigRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["SSO Config (Admin)"],"summary":"Delete Sso Config","description":"Owner-only delete.","operationId":"delete_sso_config_api_v1_organizations__organization_id__sso_config_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/organizations/{organization_id}/sso-config/test":{"post":{"tags":["SSO Config (Admin)"],"summary":"Post Sso Config Test","description":"Trigger an SSO discovery/test flow. OWNER-only (committee S1).","operationId":"post_sso_config_test_api_v1_organizations__organization_id__sso_config_test_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"organization_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Organization Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Post Sso Config Test Api V1 Organizations  Organization Id  Sso Config Test Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odooer-listing":{"get":{"tags":["Odooer Directory Listing"],"summary":"Get My Listing","description":"Return the org's listing (or null) TOGETHER WITH the plan gate.\n\n#758: this used to return the listing alone, so the UI had to guess the gate\nfrom usePlanFeatures — which reads base_plan and is deliberately more lenient\nthan the server's entitlement check. A lapsed Pro org therefore sailed past\nthe paywall, filled in the whole editor, and only met the gate at submit as a\nbare 402. The entitlement here is computed by the SAME code that raises that\n402, so the hint and the error cannot drift apart.","operationId":"get_my_listing_api_v1_odooer_listing_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingEnvelope"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Odooer Directory Listing"],"summary":"Create Listing","description":"Create the org's draft listing. Draft = not yet published.","operationId":"create_listing_api_v1_odooer_listing_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Odooer Directory Listing"],"summary":"Update Listing","description":"Partial-update the listing. Editing sensitive fields on a published\nlisting auto-unpublishes it — the customer must re-consent.","operationId":"update_listing_api_v1_odooer_listing_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Odooer Directory Listing"],"summary":"Delete Listing","description":"Erase the listing. Soft-deleted immediately; cleanup cron hard-deletes\nafter a retention window.","operationId":"delete_listing_api_v1_odooer_listing_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odooer-listing/publish":{"post":{"tags":["Odooer Directory Listing"],"summary":"Publish Listing","description":"Capture consent and mark the listing as published on the public directory.","operationId":"publish_listing_api_v1_odooer_listing_publish_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingPublishRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odooer-listing/unpublish":{"post":{"tags":["Odooer Directory Listing"],"summary":"Unpublish Listing","description":"Take the listing off the public directory. Row and content are preserved\nso the customer can republish later (with fresh consent capture).","operationId":"unpublish_listing_api_v1_odooer_listing_unpublish_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odooer-listing/logo":{"post":{"tags":["Odooer Directory Listing"],"summary":"Upload Logo","description":"Upload a logo for the org's directory listing.\n\nReuses the theme branding uploader (R2-backed, format/dimension/SVG-sanity\nvalidated) with a distinct ODOOER_LOGO asset type — keys land under\nbranding/{org_id}/odooer_logo-* so they don't collide with theme logos.\n\nEditing the logo does NOT invalidate consent because the marketing site's\nconsent text specifically enumerates the sensitive fields (name, tagline,\nwebsite, country, services, industries, case studies). Swapping a company\nlogo is presentation, not identity — the listing is still the same company.","operationId":"upload_logo_api_v1_odooer_listing_logo_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_logo_api_v1_odooer_listing_logo_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Odooer Directory Listing"],"summary":"Delete Logo","description":"Clear the listing's logo and delete the object from our bucket.\n\nlogo_url is not writable through PATCH, so this is the ONLY way to remove a logo.\nPreviously the UI's \"Remove\" button just cleared local state and the next PATCH\ndropped the key (JSON.stringify omits undefined), so the logo silently stayed on\nthe row and on the public directory while the UI reported success.\n\nDeliberately NOT entitlement-gated, unlike the upload. Removing a logo is content\nREDUCTION — taking a public claim down — and we never paywall that. Same reasoning as\nupdate_draft, unpublish() and hard_delete(). A lapsed customer must always be able to\ntake their own material off our site.","operationId":"delete_logo_api_v1_odooer_listing_logo_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"X-Organization-ID","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Organization-Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OdooerListingResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/odooers":{"get":{"tags":["Odooer Directory (public)"],"summary":"Export of published Odooer directory listings (unauth)","description":"Return the current snapshot of consented, published listings.\n\nTwo modes:\n\n* **Full dump** (no ?since): every currently-published + consented row.\n  Use this for cold starts and periodic reconciliation runs.\n* **Delta** (?since=<ts>): only rows whose updated_at > since, plus\n  `removed_slugs` for anything that used to be public but no longer is.\n  Designed for a rolling 5-10 min cron on the marketing site — cheap on\n  the wire, small on the DB.\n\nRate-limited to 30 rpm — this is a build-time consumer, not a runtime\nfetch. The marketing site is a static export; nothing on the browser\nhits this route directly.","operationId":"export_public_listings_api_v1_odooers_get","parameters":[{"name":"since","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"ISO 8601 timestamp. If provided, only listings whose updated_at is strictly greater than this value are returned, and the response additionally includes `removed_slugs` — listings that used to be public but are no longer (unpublished, consent-invalidated, or soft-deleted). Callers should persist the returned `latest_updated_at` as their next cursor.","title":"Since"},"description":"ISO 8601 timestamp. If provided, only listings whose updated_at is strictly greater than this value are returned, and the response additionally includes `removed_slugs` — listings that used to be public but are no longer (unpublished, consent-invalidated, or soft-deleted). Callers should persist the returned `latest_updated_at` as their next cursor."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicOdooersExportResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/catalog":{"get":{"tags":["Demo"],"summary":"Demo Catalog","description":"Return the curated starter-pack module list shown on the deploy form.","operationId":"demo_catalog_api_v1_demo_catalog_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoCatalogResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/status":{"get":{"tags":["Demo"],"summary":"Demo Status","description":"Caller's current quota state — used by the demo deploy page.","operationId":"demo_status_api_v1_demo_status_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoStatusResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/init":{"post":{"tags":["Demo"],"summary":"Init Demo","description":"Lazy-create the user's demo project + marker VM, return identifiers\nfor the frontend to redirect into the standard env-create page.\n\nReplaces /demo/target-vm + /demo/project (v1.47.50/v1.47.54) which\nhad the frontend orchestrate this — moves all demo-specific state\ncreation server-side so the rest of the flow is identical to a\nregular env deploy.","operationId":"init_demo_api_v1_demo_init_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Init Demo Api V1 Demo Init Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/deploy":{"post":{"tags":["Demo"],"summary":"Demo Deploy","description":"Provision a new demo env. **Deprecated.**\n\nTask 28: demo deploys now go through ``POST /api/v1/environments``\nwith the demo server selected. This route stays operational for\nexisting callers and emits a ``Deprecation`` HTTP header + warning\nlog on every call so we can track residual usage before removing in\nv3.","operationId":"demo_deploy_api_v1_demo_deploy_post","deprecated":true,"security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoDeployRequest"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoDeployResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/export/{env_id}":{"post":{"tags":["Demo"],"summary":"Demo Export","description":"Generate a signed-URL ZIP of the demo env (dump.sql + filestore + manifest).","operationId":"demo_export_api_v1_demo_export__env_id__post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoExportResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/{env_id}":{"delete":{"tags":["Demo"],"summary":"Demo Delete","description":"Manually destroy the caller's active demo env (queued, async).","operationId":"demo_delete_api_v1_demo__env_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Demo Delete Api V1 Demo  Env Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/upgrade-link":{"get":{"tags":["Demo"],"summary":"Demo Upgrade Link","description":"Return a Stripe checkout URL for the Pro tier.\n\nUsed by the 30-min warning email + tour-mode page upgrade CTA.\nResolves the user's primary org (auto-creating one if needed) so\nStripe checkout is scoped to a billable customer.","operationId":"demo_upgrade_link_api_v1_demo_upgrade_link_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoUpgradeLinkResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/{env_id}/extend":{"post":{"tags":["Demo v2"],"summary":"Extend Demo","description":"One-time +4h TTL extension for the caller's demo env.\n\nFlow (REL-1):\n  1. Verify caller is email-verified and owns the env.\n  2. Reject if ``demo_extension_used`` is already True (HTTP 409).\n  3. Reject if env is not running (HTTP 409).\n  4. Cancel old ARQ warn jobs by stored job IDs.\n  5. Re-enqueue warn jobs with the new TTL.\n  6. Re-enqueue destroy at new TTL.\n  7. Persist new TTL + extension flag + new warn job IDs + clear sent stamps.\n  8. Emit ``demo.status_changed`` SSE event.","operationId":"extend_demo_api_v1_demo__env_id__extend_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoExtendResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/{env_id}/invite":{"post":{"tags":["Demo v2"],"summary":"Create Invite","description":"Create a one-time invite to share the caller's demo env.\n\nOwner-only. Cap of 5 active (unclaimed, unexpired) invites per env.\nRe-inviting the same email returns 409 ``already_invited``.","operationId":"create_invite_api_v1_demo__env_id__invite_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoInviteRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoInviteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/invite/{token}":{"get":{"tags":["Demo v2"],"summary":"Claim Invite","description":"Public, one-time claim. Atomic UPDATE ... RETURNING.\n\nTwo concurrent claims of the same token yield exactly one 200 (the\none that observed ``claimed_at IS NULL``) and one 410 (the loser\nsees a 0-row update).\n\nCaller (frontend) follows up with a magic-link signin flow scoped to\nthe returned email; this endpoint deliberately does not mint a\nsession — that's the auth layer's job.","operationId":"claim_invite_api_v1_demo_invite__token__get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Claim Invite Api V1 Demo Invite  Token  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/waitlist":{"post":{"tags":["Demo v2"],"summary":"Join Waitlist","description":"Public waitlist sign-up.\n\nSEC-5: the response is **uniform** ({\"status\": \"ok\"}) whether the\nemail is new or already on the list. No position counter, no\n\"already-on-list\" hint — both leak existence.","operationId":"join_waitlist_api_v1_demo_waitlist_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoWaitlistRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoWaitlistResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/waitlist/{token}/claim":{"get":{"tags":["Demo v2"],"summary":"Claim Waitlist Slot","description":"Public one-time claim.\n\nAtomic UPDATE ... RETURNING pattern matches the invite claim — two\nconcurrent claims of the same token yield exactly one 200 + one 410.\nClaim is rejected if ``slot_reserved_until`` is in the past.","operationId":"claim_waitlist_slot_api_v1_demo_waitlist__token__claim_get","parameters":[{"name":"token","in":"path","required":true,"schema":{"type":"string","title":"Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Claim Waitlist Slot Api V1 Demo Waitlist  Token  Claim Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/{env_id}/mailbox":{"get":{"tags":["Demo v2"],"summary":"Get Mailbox","description":"List captured emails for the caller's demo env.\n\nReturns up to ``MAILBOX_LIMIT`` most-recent non-deleted messages.","operationId":"get_mailbox_api_v1_demo__env_id__mailbox_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoMailboxResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/demo/subdomain/{slug}/available":{"get":{"tags":["Demo v2"],"summary":"Subdomain Available","description":"Return whether the slug is free for a new demo subdomain.\n\nOrder of checks matters — bail at the first failure so the response\nis deterministic and we don't waste DB lookups when format is bad.","operationId":"subdomain_available_api_v1_demo_subdomain__slug__available_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"slug","in":"path","required":true,"schema":{"type":"string","title":"Slug"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DemoSubdomainAvailableResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/org":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get organization info","description":"Return the organization associated with this API key.","operationId":"get_org_api_public_v1_org_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicOrgResponse"}}}}}}},"/api/public/v1/org/usage":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get current resource usage","description":"Return current resource usage for the organization.","operationId":"get_org_usage_api_public_v1_org_usage_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicUsageResponse"}}}}}}},"/api/public/v1/org/api-keys":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List API keys for the organization","description":"List API keys for the organization (key hashes never returned).\n\nGap 4, 88-saas-oecsh's 2026-09-18 platform-request doc: list and revoke\nonly, deliberately no create here — \"creation requires the dashboard;\nrevoke and list do not... this alone would satisfy us\" was the\nrequesting team's own preferred bound on the privilege-escalation risk\na full-access key that could mint another full-access key would carry.\nSame shape as the dashboard's GET /api/v1/orgs/{org_id}/api-keys.","operationId":"list_org_api_keys_api_public_v1_org_api_keys_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/APIKeyResponse"},"type":"array","title":"Response List Org Api Keys Api Public V1 Org Api Keys Get"}}}}}}},"/api/public/v1/org/api-keys/{key_id}":{"delete":{"tags":["Public API v1","Public API v1"],"summary":"Revoke an API key","description":"Deactivate (soft-delete) an API key. Immediately invalid for all\nfuture requests — including if this is the key making the call, which\nis a deliberate feature: the one operation with a genuine clock on it\n(a leaked key) must not require finding someone with dashboard access.\nRequires full_access — a read_only key must not be able to revoke\nanything, including itself.","operationId":"revoke_org_api_key_api_public_v1_org_api_keys__key_id__delete","parameters":[{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/servers/registration-tokens":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List Server Registration Tokens","description":"List the org's registration tokens (pending Quick Connect panel view).","operationId":"list_server_registration_tokens_api_public_v1_servers_registration_tokens_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/RegistrationTokenSummary"},"type":"array","title":"Response List Server Registration Tokens Api Public V1 Servers Registration Tokens Get"}}}}}},"post":{"tags":["Public API v1","Public API v1"],"summary":"Create Server Registration Token","description":"Mint a single-use Quick Connect token + install command.\n\nThe token is returned ONCE in plaintext; only its SHA-256 hash is stored.\nUnconsumed tokens count as reserved slots against the org's server quota\n(service-level behaviour, unchanged).","operationId":"create_server_registration_token_api_public_v1_servers_registration_tokens_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRegistrationTokenRequest"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRegistrationTokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/servers/registration-tokens/{token_id}":{"delete":{"tags":["Public API v1","Public API v1"],"summary":"Revoke Server Registration Token","description":"Revoke an unconsumed registration token.","operationId":"revoke_server_registration_token_api_public_v1_servers_registration_tokens__token_id__delete","parameters":[{"name":"token_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Token Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/servers":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List servers","description":"List BYOS servers owned by this organisation, newest first.","operationId":"list_servers_api_public_v1_servers_get","parameters":[{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Pagination cursor from previous response","title":"Cursor"},"description":"Pagination cursor from previous response"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Results per page","default":20,"title":"Limit"},"description":"Results per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_PublicServerResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/servers/{server_id}":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get server","description":"Get a single server by ID.","operationId":"get_server_api_public_v1_servers__server_id__get","parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicServerResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/projects":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List projects","description":"List active projects for this organisation (filtered to ctx.project_id if project-scoped key).","operationId":"list_projects_api_public_v1_projects_get","parameters":[{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Pagination cursor from previous response","title":"Cursor"},"description":"Pagination cursor from previous response"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Results per page","default":20,"title":"Limit"},"description":"Results per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_PublicProjectResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Public API v1","Public API v1"],"summary":"Create a project","description":"Create a new project. Requires a full_access, org-scoped API key.","operationId":"create_project_api_public_v1_projects_post","parameters":[{"name":"X-Idempotency-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Idempotency-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicProjectCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/projects/{project_id}":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get project","description":"Get a single project by ID.","operationId":"get_project_api_public_v1_projects__project_id__get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Public API v1","Public API v1"],"summary":"Update a project","description":"Update project name, branch, or git URL. Requires full_access key.","operationId":"update_project_api_public_v1_projects__project_id__patch","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicProjectUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicProjectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Public API v1","Public API v1"],"summary":"Delete a project","description":"Soft-delete a project.\n\nRequires:\n- full_access, org-scoped API key\n- Header ``X-Confirm-Delete: true``\n- No environments left in the project (errored or inactive ones are\n  cleaned up automatically, as in the dashboard)","operationId":"delete_project_api_public_v1_projects__project_id__delete","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"X-Confirm-Delete","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Confirm-Delete"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/projects/{project_id}/environments":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List environments for a project","description":"List environments for a project.","operationId":"list_environments_api_public_v1_projects__project_id__environments_get","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by status string","title":"Status"},"description":"Filter by status string"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PublicEnvironmentResponse"},"title":"Response List Environments Api Public V1 Projects  Project Id  Environments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Public API v1","Public API v1"],"summary":"Create an environment","description":"Create a new environment inside a project, then enqueue an initial deploy.\nRequires full_access key.","operationId":"create_environment_api_public_v1_projects__project_id__environments_post","parameters":[{"name":"project_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Project Id"}},{"name":"X-Idempotency-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Idempotency-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicEnvironmentCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicEnvironmentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get environment","description":"Get a single environment by ID.","operationId":"get_environment_api_public_v1_environments__env_id__get","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicEnvironmentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Public API v1","Public API v1"],"summary":"Update an environment","description":"Update environment name or branch. Requires full_access key.","operationId":"update_environment_api_public_v1_environments__env_id__patch","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicEnvironmentUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicEnvironmentResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Public API v1","Public API v1"],"summary":"Delete an environment","description":"Enqueue environment destruction.\n\nRequires:\n- full_access API key\n- Header ``X-Confirm-Delete: true``","operationId":"delete_environment_api_public_v1_environments__env_id__delete","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"X-Confirm-Delete","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Confirm-Delete"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/status":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get environment health status","description":"Return a lightweight health snapshot for an environment.","operationId":"get_environment_status_api_public_v1_environments__env_id__status_get","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicStatusResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/logs":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get deployment logs for an environment","description":"Return deployment log text for the most recent (or specified) task.","operationId":"get_environment_logs_api_public_v1_environments__env_id__logs_get","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"task_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"description":"Specific task/deployment ID","title":"Task Id"},"description":"Specific task/deployment ID"},{"name":"lines","in":"query","required":false,"schema":{"type":"integer","maximum":5000,"minimum":1,"description":"Maximum log lines","default":200,"title":"Lines"},"description":"Maximum log lines"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicLogsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/deployments/{task_id}":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get deployment task status","description":"Get the status of a deployment task by ID.","operationId":"get_deployment_api_public_v1_deployments__task_id__get","parameters":[{"name":"task_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Task Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicTaskResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/deployments":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List deployments for an environment","description":"List all deployment tasks for an environment, newest first.","operationId":"list_deployments_api_public_v1_environments__env_id__deployments_get","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Pagination cursor from previous response","title":"Cursor"},"description":"Pagination cursor from previous response"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Results per page","default":20,"title":"Limit"},"description":"Results per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_PublicTaskResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/tasks":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List an environment's tasks of every type","description":"List an environment's tasks, newest first: deploys, clones from or into it,\nQuick Updates, backups, restores, restarts and the rest.","operationId":"list_environment_tasks_api_public_v1_environments__env_id__tasks_get","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"type","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Task type, for example clone, deploy or quick_update","title":"Type"},"description":"Task type, for example clone, deploy or quick_update"},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TaskStatus"},{"type":"null"}],"title":"Status"}},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Pagination cursor from previous response","title":"Cursor"},"description":"Pagination cursor from previous response"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Results per page","default":20,"title":"Limit"},"description":"Results per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_PublicTaskResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/clones":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List clones from or into an environment","description":"List clones with this environment as source or target, newest first, including\nqueued ones and failed ones with their reason.","operationId":"list_environment_clones_api_public_v1_environments__env_id__clones_get","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"active","in":"query","required":false,"schema":{"type":"boolean","description":"Only clones that are queued or running","default":false,"title":"Active"},"description":"Only clones that are queued or running"},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Pagination cursor from previous response","title":"Cursor"},"description":"Pagination cursor from previous response"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Results per page","default":20,"title":"Limit"},"description":"Results per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_PublicCloneOperationResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/deploy":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Trigger a deployment","description":"Trigger a deployment. Requires full_access key.\n\nOptional body ``{\"update_modules\": [\"mod_a\", \"mod_b\"]}`` (or ``[\"all\"]``)\nupdates those modules after the new code is pulled and before the health\ncheck (#1129). Allowed when the environment is in an error state, so a\npush that adds fields can be recovered in one call.","operationId":"deploy_environment_api_public_v1_environments__env_id__deploy_post","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PublicDeployRequest"},{"type":"null"}],"title":"Body"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicDeployResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/restart":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Restart the environment","description":"Restart the environment. Requires full_access key.","operationId":"restart_environment_api_public_v1_environments__env_id__restart_post","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/start":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Start a stopped environment","description":"Start a stopped environment. Requires full_access key.","operationId":"start_environment_api_public_v1_environments__env_id__start_post","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/quick-update":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Trigger a quick update (git pull + module upgrade)","description":"Trigger a quick update on a running environment.\n\nModes:\n  - `pull_restart`: git pull + container restart (hot reload).\n  - `update_all`: git pull + `-u all`.\n  - `update_specific`: git pull + `-u <modules>` (requires `modules`).\n  - `reinitialize_specific`: git pull + `-i <modules>` (requires `modules`).\n\nThe modes that update or install modules first save a copy of the\ndatabase on the server; `skip_safety_copy: true` leaves it out (#1230).\n\nA queued or running backup refuses the update (409 `task_in_progress`);\n`ignore_running_backup: true` goes ahead anyway, and that backup fails\nwhen the environment restarts, so run it again afterwards (#1288).\n\nRequires a full_access API key. Environment must be in `running` status.","operationId":"quick_update_environment_api_public_v1_environments__env_id__quick_update_post","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicQuickUpdateRequest"}}}},"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/stop":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Stop a running environment","description":"Stop a running environment. Requires full_access key.","operationId":"stop_environment_api_public_v1_environments__env_id__stop_post","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/webhooks":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List Webhooks","description":"List outgoing webhooks for the authenticated API key's org/project scope.\n\nReturns a paginated response. Use `limit` (max 100) and `offset` to page through results.","operationId":"list_webhooks_api_public_v1_webhooks_get","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicPaginatedWebhooks"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Public API v1","Public API v1"],"summary":"Create Webhook","description":"Register a new outgoing webhook. Requires full_access key.\n\nSupports optional idempotency via `X-Idempotency-Key` header (24h TTL).\nIdempotent re-submissions return the original response without creating a duplicate.","operationId":"create_webhook_api_public_v1_webhooks_post","parameters":[{"name":"X-Idempotency-Key","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Idempotency-Key"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookCreatedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/webhooks/{webhook_id}":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get Webhook","description":"Get a single webhook by ID.","operationId":"get_webhook_api_public_v1_webhooks__webhook_id__get","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Public API v1","Public API v1"],"summary":"Update Webhook","description":"Update a webhook's URL, events, description, or active state. Requires full_access key.","operationId":"update_webhook_api_public_v1_webhooks__webhook_id__patch","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Public API v1","Public API v1"],"summary":"Delete Webhook","description":"Delete a webhook and all its delivery records. Requires full_access key.","operationId":"delete_webhook_api_public_v1_webhooks__webhook_id__delete","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/webhooks/{webhook_id}/test":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Test Webhook","description":"Trigger a synchronous test ping to the webhook URL.\n\nSends a 'ping' event payload and returns the HTTP response details.\nDoes NOT create a delivery record. Requires full_access key.","operationId":"test_webhook_api_public_v1_webhooks__webhook_id__test_post","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/webhooks/{webhook_id}/rotate-secret":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Rotate Webhook Secret","description":"Rotate the HMAC signing secret for a webhook.\n\nReturns the new plaintext secret (shown ONCE). After this call the old\nsecret is invalidated immediately. Requires full_access key.","operationId":"rotate_webhook_secret_api_public_v1_webhooks__webhook_id__rotate_secret_post","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Rotate Webhook Secret Api Public V1 Webhooks  Webhook Id  Rotate Secret Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/webhooks/{webhook_id}/deliveries":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get Webhook Deliveries","description":"List the 50 most recent delivery attempts for a webhook, newest first.\n\nEach entry shows delivery status, HTTP response code, and timing.","operationId":"get_webhook_deliveries_api_public_v1_webhooks__webhook_id__deliveries_get","parameters":[{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDeliveryResponse"},"title":"Response Get Webhook Deliveries Api Public V1 Webhooks  Webhook Id  Deliveries Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{environment_id}/backups":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Create a backup for an environment","description":"Trigger a new backup (queued for async processing). Requires full_access key.\n\nMirrors the dashboard's POST /backups/environments/{id}/backups (same\nconcurrent-backup guard, quota check, and storage-config resolution) —\nthe write path this route delegates to is the same ARQ ``execute_backup``\ntask either way, so a backup taken via the API is indistinguishable from\none taken in the dashboard once it starts running.","operationId":"create_environment_backup_api_public_v1_environments__environment_id__backups_post","parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Public API v1","Public API v1"],"summary":"List backups for an environment","description":"List backups for an environment in reverse-chronological order.","operationId":"list_environment_backups_api_public_v1_environments__environment_id__backups_get","parameters":[{"name":"environment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Environment Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/BackupStatus"},{"type":"null"}],"title":"Status"}},{"name":"backup_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/BackupType"},{"type":"null"}],"title":"Backup Type"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"page_size","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Page Size"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupListResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/backups/{backup_id}/download":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get presigned download URLs for a completed backup","description":"Return presigned URLs for the backup's database dump, filestore\narchive, and manifest. The backup must be in COMPLETED status.","operationId":"get_backup_download_urls_api_public_v1_backups__backup_id__download_get","parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"expires_in","in":"query","required":false,"schema":{"type":"integer","maximum":86400,"minimum":300,"description":"URL validity in seconds (5 minutes to 24 hours).","default":3600,"title":"Expires In"},"description":"URL validity in seconds (5 minutes to 24 hours)."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupDownloadResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/backups/{backup_id}":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get one backup","description":"Return one backup, in the same shape as an item of the backup list.","operationId":"get_backup_api_public_v1_backups__backup_id__get","parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BackupResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/backups/{backup_id}/restore":{"post":{"tags":["Public API v1","Public API v1"],"summary":"Restore a backup into the environment it was taken from","description":"Restore a completed backup into the SAME environment it was taken from,\noverwriting that environment's database and files.\n\nRequires:\n- full_access API key\n- Header ``X-Confirm-Restore: true``\n\nRestoring into another environment, a new environment or another server\nstays in the dashboard. The restore itself is the dashboard's restore v2\n(same service, same worker job), so a safety backup of the current data is\ntaken first whenever there is data to back up, and a failed safety backup\naborts the restore.","operationId":"restore_backup_api_public_v1_backups__backup_id__restore_post","parameters":[{"name":"backup_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Backup Id"}},{"name":"X-Confirm-Restore","in":"header","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"X-Confirm-Restore"}}],"responses":{"202":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicBackupRestoreResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/runtime-logs":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get runtime logs (Odoo, container, PostgreSQL)","description":"Return the newest lines of an environment's container logs, read live from its server.","operationId":"get_runtime_logs_api_public_v1_environments__env_id__runtime_logs_get","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}},{"name":"source","in":"query","required":false,"schema":{"enum":["odoo","container","postgres"],"type":"string","description":"odoo or container: the Odoo container; postgres: the database","default":"odoo","title":"Source"},"description":"odoo or container: the Odoo container; postgres: the database"},{"name":"lines","in":"query","required":false,"schema":{"type":"integer","maximum":1000,"minimum":1,"description":"Newest lines to return","default":200,"title":"Lines"},"description":"Newest lines to return"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicRuntimeLogsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/environments/{env_id}/metrics":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get environment metrics","description":"Live CPU and memory of the environment's own containers, and its disk sizes.","operationId":"get_environment_metrics_api_public_v1_environments__env_id__metrics_get","parameters":[{"name":"env_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Env Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicEnvironmentMetricsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/servers/{server_id}/metrics":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get server metrics","description":"Live CPU, memory, disk and network of a server the organization owns.","operationId":"get_server_metrics_api_public_v1_servers__server_id__metrics_get","parameters":[{"name":"server_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Server Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicServerMetricsResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/support/tickets":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List support tickets","description":"The organization's support tickets, newest first. Needs a key with Support tickets on.","operationId":"list_support_tickets_api_public_v1_support_tickets_get","parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TicketStatus"},{"type":"null"}],"description":"Only tickets in this status","title":"Status"},"description":"Only tickets in this status"},{"name":"cursor","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"description":"Pagination cursor from previous response","title":"Cursor"},"description":"Pagination cursor from previous response"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Results per page","default":20,"title":"Limit"},"description":"Results per page"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_PublicSupportTicket_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/support/tickets/{ticket_id}":{"get":{"tags":["Public API v1","Public API v1"],"summary":"Get support ticket","description":"One ticket with its description and public replies, oldest first. Internal notes are never included.","operationId":"get_support_ticket_api_public_v1_support_tickets__ticket_id__get","parameters":[{"name":"ticket_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Ticket Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicSupportTicketDetail"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/public/v1/changelog":{"get":{"tags":["Public API v1","Public API v1"],"summary":"List platform releases","description":"oec.sh platform releases, newest first. Internal-only changes are never included.","operationId":"list_changelog_api_public_v1_changelog_get","parameters":[{"name":"since_version","in":"query","required":false,"schema":{"anyOf":[{"type":"string","maxLength":20,"pattern":"^[vV]?\\d{1,4}(\\.\\d{1,4}){0,3}$"},{"type":"null"}],"description":"Only releases newer than this version (exclusive), e.g. 1.53.20.","title":"Since Version"},"description":"Only releases newer than this version (exclusive), e.g. 1.53.20."},{"name":"since_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"description":"Only releases on or after this date, YYYY-MM-DD (inclusive).","title":"Since Date"},"description":"Only releases on or after this date, YYYY-MM-DD (inclusive)."},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"description":"Releases per page","default":20,"title":"Limit"},"description":"Releases per page"},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"description":"Releases to skip","default":0,"title":"Offset"},"description":"Releases to skip"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicChangelogResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/api-keys":{"get":{"tags":["API Keys"],"summary":"List Api Keys","description":"List all API keys for the organization (key hashes never returned).","operationId":"list_api_keys_api_v1_orgs__org_id__api_keys_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/APIKeyResponse"},"title":"Response List Api Keys Api V1 Orgs  Org Id  Api Keys Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["API Keys"],"summary":"Create Api Key","description":"Create a new API key.\n\nIMPORTANT: The full key is returned ONLY in this response.\nStore it securely — it cannot be retrieved again.","operationId":"create_api_key_api_v1_orgs__org_id__api_keys_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyCreatedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/api-keys/{key_id}":{"patch":{"tags":["API Keys"],"summary":"Update Api Key","description":"Toggle a key's two per-key switches.\n\n``can_register_servers`` (#979-follow-up) may only be turned on for a\nkey that already meets the #979 gate's other two conditions (org-scoped,\nfull-access) — setting it on a project-scoped or read-only key would\nsilently do nothing (server_registration.py's own gate would still 403),\nwhich is a confusing state to hand back as a success.\n\n``can_read_support_tickets`` (#1190) may only be turned on for an\norg-scoped key (any tier): tickets belong to the organization, not to a\nproject, and public/support.py refuses a project-scoped key regardless.","operationId":"update_api_key_api_v1_orgs__org_id__api_keys__key_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIKeyResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["API Keys"],"summary":"Delete Api Key","description":"Deactivate (soft-delete) an API key. Immediately invalid for all future requests.","operationId":"delete_api_key_api_v1_orgs__org_id__api_keys__key_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/api-keys/{key_id}/audit":{"get":{"tags":["API Keys"],"summary":"Get Api Key Audit Log","description":"Get the last 100 API usage audit log entries for a key.","operationId":"get_api_key_audit_log_api_v1_orgs__org_id__api_keys__key_id__audit_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"key_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Key Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/APIKeyAuditLogResponse"},"title":"Response Get Api Key Audit Log Api V1 Orgs  Org Id  Api Keys  Key Id  Audit Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/webhooks":{"get":{"tags":["Webhooks"],"summary":"List Webhooks","description":"List all outgoing webhooks for the organization. Secrets are never returned.","operationId":"list_webhooks_api_v1_orgs__org_id__webhooks_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OutgoingWebhookResponse"},"title":"Response List Webhooks Api V1 Orgs  Org Id  Webhooks Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Webhooks"],"summary":"Create Webhook","description":"Create a new outgoing webhook.\n\nIMPORTANT: The HMAC signing secret is returned ONLY in this response.\nStore it securely — it cannot be retrieved again. Use the rotate-secret\nendpoint to generate a new one if needed.","operationId":"create_webhook_api_v1_orgs__org_id__webhooks_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookCreatedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/webhooks/{webhook_id}":{"patch":{"tags":["Webhooks"],"summary":"Update Webhook","description":"Update URL, events, description, or active state of a webhook.","operationId":"update_webhook_api_v1_orgs__org_id__webhooks__webhook_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Webhooks"],"summary":"Delete Webhook","description":"Hard-delete a webhook and all its delivery records.","operationId":"delete_webhook_api_v1_orgs__org_id__webhooks__webhook_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/webhooks/{webhook_id}/test":{"post":{"tags":["Webhooks"],"summary":"Test Webhook","description":"Send a synchronous test ping to the webhook URL.\n\nDoes NOT create a delivery record. Returns success/failure immediately.","operationId":"test_webhook_api_v1_orgs__org_id__webhooks__webhook_id__test_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/webhooks/{webhook_id}/rotate-secret":{"post":{"tags":["Webhooks"],"summary":"Rotate Webhook Secret","description":"Rotate the HMAC signing secret for a webhook.\n\nIMPORTANT: The new secret is returned ONLY in this response.\nUpdate your receiver to use the new secret before this response is discarded.","operationId":"rotate_webhook_secret_api_v1_orgs__org_id__webhooks__webhook_id__rotate_secret_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OutgoingWebhookCreatedResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/webhooks/{webhook_id}/deliveries":{"get":{"tags":["Webhooks"],"summary":"List Webhook Deliveries","description":"Return the last 50 delivery attempts for a webhook.","operationId":"list_webhook_deliveries_api_v1_orgs__org_id__webhooks__webhook_id__deliveries_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"webhook_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Webhook Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDeliveryResponse"},"title":"Response List Webhook Deliveries Api V1 Orgs  Org Id  Webhooks  Webhook Id  Deliveries Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/email-notifications":{"get":{"tags":["Email Notifications"],"summary":"List Email Channels","operationId":"list_email_channels_api_v1_orgs__org_id__email_notifications_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/EmailNotificationChannelResponse"},"title":"Response List Email Channels Api V1 Orgs  Org Id  Email Notifications Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Email Notifications"],"summary":"Create Email Channel","operationId":"create_email_channel_api_v1_orgs__org_id__email_notifications_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailNotificationChannelCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailNotificationChannelResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/email-notifications/{channel_id}":{"patch":{"tags":["Email Notifications"],"summary":"Update Email Channel","operationId":"update_email_channel_api_v1_orgs__org_id__email_notifications__channel_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"channel_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Channel Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailNotificationChannelUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailNotificationChannelResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Email Notifications"],"summary":"Delete Email Channel","operationId":"delete_email_channel_api_v1_orgs__org_id__email_notifications__channel_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"channel_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Channel Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/orgs/{org_id}/email-notifications/{channel_id}/test":{"post":{"tags":["Email Notifications"],"summary":"Test Email Channel","operationId":"test_email_channel_api_v1_orgs__org_id__email_notifications__channel_id__test_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"org_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Org Id"}},{"name":"channel_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Channel Id"}},{"name":"access_token","in":"cookie","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"APIKeyAuditLogResponse":{"properties":{"method":{"type":"string","title":"Method"},"endpoint":{"type":"string","title":"Endpoint"},"status_code":{"type":"integer","title":"Status Code"},"ip_address":{"type":"string","title":"Ip Address"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["method","endpoint","status_code","ip_address","created_at"],"title":"APIKeyAuditLogResponse","description":"A single audit log entry for an API key request."},"APIKeyCreate":{"properties":{"name":{"type":"string","title":"Name"},"tier":{"$ref":"#/components/schemas/APIKeyTier"},"scope":{"$ref":"#/components/schemas/APIKeyScope"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["name","tier","scope"],"title":"APIKeyCreate","description":"Payload for creating a new API key."},"APIKeyCreatedResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"prefix":{"type":"string","title":"Prefix"},"tier":{"$ref":"#/components/schemas/APIKeyTier"},"scope":{"$ref":"#/components/schemas/APIKeyScope"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"is_active":{"type":"boolean","title":"Is Active"},"can_register_servers":{"type":"boolean","title":"Can Register Servers"},"can_read_support_tickets":{"type":"boolean","title":"Can Read Support Tickets"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"key":{"type":"string","title":"Key"}},"type":"object","required":["id","name","prefix","tier","scope","project_id","is_active","can_register_servers","can_read_support_tickets","last_used_at","expires_at","created_at","key"],"title":"APIKeyCreatedResponse","description":"Extended response returned ONLY at creation time.\n\nIncludes the full plaintext key, which is never stored and cannot be\nretrieved again after this response is sent."},"APIKeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"prefix":{"type":"string","title":"Prefix"},"tier":{"$ref":"#/components/schemas/APIKeyTier"},"scope":{"$ref":"#/components/schemas/APIKeyScope"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"is_active":{"type":"boolean","title":"Is Active"},"can_register_servers":{"type":"boolean","title":"Can Register Servers"},"can_read_support_tickets":{"type":"boolean","title":"Can Read Support Tickets"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","name","prefix","tier","scope","project_id","is_active","can_register_servers","can_read_support_tickets","last_used_at","expires_at","created_at"],"title":"APIKeyResponse","description":"API key details returned by list/get endpoints.\n\nThe full plaintext key is NEVER returned here — only the prefix for display."},"APIKeyScope":{"type":"string","enum":["org","project"],"title":"APIKeyScope"},"APIKeyTier":{"type":"string","enum":["read_only","full_access"],"title":"APIKeyTier"},"APIKeyUpdate":{"properties":{"can_register_servers":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Can Register Servers"},"can_read_support_tickets":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Can Read Support Tickets"}},"type":"object","title":"APIKeyUpdate","description":"Payload for updating an existing API key.\n\nOnly the two per-key switches are settable: `can_register_servers`\n(#979-follow-up, requested by 88-saas-oecsh's 2026-09-18 platform-request\ndoc, gap 5) and `can_read_support_tickets` (#1190). Send either or both;\na field left out is left unchanged. Everything else about a key (tier,\nscope, name) is immutable after creation by design — rotate instead."},"ActionOptions":{"properties":{"force":{"type":"boolean","title":"Force","description":"Force the action even if it might cause issues","default":false},"remove_volumes":{"type":"boolean","title":"Remove Volumes","description":"Remove volumes when destroying (destructive)","default":false},"remove_database":{"type":"boolean","title":"Remove Database","description":"Remove database when destroying (destructive)","default":false},"timeout":{"type":"integer","title":"Timeout","description":"Timeout in seconds for stop/restart operations","default":10},"wait":{"type":"boolean","title":"Wait","description":"Wait for action to complete before returning","default":true},"update_modules":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Update Modules","description":"Deploy/redeploy only: module names to update (odoo -u) after pulling code and before the health check, or ['all']."}},"type":"object","title":"ActionOptions","description":"Options for environment actions.","example":{}},"ActionRequest":{"properties":{"action":{"$ref":"#/components/schemas/EnvironmentAction","description":"Action to perform on the environment"},"options":{"anyOf":[{"$ref":"#/components/schemas/ActionOptions"},{"type":"null"}],"description":"Optional action parameters"}},"type":"object","required":["action"],"title":"ActionRequest","description":"Request to perform an action on an environment.","example":{}},"ActionResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether the action completed successfully"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID the action was performed on"},"action":{"$ref":"#/components/schemas/EnvironmentAction","description":"Action that was performed"},"previous_status":{"type":"string","title":"Previous Status","description":"Environment status before the action"},"current_status":{"type":"string","title":"Current Status","description":"Environment status after the action"},"message":{"type":"string","title":"Message","description":"Human-readable result message"},"task_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Task Id","description":"Task ID for async operations (for tracking)"},"deployment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Deployment Id","description":"Deployment ID if action triggered a deployment"},"duration_ms":{"type":"integer","title":"Duration Ms","description":"Action duration in milliseconds"}},"type":"object","required":["success","environment_id","action","previous_status","current_status","message","duration_ms"],"title":"ActionResponse","description":"Response after performing an action.","example":{}},"AddBlockedDomainRequest":{"properties":{"domain":{"type":"string","title":"Domain"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["domain"],"title":"AddBlockedDomainRequest"},"AddonSourceType":{"type":"string","enum":["git","upload"],"title":"AddonSourceType","description":"Source of a project additional repo's addon code: cloned from Git or uploaded as an archive."},"AdminEnvRow":{"properties":{"env_id":{"type":"string","format":"uuid","title":"Env Id"},"env_name":{"type":"string","title":"Env Name"},"enabled":{"type":"boolean","title":"Enabled"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version"},"is_rotating":{"type":"boolean","title":"Is Rotating"},"tamper_detected_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tamper Detected At"},"captured_count":{"type":"integer","title":"Captured Count"},"storage_used_bytes":{"type":"integer","title":"Storage Used Bytes"},"last_capture_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Capture At"}},"type":"object","required":["env_id","env_name","enabled","odoo_version","is_rotating","tamper_detected_at","captured_count","storage_used_bytes","last_capture_at"],"title":"AdminEnvRow","description":"Drill-down row for the per-org expandable section."},"AdminEnvironmentListResponse":{"properties":{"environments":{"items":{"$ref":"#/components/schemas/AdminEnvironmentSummary"},"type":"array","title":"Environments"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"total_pages":{"type":"integer","title":"Total Pages"},"status_summary":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Summary","default":{}}},"type":"object","required":["environments","total","page","per_page","total_pages"],"title":"AdminEnvironmentListResponse","description":"Paginated environment list response."},"AdminEnvironmentSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"environment_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Type"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"project_name":{"type":"string","title":"Project Name"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id"},"server_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Name"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"cpu_cores":{"type":"number","title":"Cpu Cores","default":0},"ram_mb":{"type":"integer","title":"Ram Mb","default":0},"disk_gb":{"type":"integer","title":"Disk Gb","default":0},"is_active":{"type":"boolean","title":"Is Active","default":true},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"last_deployed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Deployed At"}},"type":"object","required":["id","name","project_id","project_name"],"title":"AdminEnvironmentSummary","description":"Environment summary for admin list."},"AdminOrgRow":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"organization_name":{"type":"string","title":"Organization Name"},"plan_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan Name"},"message_count":{"type":"integer","title":"Message Count"},"total_bytes":{"type":"integer","title":"Total Bytes"},"message_cap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Message Cap"},"bytes_cap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Bytes Cap"},"auth_failure_rate_24h":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Auth Failure Rate 24H"},"envs_enabled":{"type":"integer","title":"Envs Enabled"},"last_capture_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Capture At"}},"type":"object","required":["organization_id","organization_name","plan_name","message_count","total_bytes","message_cap","bytes_cap","auth_failure_rate_24h","envs_enabled","last_capture_at"],"title":"AdminOrgRow","description":"One row of the admin top-N table.\n\nField names match ``frontend/src/app/admin/mailtest/page.tsx``\n``AdminOrgRow`` interface exactly so Day 8 UI consumes without a\nshim."},"AdminOrgsResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AdminOrgRow"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"AdminOrgsResponse"},"AdminProjectListResponse":{"properties":{"projects":{"items":{"$ref":"#/components/schemas/AdminProjectSummary"},"type":"array","title":"Projects"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"total_pages":{"type":"integer","title":"Total Pages"}},"type":"object","required":["projects","total","page","per_page","total_pages"],"title":"AdminProjectListResponse","description":"Paginated project list response."},"AdminProjectSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"organization_name":{"type":"string","title":"Organization Name"},"organization_slug":{"type":"string","title":"Organization Slug"}},"type":"object","required":["id","name","odoo_version","created_at","organization_id","organization_name","organization_slug"],"title":"AdminProjectSummary","description":"Project summary for admin list."},"AdminServerListResponse":{"properties":{"servers":{"items":{"$ref":"#/components/schemas/AdminServerSummary"},"type":"array","title":"Servers"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"total_pages":{"type":"integer","title":"Total Pages"}},"type":"object","required":["servers","total","page","per_page","total_pages"],"title":"AdminServerListResponse","description":"Paginated server list response."},"AdminServerSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"ipv4_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ipv4 Address"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name"},"organization_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Slug"},"is_shared":{"type":"boolean","title":"Is Shared","default":false},"is_active":{"type":"boolean","title":"Is Active","default":true},"cpu_cores":{"type":"integer","title":"Cpu Cores","default":0},"memory_gb":{"type":"integer","title":"Memory Gb","default":0},"disk_gb":{"type":"integer","title":"Disk Gb","default":0},"disk_available_gb":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Disk Available Gb"},"environment_count":{"type":"integer","title":"Environment Count","default":0},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["id","name"],"title":"AdminServerSummary","description":"Server summary for admin list."},"AdminTicketListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TicketResponseAdmin"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"skip":{"type":"integer","title":"Skip"},"limit":{"type":"integer","title":"Limit"}},"type":"object","required":["items","total","skip","limit"],"title":"AdminTicketListResponse","description":"Paginated ticket list (admin view).","example":{}},"AdminTicketUpdateRequest":{"properties":{"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"New ticket status"},"priority":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Priority","description":"New ticket priority"},"assigned_to":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned To","description":"Assign to portal admin user ID"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Associate ticket with an organization"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags","description":"Replace tags array"}},"type":"object","title":"AdminTicketUpdateRequest","description":"Admin-only ticket field updates.","example":{}},"AdminTunnelVmRow":{"properties":{"vm_id":{"type":"string","format":"uuid","title":"Vm Id","description":"VM UUID"},"name":{"type":"string","title":"Name","description":"VM name"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Owning organization (null for shared/portal-managed VMs)"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization name (null for shared/portal-managed VMs)"},"cf_tunnel_managed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Managed By"},"cf_tunnel_hostname":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Hostname"},"cf_tunnel_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Id"},"cf_tunnel_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Status"},"cf_tunnel_qualified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cf Tunnel Qualified At"},"cf_tunnel_qualify_attempted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cf Tunnel Qualify Attempted At"},"cf_tunnel_qualify_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Qualify Error"},"cf_tunnel_consecutive_failures":{"type":"integer","title":"Cf Tunnel Consecutive Failures","default":0},"cf_tunnel_circuit_open_since":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cf Tunnel Circuit Open Since"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether VM is active (not soft-deleted)"}},"type":"object","required":["vm_id","name","is_active"],"title":"AdminTunnelVmRow","description":"Row for the portal-admin tunnel-VMs list endpoint.\n\nJoins the tunnel diagnostics fields with organization context so admins\ncan see which tunnels are failing across orgs.","example":{}},"AffectedResourceResponse":{"properties":{"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type"},"resource_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Resource Id"},"resource_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Name"}},"type":"object","title":"AffectedResourceResponse","description":"Affected resource (environment, server, project, migration).","example":{}},"AgencyClientDomainAddRequest":{"properties":{"domain":{"type":"string","maxLength":253,"minLength":4,"title":"Domain","description":"The client's apex hostname (FQDN, no scheme)","examples":["odoo.acmecorp.com"]},"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Target environment in this project (must belong to project)"}},"type":"object","required":["domain","environment_id"],"title":"AgencyClientDomainAddRequest","description":"POST /api/v1/projects/{project_id}/client-domains body — spec §6.1."},"AgencyClientDomainCnameInfoResponse":{"properties":{"domain":{"type":"string","title":"Domain"},"cname":{"$ref":"#/components/schemas/CnameRecord"},"validation_records":{"items":{"$ref":"#/components/schemas/ValidationRecord"},"type":"array","title":"Validation Records"},"instructions":{"type":"string","title":"Instructions"},"estimated_time":{"type":"string","title":"Estimated Time","default":"5-60 minutes after CNAME is added"}},"type":"object","required":["domain","cname","instructions"],"title":"AgencyClientDomainCnameInfoResponse","description":"GET /client-domains/{id}/cname-info — spec §6.5."},"AgencyClientDomainListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AgencyClientDomainResponse"},"type":"array","title":"Items"},"soft_cap":{"type":"integer","title":"Soft Cap","default":100},"soft_cap_used":{"type":"integer","title":"Soft Cap Used","default":0}},"type":"object","required":["items"],"title":"AgencyClientDomainListResponse","description":"GET /client-domains response — spec §6.2."},"AgencyClientDomainResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id"},"environment_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Name"},"domain":{"type":"string","title":"Domain"},"cf_custom_hostname_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Custom Hostname Id"},"cf_custom_hostname_status":{"type":"string","title":"Cf Custom Hostname Status"},"cf_ssl_status":{"type":"string","title":"Cf Ssl Status"},"cname_target":{"type":"string","title":"Cname Target","default":"custom.oec.sh"},"validation_records":{"items":{"$ref":"#/components/schemas/ValidationRecord"},"type":"array","title":"Validation Records"},"last_cf_check_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Cf Check At"},"last_cf_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Cf Error"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","organization_id","project_id","domain","cf_custom_hostname_status","cf_ssl_status","created_at"],"title":"AgencyClientDomainResponse","description":"Single client-domain row response — spec §6.1."},"AgencyDomainConfigRequest":{"properties":{"agency_domain":{"type":"string","maxLength":255,"minLength":4,"title":"Agency Domain","description":"Agency domain (e.g., 'acmecloud.io')","examples":["acmecloud.io","clients.myagency.com"]},"dns_config_id":{"type":"string","format":"uuid","title":"Dns Config Id","description":"DNS config ID to use for managing subdomain records"}},"type":"object","required":["agency_domain","dns_config_id"],"title":"AgencyDomainConfigRequest","description":"Request schema for configuring an organization's agency domain."},"AgencyDomainConfigResponse":{"properties":{"agency_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agency Domain","description":"Configured agency domain"},"dns_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Dns Config Id","description":"DNS config ID used for managing subdomain records"},"dns_config_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dns Config Name","description":"Name of the DNS configuration"},"is_configured":{"type":"boolean","title":"Is Configured","description":"Whether agency domain is configured"},"active_subdomains_count":{"type":"integer","title":"Active Subdomains Count","description":"Number of active environment subdomains","default":0},"wildcard_cert_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wildcard Cert Status","description":"Wildcard cert status: not_requested, pending, active, configured, expired, error"},"wildcard_cert_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Wildcard Cert Expires At","description":"Wildcard certificate expiration date (UTC)"}},"type":"object","required":["is_configured"],"title":"AgencyDomainConfigResponse","description":"Response schema for agency domain configuration."},"AgencySubdomainListItem":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"environment_name":{"type":"string","title":"Environment Name"},"project_name":{"type":"string","title":"Project Name"},"subdomain":{"type":"string","title":"Subdomain"},"full_url":{"type":"string","title":"Full Url"},"status":{"type":"string","title":"Status"}},"type":"object","required":["environment_id","environment_name","project_name","subdomain","full_url","status"],"title":"AgencySubdomainListItem","description":"List item for agency subdomains."},"AgencySubdomainListResponse":{"properties":{"agency_domain":{"type":"string","title":"Agency Domain"},"subdomains":{"items":{"$ref":"#/components/schemas/AgencySubdomainListItem"},"type":"array","title":"Subdomains"},"total_count":{"type":"integer","title":"Total Count"}},"type":"object","required":["agency_domain","subdomains","total_count"],"title":"AgencySubdomainListResponse","description":"Response schema for listing all agency subdomains."},"AgencySubdomainRequest":{"properties":{"subdomain":{"type":"string","maxLength":63,"minLength":1,"title":"Subdomain","description":"Subdomain for the environment (e.g., 'client1')","examples":["client1","acme-prod","mycompany"]}},"type":"object","required":["subdomain"],"title":"AgencySubdomainRequest","description":"Request schema for setting an environment's agency subdomain."},"AgencySubdomainResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"agency_subdomain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agency Subdomain","description":"Configured subdomain"},"agency_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agency Url","description":"Full agency URL (e.g., https://client1.acmecloud.io)"},"dns_record_created":{"type":"boolean","title":"Dns Record Created","description":"Whether DNS A record was created","default":false}},"type":"object","required":["environment_id"],"title":"AgencySubdomainResponse","description":"Response schema for agency subdomain configuration."},"AggregateMetrics":{"properties":{"total_servers":{"type":"integer","minimum":0.0,"title":"Total Servers","description":"Total servers","default":0},"servers_healthy":{"type":"integer","minimum":0.0,"title":"Servers Healthy","description":"Servers with healthy status","default":0},"servers_warning":{"type":"integer","minimum":0.0,"title":"Servers Warning","description":"Servers with warning status","default":0},"servers_critical":{"type":"integer","minimum":0.0,"title":"Servers Critical","description":"Servers with critical status","default":0},"servers_unreachable":{"type":"integer","minimum":0.0,"title":"Servers Unreachable","description":"Servers unreachable","default":0},"avg_cpu_percent":{"type":"number","minimum":0.0,"title":"Avg Cpu Percent","description":"Average CPU percentage","default":0.0},"avg_memory_percent":{"type":"number","minimum":0.0,"title":"Avg Memory Percent","description":"Average memory percentage","default":0.0},"total_containers":{"type":"integer","minimum":0.0,"title":"Total Containers","description":"Total containers","default":0},"containers_healthy":{"type":"integer","minimum":0.0,"title":"Containers Healthy","description":"Healthy containers","default":0}},"type":"object","title":"AggregateMetrics","description":"Aggregate metrics across all servers.","example":{}},"AlertAcknowledgeRequest":{"properties":{"note":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Note","description":"Optional acknowledgment note"}},"type":"object","title":"AlertAcknowledgeRequest","description":"Request to acknowledge an alert.","example":{}},"AlertEventResponse":{"properties":{"alert_type":{"$ref":"#/components/schemas/AlertType","description":"Type of alert"},"severity":{"$ref":"#/components/schemas/AlertSeverity","description":"Severity level"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Short alert title"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Detailed message"},"metric_name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Metric Name","description":"Metric that triggered alert"},"metric_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Metric Value","description":"Value that triggered alert"},"threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Threshold","description":"Threshold that was exceeded"},"id":{"type":"string","format":"uuid","title":"Id","description":"Alert event ID"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"server_id":{"type":"string","format":"uuid","title":"Server Id","description":"Server ID"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id","description":"Environment ID"},"status":{"$ref":"#/components/schemas/AlertStatus","description":"Alert status"},"triggered_at":{"type":"string","format":"date-time","title":"Triggered At","description":"When alert was triggered"},"acknowledged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Acknowledged At","description":"When acknowledged"},"acknowledged_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Acknowledged By","description":"User who acknowledged"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At","description":"When resolved"},"fingerprint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fingerprint","description":"Deduplication fingerprint"},"occurrence_count":{"type":"integer","title":"Occurrence Count","description":"Number of occurrences","default":1},"last_occurrence":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Occurrence","description":"Last occurrence time"},"server_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Name","description":"Server name"},"environment_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Name","description":"Environment name"}},"type":"object","required":["alert_type","severity","title","id","organization_id","server_id","status","triggered_at"],"title":"AlertEventResponse","description":"Schema for alert event response.","example":{}},"AlertListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AlertEventResponse"},"type":"array","title":"Items","description":"List of alerts"},"total":{"type":"integer","title":"Total","description":"Total count"},"has_more":{"type":"boolean","title":"Has More","description":"Whether more items exist","default":false}},"type":"object","required":["items","total"],"title":"AlertListResponse","description":"Response for listing alerts.","example":{}},"AlertRuleCreate":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name","description":"Rule name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Rule description"},"alert_type":{"$ref":"#/components/schemas/AlertType","description":"Type of alert to trigger"},"severity":{"$ref":"#/components/schemas/AlertSeverity","description":"Severity level"},"metric_name":{"type":"string","maxLength":100,"title":"Metric Name","description":"Metric to monitor"},"operator":{"type":"string","pattern":"^(>|<|>=|<=|==)$","title":"Operator","description":"Comparison operator","default":">"},"threshold":{"type":"number","title":"Threshold","description":"Threshold value"},"duration_seconds":{"type":"integer","minimum":0.0,"title":"Duration Seconds","description":"Duration threshold must be exceeded","default":300},"notify_channels":{"items":{"type":"string"},"type":"array","title":"Notify Channels","description":"Notification channels"},"cooldown_seconds":{"type":"integer","minimum":0.0,"title":"Cooldown Seconds","description":"Cooldown between alerts","default":3600},"is_active":{"type":"boolean","title":"Is Active","description":"Whether rule is active","default":true}},"type":"object","required":["name","alert_type","severity","metric_name","threshold"],"title":"AlertRuleCreate","description":"Schema for creating an alert rule.","example":{}},"AlertRuleResponse":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name","description":"Rule name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Rule description"},"alert_type":{"$ref":"#/components/schemas/AlertType","description":"Type of alert to trigger"},"severity":{"$ref":"#/components/schemas/AlertSeverity","description":"Severity level"},"metric_name":{"type":"string","maxLength":100,"title":"Metric Name","description":"Metric to monitor"},"operator":{"type":"string","pattern":"^(>|<|>=|<=|==)$","title":"Operator","description":"Comparison operator","default":">"},"threshold":{"type":"number","title":"Threshold","description":"Threshold value"},"duration_seconds":{"type":"integer","minimum":0.0,"title":"Duration Seconds","description":"Duration threshold must be exceeded","default":300},"notify_channels":{"items":{"type":"string"},"type":"array","title":"Notify Channels","description":"Notification channels"},"cooldown_seconds":{"type":"integer","minimum":0.0,"title":"Cooldown Seconds","description":"Cooldown between alerts","default":3600},"is_active":{"type":"boolean","title":"Is Active","description":"Whether rule is active","default":true},"id":{"type":"string","format":"uuid","title":"Id","description":"Rule ID"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization ID (null = global)"},"create_date":{"type":"string","format":"date-time","title":"Create Date","description":"Created at"}},"type":"object","required":["name","alert_type","severity","metric_name","threshold","id","create_date"],"title":"AlertRuleResponse","description":"Schema for alert rule response.","example":{}},"AlertRuleUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"severity":{"anyOf":[{"$ref":"#/components/schemas/AlertSeverity"},{"type":"null"}]},"threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Threshold"},"duration_seconds":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Duration Seconds"},"notify_channels":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Notify Channels"},"cooldown_seconds":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Cooldown Seconds"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"AlertRuleUpdate","description":"Schema for updating an alert rule.","example":{}},"AlertSeverity":{"type":"string","enum":["info","warning","error","critical"],"title":"AlertSeverity","description":"Alert severity levels."},"AlertStats":{"properties":{"critical":{"type":"integer","minimum":0.0,"title":"Critical","description":"Number of critical alerts","default":0},"warning":{"type":"integer","minimum":0.0,"title":"Warning","description":"Number of warning alerts","default":0},"info":{"type":"integer","minimum":0.0,"title":"Info","description":"Number of info alerts","default":0},"total_active":{"type":"integer","minimum":0.0,"title":"Total Active","description":"Total active alerts","default":0}},"type":"object","title":"AlertStats","description":"Alert statistics for dashboard overview.","example":{}},"AlertStatus":{"type":"string","enum":["triggered","acknowledged","resolved"],"title":"AlertStatus","description":"Alert lifecycle status."},"AlertType":{"type":"string","enum":["cpu_high","memory_high","disk_high","container_down","container_restart","server_unreachable","backup_failed","custom"],"title":"AlertType","description":"Types of alerts."},"AllPlatformSettingsResponse":{"properties":{"dns":{"$ref":"#/components/schemas/DNSPlatformSettingsResponse"}},"type":"object","required":["dns"],"title":"AllPlatformSettingsResponse","description":"All platform settings."},"AllocatedByInfo":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"}},"type":"object","required":["id","email"],"title":"AllocatedByInfo","description":"Information about who allocated the resource."},"AllocatedTotalInfo":{"properties":{"cpu_cores":{"type":"number","title":"Cpu Cores"},"ram_mb":{"type":"integer","title":"Ram Mb"},"disk_gb":{"type":"integer","title":"Disk Gb"},"environments":{"type":"integer","title":"Environments"}},"type":"object","required":["cpu_cores","ram_mb","disk_gb","environments"],"title":"AllocatedTotalInfo","description":"Total allocated resources on a shared server."},"AllocationCreate":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization to allocate to"},"max_environments":{"type":"integer","minimum":1.0,"title":"Max Environments","description":"Maximum environments"},"cpu_quota":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"string"}],"title":"Cpu Quota","description":"CPU cores quota"},"ram_quota_mb":{"type":"integer","exclusiveMinimum":0.0,"title":"Ram Quota Mb","description":"RAM quota in MB"},"disk_quota_gb":{"type":"integer","exclusiveMinimum":0.0,"title":"Disk Quota Gb","description":"Disk quota in GB"},"expires_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires Date","description":"Expiration date (optional)"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Admin notes"}},"type":"object","required":["organization_id","max_environments","cpu_quota","ram_quota_mb","disk_quota_gb"],"title":"AllocationCreate","description":"Request schema for creating an allocation.","example":{"cpu_quota":2.0,"disk_quota_gb":20,"expires_date":"2025-12-17T00:00:00Z","max_environments":2,"notes":"Free tier allocation - 1 year trial","organization_id":"123e4567-e89b-12d3-a456-426614174000","ram_quota_mb":4096}},"AllocationListResponse":{"properties":{"allocations":{"items":{"$ref":"#/components/schemas/AllocationResponse"},"type":"array","title":"Allocations"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["allocations","total"],"title":"AllocationListResponse","description":"Response schema for listing allocations."},"AllocationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"vm_id":{"type":"string","format":"uuid","title":"Vm Id"},"vm_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vm Name"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name"},"max_environments":{"type":"integer","title":"Max Environments"},"cpu_quota":{"type":"string","title":"Cpu Quota"},"ram_quota_mb":{"type":"integer","title":"Ram Quota Mb"},"disk_quota_gb":{"type":"integer","title":"Disk Quota Gb"},"is_active":{"type":"boolean","title":"Is Active"},"allocated_date":{"type":"string","format":"date-time","title":"Allocated Date"},"expires_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires Date"},"revoked_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked Date"},"allocated_by":{"anyOf":[{"$ref":"#/components/schemas/AllocatedByInfo"},{"type":"null"}]},"revoked_by":{"anyOf":[{"$ref":"#/components/schemas/AllocatedByInfo"},{"type":"null"}]},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"current_usage":{"anyOf":[{"$ref":"#/components/schemas/CurrentUsageInfo"},{"type":"null"}]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","vm_id","organization_id","max_environments","cpu_quota","ram_quota_mb","disk_quota_gb","is_active","allocated_date","expires_date","revoked_date","notes","created_at","updated_at"],"title":"AllocationResponse","description":"Response schema for allocation details."},"AllocationRevokeResponse":{"properties":{"message":{"type":"string","title":"Message"},"allocation_id":{"type":"string","format":"uuid","title":"Allocation Id"},"is_active":{"type":"boolean","title":"Is Active"},"revoked_date":{"type":"string","format":"date-time","title":"Revoked Date"},"grace_period_ends":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Grace Period Ends"},"environments_affected":{"type":"integer","title":"Environments Affected"},"action_taken":{"type":"string","title":"Action Taken"}},"type":"object","required":["message","allocation_id","is_active","revoked_date","grace_period_ends","environments_affected","action_taken"],"title":"AllocationRevokeResponse","description":"Response schema for allocation revocation."},"AllocationUpdate":{"properties":{"max_environments":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Max Environments"},"cpu_quota":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"string"},{"type":"null"}],"title":"Cpu Quota"},"ram_quota_mb":{"anyOf":[{"type":"integer","exclusiveMinimum":0.0},{"type":"null"}],"title":"Ram Quota Mb"},"disk_quota_gb":{"anyOf":[{"type":"integer","exclusiveMinimum":0.0},{"type":"null"}],"title":"Disk Quota Gb"},"expires_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"AllocationUpdate","description":"Request schema for updating an allocation.","example":{"cpu_quota":4.0,"expires_date":"2026-12-17T00:00:00Z","max_environments":5,"notes":"Upgraded to professional tier","ram_quota_mb":8192}},"AnnouncementListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AnnouncementResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"}},"type":"object","required":["items","total","page","per_page"],"title":"AnnouncementListResponse"},"AnnouncementMarkSeenRequest":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key","description":"Stable announcement key (e.g. 'mailtest_rollout_2026_q2')"}},"type":"object","required":["key"],"title":"AnnouncementMarkSeenRequest","description":"Body for POST /api/v1/me/announcements/mark-seen.","example":{}},"AnnouncementResponse":{"properties":{"id":{"type":"string","title":"Id"},"title":{"type":"string","title":"Title"},"content":{"type":"string","title":"Content"},"announcement_type":{"type":"string","title":"Announcement Type"},"is_active":{"type":"boolean","title":"Is Active"},"link_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Link Url"},"link_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Link Text"},"secondary_link_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary Link Url"},"secondary_link_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary Link Text"},"display_until":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Until"},"created_by_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Id"},"create_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Create Date"}},"type":"object","required":["id","title","content","announcement_type","is_active"],"title":"AnnouncementResponse"},"AnnouncementSeenResponse":{"properties":{"key":{"type":"string","title":"Key"},"seen_at":{"type":"string","format":"date-time","title":"Seen At"}},"type":"object","required":["key","seen_at"],"title":"AnnouncementSeenResponse","description":"Return shape for mark-seen endpoint.","example":{}},"AnnouncementUnseenResponse":{"properties":{"unseen_keys":{"items":{"type":"string"},"type":"array","title":"Unseen Keys"}},"type":"object","title":"AnnouncementUnseenResponse","description":"Return shape for GET /api/v1/me/announcements/unseen.\n\nThe server returns a list of keys that are currently live AND unseen for\nthe calling user. The set of live keys is product-config driven (not in\nthe DB yet); Day 6 wires the endpoint against a hard-coded list.","example":{}},"AssignRoleRequest":{"properties":{"role_id":{"type":"string","format":"uuid","title":"Role Id","description":"Role to assign"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization context (null for portal-level)"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id","description":"Project context (null for org-level)"}},"type":"object","required":["role_id"],"title":"AssignRoleRequest","description":"Request to assign a role to a user.","example":{}},"AtRiskOrg":{"properties":{"org_id":{"type":"string","title":"Org Id"},"org_name":{"type":"string","title":"Org Name"},"plan":{"type":"string","title":"Plan"},"billing_interval":{"type":"string","title":"Billing Interval"},"signals":{"items":{"type":"string"},"type":"array","title":"Signals"},"owner_email":{"type":"string","title":"Owner Email"},"customer_since":{"type":"string","title":"Customer Since"},"last_alert_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Alert At"}},"type":"object","required":["org_id","org_name","plan","billing_interval","signals","owner_email","customer_since","last_alert_at"],"title":"AtRiskOrg","description":"At-risk organization with churn signals."},"AttachmentUploadResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"file_name":{"type":"string","title":"File Name"},"file_size":{"type":"integer","title":"File Size"},"content_type":{"type":"string","title":"Content Type"},"ticket_id":{"type":"string","format":"uuid","title":"Ticket Id"},"comment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Comment Id"},"uploaded_by":{"type":"string","format":"uuid","title":"Uploaded By"}},"type":"object","required":["id","file_name","file_size","content_type","ticket_id","uploaded_by"],"title":"AttachmentUploadResponse","description":"Response after a direct file upload for a ticket attachment.","example":{}},"AuditActionInfo":{"properties":{"value":{"type":"string","title":"Value","description":"Action identifier"},"display":{"type":"string","title":"Display","description":"Human-readable name"},"category":{"type":"string","title":"Category","description":"Action category"}},"type":"object","required":["value","display","category"],"title":"AuditActionInfo","description":"Information about an audit action type.","example":{}},"AuditActionsListResponse":{"properties":{"actions":{"items":{"$ref":"#/components/schemas/AuditActionInfo"},"type":"array","title":"Actions","description":"Available audit actions"}},"type":"object","required":["actions"],"title":"AuditActionsListResponse","description":"List of available audit actions.","example":{}},"AuditActorOption":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"}},"type":"object","required":["user_id"],"title":"AuditActorOption","description":"A person who appears in the org's audit log.","example":{}},"AuditFilterOptionsResponse":{"properties":{"actions":{"items":{"$ref":"#/components/schemas/AuditActionInfo"},"type":"array","title":"Actions","description":"Actions present in the log"},"resource_types":{"items":{"type":"string"},"type":"array","title":"Resource Types","description":"Resource types present in the log"},"actors":{"items":{"$ref":"#/components/schemas/AuditActorOption"},"type":"array","title":"Actors","description":"People present in the log"}},"type":"object","required":["actions","resource_types","actors"],"title":"AuditFilterOptionsResponse","description":"#1431: filter values actually present in the org's audit log.","example":{}},"AuditLogListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AuditLogResponse"},"type":"array","title":"Items","description":"List of audit logs"},"total":{"type":"integer","title":"Total","description":"Total number of matching logs"},"skip":{"type":"integer","title":"Skip","description":"Number of items skipped","default":0},"limit":{"type":"integer","title":"Limit","description":"Maximum items returned","default":50},"has_more":{"type":"boolean","title":"Has More","description":"Whether more items are available"}},"type":"object","required":["items","total","has_more"],"title":"AuditLogListResponse","description":"Response schema for paginated audit log list.","example":{}},"AuditLogResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"When the action occurred"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id","description":"User who performed the action"},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email","description":"Email of the user"},"action":{"type":"string","title":"Action","description":"Type of action performed"},"action_display":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action Display","description":"Human-readable action name"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization context"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization name"},"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type","description":"Type of affected resource"},"resource_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Resource Id","description":"ID of affected resource"},"resource_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Name","description":"Name of affected resource"},"details":{"type":"object","title":"Details","description":"Additional details"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"Client IP address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent","description":"Client user agent"},"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id","description":"Request trace ID"}},"type":"object","required":["id","timestamp","action"],"title":"AuditLogResponse","description":"Response schema for audit log entries.","example":{}},"AuthProvidersResponse":{"properties":{"oauth_providers":{"items":{"type":"string"},"type":"array","title":"Oauth Providers"},"email_password_enabled":{"type":"boolean","title":"Email Password Enabled"},"passkey_enabled":{"type":"boolean","title":"Passkey Enabled"}},"type":"object","required":["oauth_providers","email_password_enabled","passkey_enabled"],"title":"AuthProvidersResponse","description":"Response containing enabled authentication providers."},"AuthenticatedPreferencesUpdate":{"properties":{"lifecycle_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Lifecycle Enabled"},"marketing_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Marketing Enabled"},"alerts_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Alerts Enabled"},"educational_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Educational Enabled"},"news_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"News Enabled"}},"type":"object","title":"AuthenticatedPreferencesUpdate"},"AutoDeployConfig":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether auto-deployment is enabled","default":false},"branch_patterns":{"items":{"type":"string"},"type":"array","title":"Branch Patterns","description":"Glob patterns for branches to auto-deploy (e.g., 'main', 'release/*', 'feature-*'). Empty = only the environment's own branch; '*' = every branch (#1363)."},"cooldown_minutes":{"type":"integer","maximum":1440.0,"minimum":0.0,"title":"Cooldown Minutes","description":"Minimum time between auto-deploys in minutes (0 = no cooldown)","default":0},"include_paths":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Include Paths","description":"Only auto-deploy if changes are in these paths (glob patterns). None = all paths"},"exclude_paths":{"items":{"type":"string"},"type":"array","title":"Exclude Paths","description":"Skip auto-deploy if ONLY these paths changed (e.g., 'docs/*', '*.md')"},"update_modules":{"type":"boolean","title":"Update Modules","description":"#877: also run a module update after the auto-deploy. An auto-deploy pulls the new code and restarts, which is enough for Python/QWeb changes but NOT for schema changes - new fields do not appear until the modules are upgraded. Off by default because a module update takes the environment through a schema upgrade, which is not something to do on every push to a production environment without asking.","default":false},"deploy_window":{"anyOf":[{"$ref":"#/components/schemas/DeployWindow"},{"type":"null"}],"description":"#1260: only deploy pushes inside this window; pushes outside it are held and the latest one deploys when the window opens. null = any time."}},"type":"object","title":"AutoDeployConfig","description":"Auto-deployment rule configuration.\n\nControls automatic deployment behavior based on branch patterns, cooldown periods,\nand file path filters. Similar to GitHub Actions / GitLab CI patterns but simpler.","example":{"branch_patterns":["main","release/*"],"cooldown_minutes":5,"enabled":true,"exclude_paths":["docs/*","*.md"],"include_paths":["addons/*","requirements.txt"],"update_modules":false}},"AutoTuneResult":{"properties":{"workers":{"type":"integer","title":"Workers","description":"HTTP worker processes"},"max_cron_threads":{"type":"integer","title":"Max Cron Threads","description":"Cron threads"},"limit_memory_soft_mb":{"type":"integer","title":"Limit Memory Soft Mb","description":"Per-worker soft memory limit in MB"},"limit_memory_hard_mb":{"type":"integer","title":"Limit Memory Hard Mb","description":"Per-worker hard memory limit in MB"},"db_maxconn":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Db Maxconn","description":"Per-process DB connection cap"},"cpu_cores":{"type":"number","title":"Cpu Cores","description":"Environment CPU allocation the figures derive from"},"ram_mb":{"type":"integer","title":"Ram Mb","description":"Environment RAM allocation the figures derive from"},"odoo_cpu_cores":{"type":"number","title":"Odoo Cpu Cores","description":"CPU share of the Odoo container"},"odoo_ram_mb":{"type":"integer","title":"Odoo Ram Mb","description":"RAM of the Odoo container"},"postgres_cpu_cores":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Postgres Cpu Cores","description":"CPU share of PostgreSQL"},"postgres_ram_mb":{"type":"integer","title":"Postgres Ram Mb","description":"RAM of the PostgreSQL container"},"addon_count":{"type":"integer","title":"Addon Count","description":"Add-on modules counted at the last deploy","default":0},"generated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Generated At","description":"When odoo.conf was last generated with these values (applied only)"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Which path generated them: deploy | config_regeneration"}},"type":"object","required":["workers","max_cron_threads","limit_memory_soft_mb","limit_memory_hard_mb","cpu_cores","ram_mb","odoo_cpu_cores","odoo_ram_mb","postgres_ram_mb"],"title":"AutoTuneResult","description":"What Auto-Tune produces for one CPU/RAM allocation (#1029).","example":{}},"AutomationRuleAction":{"type":"string","enum":["deploy","quick_update","create_ephemeral_env","clone_neutralize_deploy","promote","destroy_env","blue_green_deploy"],"title":"AutomationRuleAction","description":"What action the rule performs when triggered."},"AutomationRuleConditions":{"properties":{"cooldown_minutes":{"type":"integer","maximum":1440.0,"minimum":0.0,"title":"Cooldown Minutes","description":"Minimum minutes between consecutive rule executions. 0 = no cooldown.","default":0},"include_paths":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Include Paths","description":"Glob patterns for file paths that must appear in the commit diff. None = any file change satisfies the condition."},"exclude_paths":{"items":{"type":"string"},"type":"array","title":"Exclude Paths","description":"Glob patterns for file paths that, when the only changes, skip the rule."},"require_env_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Require Env Status","description":"Target environment must be in this status to fire. One of: running | stopped | None (any status)."}},"type":"object","title":"AutomationRuleConditions","description":"Additional conditions that must be satisfied before an automation rule fires."},"AutomationRuleCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name","description":"Human-readable rule name."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional longer description of what this rule does."},"is_active":{"type":"boolean","title":"Is Active","description":"Whether this rule is enabled and will trigger on events.","default":true},"priority":{"type":"integer","maximum":9999.0,"minimum":1.0,"title":"Priority","description":"Execution priority when multiple rules match the same event. Lower number = higher priority.","default":100},"trigger_type":{"$ref":"#/components/schemas/AutomationRuleTrigger","description":"Event type that fires this rule."},"trigger_config":{"type":"object","title":"Trigger Config","description":"Trigger-specific configuration. Use PushTriggerConfig / PRTriggerConfig / ManualTriggerConfig / ScheduleTriggerConfig for the shape."},"conditions":{"$ref":"#/components/schemas/AutomationRuleConditions","description":"Additional conditions that must be met for the rule to fire."},"action_type":{"$ref":"#/components/schemas/AutomationRuleAction","description":"Action to perform when the rule is triggered."},"action_config":{"oneOf":[{"$ref":"#/components/schemas/DeployActionConfig"},{"$ref":"#/components/schemas/QuickUpdateActionConfig"},{"$ref":"#/components/schemas/CloneNeutralizeActionConfig"},{"$ref":"#/components/schemas/PromoteActionConfig"},{"$ref":"#/components/schemas/DestroyEnvActionConfig"}],"title":"Action Config","description":"Action-specific configuration. Must match action_type.","discriminator":{"propertyName":"action_type","mapping":{"clone_neutralize_deploy":"#/components/schemas/CloneNeutralizeActionConfig","deploy":"#/components/schemas/DeployActionConfig","destroy_env":"#/components/schemas/DestroyEnvActionConfig","promote":"#/components/schemas/PromoteActionConfig","quick_update":"#/components/schemas/QuickUpdateActionConfig"}}},"require_approval":{"type":"boolean","title":"Require Approval","description":"If True, a human must approve before the action executes.","default":false},"approval_expires_minutes":{"type":"integer","maximum":1440.0,"minimum":5.0,"title":"Approval Expires Minutes","description":"Minutes the approval window is open before it expires.","default":15},"retry_policy":{"$ref":"#/components/schemas/RetryPolicy","description":"Retry configuration for failed steps."},"circuit_breaker":{"$ref":"#/components/schemas/CircuitBreakerConfig","description":"Circuit breaker configuration."}},"type":"object","required":["name","trigger_type","action_type","action_config"],"title":"AutomationRuleCreate","description":"Payload for creating a new automation rule."},"AutomationRuleListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AutomationRuleResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"limit":{"type":"integer","title":"Limit"},"offset":{"type":"integer","title":"Offset"}},"type":"object","required":["items","total","limit","offset"],"title":"AutomationRuleListResponse","description":"Paginated list of automation rules."},"AutomationRuleReorderItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"priority":{"type":"integer","maximum":9999.0,"minimum":1.0,"title":"Priority"}},"type":"object","required":["id","priority"],"title":"AutomationRuleReorderItem","description":"A single (rule id, new priority) pair for batch reordering."},"AutomationRuleReorderRequest":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AutomationRuleReorderItem"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"AutomationRuleReorderRequest","description":"Batch priority reorder request for automation rules in a project."},"AutomationRuleReorderResponse":{"properties":{"updated":{"type":"integer","title":"Updated"}},"type":"object","required":["updated"],"title":"AutomationRuleReorderResponse","description":"Response returned after a successful batch priority reorder."},"AutomationRuleResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"},"priority":{"type":"integer","title":"Priority"},"trigger_type":{"$ref":"#/components/schemas/AutomationRuleTrigger"},"trigger_config":{"type":"object","title":"Trigger Config"},"conditions":{"type":"object","title":"Conditions"},"action_type":{"$ref":"#/components/schemas/AutomationRuleAction"},"action_config":{"type":"object","title":"Action Config"},"require_approval":{"type":"boolean","title":"Require Approval"},"approval_expires_minutes":{"type":"integer","title":"Approval Expires Minutes"},"retry_policy":{"type":"object","title":"Retry Policy"},"circuit_breaker":{"type":"object","title":"Circuit Breaker"},"last_triggered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Triggered At"},"trigger_count":{"type":"integer","title":"Trigger Count"},"consecutive_failure_count":{"type":"integer","title":"Consecutive Failure Count"},"disabled_reason":{"anyOf":[{"$ref":"#/components/schemas/DisabledReason"},{"type":"null"}]},"last_failure_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Failure At"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","project_id","name","description","is_active","priority","trigger_type","trigger_config","conditions","action_type","action_config","require_approval","approval_expires_minutes","retry_policy","circuit_breaker","last_triggered_at","trigger_count","consecutive_failure_count","disabled_reason","last_failure_at","created_by","created_at","updated_at"],"title":"AutomationRuleResponse","description":"Automation rule details returned by list/get/create/update endpoints."},"AutomationRuleRunListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AutomationRuleRunResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"limit":{"type":"integer","title":"Limit"},"offset":{"type":"integer","title":"Offset"}},"type":"object","required":["items","total","limit","offset"],"title":"AutomationRuleRunListResponse","description":"Paginated list of automation rule execution runs."},"AutomationRuleRunResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"rule_id":{"type":"string","format":"uuid","title":"Rule Id"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"rule_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rule Name"},"action_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action Type"},"trigger_type":{"type":"string","title":"Trigger Type"},"trigger_payload":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Trigger Payload"},"status":{"$ref":"#/components/schemas/AutomationRuleRunStatus"},"skip_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Skip Reason"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"step_timings":{"type":"object","title":"Step Timings"},"retry_count":{"type":"integer","title":"Retry Count"},"webhook_delivery_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Webhook Delivery Id"},"rolled_back_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Rolled Back By"},"retry_of_run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Retry Of Run Id"},"rolled_back_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Rolled Back At"},"approval_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approval Expires At"},"approved_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Approved By"},"deployment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Deployment Id"},"created_env_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created Env Id"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"}},"type":"object","required":["id","rule_id","project_id","trigger_type","trigger_payload","status","skip_reason","error_message","step_timings","retry_count","webhook_delivery_id","rolled_back_by","retry_of_run_id","rolled_back_at","approval_expires_at","approved_by","deployment_id","created_env_id","started_at","updated_at","completed_at"],"title":"AutomationRuleRunResponse","description":"Details of a single automation rule execution."},"AutomationRuleRunStatus":{"type":"string","enum":["pending","running","completed","failed","skipped","pending_approval","approved","rejected","approval_expired","rolled_back"],"title":"AutomationRuleRunStatus","description":"Status of a single automation rule execution."},"AutomationRuleTrigger":{"type":"string","enum":["push","pr_open","pr_merge","pr_close","tag_push","manual","schedule"],"title":"AutomationRuleTrigger","description":"What git/platform event triggers an automation rule."},"AutomationRuleUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name","description":"Human-readable rule name."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional longer description."},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Enable or disable the rule."},"priority":{"anyOf":[{"type":"integer","maximum":9999.0,"minimum":1.0},{"type":"null"}],"title":"Priority","description":"Execution priority (lower = higher priority)."},"trigger_type":{"anyOf":[{"$ref":"#/components/schemas/AutomationRuleTrigger"},{"type":"null"}],"description":"Updated trigger type (push, pr_open, pr_merge, pr_close, tag_push, manual, schedule)."},"trigger_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Trigger Config","description":"Updated trigger-specific configuration."},"conditions":{"anyOf":[{"$ref":"#/components/schemas/AutomationRuleConditions"},{"type":"null"}],"description":"Updated conditions."},"action_type":{"anyOf":[{"$ref":"#/components/schemas/AutomationRuleAction"},{"type":"null"}],"description":"Action type — must be set when updating action_config to keep the DB column in sync."},"action_config":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/DeployActionConfig"},{"$ref":"#/components/schemas/QuickUpdateActionConfig"},{"$ref":"#/components/schemas/CloneNeutralizeActionConfig"},{"$ref":"#/components/schemas/PromoteActionConfig"},{"$ref":"#/components/schemas/DestroyEnvActionConfig"}],"discriminator":{"propertyName":"action_type","mapping":{"clone_neutralize_deploy":"#/components/schemas/CloneNeutralizeActionConfig","deploy":"#/components/schemas/DeployActionConfig","destroy_env":"#/components/schemas/DestroyEnvActionConfig","promote":"#/components/schemas/PromoteActionConfig","quick_update":"#/components/schemas/QuickUpdateActionConfig"}}},{"type":"null"}],"title":"Action Config","description":"Updated action-specific configuration."},"require_approval":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Require Approval","description":"Update the approval gate requirement."},"approval_expires_minutes":{"anyOf":[{"type":"integer","maximum":1440.0,"minimum":5.0},{"type":"null"}],"title":"Approval Expires Minutes","description":"Updated approval expiry window in minutes."},"retry_policy":{"anyOf":[{"$ref":"#/components/schemas/RetryPolicy"},{"type":"null"}],"description":"Updated retry policy."},"circuit_breaker":{"anyOf":[{"$ref":"#/components/schemas/CircuitBreakerConfig"},{"type":"null"}],"description":"Updated circuit breaker configuration."}},"type":"object","title":"AutomationRuleUpdate","description":"Payload for updating an existing automation rule (all fields optional)."},"AvailableAction":{"properties":{"action":{"$ref":"#/components/schemas/EnvironmentAction","description":"Action identifier"},"label":{"type":"string","title":"Label","description":"Display label for the action"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Detailed description of what this action does"},"destructive":{"type":"boolean","title":"Destructive","description":"Whether this action is destructive (requires confirmation)","default":false},"confirm_required":{"type":"boolean","title":"Confirm Required","description":"Whether user confirmation is required before performing","default":false},"async_operation":{"type":"boolean","title":"Async Operation","description":"Whether this action is queued/async (returns task_id)","default":false}},"type":"object","required":["action","label"],"title":"AvailableAction","description":"An action available for the current state.","example":{}},"AvailableActionsResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"current_status":{"type":"string","title":"Current Status","description":"Current environment status"},"available_actions":{"items":{"$ref":"#/components/schemas/AvailableAction"},"type":"array","title":"Available Actions","description":"List of actions available in current state"},"pending_changes":{"type":"boolean","title":"Pending Changes","description":"Whether there are pending changes (code updates, config changes)","default":false},"last_deployed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Deployed At","description":"Timestamp of last successful deployment"}},"type":"object","required":["environment_id","current_status","available_actions"],"title":"AvailableActionsResponse","description":"Response with available actions for an environment.","example":{}},"AvailableAddonRepo":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Repository ID"},"repo_type":{"$ref":"#/components/schemas/RepoType","description":"Type of repo (platform/organization)"},"name":{"type":"string","title":"Name","description":"Repository display name"},"slug":{"type":"string","title":"Slug","description":"URL-friendly identifier"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Repository description"},"git_repo_url":{"type":"string","title":"Git Repo Url","description":"Git repository URL"},"git_provider":{"$ref":"#/components/schemas/GitProvider-Output","description":"Git provider — the branch selector needs this to fetch branches; sniffing it from git_repo_url alone can never produce 'generic' (self-hosted Gitea/Forgejo/GitHub-Enterprise, #993)"},"is_public":{"type":"boolean","title":"Is Public","description":"Whether repository is public"},"priority":{"type":"integer","title":"Priority","description":"Load priority"},"default_selected":{"type":"boolean","title":"Default Selected","description":"Whether selected by default for new projects"},"estimated_size_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Size Mb","description":"Estimated repository size in MB"},"is_selected":{"type":"boolean","title":"Is Selected","description":"Whether this repo is selected for the project"}},"type":"object","required":["id","repo_type","name","slug","description","git_repo_url","git_provider","is_public","priority","default_selected","estimated_size_mb","is_selected"],"title":"AvailableAddonRepo","description":"An available addon repo with selection status.","example":{}},"AvailableBucket":{"properties":{"name":{"type":"string","title":"Name","description":"Name of the bucket."},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region","description":"Region where the bucket is located (if available)."},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Timestamp when the bucket was created (if available)."}},"type":"object","required":["name"],"title":"AvailableBucket","description":"Schema for a single available bucket from the provider."},"AvailableBucketsResponse":{"properties":{"buckets":{"items":{"$ref":"#/components/schemas/AvailableBucket"},"type":"array","title":"Buckets","description":"List of available buckets from the cloud provider.","default":[]}},"type":"object","title":"AvailableBucketsResponse","description":"Response schema for listing available buckets."},"AvailableConnectionsResponse":{"properties":{"connections":{"items":{"$ref":"#/components/schemas/ConnectionInfo"},"type":"array","title":"Connections"}},"type":"object","required":["connections"],"title":"AvailableConnectionsResponse","description":"List of available Git connections."},"AvailableRegion":{"properties":{"value":{"type":"string","title":"Value","description":"Region identifier/code to use in API calls"},"label":{"type":"string","title":"Label","description":"Human-readable region name"}},"type":"object","required":["value","label"],"title":"AvailableRegion","description":"Schema for an available storage region from the cloud provider."},"AvailableRegionsResponse":{"properties":{"regions":{"items":{"$ref":"#/components/schemas/AvailableRegion"},"type":"array","title":"Regions","description":"List of available regions from the cloud provider","default":[]},"provider":{"type":"string","title":"Provider","description":"Cloud provider that owns these regions"},"account_name":{"type":"string","title":"Account Name","description":"Name of the cloud account"}},"type":"object","required":["provider","account_name"],"title":"AvailableRegionsResponse","description":"Response schema for available storage regions."},"AvailableServicesResponse":{"properties":{"dns_providers":{"items":{"type":"object"},"type":"array","title":"Dns Providers","description":"DNS providers available for this cloud account"},"storage_providers":{"items":{"type":"object"},"type":"array","title":"Storage Providers","description":"Storage providers available for this cloud account"},"split_token_warnings":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Split Token Warnings","description":"Warnings about providers that need separate tokens"}},"type":"object","required":["dns_providers","storage_providers"],"title":"AvailableServicesResponse","description":"Response schema for services available from a specific cloud account."},"AvailableZone":{"properties":{"zone_id":{"type":"string","title":"Zone Id","description":"Provider's unique zone identifier"},"domain":{"type":"string","title":"Domain","description":"Domain name (e.g., 'example.com')"},"record_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Record Count","description":"Number of DNS records in the zone (if available)"}},"type":"object","required":["zone_id","domain"],"title":"AvailableZone","description":"Schema for an available DNS zone from the cloud provider."},"AvailableZonesResponse":{"properties":{"zones":{"items":{"$ref":"#/components/schemas/AvailableZone"},"type":"array","title":"Zones","description":"List of available DNS zones from the cloud provider","default":[]},"provider":{"type":"string","title":"Provider","description":"Cloud provider that owns these zones"},"account_name":{"type":"string","title":"Account Name","description":"Name of the cloud account"},"dns_setup_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dns Setup Hint","description":"Hint message when DNS API is not enabled, with enable URL"},"dns_enable_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dns Enable Url","description":"Direct URL to enable the DNS API on the cloud project"}},"type":"object","required":["provider","account_name"],"title":"AvailableZonesResponse","description":"Response schema for available DNS zones."},"BackupComplianceResponse":{"properties":{"compliance_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Compliance Percent","description":"Percentage of compliant environments"},"environments_compliant":{"type":"integer","minimum":0.0,"title":"Environments Compliant","description":"Number of compliant environments"},"environments_total":{"type":"integer","minimum":0.0,"title":"Environments Total","description":"Total environments"},"non_compliant":{"items":{"$ref":"#/components/schemas/NonCompliantEnvironment"},"type":"array","title":"Non Compliant","description":"List of non-compliant environments"},"failed_24h":{"items":{"$ref":"#/components/schemas/FailedBackupInfo"},"type":"array","title":"Failed 24H","description":"List of failed backups in last 24 hours"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"When compliance was checked"}},"type":"object","required":["compliance_percent","environments_compliant","environments_total","timestamp"],"title":"BackupComplianceResponse","description":"Detailed backup compliance information.","example":{}},"BackupCreate":{"properties":{"backup_type":{"$ref":"#/components/schemas/BackupType","description":"Type of backup","default":"manual"},"storage_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Config Id","description":"Storage config to use (uses default if not specified)"},"include_filestore":{"type":"boolean","title":"Include Filestore","description":"Include filestore in backup","default":true},"retention_type":{"anyOf":[{"$ref":"#/components/schemas/RetentionType"},{"type":"null"}],"description":"Retention tier (permanent, never deleted, if not specified)"},"notes":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Notes","description":"Optional freeform note describing what's in this backup (max 500 chars)"}},"type":"object","title":"BackupCreate","description":"Schema for creating a manual backup.","example":{}},"BackupDownloadResponse":{"properties":{"backup_id":{"type":"string","format":"uuid","title":"Backup Id","description":"Backup ID"},"database_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Database Url","description":"Presigned URL to download database backup"},"filestore_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filestore Url","description":"Presigned URL to download filestore backup"},"manifest_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manifest Url","description":"Presigned URL to download backup manifest"},"expires_in":{"type":"integer","title":"Expires In","description":"URL validity in seconds"},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"URL expiration timestamp"},"use_streaming":{"type":"boolean","title":"Use Streaming","description":"True if URLs are backend streaming endpoints (when signed URLs are not available)","default":false}},"type":"object","required":["backup_id","expires_in","expires_at"],"title":"BackupDownloadResponse","description":"Response with presigned download URLs.","example":{}},"BackupHandlingAction":{"type":"string","enum":["keep_all","delete_all","keep_latest"],"title":"BackupHandlingAction","description":"What to do with backups when deleting an environment."},"BackupHealthSummary":{"properties":{"total_backups":{"type":"integer","title":"Total Backups"},"successful_last_24h":{"type":"integer","title":"Successful Last 24H"},"failed_last_24h":{"type":"integer","title":"Failed Last 24H"},"pending":{"type":"integer","title":"Pending"},"success_rate":{"type":"number","title":"Success Rate"},"total_storage_bytes":{"type":"integer","title":"Total Storage Bytes"}},"type":"object","required":["total_backups","successful_last_24h","failed_last_24h","pending","success_rate","total_storage_bytes"],"title":"BackupHealthSummary","description":"Backup health overview."},"BackupListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BackupResponse"},"type":"array","title":"Items","description":"List of items"},"total":{"type":"integer","title":"Total","description":"Total number of items"},"page":{"type":"integer","minimum":1.0,"title":"Page","description":"Current page number","default":1},"page_size":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Page Size","description":"Items per page","default":20},"pages":{"type":"integer","title":"Pages","description":"Total number of pages"}},"type":"object","required":["items","total","pages"],"title":"BackupListResponse","description":"Paginated list of backups.","example":{}},"BackupPolicyCreate":{"properties":{"is_enabled":{"type":"boolean","title":"Is Enabled","description":"Whether automated backups are enabled","default":true},"schedule_cron":{"type":"string","maxLength":100,"title":"Schedule Cron","description":"Cron expression for backup schedule (default: 2 AM daily)","default":"0 2 * * *"},"timezone":{"type":"string","maxLength":50,"title":"Timezone","description":"Timezone for schedule","default":"UTC"},"daily_retention":{"type":"integer","maximum":365.0,"minimum":0.0,"title":"Daily Retention","description":"Days to keep daily backups","default":7},"weekly_retention":{"type":"integer","maximum":52.0,"minimum":0.0,"title":"Weekly Retention","description":"Weeks to keep weekly backups","default":4},"monthly_retention":{"type":"integer","maximum":60.0,"minimum":0.0,"title":"Monthly Retention","description":"Months to keep monthly backups","default":12},"yearly_retention":{"type":"integer","maximum":10.0,"minimum":0.0,"title":"Yearly Retention","description":"Years to keep yearly backups","default":2},"weekly_backup_day":{"type":"integer","maximum":6.0,"minimum":0.0,"title":"Weekly Backup Day","description":"Day of week for weekly backup (0=Mon, 6=Sun)","default":6},"notify_on_success":{"type":"boolean","title":"Notify On Success","description":"Send notification on successful backup","default":false},"notify_on_failure":{"type":"boolean","title":"Notify On Failure","description":"Send notification on failed backup","default":true},"storage_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Config Id","description":"Storage config to use for backups"}},"type":"object","title":"BackupPolicyCreate","description":"Schema for creating a backup policy.","example":{}},"BackupPolicyResponse":{"properties":{"is_enabled":{"type":"boolean","title":"Is Enabled","description":"Whether automated backups are enabled","default":true},"schedule_cron":{"type":"string","maxLength":100,"title":"Schedule Cron","description":"Cron expression for backup schedule (default: 2 AM daily)","default":"0 2 * * *"},"timezone":{"type":"string","maxLength":50,"title":"Timezone","description":"Timezone for schedule","default":"UTC"},"daily_retention":{"type":"integer","maximum":365.0,"minimum":0.0,"title":"Daily Retention","description":"Days to keep daily backups","default":7},"weekly_retention":{"type":"integer","maximum":52.0,"minimum":0.0,"title":"Weekly Retention","description":"Weeks to keep weekly backups","default":4},"monthly_retention":{"type":"integer","maximum":60.0,"minimum":0.0,"title":"Monthly Retention","description":"Months to keep monthly backups","default":12},"yearly_retention":{"type":"integer","maximum":10.0,"minimum":0.0,"title":"Yearly Retention","description":"Years to keep yearly backups","default":2},"weekly_backup_day":{"type":"integer","maximum":6.0,"minimum":0.0,"title":"Weekly Backup Day","description":"Day of week for weekly backup (0=Mon, 6=Sun)","default":6},"notify_on_success":{"type":"boolean","title":"Notify On Success","description":"Send notification on successful backup","default":false},"notify_on_failure":{"type":"boolean","title":"Notify On Failure","description":"Send notification on failed backup","default":true},"id":{"type":"string","format":"uuid","title":"Id","description":"Policy ID"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment this policy applies to"},"storage_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Config Id","description":"Default storage for backups"},"last_backup_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Backup At","description":"Last backup timestamp"},"last_backup_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Backup Status","description":"Last backup status"},"next_backup_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Backup At","description":"Next scheduled backup"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["id","environment_id","created_at","updated_at"],"title":"BackupPolicyResponse","description":"Schema for backup policy response.","example":{}},"BackupPolicySource":{"type":"string","enum":["org_default","custom"],"title":"BackupPolicySource","description":"Source of backup policy for an environment."},"BackupPolicySourceUpdate":{"properties":{"backup_policy_source":{"$ref":"#/components/schemas/BackupPolicySource","description":"Policy source: 'org_default' (use org policy) or 'custom' (use env-level policy)"}},"type":"object","required":["backup_policy_source"],"title":"BackupPolicySourceUpdate","description":"Schema for updating environment backup policy source.","example":{}},"BackupPolicyUpdate":{"properties":{"is_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Enabled","description":"Enable/disable backups"},"schedule_cron":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Schedule Cron","description":"Cron expression"},"timezone":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Timezone","description":"Timezone"},"daily_retention":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":0.0},{"type":"null"}],"title":"Daily Retention","description":"Daily retention"},"weekly_retention":{"anyOf":[{"type":"integer","maximum":52.0,"minimum":0.0},{"type":"null"}],"title":"Weekly Retention","description":"Weekly retention"},"monthly_retention":{"anyOf":[{"type":"integer","maximum":60.0,"minimum":0.0},{"type":"null"}],"title":"Monthly Retention","description":"Monthly retention"},"yearly_retention":{"anyOf":[{"type":"integer","maximum":10.0,"minimum":0.0},{"type":"null"}],"title":"Yearly Retention","description":"Yearly retention"},"weekly_backup_day":{"anyOf":[{"type":"integer","maximum":6.0,"minimum":0.0},{"type":"null"}],"title":"Weekly Backup Day","description":"Weekly backup day"},"storage_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Config Id","description":"Storage config ID"},"notify_on_success":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify On Success","description":"Notify on success"},"notify_on_failure":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify On Failure","description":"Notify on failure"}},"type":"object","title":"BackupPolicyUpdate","description":"Schema for updating a backup policy.","example":{}},"BackupResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Backup ID"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id","description":"Environment backed up; null once its project is deleted"},"storage_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Config Id","description":"Storage config used"},"task_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Task Id","description":"Background task ID"},"status":{"$ref":"#/components/schemas/BackupStatus","description":"Current backup status"},"backup_type":{"$ref":"#/components/schemas/BackupType","description":"Type of backup"},"database_size":{"type":"integer","title":"Database Size","description":"Database backup size in bytes"},"filestore_size":{"type":"integer","title":"Filestore Size","description":"Filestore backup size in bytes"},"total_size":{"type":"integer","title":"Total Size","description":"Total backup size in bytes"},"compressed_size":{"type":"integer","title":"Compressed Size","description":"Compressed size in bytes"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When backup started"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When backup completed"},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds","description":"Backup duration in seconds"},"retention_type":{"anyOf":[{"$ref":"#/components/schemas/RetentionType"},{"type":"null"}],"description":"GFS retention tier"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"When backup expires"},"is_verified":{"type":"boolean","title":"Is Verified","description":"Whether backup was verified"},"verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Verified At","description":"When backup was verified"},"database_checksum":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Database Checksum","description":"SHA-256 of database backup"},"filestore_checksum":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filestore Checksum","description":"SHA-256 of filestore backup"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if failed"},"environment_snapshot":{"anyOf":[{"$ref":"#/components/schemas/BackupSnapshotInfo"},{"type":"null"}],"description":"Snapshot of environment, project, and VM state at backup time"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Customer note describing what's in this backup"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Record creation timestamp"}},"type":"object","required":["id","status","backup_type","database_size","filestore_size","total_size","compressed_size","is_verified","created_at"],"title":"BackupResponse","description":"Schema for backup response.","example":{}},"BackupSnapshotInfo":{"properties":{"environment":{"anyOf":[{"$ref":"#/components/schemas/EnvironmentSnapshotInfo"},{"type":"null"}],"description":"Environment info at backup time"},"project":{"anyOf":[{"$ref":"#/components/schemas/ProjectSnapshotInfo"},{"type":"null"}],"description":"Project info at backup time"},"vm":{"anyOf":[{"$ref":"#/components/schemas/VMSnapshotInfo"},{"type":"null"}],"description":"VM/Server info at backup time"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp","description":"Snapshot creation timestamp"}},"type":"object","title":"BackupSnapshotInfo","description":"Complete snapshot info stored at backup time.","example":{}},"BackupStats":{"properties":{"compliant_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Compliant Percent","description":"Percentage of environments with recent backups","default":0.0},"total_24h":{"type":"integer","minimum":0.0,"title":"Total 24H","description":"Total backups completed in last 24 hours","default":0},"failed_24h":{"type":"integer","minimum":0.0,"title":"Failed 24H","description":"Failed backups in last 24 hours","default":0},"environments_without_backup":{"type":"integer","minimum":0.0,"title":"Environments Without Backup","description":"Number of environments without recent backups","default":0},"total_environments":{"type":"integer","minimum":0.0,"title":"Total Environments","description":"Number of environments with a backup policy enabled (the compliance denominator). 0 means backups are not configured, so compliant_percent is vacuously 100 and the UI should show a not-configured state instead.","default":0}},"type":"object","title":"BackupStats","description":"Backup statistics for dashboard overview.","example":{}},"BackupStatus":{"type":"string","enum":["pending","in_progress","uploading","completed","failed","cancelled","expired","deleted"],"title":"BackupStatus","description":"Backup operation status."},"BackupSummary":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"total_backups":{"type":"integer","title":"Total Backups","description":"Total number of backups"},"completed_backups":{"type":"integer","title":"Completed Backups","description":"Number of completed backups"},"failed_backups":{"type":"integer","title":"Failed Backups","description":"Number of failed backups"},"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total storage used by backups"},"oldest_backup_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Oldest Backup At","description":"Oldest backup timestamp"},"newest_backup_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Newest Backup At","description":"Newest backup timestamp"},"last_successful_backup_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Successful Backup At","description":"Last successful backup timestamp"},"policy_enabled":{"type":"boolean","title":"Policy Enabled","description":"Whether backup policy is enabled"},"next_scheduled_backup":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Scheduled Backup","description":"Next scheduled backup"}},"type":"object","required":["environment_id","total_backups","completed_backups","failed_backups","total_size_bytes","policy_enabled"],"title":"BackupSummary","description":"Backup summary statistics for an environment.","example":{}},"BackupType":{"type":"string","enum":["manual","scheduled","pre_restore","pre_upgrade","pre_destroy"],"title":"BackupType","description":"Type of backup."},"BackupUpdate":{"properties":{"notes":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Notes","description":"Updated freeform note. Pass an empty string to clear."}},"type":"object","title":"BackupUpdate","description":"Schema for editing a backup's mutable metadata. Currently only `notes`.","example":{}},"BannerResponse":{"properties":{"show_banner":{"type":"boolean","title":"Show Banner","default":false},"plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan"},"recovery_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recovery Url"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","title":"BannerResponse"},"BillableItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Billable item ID"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"subscription_id":{"type":"string","format":"uuid","title":"Subscription Id","description":"Subscription ID"},"item_type":{"type":"string","title":"Item Type","description":"Item type (byos_server, platform_env, addon)"},"reference_id":{"type":"string","format":"uuid","title":"Reference Id","description":"Referenced entity ID (VM or environment)"},"reference_name":{"type":"string","title":"Reference Name","description":"Referenced entity name"},"tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tier","description":"Tier/size (standard, professional, small, etc.)"},"quantity":{"type":"integer","title":"Quantity","description":"Quantity"},"unit_price":{"type":"string","title":"Unit Price","description":"Unit price"},"status":{"type":"string","title":"Status","description":"Item status (active, cancelled)"},"stripe_subscription_item_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Subscription Item Id","description":"Stripe subscription item ID"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When billing started"},"cancelled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cancelled At","description":"When item was cancelled"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"}},"type":"object","required":["id","organization_id","subscription_id","item_type","reference_id","reference_name","quantity","unit_price","status","created_at"],"title":"BillableItemResponse","description":"Billable item details.","example":{}},"BillingSummaryCosts":{"properties":{"base_plan_cost":{"type":"number","title":"Base Plan Cost","description":"Base plan monthly cost"},"items_cost":{"type":"number","title":"Items Cost","description":"Additional items monthly cost"},"total_monthly":{"type":"number","title":"Total Monthly","description":"Total monthly cost"},"currency":{"type":"string","title":"Currency","description":"Currency","default":"USD"},"recurring_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Recurring Amount","description":"Base plan amount charged per billing interval; null if unknown"},"recurring_interval":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recurring Interval","description":"Billing interval of recurring_amount: month or year"}},"type":"object","required":["base_plan_cost","items_cost","total_monthly"],"title":"BillingSummaryCosts","description":"Cost breakdown in billing summary.","example":{}},"BillingSummaryItem":{"properties":{"id":{"type":"string","title":"Id","description":"Item ID"},"type":{"type":"string","title":"Type","description":"Item type"},"name":{"type":"string","title":"Name","description":"Item name"},"tier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tier","description":"Item tier"},"price":{"type":"number","title":"Price","description":"Item price"},"quantity":{"type":"integer","title":"Quantity","description":"Item quantity"}},"type":"object","required":["id","type","name","price","quantity"],"title":"BillingSummaryItem","description":"Item in billing summary.","example":{}},"BillingSummaryPlanFeatures":{"properties":{"backup_frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Backup Frequency","description":"Backup frequency"},"backup_retention_days":{"type":"integer","title":"Backup Retention Days","description":"Backup retention days","default":7},"monitoring_enabled":{"type":"boolean","title":"Monitoring Enabled","description":"Monitoring enabled","default":true},"ssh_terminal_enabled":{"type":"boolean","title":"Ssh Terminal Enabled","description":"SSH terminal enabled","default":true},"auto_provision_enabled":{"type":"boolean","title":"Auto Provision Enabled","description":"Auto-provision enabled","default":true},"clone_enabled":{"type":"boolean","title":"Clone Enabled","description":"Clone feature enabled","default":true},"sanitize_enabled":{"type":"boolean","title":"Sanitize Enabled","description":"Sanitization options enabled","default":false},"custom_domain_enabled":{"type":"boolean","title":"Custom Domain Enabled","description":"Custom domain enabled","default":false},"custom_domains":{"type":"boolean","title":"Custom Domains","description":"Custom domains enabled (alias)","default":false},"dns_management_enabled":{"type":"boolean","title":"Dns Management Enabled","description":"DNS management enabled","default":false},"replica_enabled":{"type":"boolean","title":"Replica Enabled","description":"PostgreSQL replica enabled","default":false},"pgbouncer_enabled":{"type":"boolean","title":"Pgbouncer Enabled","description":"PgBouncer enabled","default":false},"tuned_postgres_enabled":{"type":"boolean","title":"Tuned Postgres Enabled","description":"Tuned PostgreSQL enabled","default":false},"advanced_monitoring_enabled":{"type":"boolean","title":"Advanced Monitoring Enabled","description":"Advanced monitoring enabled","default":false},"clone_cross_server_enabled":{"type":"boolean","title":"Clone Cross Server Enabled","description":"Cross-server clone enabled","default":false},"priority_support":{"type":"boolean","title":"Priority Support","description":"Priority support enabled","default":false},"sso_enabled":{"type":"boolean","title":"Sso Enabled","description":"SSO enabled","default":false}},"type":"object","title":"BillingSummaryPlanFeatures","description":"Plan feature flags in billing summary.","example":{}},"BillingSummaryPlanLimits":{"properties":{"max_servers":{"type":"integer","title":"Max Servers","description":"Maximum servers"},"max_environments":{"type":"integer","title":"Max Environments","description":"Maximum environments"},"max_projects":{"type":"integer","title":"Max Projects","description":"Maximum projects"},"max_members":{"type":"integer","title":"Max Members","description":"Maximum members"},"included_byos_servers":{"type":"integer","title":"Included Byos Servers","description":"Included BYOS servers"},"included_platform_envs":{"type":"integer","title":"Included Platform Envs","description":"Included platform environments"}},"type":"object","required":["max_servers","max_environments","max_projects","max_members","included_byos_servers","included_platform_envs"],"title":"BillingSummaryPlanLimits","description":"Plan limits in billing summary.","example":{}},"BillingSummaryResponse":{"properties":{"subscription":{"$ref":"#/components/schemas/BillingSummarySubscription","description":"Subscription details"},"plan_limits":{"$ref":"#/components/schemas/BillingSummaryPlanLimits","description":"Plan quota limits"},"plan_features":{"$ref":"#/components/schemas/BillingSummaryPlanFeatures","description":"Plan feature flags"},"usage":{"$ref":"#/components/schemas/BillingSummaryUsage","description":"Current usage"},"billing":{"$ref":"#/components/schemas/BillingSummaryCosts","description":"Cost breakdown"},"items":{"items":{"$ref":"#/components/schemas/BillingSummaryItem"},"type":"array","title":"Items","description":"Billable items"}},"type":"object","required":["subscription","plan_limits","plan_features","usage","billing","items"],"title":"BillingSummaryResponse","description":"Complete billing summary for an organization.","example":{}},"BillingSummarySubscription":{"properties":{"id":{"type":"string","title":"Id","description":"Subscription ID"},"base_plan":{"type":"string","title":"Base Plan","description":"Current plan"},"status":{"type":"string","title":"Status","description":"Current status"},"billing_interval":{"type":"string","title":"Billing Interval","description":"Billing interval"},"trial_ends_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trial Ends At","description":"Trial end date"},"current_period_end":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Period End","description":"Period end date"},"pending_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pending Plan","description":"Pending plan change"},"can_pause":{"type":"boolean","title":"Can Pause","description":"Whether subscription can be paused"}},"type":"object","required":["id","base_plan","status","billing_interval","can_pause"],"title":"BillingSummarySubscription","description":"Subscription info in billing summary.","example":{}},"BillingSummaryUsage":{"properties":{"servers":{"type":"integer","title":"Servers","description":"Current server count"},"environments":{"type":"integer","title":"Environments","description":"Current environment count"},"projects":{"type":"integer","title":"Projects","description":"Current project count"},"members":{"type":"integer","title":"Members","description":"Current member count"}},"type":"object","required":["servers","environments","projects","members"],"title":"BillingSummaryUsage","description":"Usage statistics in billing summary.","example":{}},"BlockedDomainListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BlockedDomainResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"total_pages":{"type":"integer","title":"Total Pages"}},"type":"object","required":["items","total","page","per_page","total_pages"],"title":"BlockedDomainListResponse"},"BlockedDomainResponse":{"properties":{"id":{"type":"string","title":"Id"},"domain":{"type":"string","title":"Domain"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By"}},"type":"object","required":["id","domain","reason","created_at","created_by"],"title":"BlockedDomainResponse"},"Body_admin_upload_attachment_api_v1_admin_support_tickets__ticket_id__attachments_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_admin_upload_attachment_api_v1_admin_support_tickets__ticket_id__attachments_post"},"Body_reupload_project_additional_repo_api_v1_projects__project_id__additional_repos__repo_id__reupload_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"priority":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Priority"}},"type":"object","required":["file"],"title":"Body_reupload_project_additional_repo_api_v1_projects__project_id__additional_repos__repo_id__reupload_post"},"Body_upload_asset_api_v1_organizations__organization_id__theme_upload__asset_type__post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_asset_api_v1_organizations__organization_id__theme_upload__asset_type__post"},"Body_upload_attachment_api_v1_support_tickets__ticket_id__attachments_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_attachment_api_v1_support_tickets__ticket_id__attachments_post"},"Body_upload_avatar_api_v1_users_me_avatar_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_avatar_api_v1_users_me_avatar_post"},"Body_upload_chunk_api_v1_migrations__migration_id__upload_chunk_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_chunk_api_v1_migrations__migration_id__upload_chunk_post"},"Body_upload_direct_api_v1_migrations__migration_id__upload_direct_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_direct_api_v1_migrations__migration_id__upload_direct_post"},"Body_upload_logo_api_v1_odooer_listing_logo_post":{"properties":{"file":{"type":"string","format":"binary","title":"File","description":"PNG, JPEG, WebP, or SVG. Max 2MB, 1024x1024."}},"type":"object","required":["file"],"title":"Body_upload_logo_api_v1_odooer_listing_logo_post"},"Body_upload_project_additional_repo_api_v1_projects__project_id__additional_repos_upload_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"priority":{"type":"integer","title":"Priority","default":100},"environment_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Environment Ids","default":[]}},"type":"object","required":["file"],"title":"Body_upload_project_additional_repo_api_v1_projects__project_id__additional_repos_upload_post"},"BranchInfo":{"properties":{"name":{"type":"string","title":"Name","description":"Branch name"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this is the default branch","default":false},"is_protected":{"type":"boolean","title":"Is Protected","description":"Whether branch is protected","default":false}},"type":"object","required":["name"],"title":"BranchInfo","description":"Schema for branch information.","example":{}},"BranchListResponse":{"properties":{"branches":{"items":{"$ref":"#/components/schemas/BranchInfo"},"type":"array","title":"Branches","description":"List of branches"},"page":{"type":"integer","title":"Page","description":"Current page"},"per_page":{"type":"integer","title":"Per Page","description":"Items per page"}},"type":"object","required":["branches","page","per_page"],"title":"BranchListResponse","description":"Schema for branch list response.","example":{}},"BranchResponse":{"properties":{"name":{"type":"string","title":"Name"},"is_default":{"type":"boolean","title":"Is Default","default":false},"is_protected":{"type":"boolean","title":"Is Protected","default":false},"commit_sha":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Commit Sha"}},"type":"object","required":["name"],"title":"BranchResponse","description":"Branch information."},"BranchesListResponse":{"properties":{"branches":{"items":{"$ref":"#/components/schemas/BranchResponse"},"type":"array","title":"Branches"},"connection_id":{"type":"string","title":"Connection Id"},"repo_full_name":{"type":"string","title":"Repo Full Name"}},"type":"object","required":["branches","connection_id","repo_full_name"],"title":"BranchesListResponse","description":"List of branches."},"BucketInfoResponse":{"properties":{"name":{"type":"string","title":"Name","description":"Bucket name"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region","description":"Bucket region"},"creation_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Creation Date","description":"When bucket was created"}},"type":"object","required":["name"],"title":"BucketInfoResponse","description":"Information about a storage bucket.","example":{}},"BulkTicketUpdateRequest":{"properties":{"ticket_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ticket Ids","description":"Ticket IDs to update"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"New status for all tickets"},"assigned_to":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned To","description":"Assign all tickets to this admin"}},"type":"object","required":["ticket_ids"],"title":"BulkTicketUpdateRequest","description":"Bulk update multiple tickets (admin only).","example":{}},"CSATRatingRequest":{"properties":{"rating":{"type":"integer","maximum":5.0,"minimum":1.0,"title":"Rating","description":"Satisfaction rating (1-5 stars)"},"comment":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Comment","description":"Optional feedback comment"},"token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Token","description":"Anti-spam CSAT token from resolution email (optional for authenticated users)"}},"type":"object","required":["rating"],"title":"CSATRatingRequest","description":"Customer satisfaction rating on a resolved ticket.","example":{}},"CancellationInfo":{"properties":{"org_name":{"type":"string","title":"Org Name"},"plan":{"type":"string","title":"Plan"},"cancelled_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cancelled At"},"cancel_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cancel Reason"},"cancel_feedback":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cancel Feedback"}},"type":"object","required":["org_name","plan","cancelled_at","cancel_reason","cancel_feedback"],"title":"CancellationInfo","description":"Recent cancellation details."},"CannedResponseCreateRequest":{"properties":{"title":{"type":"string","maxLength":200,"minLength":1,"title":"Title","description":"Template title"},"content":{"type":"string","maxLength":10000,"minLength":1,"title":"Content","description":"Template content with {variable} placeholders"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id","description":"Optional category filter for the template"}},"type":"object","required":["title","content"],"title":"CannedResponseCreateRequest","description":"Create a canned response template.","example":{}},"CannedResponsePreviewRequest":{"properties":{"variables":{"additionalProperties":{"type":"string"},"type":"object","title":"Variables","description":"Variable name -> value mapping (e.g. ticket_number, user_name)"}},"type":"object","title":"CannedResponsePreviewRequest","description":"Preview a canned response with variable substitution.","example":{}},"CannedResponseResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"content":{"type":"string","title":"Content"},"category":{"anyOf":[{"$ref":"#/components/schemas/TicketCategoryResponse"},{"type":"null"}]},"is_active":{"type":"boolean","title":"Is Active"}},"type":"object","required":["id","title","content","is_active"],"title":"CannedResponseResponse","description":"Canned response template for admin display.","example":{}},"CannedResponseUpdateRequest":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Title","description":"Template title"},"content":{"anyOf":[{"type":"string","maxLength":10000,"minLength":1},{"type":"null"}],"title":"Content","description":"Template content"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id","description":"Optional category filter"}},"type":"object","title":"CannedResponseUpdateRequest","description":"Update a canned response template.","example":{}},"CaseStudy":{"properties":{"title":{"type":"string","maxLength":200,"minLength":4,"title":"Title"},"industry":{"type":"string","title":"Industry","description":"One of VALID_INDUSTRIES"},"description":{"type":"string","maxLength":800,"minLength":20,"title":"Description"},"outcome":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Outcome"},"client_name":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"Client Name"}},"type":"object","required":["title","industry","description"],"title":"CaseStudy","description":"One case study on a listing. Client name is optional free text —\nlisters who name a client are expected to have that client's permission,\nsame as any consulting portfolio. This is not verified server-side."},"CategoryCreateRequest":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Display name"},"slug":{"type":"string","maxLength":100,"minLength":1,"title":"Slug","description":"URL-safe slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional description"}},"type":"object","required":["name","slug"],"title":"CategoryCreateRequest","description":"Create a ticket category.","example":{}},"CategoryUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Display name"},"slug":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Slug","description":"URL-safe slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional description"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Whether category is selectable"}},"type":"object","title":"CategoryUpdateRequest","description":"Update a ticket category.","example":{}},"CheckResult":{"properties":{"name":{"type":"string","title":"Name","description":"Check name (e.g., docker_installed)"},"status":{"$ref":"#/components/schemas/PreflightCheckStatus","description":"Check status"},"message":{"type":"string","title":"Message","description":"Human-readable message"},"details":{"type":"object","title":"Details","description":"Additional details"},"severity":{"$ref":"#/components/schemas/PreflightCheckSeverity","description":"Check severity","default":"info"},"fixable":{"type":"boolean","title":"Fixable","description":"Whether the issue can be auto-fixed","default":false},"fix_action":{"anyOf":[{"$ref":"#/components/schemas/FixAction"},{"type":"null"}],"description":"Action to fix the issue"},"hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hint","description":"Actionable suggestion to resolve the issue (only set for non-passed checks)"}},"type":"object","required":["name","status","message"],"title":"CheckResult","description":"Result of a single preflight check."},"CheckSummary":{"properties":{"total":{"type":"integer","title":"Total","description":"Total number of checks"},"passed":{"type":"integer","title":"Passed","description":"Number of passed checks"},"failed":{"type":"integer","title":"Failed","description":"Number of failed checks"},"warnings":{"type":"integer","title":"Warnings","description":"Number of warning checks"},"skipped":{"type":"integer","title":"Skipped","description":"Number of skipped checks","default":0}},"type":"object","required":["total","passed","failed","warnings"],"title":"CheckSummary","description":"Summary of all check results."},"CheckUrlRequest":{"properties":{"cloud_url":{"type":"string","maxLength":2048,"title":"Cloud Url","description":"URL to check"}},"type":"object","required":["cloud_url"],"title":"CheckUrlRequest","description":"Request to check a cloud URL's file size and recommend servers.","example":{}},"CheckUrlResponse":{"properties":{"file_size":{"type":"integer","title":"File Size","description":"File size in bytes from HEAD request"},"file_name":{"type":"string","title":"File Name","description":"Detected file name"},"requires_server":{"type":"boolean","title":"Requires Server","description":"True if file > 10GB (must use VM-direct download)"},"recommends_server":{"type":"boolean","title":"Recommends Server","description":"True if file > 500MB (server download recommended)"},"available_servers":{"items":{"$ref":"#/components/schemas/ServerRecommendation"},"type":"array","title":"Available Servers","description":"Org servers available for direct download","default":[]}},"type":"object","required":["file_size","file_name","requires_server","recommends_server"],"title":"CheckUrlResponse","description":"Response with URL file info and server recommendations.","example":{}},"CheckoutSessionRequest":{"properties":{"plan":{"type":"string","title":"Plan","description":"Plan to subscribe to"},"billing_interval":{"type":"string","title":"Billing Interval","description":"Billing interval","default":"monthly"},"success_url":{"type":"string","title":"Success Url","description":"URL to redirect on success"},"cancel_url":{"type":"string","title":"Cancel Url","description":"URL to redirect on cancel"},"ga_client_id":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Ga Client Id","description":"GA4 client ID from _ga cookie for purchase attribution"},"ga_session_id":{"anyOf":[{"type":"string","pattern":"^[0-9]{1,20}$"},{"type":"null"}],"title":"Ga Session Id","description":"GA4 session ID from the _ga_<container> cookie (#1132)"},"policy_acceptance_id":{"type":"string","format":"uuid","title":"Policy Acceptance Id","description":"ID of the fresh PolicyAcceptance row recorded via POST /billing/policy-acceptance. Must belong to the current user, be of event_type PRE_CHECKOUT_INTERSTITIAL, have both acknowledgments true, and be < 30 minutes old."}},"type":"object","required":["plan","success_url","cancel_url","policy_acceptance_id"],"title":"CheckoutSessionRequest","description":"Request to create a checkout session.","example":{}},"CheckoutSessionResponse":{"properties":{"checkout_url":{"type":"string","title":"Checkout Url","description":"Stripe checkout URL"},"session_id":{"type":"string","title":"Session Id","description":"Stripe checkout session ID for Stripe.js"},"mode":{"type":"string","title":"Mode","description":"How the plan change was handled (#708). 'checkout' = redirect the browser to checkout_url (Stripe-hosted). 'in_place' = the existing paid subscription was modified in place (no Stripe Checkout); the frontend should show a success toast and refresh the billing view instead of redirecting. checkout_url still points at the success page in this case as a redirect-safe fallback. 'pay_invoice' = every live Stripe subscription of the customer is past_due or unpaid (#870): no Checkout was created, and checkout_url is the open invoice's hosted page (or a billing-portal session) the browser must be redirected to so the customer can pay it.","default":"checkout"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Optional human-readable message for in-place plan changes and pay_invoice."}},"type":"object","required":["checkout_url","session_id"],"title":"CheckoutSessionResponse","description":"Checkout session details.","example":{}},"ChunkUploadResponse":{"properties":{"chunk_number":{"type":"integer","title":"Chunk Number","description":"Chunk number uploaded"},"etag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Etag","description":"ETag of the uploaded chunk"},"chunks_completed":{"type":"integer","title":"Chunks Completed","description":"Total chunks uploaded so far"},"total_chunks":{"type":"integer","title":"Total Chunks","description":"Total chunks expected"},"is_complete":{"type":"boolean","title":"Is Complete","description":"Whether all chunks are uploaded"}},"type":"object","required":["chunk_number","chunks_completed","total_chunks","is_complete"],"title":"ChunkUploadResponse","description":"Response after chunk upload.","example":{}},"ChurningOrg":{"properties":{"org_id":{"type":"string","title":"Org Id"},"org_name":{"type":"string","title":"Org Name"},"plan":{"type":"string","title":"Plan"},"billing_interval":{"type":"string","title":"Billing Interval"},"reason":{"type":"string","title":"Reason"},"owner_email":{"type":"string","title":"Owner Email"},"customer_since":{"type":"string","title":"Customer Since"},"period_ends_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Period Ends At"}},"type":"object","required":["org_id","org_name","plan","billing_interval","reason","owner_email","customer_since","period_ends_at"],"title":"ChurningOrg","description":"Org that has decided to leave but is still inside the paid period."},"CircuitBreakerConfig":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether the circuit breaker is active for this rule.","default":true},"max_consecutive_failures":{"type":"integer","maximum":20.0,"minimum":1.0,"title":"Max Consecutive Failures","description":"Number of consecutive failures that trip the circuit breaker.","default":3},"window_minutes":{"type":"integer","maximum":1440.0,"minimum":1.0,"title":"Window Minutes","description":"Rolling window (minutes) over which failures are counted.","default":60}},"type":"object","title":"CircuitBreakerConfig","description":"Circuit breaker configuration — auto-disables a rule after repeated failures."},"CleanupError":{"properties":{"step":{"type":"string","title":"Step"},"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type"},"resource_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Resource Id"},"error":{"type":"string","title":"Error"}},"type":"object","required":["step","error"],"title":"CleanupError","description":"Error from a cleanup step."},"CleanupPolicyResponse":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether automatic cleanup is enabled","default":false},"schedule":{"$ref":"#/components/schemas/CleanupSchedule","description":"How often to run cleanup (daily/weekly/monthly)","default":"disabled"},"cleanup_types":{"items":{"$ref":"#/components/schemas/CleanupType"},"type":"array","title":"Cleanup Types","description":"List of cleanup operations to perform","default":["dangling_images","stopped_containers"]},"container_age_days":{"type":"integer","maximum":365.0,"minimum":1.0,"title":"Container Age Days","description":"Age threshold for stopped containers (days)","default":7},"image_age_days":{"type":"integer","maximum":365.0,"minimum":1.0,"title":"Image Age Days","description":"Age threshold for unused images (days)","default":14},"dry_run":{"type":"boolean","title":"Dry Run","description":"Preview mode - no actual deletion","default":false},"preserve_tagged_images":{"type":"boolean","title":"Preserve Tagged Images","description":"Never delete tagged images","default":true},"notify_on_completion":{"type":"boolean","title":"Notify On Completion","description":"Send notification when cleanup completes","default":true},"notify_on_errors":{"type":"boolean","title":"Notify On Errors","description":"Send notification if cleanup fails","default":true},"notification_threshold_mb":{"type":"integer","minimum":0.0,"title":"Notification Threshold Mb","description":"Only notify if space freed exceeds this (MB)","default":1024},"disk_warning_threshold":{"type":"integer","maximum":100.0,"minimum":0.0,"title":"Disk Warning Threshold","description":"Disk usage percentage to trigger warning alert","default":85},"disk_critical_threshold":{"type":"integer","maximum":100.0,"minimum":0.0,"title":"Disk Critical Threshold","description":"Disk usage percentage to trigger critical alert","default":95},"settings":{"type":"object","title":"Settings","description":"Additional policy settings"},"id":{"type":"string","format":"uuid","title":"Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"last_run_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Run At"},"next_run_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Run At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"updated_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Updated By"}},"type":"object","required":["id","organization_id","created_at","updated_at"],"title":"CleanupPolicyResponse","description":"Schema for cleanup policy response.","example":{}},"CleanupPolicyUpdate":{"properties":{"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled"},"schedule":{"anyOf":[{"$ref":"#/components/schemas/CleanupSchedule"},{"type":"null"}]},"cleanup_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/CleanupType"},"type":"array"},{"type":"null"}],"title":"Cleanup Types"},"container_age_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Container Age Days"},"image_age_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Image Age Days"},"dry_run":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Dry Run"},"preserve_tagged_images":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Preserve Tagged Images"},"notify_on_completion":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify On Completion"},"notify_on_errors":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify On Errors"},"notification_threshold_mb":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Notification Threshold Mb"},"disk_warning_threshold":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Disk Warning Threshold"},"disk_critical_threshold":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Disk Critical Threshold"},"settings":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Settings"}},"type":"object","title":"CleanupPolicyUpdate","description":"Schema for updating cleanup policy.","example":{}},"CleanupProgress":{"properties":{"current_step":{"type":"string","title":"Current Step"},"total_steps":{"type":"integer","title":"Total Steps"},"completed_steps":{"type":"integer","title":"Completed Steps"},"percent_complete":{"type":"integer","title":"Percent Complete"},"current_step_details":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Step Details"},"errors":{"items":{"$ref":"#/components/schemas/CleanupError"},"type":"array","title":"Errors"}},"type":"object","required":["current_step","total_steps","completed_steps","percent_complete"],"title":"CleanupProgress","description":"Progress of cleanup operation."},"CleanupRunListResponse":{"properties":{"runs":{"items":{"$ref":"#/components/schemas/CleanupRunResponse"},"type":"array","title":"Runs"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"page_size":{"type":"integer","title":"Page Size"}},"type":"object","required":["runs","total","page","page_size"],"title":"CleanupRunListResponse","description":"Response for listing cleanup runs.","example":{}},"CleanupRunResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"policy_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Policy Id"},"vm_id":{"type":"string","format":"uuid","title":"Vm Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"task_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Task Id"},"cleanup_types":{"items":{"type":"string"},"type":"array","title":"Cleanup Types"},"status":{"$ref":"#/components/schemas/CleanupStatus"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds"},"dry_run":{"type":"boolean","title":"Dry Run"},"disk_before_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Disk Before Bytes"},"disk_after_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Disk After Bytes"},"space_freed_bytes":{"type":"integer","title":"Space Freed Bytes"},"space_freed_mb":{"type":"number","title":"Space Freed Mb","description":"Space freed in MB (computed)","default":0},"space_freed_gb":{"type":"number","title":"Space Freed Gb","description":"Space freed in GB (computed)","default":0},"containers_removed":{"type":"integer","title":"Containers Removed","default":0},"images_removed":{"type":"integer","title":"Images Removed","default":0},"volumes_removed":{"type":"integer","title":"Volumes Removed","default":0},"networks_removed":{"type":"integer","title":"Networks Removed","default":0},"build_cache_cleared_bytes":{"type":"integer","title":"Build Cache Cleared Bytes","default":0},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"results":{"type":"object","title":"Results","description":"Detailed results per cleanup type"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","vm_id","organization_id","cleanup_types","status","dry_run","space_freed_bytes","created_at","updated_at"],"title":"CleanupRunResponse","description":"Schema for cleanup run response.","example":{}},"CleanupSchedule":{"type":"string","enum":["disabled","daily","weekly","monthly"],"title":"CleanupSchedule","description":"Schedule frequency for automatic cleanup."},"CleanupStatus":{"type":"string","enum":["pending","in_progress","completed","failed","cancelled"],"title":"CleanupStatus","description":"Status of cleanup operation."},"CleanupType":{"type":"string","enum":["dangling_images","stopped_containers","unused_images","unused_volumes","unused_networks","build_cache","full"],"title":"CleanupType","description":"Type of cleanup operation."},"CloneEnvironmentRequest":{"properties":{"target":{"$ref":"#/components/schemas/CloneTargetConfig","description":"Target configuration for the clone"},"neutralize":{"type":"boolean","title":"Neutralize","description":"Run Odoo's native neutralize to disable emails, crons, payments, etc. (recommended)","default":true},"include_filestore":{"type":"boolean","title":"Include Filestore","description":"Include filestore in clone","default":true}},"type":"object","required":["target"],"title":"CloneEnvironmentRequest","description":"Request to clone an environment.\n\nUses Odoo's native neutralize command (v16+) which:\n- Disables mail servers, crons, webhooks\n- Disables payment providers, OAuth, IAP\n- Clears calendar sync, push notifications\n- And 50+ more module-specific neutralizations","example":{}},"CloneNeutralizeActionConfig":{"properties":{"action_type":{"type":"string","const":"clone_neutralize_deploy","title":"Action Type","default":"clone_neutralize_deploy"},"source_env_id":{"type":"string","format":"uuid","title":"Source Env Id","description":"Environment to clone from."},"target_env_id":{"type":"string","format":"uuid","title":"Target Env Id","description":"Environment to deploy the neutralized clone into."},"neutralize":{"type":"boolean","title":"Neutralize","description":"Run odoo-bin neutralize after clone to disable emails, crons, etc.","default":true},"include_filestore":{"type":"boolean","title":"Include Filestore","description":"If True, include the Odoo filestore in the clone.","default":true},"git_branch_override":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Branch Override","description":"Branch to deploy into the cloned env. None = same as source."}},"type":"object","required":["source_env_id","target_env_id"],"title":"CloneNeutralizeActionConfig","description":"Configuration for a clone-neutralize-deploy pipeline action."},"CloneOperationListItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"source_environment_id":{"type":"string","format":"uuid","title":"Source Environment Id"},"target_environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Target Environment Id"},"status":{"$ref":"#/components/schemas/CloneStatus"},"progress_percent":{"type":"integer","title":"Progress Percent"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"create_date":{"type":"string","format":"date-time","title":"Create Date"}},"type":"object","required":["id","source_environment_id","target_environment_id","status","progress_percent","started_at","completed_at","created_by","create_date"],"title":"CloneOperationListItem","description":"Minimal clone operation info for list views.","example":{}},"CloneOperationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Clone operation ID"},"source_environment_id":{"type":"string","format":"uuid","title":"Source Environment Id","description":"Source environment ID"},"target_environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Target Environment Id","description":"Target environment ID (once created)"},"status":{"$ref":"#/components/schemas/CloneStatus","description":"Current status"},"progress":{"anyOf":[{"$ref":"#/components/schemas/CloneProgressSchema"},{"type":"null"}],"description":"Progress information"},"neutralize_result":{"anyOf":[{"$ref":"#/components/schemas/NeutralizeResultSchema"},{"type":"null"}],"description":"Results of neutralization (when complete)"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When clone started"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When clone completed"},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds","description":"Total duration in seconds"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if failed"},"error_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Step","description":"Step where error occurred"},"cancel_requested":{"type":"boolean","title":"Cancel Requested","description":"#1351: a cancel was asked for; the clone is stopping and cleaning up","default":false}},"type":"object","required":["id","source_environment_id","status"],"title":"CloneOperationResponse","description":"Response for a clone operation.","example":{}},"CloneProgressSchema":{"properties":{"current_step":{"type":"string","title":"Current Step","description":"Current step name"},"progress_percent":{"type":"integer","maximum":100.0,"minimum":0.0,"title":"Progress Percent","description":"Progress percentage"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Progress message"},"steps_completed":{"type":"integer","title":"Steps Completed","description":"Number of steps completed","default":0},"total_steps":{"type":"integer","title":"Total Steps","description":"Total number of steps","default":7}},"type":"object","required":["current_step","progress_percent"],"title":"CloneProgressSchema","description":"Progress information for clone operation.","example":{}},"CloneStatus":{"type":"string","enum":["pending","pre_checks","validating","creating_target","configuring_dns","copying_addons","backing_up","backing_up_database","backing_up_filestore","restoring","restoring_database","restoring_filestore","sanitizing","verifying","verifying_ssl","completed","failed","cancelled"],"title":"CloneStatus","description":"Clone operation status (matches model enum)."},"CloneTargetConfig":{"properties":{"create_new":{"type":"boolean","title":"Create New","description":"True to create new env, False to overwrite existing","default":true},"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Name for new environment (required if create_new=True)"},"environment_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Type","description":"Environment type for new env (development, staging, production)","default":"staging"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"Server/VM for new environment (uses source VM if None)"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Custom domain for new environment"},"target_environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Target Environment Id","description":"Existing environment to overwrite (required if create_new=False)"},"cpu_cores":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.25},{"type":"string"},{"type":"null"}],"title":"Cpu Cores","description":"CPU cores override (uses source if not set)"},"ram_mb":{"anyOf":[{"type":"integer","maximum":131072.0,"minimum":256.0},{"type":"null"}],"title":"Ram Mb","description":"RAM in MB override (uses source if not set)"},"disk_gb":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Disk Gb","description":"Disk in GB override (uses source if not set)"},"postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Version","description":"PostgreSQL version override"},"enable_pgtune":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Pgtune","description":"Enable PGTune override (uses source if not set)"},"enable_pgbouncer":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Pgbouncer","description":"Enable PgBouncer override (uses source if not set)"},"git_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Branch","description":"Git branch override (uses source if not set)"},"auto_deploy_config":{"anyOf":[{"$ref":"#/components/schemas/AutoDeployConfig"},{"type":"null"}],"description":"Auto-deploy settings for the new environment, turned on when the clone finishes"},"odoo_config":{"anyOf":[{"$ref":"#/components/schemas/OdooConfig"},{"type":"null"}],"description":"odoo.conf settings for the new environment (uses source if not set)"}},"type":"object","title":"CloneTargetConfig","description":"Target configuration for clone operation.","example":{}},"ClonedFromInfo":{"properties":{"source_environment_id":{"type":"string","format":"uuid","title":"Source Environment Id","description":"ID of the source environment"},"source_environment_name":{"type":"string","title":"Source Environment Name","description":"Name of the source environment"},"cloned_at":{"type":"string","format":"date-time","title":"Cloned At","description":"When the clone was created"},"clone_operation_id":{"type":"string","format":"uuid","title":"Clone Operation Id","description":"ID of the clone operation"}},"type":"object","required":["source_environment_id","source_environment_name","cloned_at","clone_operation_id"],"title":"ClonedFromInfo","description":"Information about the source environment for cloned environments.","example":{}},"CloudAccountCapability":{"type":"string","enum":["compute","storage","dns"],"title":"CloudAccountCapability","description":"Services a cloud account can provide."},"CloudAccountCreate":{"properties":{"provider":{"type":"string","maxLength":50,"minLength":1,"pattern":"^[a-z0-9_]+$","title":"Provider","description":"Cloud provider (aws, gcp, azure, digitalocean, hetzner, etc.)"},"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Display name for the account"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Optional description"},"auth_type":{"anyOf":[{"type":"string","maxLength":50,"pattern":"^[a-z0-9_]+$"},{"type":"null"}],"title":"Auth Type","description":"Authentication type (oauth, api_key, iam, etc.). Defaults to provider's default."},"credentials":{"type":"object","title":"Credentials","description":"Provider credentials (will be encrypted)"},"provider_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Provider Config","description":"Non-sensitive provider configuration"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this is the default account for this provider","default":false}},"type":"object","required":["provider","name","credentials"],"title":"CloudAccountCreate","description":"Schema for creating a new cloud account."},"CloudAccountList":{"properties":{"accounts":{"items":{"type":"object"},"type":"array","title":"Accounts"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["accounts","total"],"title":"CloudAccountList","description":"Response schema for list of cloud accounts."},"CloudAccountProvider":{"type":"string","enum":["aws","azure","gcp","digitalocean","vultr","linode","ovhcloud","hetzner","cloudflare","backblaze_b2","minio","wasabi","cloudflare_tunnel","ftp","sftp"],"title":"CloudAccountProvider","description":"All supported cloud providers.\n\nOrganized by capability:\n- Multi-service: AWS, Azure, GCP, DigitalOcean, Vultr, Linode, OVHcloud\n- Compute-only: Hetzner\n- Storage+DNS: Cloudflare\n- Storage-only: Backblaze B2, MinIO, Wasabi, FTP, SFTP"},"CloudAccountResponse":{"properties":{"account":{"type":"object","title":"Account"}},"type":"object","required":["account"],"title":"CloudAccountResponse","description":"Response schema for single cloud account."},"CloudAccountSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"provider":{"type":"string","title":"Provider"},"capabilities":{"items":{"type":"string"},"type":"array","title":"Capabilities"},"has_compute_configs":{"type":"boolean","title":"Has Compute Configs","default":false},"has_storage_configs":{"type":"boolean","title":"Has Storage Configs","default":false},"has_dns_configs":{"type":"boolean","title":"Has Dns Configs","default":false}},"type":"object","required":["id","name","provider","capabilities"],"title":"CloudAccountSummary","description":"Summary of a cloud account for impact report."},"CloudAccountUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"New display name"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"New description"},"credentials":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Credentials","description":"New credentials (will be encrypted). Status will reset to pending."},"provider_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Provider Config","description":"New provider configuration"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"New active status"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default","description":"New default status"}},"type":"object","title":"CloudAccountUpdate","description":"Schema for updating a cloud account."},"CloudAuthType":{"type":"string","enum":["oauth","api_key"],"title":"CloudAuthType","description":"Cloud provider authentication types."},"CloudConnectionCreateApiKey":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description"},"provider":{"$ref":"#/components/schemas/schemas__cloud_provider__CloudProviderType","description":"Cloud provider"},"api_key":{"type":"string","minLength":1,"title":"Api Key","description":"API key/token"},"api_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Secret","description":"API secret (for providers that need key+secret)"},"is_default":{"type":"boolean","title":"Is Default","description":"Set as default connection for this provider","default":false},"default_image":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Default Image","description":"Default OS image slug/ID for provisioning (e.g., 'ubuntu-24-04-x64'). If not set, uses platform defaults."}},"type":"object","required":["name","provider","api_key"],"title":"CloudConnectionCreateApiKey","description":"Schema for creating a cloud connection with API key.","example":{}},"CloudConnectionListResponse":{"properties":{"connections":{"items":{"$ref":"#/components/schemas/CloudConnectionResponse"},"type":"array","title":"Connections","description":"Cloud connections"},"total":{"type":"integer","title":"Total","description":"Total count"}},"type":"object","required":["connections","total"],"title":"CloudConnectionListResponse","description":"List of cloud connections.","example":{}},"CloudConnectionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"name":{"type":"string","title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional description"},"provider":{"$ref":"#/components/schemas/CloudProviderType-Output","description":"Cloud provider"},"auth_type":{"anyOf":[{"$ref":"#/components/schemas/CloudAuthType"},{"type":"null"}],"description":"Authentication type"},"oauth_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Oauth Account Id","description":"OAuth account ID/email"},"oauth_account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Oauth Account Name","description":"OAuth account name"},"oauth_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Oauth Expires At","description":"OAuth token expiration"},"oauth_scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Oauth Scopes","description":"Granted OAuth scopes"},"status":{"$ref":"#/components/schemas/CloudConnectionStatus","description":"Connection status"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether connection is active"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this is default for provider"},"last_validated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Validated At","description":"Last validation timestamp"},"validation_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation Error","description":"Last validation error"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"Last usage timestamp"},"servers_created":{"type":"integer","title":"Servers Created","description":"Number of servers created","default":0},"default_image":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Image","description":"Default OS image slug/ID for provisioning"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By","description":"User who created this connection"},"create_date":{"type":"string","format":"date-time","title":"Create Date","description":"Creation timestamp"},"write_date":{"type":"string","format":"date-time","title":"Write Date","description":"Last update timestamp"}},"type":"object","required":["id","organization_id","name","provider","status","is_active","is_default","created_by","create_date","write_date"],"title":"CloudConnectionResponse","description":"Schema for cloud connection response.","example":{}},"CloudConnectionStatus":{"type":"string","enum":["active","expired","invalid","error","pending"],"title":"CloudConnectionStatus","description":"Cloud provider connection status."},"CloudConnectionUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Optional description"},"api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Key","description":"New API key/token"},"api_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Secret","description":"New API secret"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Whether connection is active"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default","description":"Set as default for this provider"},"default_image":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Default Image","description":"Default OS image slug/ID for provisioning"}},"type":"object","title":"CloudConnectionUpdate","description":"Schema for updating a cloud connection.","example":{}},"CloudProviderType":{"type":"string","enum":["aws","azure","gcp","digitalocean","vultr","ovhcloud","hetzner","linode"],"title":"CloudProviderType","description":"Supported cloud providers for compute."},"CloudProviderType-Output":{"type":"string","enum":["aws","azure","gcp","digitalocean","vultr","ovhcloud","hetzner","linode"],"title":"CloudProviderType","description":"Supported cloud providers."},"CloudUrlImportRequest":{"properties":{"cloud_url":{"type":"string","maxLength":2048,"title":"Cloud Url","description":"Cloud URL to import from"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id","description":"Optional: VM to download directly to (for large files)"}},"type":"object","required":["cloud_url"],"title":"CloudUrlImportRequest","description":"Request to import from cloud URL.","example":{}},"CnameRecord":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","const":"CNAME","title":"Type","default":"CNAME"},"value":{"type":"string","title":"Value"},"ttl":{"type":"integer","title":"Ttl","default":300}},"type":"object","required":["name","value"],"title":"CnameRecord","description":"The CNAME the client must add at their DNS provider."},"CompatibleEnvironmentSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Environment ID"},"name":{"type":"string","title":"Name","description":"Environment name"},"environment_type":{"type":"string","title":"Environment Type","description":"Environment type"},"status":{"type":"string","title":"Status","description":"Current environment status"},"server_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Name","description":"Server name"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version","description":"Odoo version"}},"type":"object","required":["id","name","environment_type","status"],"title":"CompatibleEnvironmentSummary","description":"Summary of an environment compatible with a backup for restore.","example":{}},"CompatibleServerResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Server ID"},"name":{"type":"string","title":"Name","description":"Server name"},"ip_address":{"type":"string","title":"Ip Address","description":"Server IP address"},"available_cpu":{"type":"number","title":"Available Cpu","description":"Available CPU cores"},"available_ram_mb":{"type":"integer","title":"Available Ram Mb","description":"Available RAM in MB"},"available_disk_gb":{"type":"integer","title":"Available Disk Gb","description":"Available disk in GB"},"current_environments":{"type":"integer","title":"Current Environments","description":"Number of environments on server"},"recommended":{"type":"boolean","title":"Recommended","description":"Whether this server is recommended"},"incompatibility_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Incompatibility Reason","description":"Reason if server is not compatible"}},"type":"object","required":["id","name","ip_address","available_cpu","available_ram_mb","available_disk_gb","current_environments","recommended"],"title":"CompatibleServerResponse","description":"Response for compatible server in cross-server restore.","example":{}},"ComplianceOverview":{"properties":{"total_vms":{"type":"integer","title":"Total Vms","description":"Total number of VMs"},"compliant_vms":{"type":"integer","title":"Compliant Vms","description":"Number of compliant VMs"},"non_compliant_vms":{"type":"integer","title":"Non Compliant Vms","description":"Number of non-compliant VMs"},"unchecked_vms":{"type":"integer","title":"Unchecked Vms","description":"Number of VMs never checked"},"compliance_rate":{"type":"number","title":"Compliance Rate","description":"Percentage of compliant VMs"},"total_critical_failures":{"type":"integer","title":"Total Critical Failures","description":"Total critical failures across all VMs"},"total_high_failures":{"type":"integer","title":"Total High Failures","description":"Total high severity failures"},"vms":{"items":{"$ref":"#/components/schemas/VMComplianceStatus"},"type":"array","title":"Vms","description":"List of VMs with compliance status"}},"type":"object","required":["total_vms","compliant_vms","non_compliant_vms","unchecked_vms","compliance_rate","total_critical_failures","total_high_failures","vms"],"title":"ComplianceOverview","description":"Overview of compliance across all VMs."},"ComputeConfigSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"}},"type":"object","required":["id","name"],"title":"ComputeConfigSummary","description":"Summary of a compute configuration for deletion impact."},"ConnectedAccount":{"properties":{"provider":{"type":"string","title":"Provider"},"provider_user_id":{"type":"string","title":"Provider User Id"},"connected_at":{"type":"string","format":"date-time","title":"Connected At"}},"type":"object","required":["provider","provider_user_id","connected_at"],"title":"ConnectedAccount","description":"Connected OAuth account info."},"ConnectionHostType":{"type":"string","enum":["auto","ipv4","ipv6","fqdn","hostname"],"title":"ConnectionHostType","description":"Which address/hostname to use for SSH connection."},"ConnectionInfo":{"properties":{"id":{"type":"string","title":"Id"},"provider":{"type":"string","title":"Provider"},"username":{"type":"string","title":"Username"},"name":{"type":"string","title":"Name"},"level":{"type":"string","title":"Level"},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name"}},"type":"object","required":["id","provider","username","name","level"],"title":"ConnectionInfo","description":"Git connection info for selection."},"ConnectionStatus":{"type":"string","enum":["active","expired","revoked","error"],"title":"ConnectionStatus","description":"Git connection status."},"ConnectionTestRequest":{"properties":{"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"Run the test on this server (one of your own, in this organization)"},"all_env_servers":{"type":"boolean","title":"All Env Servers","description":"Run on every server whose environments use this connection","default":false},"from_platform":{"type":"boolean","title":"From Platform","description":"Run from the platform even if a server is available","default":false}},"type":"object","title":"ConnectionTestRequest","description":"Optional body for POST /{connection_id}/test (#1171).\n\nWith no fields set, the test runs on the connection's default test server,\nelse on the servers of active environments using it (up to 3), else from\nthe platform.","example":{}},"ConnectionTestResponse":{"properties":{"overall_status":{"$ref":"#/components/schemas/ExternalDBConnectionStatus"},"server_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Version"},"sub_tests":{"items":{"$ref":"#/components/schemas/ConnectionTestSubResult"},"type":"array","title":"Sub Tests"},"error_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Summary"},"tested_from":{"type":"string","title":"Tested From","description":"'platform' or 'server'","default":"platform"},"server_results":{"items":{"$ref":"#/components/schemas/ServerTestResult"},"type":"array","title":"Server Results"}},"type":"object","required":["overall_status","sub_tests"],"title":"ConnectionTestResponse","description":"Response schema for POST /{connection_id}/test.\n\nMirrors TestConnectionResult from services/external_database/connection_tester.py.\nThe top-level fields are the overall result: the single test, or the worst\nof the per-server results (``server_results``) when it ran on servers.\nSECURITY: no credentials, no stacktraces, no internal host details beyond\nwhat is already stored on the connection row.","example":{}},"ConnectionTestSubResult":{"properties":{"name":{"type":"string","title":"Name","description":"Sub-test identifier: ssrf_check, tcp_tls_auth, privilege_check, pgbouncer_check, server_version, replica_check, server_connect"},"passed":{"type":"boolean","title":"Passed"},"detail":{"type":"string","title":"Detail","default":""}},"type":"object","required":["name","passed"],"title":"ConnectionTestSubResult","description":"Result for a single connection sub-test.","example":{}},"ConnectionType":{"type":"string","enum":["platform","organization","user","public"],"title":"ConnectionType","description":"Type of Git connection used for authentication."},"ConnectionValidateRequest":{"properties":{"connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connection Id","description":"Existing connection ID to validate"},"provider":{"anyOf":[{"$ref":"#/components/schemas/schemas__cloud_provider__CloudProviderType"},{"type":"null"}],"description":"Provider for new credentials"},"api_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Key","description":"API key to validate"},"api_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Secret","description":"API secret to validate"}},"type":"object","title":"ConnectionValidateRequest","description":"Request to validate a connection.","example":{}},"ConnectionValidateResponse":{"properties":{"valid":{"type":"boolean","title":"Valid","description":"Whether connection is valid"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id","description":"Account ID from provider"},"account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Name","description":"Account name from provider"},"account_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Email","description":"Account email"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if validation failed"}},"type":"object","required":["valid"],"title":"ConnectionValidateResponse","description":"Connection validation result.","example":{}},"ConnectionValidationResponse":{"properties":{"valid":{"type":"boolean","title":"Valid","description":"Whether connection is valid"},"username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Username","description":"Authenticated username"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes","description":"Token scopes"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if validation failed"},"rate_limit_remaining":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Rate Limit Remaining","description":"API rate limit remaining"}},"type":"object","required":["valid","username","scopes","error","rate_limit_remaining"],"title":"ConnectionValidationResponse","description":"Schema for connection validation result.","example":{}},"ConnectivityTestResponse":{"properties":{"reachable":{"type":"boolean","title":"Reachable"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"recommendation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recommendation"},"tunnel_eligible":{"type":"boolean","title":"Tunnel Eligible","default":false}},"type":"object","required":["reachable"],"title":"ConnectivityTestResponse","description":"Result of testing connectivity to a registered server."},"ContainerMetrics":{"properties":{"container_id":{"type":"string","title":"Container Id","description":"Docker container ID"},"container_name":{"type":"string","title":"Container Name","description":"Container name"},"cpu_percent":{"type":"number","minimum":0.0,"title":"Cpu Percent","description":"CPU usage percentage"},"memory_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Memory Percent","description":"Memory usage percentage"},"memory_used_bytes":{"type":"integer","minimum":0.0,"title":"Memory Used Bytes","description":"Memory used in bytes"},"memory_limit_bytes":{"type":"integer","minimum":0.0,"title":"Memory Limit Bytes","description":"Memory limit in bytes"},"network_rx_bytes":{"type":"integer","minimum":0.0,"title":"Network Rx Bytes","description":"Network received bytes"},"network_tx_bytes":{"type":"integer","minimum":0.0,"title":"Network Tx Bytes","description":"Network transmitted bytes"},"status":{"type":"string","title":"Status","description":"Container status: running, stopped, restarting"},"restart_count":{"type":"integer","minimum":0.0,"title":"Restart Count","description":"Number of restarts"},"uptime_seconds":{"type":"integer","minimum":0.0,"title":"Uptime Seconds","description":"Uptime in seconds"}},"type":"object","required":["container_id","container_name","cpu_percent","memory_percent","memory_used_bytes","memory_limit_bytes","network_rx_bytes","network_tx_bytes","status","restart_count","uptime_seconds"],"title":"ContainerMetrics","description":"Per-container metrics from Netdata.","example":{}},"CreateAnnouncementRequest":{"properties":{"title":{"type":"string","maxLength":200,"minLength":1,"title":"Title"},"content":{"type":"string","maxLength":5000,"minLength":1,"title":"Content"},"announcement_type":{"type":"string","title":"Announcement Type","default":"info"},"is_active":{"type":"boolean","title":"Is Active","default":false},"link_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Link Url"},"link_text":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Link Text"},"secondary_link_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Secondary Link Url"},"secondary_link_text":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Secondary Link Text"},"display_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Display Until"}},"type":"object","required":["title","content"],"title":"CreateAnnouncementRequest"},"CreateBucketRequest":{"properties":{"bucket_name":{"type":"string","maxLength":63,"minLength":3,"title":"Bucket Name","description":"Name of the bucket to create. Must be unique within the provider."},"region":{"type":"string","maxLength":50,"minLength":1,"title":"Region","description":"Region/location where the bucket should be created."},"storage_account_name":{"anyOf":[{"type":"string","maxLength":24,"minLength":3},{"type":"null"}],"title":"Storage Account Name","description":"Azure storage account name. Required for Azure Blob Storage."}},"type":"object","required":["bucket_name","region"],"title":"CreateBucketRequest","description":"Request schema for creating a new storage bucket."},"CreateBucketResponse":{"properties":{"bucket_name":{"type":"string","title":"Bucket Name","description":"Name of the created bucket."},"region":{"type":"string","title":"Region","description":"Region where the bucket was created."},"endpoint":{"type":"string","title":"Endpoint","description":"S3-compatible endpoint URL for accessing the bucket."},"storage_config_id":{"type":"string","format":"uuid","title":"Storage Config Id","description":"ID of the auto-created StorageConfig record."}},"type":"object","required":["bucket_name","region","endpoint","storage_config_id"],"title":"CreateBucketResponse","description":"Response schema for bucket creation."},"CreateRegistrationTokenRequest":{"properties":{"server_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Name"},"ssh_username":{"type":"string","title":"Ssh Username","default":"root"},"expires_in":{"type":"string","enum":["1h","6h","24h","48h","7d"],"title":"Expires In","default":"24h"},"auto_deploy":{"anyOf":[{"$ref":"#/components/schemas/schemas__server_registration__AutoDeployConfig"},{"type":"null"}]}},"type":"object","title":"CreateRegistrationTokenRequest","description":"Request to create a new registration token."},"CreateRegistrationTokenResponse":{"properties":{"token_id":{"type":"string","format":"uuid","title":"Token Id"},"token":{"type":"string","title":"Token"},"install_command":{"type":"string","title":"Install Command"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"status":{"type":"string","title":"Status"}},"type":"object","required":["token_id","token","install_command","expires_at","status"],"title":"CreateRegistrationTokenResponse","description":"Response after creating a registration token (token shown ONCE)."},"CreateRepoRequest":{"properties":{"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"private":{"type":"boolean","title":"Private","default":true},"org":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Org"}},"type":"object","required":["name"],"title":"CreateRepoRequest","description":"Request to create a new repository."},"CreateRepoResponse":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"full_name":{"type":"string","title":"Full Name"},"html_url":{"type":"string","title":"Html Url"},"clone_url":{"type":"string","title":"Clone Url"},"default_branch":{"type":"string","title":"Default Branch"}},"type":"object","required":["id","name","full_name","html_url","clone_url","default_branch"],"title":"CreateRepoResponse","description":"Response after creating repository."},"CredentialFieldSchema":{"properties":{"name":{"type":"string","title":"Name","description":"Field name"},"type":{"type":"string","title":"Type","description":"Input type (text, password, textarea)"},"required":{"type":"boolean","title":"Required","description":"Whether field is required"},"label":{"type":"string","title":"Label","description":"Display label"},"help":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Help","description":"Help text"},"placeholder":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Placeholder","description":"Input placeholder"},"default":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default","description":"Default value"}},"type":"object","required":["name","type","required","label"],"title":"CredentialFieldSchema","description":"Schema for a credential input field.","example":{}},"CronJobExecutionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CronJobExecutionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"cron_job_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cron Job Name"}},"type":"object","required":["items","total"],"title":"CronJobExecutionListResponse","description":"Response schema for list of cron job executions."},"CronJobExecutionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"cron_job_id":{"type":"string","format":"uuid","title":"Cron Job Id"},"cron_job_name":{"type":"string","title":"Cron Job Name"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Ms"},"success":{"type":"boolean","title":"Success"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"result_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Result Summary"},"worker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Worker Id"}},"type":"object","required":["id","cron_job_id","cron_job_name","started_at","success"],"title":"CronJobExecutionResponse","description":"Response schema for a cron job execution."},"CronJobListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CronJobResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"CronJobListResponse","description":"Response schema for list of cron jobs."},"CronJobResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"function_name":{"type":"string","title":"Function Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"cron_minute":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cron Minute"},"cron_hour":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cron Hour"},"cron_day":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cron Day"},"cron_weekday":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cron Weekday"},"cron_month":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cron Month"},"schedule_display":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schedule Display"},"status":{"$ref":"#/components/schemas/CronStatus"},"is_enabled":{"type":"boolean","title":"Is Enabled"},"last_run_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Run At"},"next_run_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Run At"},"last_run_duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Last Run Duration Ms"},"last_run_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Run Status"},"last_error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Error Message"},"total_runs":{"type":"integer","title":"Total Runs","default":0},"successful_runs":{"type":"integer","title":"Successful Runs","default":0},"failed_runs":{"type":"integer","title":"Failed Runs","default":0},"success_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Success Rate"},"create_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Create Date"},"write_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Write Date"}},"type":"object","required":["id","name","function_name","status","is_enabled"],"title":"CronJobResponse","description":"Response schema for a cron job."},"CronJobToggleRequest":{"properties":{"is_enabled":{"type":"boolean","title":"Is Enabled","description":"Whether the cron job should be enabled"}},"type":"object","required":["is_enabled"],"title":"CronJobToggleRequest","description":"Request to enable/disable a cron job."},"CronJobTriggerResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"},"job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Id"},"cron_job_name":{"type":"string","title":"Cron Job Name"}},"type":"object","required":["success","message","cron_job_name"],"title":"CronJobTriggerResponse","description":"Response for manually triggering a cron job."},"CronJobsSummary":{"properties":{"total_jobs":{"type":"integer","title":"Total Jobs"},"active_jobs":{"type":"integer","title":"Active Jobs"},"disabled_jobs":{"type":"integer","title":"Disabled Jobs"},"error_jobs":{"type":"integer","title":"Error Jobs"},"total_executions_24h":{"type":"integer","title":"Total Executions 24H"},"successful_executions_24h":{"type":"integer","title":"Successful Executions 24H"},"failed_executions_24h":{"type":"integer","title":"Failed Executions 24H"},"next_scheduled_job":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Scheduled Job"},"next_scheduled_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Scheduled Time"}},"type":"object","required":["total_jobs","active_jobs","disabled_jobs","error_jobs","total_executions_24h","successful_executions_24h","failed_executions_24h"],"title":"CronJobsSummary","description":"Summary statistics for all cron jobs."},"CronStatus":{"type":"string","enum":["active","disabled","error"],"title":"CronStatus","description":"Cron job status."},"CurrentUsageInfo":{"properties":{"environments_deployed":{"type":"integer","title":"Environments Deployed","description":"Number of environments deployed"},"cpu_used":{"type":"string","title":"Cpu Used","description":"CPU cores used"},"ram_used_mb":{"type":"integer","title":"Ram Used Mb","description":"RAM used in MB"},"disk_used_gb":{"type":"integer","title":"Disk Used Gb","description":"Disk used in GB"}},"type":"object","required":["environments_deployed","cpu_used","ram_used_mb","disk_used_gb"],"title":"CurrentUsageInfo","description":"Current resource usage for an allocation."},"CustomDomainRequest":{"properties":{"domain":{"type":"string","maxLength":255,"minLength":4,"title":"Domain","description":"Custom domain. Accepts plain ('erp.acme-corp.com') or wildcard ('*.acme-corp.com'). Wildcards require the Pro plan."}},"type":"object","required":["domain"],"title":"CustomDomainRequest","description":"Request to set custom domain for an environment.\n\nAccepts both plain domains ('erp.acme.com') and single-leftmost\nwildcards ('*.acme.com'). Wildcards are gated on the\n`pro_wildcard_ssl_enabled` plan feature at the route layer; this\nschema only validates SHAPE.","example":{}},"CustomDomainStatus":{"properties":{"domain":{"type":"string","title":"Domain","description":"The custom domain"},"dns_configured":{"type":"boolean","title":"Dns Configured","description":"Whether DNS is correctly configured","default":false},"ssl_status":{"type":"string","title":"Ssl Status","description":"SSL certificate status: pending, provisioning, active, failed","default":"pending"},"ssl_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ssl Expires At","description":"SSL certificate expiration date"},"last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Checked At","description":"Last time DNS was checked"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if verification failed"}},"type":"object","required":["domain"],"title":"CustomDomainStatus","description":"Status of custom domain configuration.","example":{}},"CustomDomainVerificationResponse":{"properties":{"domain":{"type":"string","title":"Domain","description":"The custom domain"},"verification_type":{"type":"string","title":"Verification Type","description":"DNS record type for verification","default":"CNAME"},"verification_target":{"type":"string","title":"Verification Target","description":"Target value for the DNS record"},"verification_txt_record":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Txt Record","description":"TXT record value for ownership verification (if required)"},"is_verified":{"type":"boolean","title":"Is Verified","description":"Whether DNS configuration has been verified","default":false},"ssl_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssl Status","description":"SSL certificate status: pending, provisioning, active, failed"},"instructions":{"type":"string","title":"Instructions","description":"Human-readable instructions for DNS configuration"}},"type":"object","required":["domain","verification_target","instructions"],"title":"CustomDomainVerificationResponse","description":"Response with DNS verification instructions.","example":{}},"CustomerPortalRequest":{"properties":{"return_url":{"type":"string","title":"Return Url","description":"URL to return to after portal"},"flow":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Flow","description":"Optional Stripe portal deep-link flow. Currently supports 'payment_method_update' which drops the user on the update-card screen (used by the over-quota banner when a subscription was cancelled for failed payment). None opens the portal home."}},"type":"object","required":["return_url"],"title":"CustomerPortalRequest","description":"Request to create a customer portal session.","example":{}},"CustomerPortalResponse":{"properties":{"portal_url":{"type":"string","title":"Portal Url","description":"Stripe customer portal URL"}},"type":"object","required":["portal_url"],"title":"CustomerPortalResponse","description":"Customer portal session details.","example":{}},"DLQListResponse":{"properties":{"tasks":{"items":{"$ref":"#/components/schemas/FailedTaskResponse"},"type":"array","title":"Tasks","description":"List of failed tasks"},"total":{"type":"integer","title":"Total","description":"Total number of tasks in DLQ"},"page":{"type":"integer","title":"Page","description":"Current page number"},"page_size":{"type":"integer","title":"Page Size","description":"Number of tasks per page"}},"type":"object","required":["tasks","total","page","page_size"],"title":"DLQListResponse","description":"Response schema for DLQ task list."},"DLQStatsResponse":{"properties":{"total_tasks":{"type":"integer","title":"Total Tasks","description":"Total number of tasks in DLQ"},"oldest_task":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Oldest Task","description":"Oldest task in DLQ"},"newest_task":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Newest Task","description":"Newest task in DLQ"}},"type":"object","required":["total_tasks"],"title":"DLQStatsResponse","description":"Response schema for DLQ statistics."},"DNSConfigCreate":{"properties":{"name":{"type":"string","maxLength":100,"title":"Name","description":"Display name for this DNS configuration","examples":["Production Cloudflare","Marketing DNS"]},"provider":{"$ref":"#/components/schemas/DNSProviderType","description":"DNS provider type"},"provider_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Provider Config","description":"Provider-specific configuration (non-sensitive)","examples":[{"account_id":"abc123"},{"resource_group":"my-rg"}]},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this is the default DNS config for the organization","default":false},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID to create the config for"},"cloud_account_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cloud Account Id","description":"CloudAccount ID to use for credentials. When set, credentials are pulled from the cloud account."},"credentials":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Credentials","description":"Provider credentials (will be encrypted). Required when cloud_account_id is not set.","examples":[{"api_token":"your_cloudflare_token"}]},"enable_wildcard_ssl":{"type":"boolean","title":"Enable Wildcard Ssl","description":"Enable wildcard SSL for instant HTTPS on all system domains","default":false},"wildcard_domain":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Wildcard Domain","description":"Domain for wildcard certificate (e.g., 'apps.oec.sh' → *.apps.oec.sh)","examples":["apps.oec.sh","apps.mypaas.com"]}},"type":"object","required":["name","provider","organization_id"],"title":"DNSConfigCreate","description":"Schema for creating a DNS configuration.\n\nSupports two modes:\n1. Linked to CloudAccount: Set cloud_account_id, credentials are pulled from account\n2. Standalone: Provide credentials directly (legacy mode)","example":{}},"DNSConfigResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"DNS config ID"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"provider":{"$ref":"#/components/schemas/DNSProviderType","description":"DNS provider type"},"name":{"type":"string","title":"Name","description":"Display name"},"provider_config":{"type":"object","title":"Provider Config","description":"Provider-specific configuration"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this is the default config"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether this configuration is active"},"last_verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Verified At","description":"Last time credentials were verified"},"verification_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Error","description":"Last verification error (if any)"},"cloud_account_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cloud Account Id","description":"CloudAccount ID if credentials are linked"},"cloud_account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cloud Account Name","description":"CloudAccount name for display"},"credential_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Credential Source","description":"Where credentials come from: 'cloud_account' or 'local'"},"enable_wildcard_ssl":{"type":"boolean","title":"Enable Wildcard Ssl","description":"Whether wildcard SSL is enabled for system domains","default":false},"wildcard_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wildcard Domain","description":"Domain for wildcard certificate (e.g., 'apps.oec.sh')"},"wildcard_cert_status":{"type":"string","title":"Wildcard Cert Status","description":"Wildcard certificate status: not_requested, pending, active, expired, error","default":"not_requested"},"wildcard_cert_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Wildcard Cert Expires At","description":"Wildcard certificate expiration date"},"wildcard_cert_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wildcard Cert Error","description":"Last wildcard certificate error (if any)"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["id","organization_id","provider","name","is_default","is_active","created_at","updated_at"],"title":"DNSConfigResponse","description":"Schema for DNS configuration response.","example":{}},"DNSConfigSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"provider":{"type":"string","title":"Provider"},"domain_count":{"type":"integer","title":"Domain Count","default":0}},"type":"object","required":["id","name","provider"],"title":"DNSConfigSummary","description":"Summary of a DNS config for impact report."},"DNSConfigUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Name","description":"New display name"},"credentials":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Credentials","description":"New credentials (will be encrypted)"},"provider_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Provider Config","description":"New provider-specific configuration"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default","description":"Set as default DNS config"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Enable or disable this configuration"},"enable_wildcard_ssl":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Wildcard Ssl","description":"Enable/disable wildcard SSL for system domains"},"wildcard_domain":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Wildcard Domain","description":"Domain for wildcard certificate"}},"type":"object","title":"DNSConfigUpdate","description":"Schema for updating a DNS configuration.","example":{}},"DNSPlatformSettingsResponse":{"properties":{"available_providers":{"items":{"type":"string"},"type":"array","title":"Available Providers","description":"Providers available on this platform (from ENV)"},"enabled_providers":{"items":{"type":"string"},"type":"array","title":"Enabled Providers","description":"Providers currently enabled for organizations"},"ttl_limits":{"additionalProperties":{"type":"integer"},"type":"object","title":"Ttl Limits","description":"TTL min/max limits"},"rate_limit_per_minute":{"type":"integer","title":"Rate Limit Per Minute","description":"API rate limit per org"},"max_domains_per_project":{"type":"integer","title":"Max Domains Per Project","description":"Max domains per project"},"max_dns_configs_per_org":{"type":"integer","title":"Max Dns Configs Per Org","description":"Max DNS configs per org"}},"type":"object","required":["available_providers","enabled_providers","ttl_limits","rate_limit_per_minute","max_domains_per_project","max_dns_configs_per_org"],"title":"DNSPlatformSettingsResponse","description":"DNS platform settings response."},"DNSProviderType":{"type":"string","enum":["cloudflare","route53","azure","google","digitalocean","vultr","linode","ovhcloud","hetzner"],"title":"DNSProviderType","description":"Supported DNS providers."},"DNSRecordCreate":{"properties":{"zone_id":{"type":"string","title":"Zone Id","description":"Provider's zone ID"},"record_type":{"$ref":"#/components/schemas/DNSRecordType","description":"DNS record type"},"name":{"type":"string","title":"Name","description":"Record name (subdomain or full domain)"},"content":{"type":"string","title":"Content","description":"Record value (IP, hostname, text)"},"ttl":{"type":"integer","maximum":86400.0,"minimum":1.0,"title":"Ttl","description":"Time to live in seconds (1 = automatic for Cloudflare)","default":300},"proxied":{"type":"boolean","title":"Proxied","description":"Enable Cloudflare proxy mode","default":true},"priority":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":0.0},{"type":"null"}],"title":"Priority","description":"Priority for MX/SRV records"}},"type":"object","required":["zone_id","record_type","name","content"],"title":"DNSRecordCreate","description":"Schema for creating a DNS record directly.","example":{}},"DNSRecordResponse":{"properties":{"id":{"type":"string","title":"Id","description":"Provider's record ID"},"zone_id":{"type":"string","title":"Zone Id","description":"Zone ID"},"type":{"$ref":"#/components/schemas/DNSRecordType","description":"Record type"},"name":{"type":"string","title":"Name","description":"Full record name"},"content":{"type":"string","title":"Content","description":"Record value"},"ttl":{"type":"integer","title":"Ttl","description":"TTL in seconds"},"proxied":{"type":"boolean","title":"Proxied","description":"Cloudflare proxy mode"},"priority":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Priority","description":"MX/SRV priority"}},"type":"object","required":["id","zone_id","type","name","content","ttl","proxied","priority"],"title":"DNSRecordResponse","description":"Schema for DNS record response.","example":{}},"DNSRecordType":{"type":"string","enum":["A","AAAA","CNAME","TXT","MX","NS","SRV","CAA"],"title":"DNSRecordType","description":"DNS record types."},"DailyTrend":{"properties":{"date":{"type":"string","title":"Date"},"success":{"type":"integer","title":"Success"},"failed":{"type":"integer","title":"Failed"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["date","success","failed","total"],"title":"DailyTrend","description":"Daily deployment counts."},"DashboardStatsResponse":{"properties":{"servers":{"$ref":"#/components/schemas/ServerStats","description":"Server statistics"},"backups":{"$ref":"#/components/schemas/BackupStats","description":"Backup statistics"},"alerts":{"$ref":"#/components/schemas/AlertStats","description":"Alert statistics"},"deployments":{"$ref":"#/components/schemas/DeploymentStats","description":"Deployment statistics"},"environments":{"$ref":"#/components/schemas/EnvironmentStats","description":"Environment statistics"},"queue":{"$ref":"#/components/schemas/QueueStats","description":"Task queue statistics"},"capacity":{"$ref":"#/components/schemas/InfraCapacityStats","description":"Infrastructure capacity statistics"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"When statistics were generated"}},"type":"object","required":["servers","backups","alerts","deployments","environments","queue","capacity","timestamp"],"title":"DashboardStatsResponse","description":"Combined dashboard statistics response.","example":{}},"DatedBuildResponse":{"properties":{"tag":{"type":"string","title":"Tag"},"published_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Published At"},"running":{"type":"boolean","title":"Running","default":false},"selected":{"type":"boolean","title":"Selected","default":false}},"type":"object","required":["tag"],"title":"DatedBuildResponse"},"DeletionImpactResponse":{"properties":{"can_delete_safely":{"type":"boolean","title":"Can Delete Safely","description":"Whether the account can be deleted without affecting any dependencies"},"dependencies":{"$ref":"#/components/schemas/DependencyList","description":"List of resources that depend on this cloud account"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Human-readable warnings about what will be affected","default":[]}},"type":"object","required":["can_delete_safely","dependencies"],"title":"DeletionImpactResponse","description":"Response schema for deletion impact analysis."},"DemoCatalogResponse":{"properties":{"starter_pack":{"items":{"$ref":"#/components/schemas/DemoModuleOption"},"type":"array","title":"Starter Pack"}},"type":"object","required":["starter_pack"],"title":"DemoCatalogResponse","description":"GET /api/v1/demo/catalog response. Powers the deploy form's module list."},"DemoDeployRequest":{"properties":{"odoo_version":{"type":"string","enum":["17.0","18.0","19.0"],"title":"Odoo Version"},"modules":{"items":{"type":"string"},"type":"array","maxItems":50,"title":"Modules"},"environment_type":{"type":"string","enum":["development","staging"],"title":"Environment Type","default":"development"},"captcha_token":{"type":"string","title":"Captcha Token"}},"type":"object","required":["odoo_version","captcha_token"],"title":"DemoDeployRequest","description":"POST /api/v1/demo/deploy body."},"DemoDeployResponse":{"properties":{"env_id":{"type":"string","format":"uuid","title":"Env Id"},"poll_url":{"type":"string","title":"Poll Url"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"}},"type":"object","required":["env_id","poll_url","expires_at"],"title":"DemoDeployResponse","description":"POST /api/v1/demo/deploy 202 response."},"DemoExportResponse":{"properties":{"download_url":{"type":"string","title":"Download Url"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"}},"type":"object","required":["download_url","expires_at"],"title":"DemoExportResponse","description":"POST /api/v1/demo/export/{env_id} response."},"DemoExtendResponse":{"properties":{"env_id":{"type":"string","format":"uuid","title":"Env Id"},"new_expires_at":{"type":"string","format":"date-time","title":"New Expires At"},"extension_used":{"type":"boolean","title":"Extension Used","default":true}},"type":"object","required":["env_id","new_expires_at"],"title":"DemoExtendResponse"},"DemoInviteRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"}},"type":"object","required":["email"],"title":"DemoInviteRequest"},"DemoInviteResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","format":"email","title":"Email"},"token":{"type":"string","title":"Token"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"}},"type":"object","required":["id","email","token","expires_at"],"title":"DemoInviteResponse"},"DemoMailboxMessage":{"properties":{"id":{"type":"string","title":"Id"},"from_addr":{"type":"string","title":"From Addr"},"to_addr":{"type":"string","title":"To Addr"},"subject":{"type":"string","title":"Subject"},"received_at":{"type":"string","format":"date-time","title":"Received At"},"snippet":{"type":"string","title":"Snippet"}},"type":"object","required":["id","from_addr","to_addr","subject","received_at","snippet"],"title":"DemoMailboxMessage"},"DemoMailboxResponse":{"properties":{"messages":{"items":{"$ref":"#/components/schemas/DemoMailboxMessage"},"type":"array","title":"Messages"}},"type":"object","required":["messages"],"title":"DemoMailboxResponse"},"DemoModuleOption":{"properties":{"technical_name":{"type":"string","title":"Technical Name"},"label":{"type":"string","title":"Label"},"description":{"type":"string","title":"Description"},"category":{"type":"string","title":"Category"}},"type":"object","required":["technical_name","label","description","category"],"title":"DemoModuleOption","description":"One module entry surfaced in the demo deploy form's starter pack."},"DemoStatusResponse":{"properties":{"current_env_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Current Env Id"},"can_deploy_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Can Deploy At"},"deploys_today":{"type":"integer","title":"Deploys Today"},"capacity_remaining":{"type":"integer","title":"Capacity Remaining"}},"type":"object","required":["current_env_id","can_deploy_at","deploys_today","capacity_remaining"],"title":"DemoStatusResponse","description":"GET /api/v1/demo/status response.\n\n`can_deploy_at` is only populated when the caller is in cooldown.\n`current_env_id` is set when the caller already has a live demo.\n`capacity_remaining` is the platform-wide free demo slot count."},"DemoSubdomainAvailableResponse":{"properties":{"available":{"type":"boolean","title":"Available"},"reason":{"type":"string","title":"Reason"}},"type":"object","required":["available","reason"],"title":"DemoSubdomainAvailableResponse"},"DemoUpgradeLinkResponse":{"properties":{"stripe_checkout_url":{"type":"string","title":"Stripe Checkout Url"}},"type":"object","required":["stripe_checkout_url"],"title":"DemoUpgradeLinkResponse","description":"GET /api/v1/demo/upgrade-link response."},"DemoWaitlistRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"captcha_token":{"type":"string","title":"Captcha Token"}},"type":"object","required":["email","captcha_token"],"title":"DemoWaitlistRequest"},"DemoWaitlistResponse":{"properties":{"status":{"type":"string","title":"Status","default":"ok"}},"type":"object","title":"DemoWaitlistResponse"},"DepartureCancelledResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"message":{"type":"string","title":"Message"},"status":{"$ref":"#/components/schemas/DepartureStatus"}},"type":"object","required":["message","status"],"title":"DepartureCancelledResponse","description":"Response after cancelling departure."},"DepartureImpactResponse":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"organization_name":{"type":"string","title":"Organization Name"},"total_projects":{"type":"integer","title":"Total Projects","default":0},"total_environments":{"type":"integer","title":"Total Environments","default":0},"active_environments":{"type":"integer","title":"Active Environments","default":0},"total_backups":{"type":"integer","title":"Total Backups","default":0},"total_backup_size_bytes":{"type":"integer","title":"Total Backup Size Bytes","default":0},"cloud_accounts":{"items":{"$ref":"#/components/schemas/CloudAccountSummary"},"type":"array","title":"Cloud Accounts"},"git_connections":{"items":{"$ref":"#/components/schemas/GitConnectionSummary"},"type":"array","title":"Git Connections"},"dns_configs":{"items":{"$ref":"#/components/schemas/DNSConfigSummary"},"type":"array","title":"Dns Configs"},"storage_configs":{"items":{"$ref":"#/components/schemas/StorageConfigSummary"},"type":"array","title":"Storage Configs"},"active_environment_samples":{"items":{"$ref":"#/components/schemas/schemas__departure__EnvironmentSummary"},"type":"array","title":"Active Environment Samples"},"subscription_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subscription Status"},"current_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Plan"},"outstanding_amount":{"type":"number","title":"Outstanding Amount","default":0.0},"prorated_refund_estimate":{"type":"number","title":"Prorated Refund Estimate","default":0.0},"total_members":{"type":"integer","title":"Total Members","default":0},"data_export_size_estimate_bytes":{"type":"integer","title":"Data Export Size Estimate Bytes","default":0},"cleanup_time_estimate_minutes":{"type":"integer","title":"Cleanup Time Estimate Minutes","default":5},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"}},"type":"object","required":["organization_id","organization_name"],"title":"DepartureImpactResponse","description":"Full impact report of departing."},"DepartureInitiatedResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"message":{"type":"string","title":"Message"},"status":{"$ref":"#/components/schemas/DepartureStatus"},"grace_period_ends_at":{"type":"string","format":"date-time","title":"Grace Period Ends At"},"export_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Export Url"},"export_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Export Expires At"}},"type":"object","required":["message","status","grace_period_ends_at"],"title":"DepartureInitiatedResponse","description":"Response after initiating departure."},"DepartureStatus":{"type":"string","enum":["none","initiated","grace_period","cleanup_pending","cleanup_in_progress","completed"],"title":"DepartureStatus","description":"Status of organization departure process.\n\nFlow: NONE -> INITIATED -> GRACE_PERIOD -> CLEANUP_PENDING -> CLEANUP_IN_PROGRESS -> COMPLETED\n\nValues:\n- NONE: Organization is active, no departure initiated\n- INITIATED: User initiated departure, processing started\n- GRACE_PERIOD: In 30-day grace period, can still cancel\n- CLEANUP_PENDING: Grace period expired, awaiting cleanup\n- CLEANUP_IN_PROGRESS: Cleanup task running\n- COMPLETED: Fully purged (only in audit logs, org deleted)"},"DepartureStatusResponse":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"status":{"$ref":"#/components/schemas/DepartureStatus"},"is_departing":{"type":"boolean","title":"Is Departing","default":false},"initiated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Initiated At"},"initiated_by_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Initiated By Email"},"grace_period_ends_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Grace Period Ends At"},"days_remaining":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Days Remaining"},"export_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Export Url"},"export_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Export Expires At"},"cleanup_progress":{"anyOf":[{"$ref":"#/components/schemas/CleanupProgress"},{"type":"null"}]},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["organization_id","status"],"title":"DepartureStatusResponse","description":"Current departure status."},"DependencyList":{"properties":{"compute_configs":{"items":{"$ref":"#/components/schemas/ComputeConfigSummary"},"type":"array","title":"Compute Configs","default":[]},"storage_configs":{"items":{"$ref":"#/components/schemas/schemas__cloud_account__StorageConfigSummary"},"type":"array","title":"Storage Configs","default":[]},"dns_configs":{"items":{"$ref":"#/components/schemas/schemas__cloud_account__DNSConfigSummary"},"type":"array","title":"Dns Configs","default":[]},"total_count":{"type":"integer","title":"Total Count","default":0}},"type":"object","title":"DependencyList","description":"List of dependencies for a cloud account."},"DeployActionConfig":{"properties":{"action_type":{"type":"string","const":"deploy","title":"Action Type","default":"deploy"},"target_env_id":{"type":"string","format":"uuid","title":"Target Env Id","description":"Environment to deploy to."},"force":{"type":"boolean","title":"Force","description":"If True, force deploy even if environment is already up-to-date.","default":false},"update_modules":{"type":"boolean","title":"Update Modules","description":"If True, run a module update (-u) as part of the deploy.","default":false}},"type":"object","required":["target_env_id"],"title":"DeployActionConfig","description":"Configuration for a standard deploy action."},"DeployAllRequest":{"properties":{"force":{"type":"boolean","title":"Force","description":"Force deployment even if no changes detected","default":false}},"type":"object","title":"DeployAllRequest","description":"Schema for deploying all repositories to an environment.","example":{}},"DeployRepositoryRequest":{"properties":{"repository_id":{"type":"string","format":"uuid","title":"Repository Id","description":"ID of the repository to deploy"},"branch_override":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Branch Override","description":"Override branch (uses env mapping if not specified)"},"force":{"type":"boolean","title":"Force","description":"Force deployment even if no changes detected","default":false}},"type":"object","required":["repository_id"],"title":"DeployRepositoryRequest","description":"Schema for triggering repository deployment to an environment.","example":{}},"DeployRepositoryResponse":{"properties":{"task_id":{"type":"string","format":"uuid","title":"Task Id"},"repository_id":{"type":"string","format":"uuid","title":"Repository Id"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"branch":{"type":"string","title":"Branch"},"message":{"type":"string","title":"Message","default":"Deployment started"}},"type":"object","required":["task_id","repository_id","environment_id","branch"],"title":"DeployRepositoryResponse","description":"Schema for repository deployment response.","example":{}},"DeployWindow":{"properties":{"timezone":{"type":"string","maxLength":64,"title":"Timezone","description":"IANA timezone, e.g. Europe/Rome"},"days":{"items":{"type":"integer"},"type":"array","title":"Days","description":"Weekdays the window opens on, Mon=0 .. Sun=6"},"start":{"type":"string","title":"Start","description":"Opening time, HH:MM"},"end":{"type":"string","title":"End","description":"Closing time, HH:MM (before start = overnight)"}},"type":"object","required":["timezone","days","start","end"],"title":"DeployWindow","description":"#1260: pushes outside this window are held and deploy when it opens.\n\n``days`` are ISO weekdays from 0 (Mon=0) and name the day the window\nOPENS; an overnight window (``end`` before ``start``) closes the next day.\nTimes are wall-clock in ``timezone``, so 02:00 stays 02:00 across DST.","example":{}},"DeploymentAnalyticsResponse":{"properties":{"period_days":{"type":"integer","title":"Period Days"},"kpis":{"$ref":"#/components/schemas/DeploymentKPIs"},"by_trigger":{"items":{"$ref":"#/components/schemas/TriggerBreakdown"},"type":"array","title":"By Trigger"},"daily_trend":{"items":{"$ref":"#/components/schemas/DailyTrend"},"type":"array","title":"Daily Trend"},"top_organizations":{"items":{"$ref":"#/components/schemas/TopOrganization"},"type":"array","title":"Top Organizations"},"task_type_breakdown":{"items":{"$ref":"#/components/schemas/TaskTypeBreakdown"},"type":"array","title":"Task Type Breakdown"}},"type":"object","required":["period_days","kpis","by_trigger","daily_trend","top_organizations","task_type_breakdown"],"title":"DeploymentAnalyticsResponse","description":"Full deployment analytics response."},"DeploymentCreate":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id","description":"Environment ID (staging, production, etc.)"},"git_commit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Commit","description":"Git commit SHA"},"git_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Branch","description":"Git branch"},"trigger":{"$ref":"#/components/schemas/DeploymentTrigger","description":"Deployment trigger","default":"manual"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"Override VM (defaults to environment's VM)"}},"type":"object","required":["project_id"],"title":"DeploymentCreate","description":"Schema for creating a deployment.","example":{}},"DeploymentKPIs":{"properties":{"total_deployments":{"type":"integer","title":"Total Deployments"},"success_rate":{"type":"number","title":"Success Rate"},"avg_duration_seconds":{"type":"number","title":"Avg Duration Seconds"},"active_now":{"type":"integer","title":"Active Now"}},"type":"object","required":["total_deployments","success_rate","avg_duration_seconds","active_now"],"title":"DeploymentKPIs","description":"Top-level deployment KPI metrics."},"DeploymentResponse":{"properties":{"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id","description":"Environment ID"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM where deployed"},"version":{"type":"integer","title":"Version","description":"Deployment version number"},"status":{"type":"string","title":"Status","description":"Deployment status"},"trigger":{"type":"string","title":"Trigger","description":"Deployment trigger"},"triggered_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Triggered By","description":"User who triggered"},"git_commit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Commit","description":"Git commit SHA"},"git_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Branch","description":"Git branch"},"git_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Message","description":"Git commit message"},"extra_data":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Extra Data","description":"Additional deployment data"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"Start timestamp"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"Completion timestamp"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Duration in seconds"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if failed"},"container_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Container Id","description":"Container ID if created"},"image_tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Tag","description":"Docker image used"}},"type":"object","required":["created_at","updated_at","id","project_id","version","status","trigger"],"title":"DeploymentResponse","description":"Schema for deployment response.","example":{}},"DeploymentStats":{"properties":{"running":{"type":"integer","minimum":0.0,"title":"Running","description":"Deployments currently running","default":0},"queued":{"type":"integer","minimum":0.0,"title":"Queued","description":"Deployments queued","default":0},"completed_24h":{"type":"integer","minimum":0.0,"title":"Completed 24H","description":"Deployments completed in last 24 hours","default":0},"failed_24h":{"type":"integer","minimum":0.0,"title":"Failed 24H","description":"Deployments failed in last 24 hours","default":0}},"type":"object","title":"DeploymentStats","description":"Deployment statistics for dashboard overview.","example":{}},"DeploymentStatus":{"type":"string","enum":["pending","queued","building","deploying","running","success","failed","cancelled","rolled_back","destroyed"],"title":"DeploymentStatus","description":"Deployment status states."},"DeploymentTemplateCreate":{"properties":{"name":{"type":"string","maxLength":100,"title":"Name","description":"Template display name"},"slug":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Slug","description":"URL slug (auto-generated if omitted)"},"description":{"type":"string","title":"Description","description":"Short description for card display"},"long_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Long Description","description":"Detailed description"},"category":{"type":"string","maxLength":50,"title":"Category","description":"Category: ecommerce, manufacturing, accounting, general, pos, hr"},"icon":{"type":"string","maxLength":50,"title":"Icon","description":"Lucide icon name","default":"box"},"odoo_version":{"type":"string","maxLength":10,"title":"Odoo Version","description":"Odoo version (e.g., 19.0)"},"env_type":{"type":"string","maxLength":20,"title":"Env Type","description":"Environment type: production, staging, development"},"cpu_cores":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.25},{"type":"string"}],"title":"Cpu Cores","description":"CPU cores"},"ram_mb":{"type":"integer","maximum":131072.0,"minimum":256.0,"title":"Ram Mb","description":"RAM in MB"},"disk_gb":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Disk Gb","description":"Disk in GB"},"postgres_version":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Postgres Version"},"enable_pgtune":{"type":"boolean","title":"Enable Pgtune","default":true},"enable_pgbouncer":{"type":"boolean","title":"Enable Pgbouncer","default":true},"enable_read_replica":{"type":"boolean","title":"Enable Read Replica","default":false},"postgres_cpu_cores":{"anyOf":[{"type":"number","maximum":16.0,"minimum":0.1},{"type":"string"},{"type":"null"}],"title":"Postgres Cpu Cores"},"postgres_ram_mb":{"anyOf":[{"type":"integer","maximum":65536.0,"minimum":128.0},{"type":"null"}],"title":"Postgres Ram Mb"},"odoo_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Odoo Config","description":"OdooConfig object"},"with_demo_data":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"With Demo Data"},"is_featured":{"type":"boolean","title":"Is Featured","default":false},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"display_order":{"type":"integer","minimum":0.0,"title":"Display Order","default":0},"min_plan":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Min Plan"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"is_active":{"type":"boolean","title":"Is Active","default":true},"repos":{"items":{"$ref":"#/components/schemas/DeploymentTemplateRepoCreate"},"type":"array","title":"Repos"}},"type":"object","required":["name","description","category","odoo_version","env_type","cpu_cores","ram_mb","disk_gb"],"title":"DeploymentTemplateCreate","description":"Schema for creating a deployment template (admin).","example":{}},"DeploymentTemplateDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"type":"string","title":"Description"},"long_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Long Description"},"category":{"type":"string","title":"Category"},"icon":{"type":"string","title":"Icon"},"odoo_version":{"type":"string","title":"Odoo Version"},"env_type":{"type":"string","title":"Env Type"},"cpu_cores":{"type":"string","title":"Cpu Cores"},"ram_mb":{"type":"integer","title":"Ram Mb"},"disk_gb":{"type":"integer","title":"Disk Gb"},"postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Version"},"enable_pgtune":{"type":"boolean","title":"Enable Pgtune","default":true},"enable_pgbouncer":{"type":"boolean","title":"Enable Pgbouncer","default":true},"enable_read_replica":{"type":"boolean","title":"Enable Read Replica","default":false},"postgres_cpu_cores":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Cpu Cores"},"postgres_ram_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Postgres Ram Mb"},"odoo_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Odoo Config"},"with_demo_data":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"With Demo Data"},"is_featured":{"type":"boolean","title":"Is Featured","default":false},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"display_order":{"type":"integer","title":"Display Order","default":0},"deploy_count":{"type":"integer","title":"Deploy Count","default":0},"min_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Min Plan"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"is_active":{"type":"boolean","title":"Is Active","default":true},"repos":{"items":{"$ref":"#/components/schemas/DeploymentTemplateRepoResponse"},"type":"array","title":"Repos","default":[]},"estimated_concurrent_users":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Concurrent Users"},"create_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Create Date"},"write_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Write Date"}},"type":"object","required":["id","name","slug","description","category","icon","odoo_version","env_type","cpu_cores","ram_mb","disk_gb"],"title":"DeploymentTemplateDetailResponse","description":"Full template detail with repos.","example":{}},"DeploymentTemplateListResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"type":"string","title":"Description"},"category":{"type":"string","title":"Category"},"icon":{"type":"string","title":"Icon"},"odoo_version":{"type":"string","title":"Odoo Version"},"env_type":{"type":"string","title":"Env Type"},"cpu_cores":{"type":"string","title":"Cpu Cores"},"ram_mb":{"type":"integer","title":"Ram Mb"},"disk_gb":{"type":"integer","title":"Disk Gb"},"is_featured":{"type":"boolean","title":"Is Featured","default":false},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"deploy_count":{"type":"integer","title":"Deploy Count","default":0},"min_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Min Plan"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"display_order":{"type":"integer","title":"Display Order","default":0},"is_active":{"type":"boolean","title":"Is Active","default":true},"estimated_concurrent_users":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Concurrent Users"},"create_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Create Date"}},"type":"object","required":["id","name","slug","description","category","icon","odoo_version","env_type","cpu_cores","ram_mb","disk_gb"],"title":"DeploymentTemplateListResponse","description":"Schema for template list/card view. No repos — keep payload small.","example":{}},"DeploymentTemplateRepoCreate":{"properties":{"repo_url":{"type":"string","maxLength":500,"title":"Repo Url","description":"Git repository URL"},"repo_name":{"type":"string","maxLength":100,"title":"Repo Name","description":"Display name"},"branch":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Branch","description":"Branch override (null = inherit version)"},"is_required":{"type":"boolean","title":"Is Required","description":"Whether repo is required (locked in form)","default":true},"display_order":{"type":"integer","minimum":0.0,"title":"Display Order","description":"Sort order","default":0}},"type":"object","required":["repo_url","repo_name"],"title":"DeploymentTemplateRepoCreate","description":"Schema for creating/adding a repo to a template.","example":{}},"DeploymentTemplateRepoResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"repo_url":{"type":"string","title":"Repo Url"},"repo_name":{"type":"string","title":"Repo Name"},"branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch"},"is_required":{"type":"boolean","title":"Is Required","default":true},"display_order":{"type":"integer","title":"Display Order","default":0}},"type":"object","required":["id","repo_url","repo_name"],"title":"DeploymentTemplateRepoResponse","description":"Schema for repo in API responses.","example":{}},"DeploymentTemplateUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"long_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Long Description"},"category":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Category"},"icon":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Icon"},"odoo_version":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Odoo Version"},"env_type":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Env Type"},"cpu_cores":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.25},{"type":"string"},{"type":"null"}],"title":"Cpu Cores"},"ram_mb":{"anyOf":[{"type":"integer","maximum":131072.0,"minimum":256.0},{"type":"null"}],"title":"Ram Mb"},"disk_gb":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Disk Gb"},"postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Version"},"enable_pgtune":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Pgtune"},"enable_pgbouncer":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Pgbouncer"},"enable_read_replica":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Read Replica"},"postgres_cpu_cores":{"anyOf":[{"type":"number","maximum":16.0,"minimum":0.1},{"type":"string"},{"type":"null"}],"title":"Postgres Cpu Cores"},"postgres_ram_mb":{"anyOf":[{"type":"integer","maximum":65536.0,"minimum":128.0},{"type":"null"}],"title":"Postgres Ram Mb"},"odoo_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Odoo Config"},"with_demo_data":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"With Demo Data"},"is_featured":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Featured"},"is_verified":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Verified"},"display_order":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Display Order"},"min_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Min Plan"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"DeploymentTemplateUpdate","description":"Schema for updating a deployment template (admin). All fields optional.","example":{}},"DeploymentTrigger":{"type":"string","enum":["manual","git_push","webhook","scheduled","rollback","auto_deploy","destroy","config_update","clone","automation_rule","pr_open","pr_merge","tag_push"],"title":"DeploymentTrigger","description":"Deployment trigger types."},"DestroyEnvActionConfig":{"properties":{"action_type":{"type":"string","const":"destroy_env","title":"Action Type","default":"destroy_env"},"target_env_id":{"type":"string","format":"uuid","title":"Target Env Id","description":"Environment to destroy."}},"type":"object","required":["target_env_id"],"title":"DestroyEnvActionConfig","description":"Configuration for an environment destruction action."},"DetailedUtilizationResponse":{"properties":{"vm_id":{"type":"string","format":"uuid","title":"Vm Id"},"vm_name":{"type":"string","title":"Vm Name"},"physical_capacity":{"$ref":"#/components/schemas/PhysicalCapacityInfo"},"allocated_total":{"$ref":"#/components/schemas/AllocatedTotalInfo"},"used_actual":{"$ref":"#/components/schemas/UsedActualInfo"},"allocations":{"items":{"$ref":"#/components/schemas/OrgUtilizationInfo"},"type":"array","title":"Allocations"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings"}},"type":"object","required":["vm_id","vm_name","physical_capacity","allocated_total","used_actual","allocations"],"title":"DetailedUtilizationResponse","description":"Detailed utilization response for a shared server."},"DisabledReason":{"type":"string","enum":["circuit_breaker","manual"],"title":"DisabledReason","description":"Why an automation rule was automatically disabled."},"DiskUsageBreakdown":{"properties":{"images":{"type":"integer","title":"Images","description":"Space used by images (bytes)","default":0},"containers":{"type":"integer","title":"Containers","description":"Space used by containers (bytes)","default":0},"volumes":{"type":"integer","title":"Volumes","description":"Space used by volumes (bytes)","default":0},"build_cache":{"type":"integer","title":"Build Cache","description":"Space used by build cache (bytes)","default":0},"total":{"type":"integer","title":"Total","description":"Total space used (bytes)","default":0},"reclaimable":{"type":"integer","title":"Reclaimable","description":"Reclaimable space (bytes)","default":0}},"type":"object","title":"DiskUsageBreakdown","description":"Docker disk usage breakdown.","example":{}},"DiskUsageResponse":{"properties":{"vm_id":{"type":"string","format":"uuid","title":"Vm Id"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"When usage was checked"},"breakdown":{"$ref":"#/components/schemas/DiskUsageBreakdown"},"total_disk_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Disk Bytes","description":"Total disk space on server"},"available_disk_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Available Disk Bytes","description":"Available disk space on server"}},"type":"object","required":["vm_id","breakdown"],"title":"DiskUsageResponse","description":"Docker disk usage response.","example":{}},"DomainCreate":{"properties":{"domain":{"type":"string","maxLength":255,"title":"Domain","description":"Full domain name","examples":["app.example.com","staging.myproject.io"]},"dns_record_type":{"$ref":"#/components/schemas/DNSRecordType","description":"DNS record type","default":"A"},"ttl":{"type":"integer","maximum":86400.0,"minimum":60.0,"title":"Ttl","description":"Time to live in seconds","default":300},"proxied":{"type":"boolean","title":"Proxied","description":"Enable Cloudflare proxy mode (orange cloud)","default":false},"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID this domain belongs to"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID this domain is for"},"dns_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Dns Config Id","description":"DNS config to use for managing this domain"},"root_domain":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Root Domain","description":"Root domain for zone lookup (auto-detected if not provided)"},"target_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Ip","description":"Target IP address for A/AAAA records"},"target_cname":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Cname","description":"Target hostname for CNAME records"},"auto_configure":{"type":"boolean","title":"Auto Configure","description":"Automatically create DNS record on save","default":false},"is_primary":{"type":"boolean","title":"Is Primary","description":"Set as primary domain for the environment","default":false}},"type":"object","required":["domain","project_id","environment_id"],"title":"DomainCreate","description":"Schema for creating a domain.","example":{}},"DomainResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Domain ID"},"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"dns_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Dns Config Id","description":"DNS config ID (if managed)"},"domain":{"type":"string","title":"Domain","description":"Full domain name"},"root_domain":{"type":"string","title":"Root Domain","description":"Root domain"},"dns_record_type":{"$ref":"#/components/schemas/DNSRecordType","description":"DNS record type"},"target_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Ip","description":"Target IP address"},"target_cname":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Cname","description":"Target CNAME"},"ttl":{"type":"integer","title":"Ttl","description":"TTL in seconds"},"proxied":{"type":"boolean","title":"Proxied","description":"Cloudflare proxy mode"},"resolution_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolution Note","description":"Explains auto-applied changes (e.g., record type changed from A to CNAME)"},"dns_record_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dns Record Id","description":"Provider's record ID"},"dns_zone_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dns Zone Id","description":"Provider's zone ID"},"cf_hostname_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Hostname Id","description":"Cloudflare for SaaS hostname ID"},"ssl_enabled":{"type":"boolean","title":"Ssl Enabled","description":"SSL enabled"},"ssl_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssl Provider","description":"SSL provider"},"ssl_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ssl Expires At","description":"SSL certificate expiry"},"ssl_auto_renew":{"type":"boolean","title":"Ssl Auto Renew","description":"Auto-renew SSL"},"is_primary":{"type":"boolean","title":"Is Primary","description":"Primary domain for environment"},"is_verified":{"type":"boolean","title":"Is Verified","description":"Domain ownership verified"},"verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Verified At","description":"Verification timestamp"},"is_active":{"type":"boolean","title":"Is Active","description":"Domain active"},"dns_propagated":{"type":"boolean","title":"Dns Propagated","description":"DNS has propagated"},"redirect_to_domain_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Redirect To Domain Id","description":"Domain this one 301-redirects to, if any"},"status":{"type":"string","title":"Status","description":"Domain status","default":"pending"},"ssl_status":{"type":"string","title":"Ssl Status","description":"SSL status","default":"none"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["id","project_id","environment_id","dns_config_id","domain","root_domain","dns_record_type","target_ip","target_cname","ttl","proxied","dns_record_id","dns_zone_id","ssl_enabled","ssl_provider","ssl_expires_at","ssl_auto_renew","is_primary","is_verified","verified_at","is_active","dns_propagated","created_at","updated_at"],"title":"DomainResponse","description":"Schema for domain response.","example":{}},"DomainUpdate":{"properties":{"target_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Ip","description":"New target IP address"},"target_cname":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Cname","description":"New target hostname"},"ttl":{"anyOf":[{"type":"integer","maximum":86400.0,"minimum":60.0},{"type":"null"}],"title":"Ttl","description":"New TTL value"},"proxied":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Proxied","description":"Toggle Cloudflare proxy mode"},"is_primary":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Primary","description":"Set as primary domain"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Enable or disable domain"},"redirect_to_domain_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Redirect To Domain Id","description":"Set this domain to 301-redirect to another verified domain in the same environment (e.g. www -> apex). Pass null to clear an existing redirect. Omit the field entirely to leave it unchanged -- distinguished from an explicit null via model_fields_set, not the value itself."}},"type":"object","title":"DomainUpdate","description":"Schema for updating a domain.","example":{}},"DowngradeImpactFeature":{"properties":{"feature":{"type":"string","title":"Feature","description":"Feature code"},"name":{"type":"string","title":"Name","description":"Human-readable feature name"},"description":{"type":"string","title":"Description","description":"What will happen to this feature"},"count":{"type":"integer","title":"Count","description":"Number of affected resources"},"resources":{"items":{"$ref":"#/components/schemas/DowngradeImpactResource"},"type":"array","title":"Resources","description":"Affected resources"}},"type":"object","required":["feature","name","description","count"],"title":"DowngradeImpactFeature","description":"A feature category affected by downgrade.","example":{}},"DowngradeImpactResource":{"properties":{"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Domain name (for custom domains)"},"environment_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Name","description":"Environment name"},"environment_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Id","description":"Environment ID"},"policy_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policy Id","description":"Backup policy ID"},"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type","description":"Resource type"},"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id","description":"Resource ID"},"replica_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Replica Status","description":"Replica status"}},"type":"object","title":"DowngradeImpactResource","description":"A single resource affected by downgrade.","example":{}},"DowngradeImpactResponse":{"properties":{"target_plan":{"type":"string","title":"Target Plan","description":"Target plan being assessed"},"affected_features":{"items":{"$ref":"#/components/schemas/DowngradeImpactFeature"},"type":"array","title":"Affected Features","description":"Features that will be affected"},"total_affected_resources":{"type":"integer","title":"Total Affected Resources","description":"Total number of resources affected","default":0}},"type":"object","required":["target_plan"],"title":"DowngradeImpactResponse","description":"Response showing what will be affected by a plan downgrade.","example":{}},"EffectiveBackupPolicyResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"policy_source":{"$ref":"#/components/schemas/BackupPolicySource","description":"Source of the effective policy"},"enabled":{"type":"boolean","title":"Enabled","description":"Whether automated backups are enabled"},"schedule_cron":{"type":"string","title":"Schedule Cron","description":"Cron expression for backup schedule"},"timezone":{"type":"string","title":"Timezone","description":"Timezone for schedule"},"daily_retention":{"type":"integer","title":"Daily Retention","description":"Days to keep daily backups"},"weekly_retention":{"type":"integer","title":"Weekly Retention","description":"Weeks to keep weekly backups"},"monthly_retention":{"type":"integer","title":"Monthly Retention","description":"Months to keep monthly backups"},"yearly_retention":{"type":"integer","title":"Yearly Retention","description":"Years to keep yearly backups"},"weekly_backup_day":{"type":"integer","title":"Weekly Backup Day","description":"Day of week for weekly backup"},"storage_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Id","description":"Storage config ID"},"notify_on_success":{"type":"boolean","title":"Notify On Success","description":"Notify on success"},"notify_on_failure":{"type":"boolean","title":"Notify On Failure","description":"Notify on failure"},"org_policy_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Org Policy Id","description":"Organization policy ID (when using org_default)"},"environment_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Type","description":"Environment type (when using org_default)"},"custom_policy_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Custom Policy Id","description":"Custom environment policy ID (when using custom)"}},"type":"object","required":["environment_id","policy_source","enabled","schedule_cron","timezone","daily_retention","weekly_retention","monthly_retention","yearly_retention","weekly_backup_day","notify_on_success","notify_on_failure"],"title":"EffectiveBackupPolicyResponse","description":"Schema for effective backup policy for an environment.\n\nShows the resolved policy based on the environment's backup_policy_source setting.","example":{}},"EmailNotificationChannelCreate":{"properties":{"recipients":{"items":{"type":"string","format":"email"},"type":"array","title":"Recipients"},"events":{"items":{"type":"string"},"type":"array","title":"Events"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"is_active":{"type":"boolean","title":"Is Active","default":true}},"type":"object","required":["recipients","events"],"title":"EmailNotificationChannelCreate"},"EmailNotificationChannelResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"recipients":{"items":{"type":"string"},"type":"array","title":"Recipients"},"events":{"items":{"type":"string"},"type":"array","title":"Events"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","organization_id","project_id","recipients","events","description","is_active","created_at"],"title":"EmailNotificationChannelResponse"},"EmailNotificationChannelUpdate":{"properties":{"recipients":{"anyOf":[{"items":{"type":"string","format":"email"},"type":"array"},{"type":"null"}],"title":"Recipients"},"events":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Events"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"EmailNotificationChannelUpdate"},"EmailPreferencesResponse":{"properties":{"email":{"type":"string","title":"Email"},"lifecycle_enabled":{"type":"boolean","title":"Lifecycle Enabled","default":true},"marketing_enabled":{"type":"boolean","title":"Marketing Enabled","default":true},"alerts_enabled":{"type":"boolean","title":"Alerts Enabled","default":true},"educational_enabled":{"type":"boolean","title":"Educational Enabled","default":true},"news_enabled":{"type":"boolean","title":"News Enabled","default":true}},"type":"object","required":["email"],"title":"EmailPreferencesResponse"},"EmailPreferencesUpdate":{"properties":{"token":{"type":"string","title":"Token"},"lifecycle_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Lifecycle Enabled"},"marketing_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Marketing Enabled"},"alerts_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Alerts Enabled"},"educational_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Educational Enabled"},"news_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"News Enabled"}},"type":"object","required":["token"],"title":"EmailPreferencesUpdate"},"EmailTestResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"sent_to":{"items":{"type":"string"},"type":"array","title":"Sent To"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","sent_to","message"],"title":"EmailTestResponse"},"EmailTypeStat":{"properties":{"type":{"type":"string","title":"Type"},"sent":{"type":"integer","title":"Sent"},"failed":{"type":"integer","title":"Failed"}},"type":"object","required":["type","sent","failed"],"title":"EmailTypeStat","description":"Email delivery stats for a single email type."},"EmailVerificationRequest":{"properties":{"token":{"type":"string","title":"Token"}},"type":"object","required":["token"],"title":"EmailVerificationRequest","description":"Request to verify email with token."},"EnhancedPlatformStatsResponse":{"properties":{"total_users":{"type":"integer","title":"Total Users"},"active_users":{"type":"integer","title":"Active Users"},"total_organizations":{"type":"integer","title":"Total Organizations"},"total_projects":{"type":"integer","title":"Total Projects"},"total_servers":{"type":"integer","title":"Total Servers"},"total_environments":{"type":"integer","title":"Total Environments"},"total_paying_customers":{"type":"integer","title":"Total Paying Customers","default":0},"odooer_published":{"type":"integer","title":"Odooer Published","default":0},"odooer_drafts":{"type":"integer","title":"Odooer Drafts","default":0},"users_by_role":{"additionalProperties":{"type":"integer"},"type":"object","title":"Users By Role"},"server_health":{"$ref":"#/components/schemas/api__v1__routes__admin__stats_routes__ServerHealthSummary"},"backup_health":{"$ref":"#/components/schemas/BackupHealthSummary"},"environment_summary":{"$ref":"#/components/schemas/EnvironmentSummary"},"user_trend":{"$ref":"#/components/schemas/TrendData"},"project_trend":{"$ref":"#/components/schemas/TrendData"},"backup_trend":{"$ref":"#/components/schemas/TrendData"},"recent_activities":{"items":{"$ref":"#/components/schemas/RecentActivity"},"type":"array","title":"Recent Activities"},"total_storage_used_bytes":{"type":"integer","title":"Total Storage Used Bytes"},"storage_configs_count":{"type":"integer","title":"Storage Configs Count"},"open_tickets":{"type":"integer","title":"Open Tickets","default":0},"unassigned_tickets":{"type":"integer","title":"Unassigned Tickets","default":0},"avg_response_hours":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Response Hours"}},"type":"object","required":["total_users","active_users","total_organizations","total_projects","total_servers","total_environments","users_by_role","server_health","backup_health","environment_summary","user_trend","project_trend","backup_trend","recent_activities","total_storage_used_bytes","storage_configs_count"],"title":"EnhancedPlatformStatsResponse","description":"Enhanced platform statistics for admin dashboard."},"EnvRepoOverridesResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"repos":{"items":{"$ref":"#/components/schemas/EnvRepoWithOverrideStatus"},"type":"array","title":"Repos","default":[]},"excluded_count":{"type":"integer","title":"Excluded Count","default":0},"overridden_count":{"type":"integer","title":"Overridden Count","default":0},"total_count":{"type":"integer","title":"Total Count","default":0},"ineffective_overrides":{"items":{"$ref":"#/components/schemas/IneffectiveOverride"},"type":"array","title":"Ineffective Overrides","default":[]},"ineffective_count":{"type":"integer","title":"Ineffective Count","default":0},"version":{"type":"string","title":"Version","default":""}},"type":"object","required":["environment_id"],"title":"EnvRepoOverridesResponse","description":"Full response showing all repos with override status for an environment.\n\n`repos` and the counts cover repos this environment deploys. Stored rows\nfor any other repo are listed in `ineffective_overrides`.","example":{}},"EnvRepoWithOverrideStatus":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"repo_type":{"type":"string","title":"Repo Type"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"default_branch":{"type":"string","title":"Default Branch"},"is_excluded":{"type":"boolean","title":"Is Excluded","default":false},"branch_override":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch Override"}},"type":"object","required":["id","repo_type","name","slug","default_branch"],"title":"EnvRepoWithOverrideStatus","description":"A repo available for environment with its override status.","example":{}},"EnvironmentAction":{"type":"string","enum":["start","stop","pause","resume","restart","deploy","redeploy","destroy","clone","sync"],"title":"EnvironmentAction","description":"Available actions for environments."},"EnvironmentAddonsPathResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"resolved_addons_paths":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Resolved Addons Paths","description":"Auto-discovered addons paths from last deploy scan"},"custom_addons_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Addons Path","description":"User-specified custom addons_path override"},"effective_addons_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Effective Addons Path","description":"The addons_path actually in use (custom if set, else auto-detected)"}},"type":"object","required":["environment_id"],"title":"EnvironmentAddonsPathResponse","description":"Response for environment addons path info.","example":{}},"EnvironmentAutoTuneResponse":{"properties":{"applied":{"anyOf":[{"$ref":"#/components/schemas/AutoTuneResult"},{"type":"null"}],"description":"Values last written to odoo.conf; None before any generation"},"preview":{"$ref":"#/components/schemas/AutoTuneResult","description":"Values the next deploy would produce for the requested (or current) CPU/RAM"}},"type":"object","required":["preview"],"title":"EnvironmentAutoTuneResponse","description":"Applied vs. previewed Auto-Tune values for an environment (#1029).","example":{}},"EnvironmentBackupInfo":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"environment_name":{"type":"string","title":"Environment Name","description":"Environment name"},"backup_count":{"type":"integer","title":"Backup Count","description":"Number of backups"},"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total size of backups"},"latest_backup_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Latest Backup At","description":"Most recent backup timestamp"},"has_backups":{"type":"boolean","title":"Has Backups","description":"Whether environment has any backups"}},"type":"object","required":["environment_id","environment_name","backup_count","total_size_bytes","has_backups"],"title":"EnvironmentBackupInfo","description":"Information about backups when deleting an environment.","example":{}},"EnvironmentCustomDomainState":{"properties":{"domain":{"type":"string","title":"Domain","description":"The environment's custom_domain value"},"is_wildcard":{"type":"boolean","title":"Is Wildcard","description":"True for '*.apex' domains"},"is_verified":{"type":"boolean","title":"Is Verified","description":"environment.custom_domain_verified — Traefik routes on this"},"ssl_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssl Status","description":"Cert status, if known"},"verification_txt_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Txt Name","description":"TXT record name proving ownership (null once verified)"},"verification_txt_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Txt Value","description":"TXT record value proving ownership (null once verified)"}},"type":"object","required":["domain","is_wildcard","is_verified"],"title":"EnvironmentCustomDomainState","description":"The environment-level `custom_domain` field, as the UI needs it (#771).\n\nWildcards (`*.acme.com`) only exist here — `domainsApi.add` rejects them\nand `set_custom_domain` writes no `ProjectDomain` row — so without this\nblock the Domains tab could not show a wildcard at all, let alone the TXT\nrecord needed to verify one. That is what made the flow unverifiable\nafter wildcard self-verification was (correctly) removed.","example":{}},"EnvironmentMonitoringItem":{"properties":{"environment_id":{"type":"string","title":"Environment Id","description":"Environment UUID"},"environment_name":{"type":"string","title":"Environment Name","description":"Environment display name"},"environment_type":{"type":"string","title":"Environment Type","description":"Environment type: development, staging, production"},"project_id":{"type":"string","title":"Project Id","description":"Parent project UUID"},"project_name":{"type":"string","title":"Project Name","description":"Parent project name"},"server_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Id","description":"Server UUID if deployed"},"server_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Name","description":"Server name if deployed"},"status":{"type":"string","title":"Status","description":"Environment status: running, stopped, error, deploying"},"container_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Container Name","description":"Docker container name"},"cpu_percent":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Cpu Percent","description":"CPU usage percentage"},"memory_percent":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Memory Percent","description":"Memory usage percentage"},"memory_used_mb":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Memory Used Mb","description":"Memory used in MB"},"memory_limit_mb":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Memory Limit Mb","description":"Memory limit in MB"},"db_memory_used_mb":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Db Memory Used Mb","description":"PostgreSQL container memory used in MB"},"db_memory_limit_mb":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Db Memory Limit Mb","description":"PostgreSQL container memory limit in MB"},"uptime_seconds":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Uptime Seconds","description":"Container uptime in seconds"},"last_check":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Check","description":"When metrics were last checked"}},"type":"object","required":["environment_id","environment_name","environment_type","project_id","project_name","status"],"title":"EnvironmentMonitoringItem","description":"Monitoring data for a single environment.","example":{}},"EnvironmentMonitoringResponse":{"properties":{"environments":{"items":{"$ref":"#/components/schemas/EnvironmentMonitoringItem"},"type":"array","title":"Environments","description":"Environment monitoring data"},"total":{"type":"integer","minimum":0.0,"title":"Total","description":"Total number of environments"},"queried_at":{"type":"string","format":"date-time","title":"Queried At","description":"When the data was queried"}},"type":"object","required":["environments","total","queried_at"],"title":"EnvironmentMonitoringResponse","description":"Response for environment-level monitoring data.","example":{}},"EnvironmentPolicySourceResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"environment_name":{"type":"string","title":"Environment Name","description":"Environment name"},"environment_type":{"type":"string","title":"Environment Type","description":"Environment type"},"backup_policy_source":{"$ref":"#/components/schemas/BackupPolicySource","description":"Current policy source"},"has_custom_policy":{"type":"boolean","title":"Has Custom Policy","description":"Whether a custom policy exists"},"effective_enabled":{"type":"boolean","title":"Effective Enabled","description":"Whether backups are enabled"},"effective_schedule":{"type":"string","title":"Effective Schedule","description":"Effective cron schedule"},"effective_storage_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Effective Storage Id","description":"Effective storage ID"}},"type":"object","required":["environment_id","environment_name","environment_type","backup_policy_source","has_custom_policy","effective_enabled","effective_schedule"],"title":"EnvironmentPolicySourceResponse","description":"Response showing environment's policy source and summary.","example":{}},"EnvironmentResources":{"properties":{"cpu_cores":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.25},{"type":"string"}],"title":"Cpu Cores","description":"Allocated CPU cores for this environment","default":"1.0"},"ram_mb":{"type":"integer","maximum":131072.0,"minimum":256.0,"title":"Ram Mb","description":"Allocated RAM in MB for this environment","default":2048},"disk_gb":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Disk Gb","description":"Allocated disk space in GB for this environment","default":10}},"type":"object","title":"EnvironmentResources","description":"Resource allocation for an environment.","example":{}},"EnvironmentSnapshotInfo":{"properties":{"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id","description":"Environment ID at backup time"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Environment name at backup time"},"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type","description":"Environment type at backup time"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Environment status at backup time"},"container_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Container Name","description":"Container name at backup time"},"db_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Db Name","description":"Database name at backup time"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Domain at backup time"}},"type":"object","title":"EnvironmentSnapshotInfo","description":"Environment info from backup snapshot.","example":{}},"EnvironmentStats":{"properties":{"running":{"type":"integer","minimum":0.0,"title":"Running","description":"Running environments","default":0},"stopped":{"type":"integer","minimum":0.0,"title":"Stopped","description":"Stopped environments","default":0},"error":{"type":"integer","minimum":0.0,"title":"Error","description":"Environments in error state","default":0},"deploying":{"type":"integer","minimum":0.0,"title":"Deploying","description":"Environments being deployed","default":0},"pending":{"type":"integer","minimum":0.0,"title":"Pending","description":"Pending environments","default":0},"total":{"type":"integer","minimum":0.0,"title":"Total","description":"Total environments","default":0},"by_type":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Type","description":"Environment counts by type (development, staging, production)"}},"type":"object","title":"EnvironmentStats","description":"Environment statistics for dashboard overview.","example":{}},"EnvironmentStatusAction":{"properties":{"label":{"type":"string","title":"Label","description":"Button text, e.g. 'View deploy log'"},"kind":{"type":"string","title":"Kind","description":"server | view_logs | contact | settings"}},"type":"object","required":["label","kind"],"title":"EnvironmentStatusAction","description":"The one next step offered with a status reason (#1135).","example":{}},"EnvironmentStatusReason":{"properties":{"code":{"type":"string","title":"Code","description":"server_unreachable | server_error | deploy_failed | addon_dependencies_failed | odoo_not_responding | database_unavailable | out_of_memory | disk_full | restore_failed | clone_failed | server_missing | unknown"},"message":{"type":"string","title":"Message","description":"Customer-facing explanation"},"since":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Since","description":"When this started, if known"},"action":{"anyOf":[{"$ref":"#/components/schemas/EnvironmentStatusAction"},{"type":"null"}]}},"type":"object","required":["code","message"],"title":"EnvironmentStatusReason","description":"Why an environment is in its current status, in plain language (#1135).","example":{}},"EnvironmentSummary":{"properties":{"total":{"type":"integer","title":"Total"},"running":{"type":"integer","title":"Running"},"stopped":{"type":"integer","title":"Stopped"},"error":{"type":"integer","title":"Error"},"deploying":{"type":"integer","title":"Deploying"}},"type":"object","required":["total","running","stopped","error","deploying"],"title":"EnvironmentSummary","description":"Environment status overview."},"EnvironmentType":{"type":"string","enum":["development","staging","production"],"title":"EnvironmentType","description":"Project environment types."},"EnvironmentUsageResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"environment_name":{"type":"string","title":"Environment Name","description":"Environment name"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"period_start":{"type":"string","format":"date-time","title":"Period Start","description":"Period start"},"period_end":{"type":"string","format":"date-time","title":"Period End","description":"Period end"},"cpu_cores_allocated":{"type":"number","title":"Cpu Cores Allocated","description":"Allocated CPU cores"},"ram_mb_allocated":{"type":"integer","title":"Ram Mb Allocated","description":"Allocated RAM in MB"},"disk_gb_allocated":{"type":"integer","title":"Disk Gb Allocated","description":"Allocated disk in GB"},"cpu_hours":{"type":"string","title":"Cpu Hours","description":"CPU hours used"},"memory_gb_hours":{"type":"string","title":"Memory Gb Hours","description":"Memory GB-hours used"},"storage_gb_avg":{"type":"string","title":"Storage Gb Avg","description":"Average storage used"},"deployment_count":{"type":"integer","title":"Deployment Count","description":"Number of deployments"},"backup_count":{"type":"integer","title":"Backup Count","description":"Number of backups"},"estimated_cost":{"type":"string","title":"Estimated Cost","description":"Estimated cost"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether environment is currently active"}},"type":"object","required":["environment_id","environment_name","organization_id","period_start","period_end","cpu_cores_allocated","ram_mb_allocated","disk_gb_allocated","cpu_hours","memory_gb_hours","storage_gb_avg","deployment_count","backup_count","estimated_cost","is_active"],"title":"EnvironmentUsageResponse","description":"Usage for a specific environment.","example":{}},"ExportDownloadResponse":{"properties":{"available":{"type":"boolean","title":"Available"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size Bytes"},"generated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Generated At"}},"type":"object","required":["available"],"title":"ExportDownloadResponse","description":"Response with export download info."},"ExtendGracePeriodRequest":{"properties":{"additional_days":{"type":"integer","maximum":30.0,"minimum":1.0,"title":"Additional Days","description":"Number of days to extend (max 30)"},"reason":{"type":"string","maxLength":500,"minLength":10,"title":"Reason","description":"Reason for extension"}},"type":"object","required":["additional_days","reason"],"title":"ExtendGracePeriodRequest","description":"Request to extend grace period (admin only)."},"ExternalDBConnectionStatus":{"type":"string","enum":["untested","healthy","unreachable","auth_failed","invalid_pooling"],"title":"ExternalDBConnectionStatus","description":"Last-known connectivity status for the external database connection."},"ExternalDBProvider":{"type":"string","enum":["aws_rds","aws_aurora","do_managed","vultr_managed","hetzner_managed","azure_database","gcp_cloudsql","self_hosted","other"],"title":"ExternalDBProvider","description":"Supported external PostgreSQL provider types."},"ExternalDBSSLMode":{"type":"string","enum":["disable","require","verify-ca","verify-full"],"title":"ExternalDBSSLMode","description":"PostgreSQL SSL connection modes."},"ExternalDatabaseConnectionCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Display name for the connection (letters, digits, spaces, underscores, hyphens)"},"provider":{"$ref":"#/components/schemas/ExternalDBProvider","description":"External PostgreSQL provider type"},"host":{"type":"string","maxLength":255,"minLength":1,"title":"Host","description":"Hostname or IP address of the PostgreSQL cluster"},"port":{"type":"integer","maximum":65535.0,"minimum":1.0,"title":"Port","description":"TCP port (default 5432)","default":5432},"ssl_mode":{"$ref":"#/components/schemas/ExternalDBSSLMode","description":"PostgreSQL SSL connection mode (default: require)","default":"require"},"ssl_root_cert":{"anyOf":[{"type":"string","maxLength":20000},{"type":"null"}],"title":"Ssl Root Cert","description":"PEM-encoded CA certificate for SSL verification (optional)"},"admin_username":{"type":"string","maxLength":63,"minLength":1,"title":"Admin Username","description":"Admin username with CREATE DATABASE / CREATE ROLE privileges"},"admin_password":{"type":"string","maxLength":500,"minLength":1,"title":"Admin Password","description":"Admin password (stored encrypted)"},"replica_host":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Replica Host","description":"Optional read-replica hostname or IP (connection-level; per-env override in v2)"},"replica_port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Replica Port","description":"TCP port for the replica endpoint (default: same as primary port)"}},"type":"object","required":["name","provider","host","admin_username","admin_password"],"title":"ExternalDatabaseConnectionCreate","description":"Schema for creating a new external database connection.\n\nPOST /organizations/{org_id}/external-database-connections","example":{}},"ExternalDatabaseConnectionListResponse":{"properties":{"connections":{"items":{"$ref":"#/components/schemas/ExternalDatabaseConnectionResponse"},"type":"array","title":"Connections"},"total":{"type":"integer","title":"Total","description":"Total number of connections for this organization"}},"type":"object","required":["connections","total"],"title":"ExternalDatabaseConnectionListResponse","description":"Response schema for listing external database connections.","example":{}},"ExternalDatabaseConnectionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"name":{"type":"string","title":"Name"},"provider":{"$ref":"#/components/schemas/ExternalDBProvider"},"host":{"type":"string","title":"Host"},"port":{"type":"integer","title":"Port"},"ssl_mode":{"$ref":"#/components/schemas/ExternalDBSSLMode"},"has_ssl_root_cert":{"type":"boolean","title":"Has Ssl Root Cert","description":"True when a custom CA certificate is stored; cert blob is never returned","default":false},"admin_username":{"type":"string","title":"Admin Username"},"server_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Version"},"replica_host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Replica Host"},"replica_port":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Replica Port"},"connection_status":{"$ref":"#/components/schemas/ExternalDBConnectionStatus"},"last_health_check_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Health Check At"},"last_health_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Health Error"},"test_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Test Vm Id","description":"Default server for connection tests"},"last_tested_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Last Tested Vm Id","description":"Server the current status was measured from (null = platform)"},"last_tested_from":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Tested From","description":"'server' or 'platform' for where the last test ran; null if never tested"},"requires_server_test":{"type":"boolean","title":"Requires Server Test","description":"True when the platform could not test this host (private or not resolvable from the platform). It can still be used for an environment on your own server, where the deploy verifies it.","default":false},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Timestamp when the connection was created"}},"type":"object","required":["id","organization_id","name","provider","host","port","ssl_mode","admin_username","connection_status","is_active","created_at"],"title":"ExternalDatabaseConnectionResponse","description":"Response schema for an external database connection.\n\nSECURITY: credentials_encrypted, _credentials_encrypted, and ssl_root_cert\nblob are intentionally excluded. Only has_ssl_root_cert (bool) is exposed\nso the UI can show a \"Custom CA\" badge without leaking the cert.\n\nThe model column is `create_date` (Odoo convention); we surface it as\n`created_at` in the JSON response via serialization_alias.","example":{}},"ExternalDatabaseConnectionUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"New display name"},"host":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Host","description":"New hostname or IP address"},"port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Port","description":"New TCP port"},"ssl_mode":{"anyOf":[{"$ref":"#/components/schemas/ExternalDBSSLMode"},{"type":"null"}],"description":"New SSL connection mode"},"ssl_root_cert":{"anyOf":[{"type":"string","maxLength":20000},{"type":"null"}],"title":"Ssl Root Cert","description":"New PEM CA certificate (pass empty string to clear)"},"admin_username":{"anyOf":[{"type":"string","maxLength":63,"minLength":1},{"type":"null"}],"title":"Admin Username","description":"New admin username"},"admin_password":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Admin Password","description":"New admin password (stored encrypted)"},"replica_host":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Replica Host","description":"New replica hostname (pass empty string to clear)"},"replica_port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Replica Port","description":"New replica TCP port"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Enable or disable the connection"},"test_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Test Vm Id","description":"Default server for connection tests (#1171): one of your own servers in this organization. Pass null to clear."}},"type":"object","title":"ExternalDatabaseConnectionUpdate","description":"Schema for partial updates to an external database connection.\n\nPATCH /organizations/{org_id}/external-database-connections/{id}\n\nNote: provider is intentionally NOT updatable — changing it would\ninvalidate all attached environments' cluster assumptions.","example":{}},"ExternalDatabaseSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"External database connection ID"},"name":{"type":"string","title":"Name","description":"Connection display name"},"host":{"type":"string","title":"Host","description":"Database host (DNS name or IP)"},"port":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Port","description":"Database port (e.g. 5432)"},"connection_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connection Status","description":"Last-known connectivity status (e.g. 'healthy', 'untested')."},"has_replica":{"type":"boolean","title":"Has Replica","description":"Whether a read replica host is configured on this connection.","default":false}},"type":"object","required":["id","name","host"],"title":"ExternalDatabaseSummary","description":"Read-only summary of the external PostgreSQL connection linked to an env.\n\nSurfaced on the environment detail page so external-PG (two-server)\ncustomers can see, at a glance, that the app server here talks to a\ndatabase hosted on a separate connection/cluster.\n\nCredentials (admin_username / password / encrypted blob) are intentionally\nNOT exposed — this is a customer-facing, read-only association summary.","example":{}},"FailedBackupInfo":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Backup ID"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID"},"environment_name":{"type":"string","title":"Environment Name","description":"Environment name"},"project_name":{"type":"string","title":"Project Name","description":"Project name"},"failed_at":{"type":"string","format":"date-time","title":"Failed At","description":"When backup failed"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message from failed backup"}},"type":"object","required":["id","environment_id","environment_name","project_name","failed_at"],"title":"FailedBackupInfo","description":"Information about a failed backup.","example":{}},"FailedTaskResponse":{"properties":{"job_id":{"type":"string","title":"Job Id","description":"ARQ job ID"},"function_name":{"type":"string","title":"Function Name","description":"Name of the failed task function"},"args":{"items":{},"type":"array","title":"Args","description":"Positional arguments"},"kwargs":{"type":"object","title":"Kwargs","description":"Keyword arguments"},"error":{"type":"string","title":"Error","description":"Error message from exception"},"traceback":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Traceback","description":"Full traceback string"},"retry_count":{"type":"integer","title":"Retry Count","description":"Number of times the task was retried"},"failed_at":{"type":"string","title":"Failed At","description":"ISO timestamp when task failed"}},"type":"object","required":["job_id","function_name","error","retry_count","failed_at"],"title":"FailedTaskResponse","description":"Response schema for a failed task in DLQ."},"FixAction":{"type":"string","enum":["install_docker","install_docker_compose","start_docker","restart_docker","upgrade_docker","install_packages","install_compose_v2","configure_swap","configure_inotify","configure_firewall","install_netdata","start_netdata","restart_netdata","setup_traefik","reinstall_ca_bundle"],"title":"FixAction","description":"Available fix actions."},"ForcePurgeRequest":{"properties":{"confirm_text":{"type":"string","title":"Confirm Text","description":"Must be exactly 'FORCE PURGE' to confirm"},"reason":{"type":"string","maxLength":500,"minLength":10,"title":"Reason","description":"Reason for force purge"}},"type":"object","required":["confirm_text","reason"],"title":"ForcePurgeRequest","description":"Request to force purge (admin only)."},"ForcePurgeResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"message":{"type":"string","title":"Message"},"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"}},"type":"object","required":["message"],"title":"ForcePurgeResponse","description":"Response after force purge."},"GenerateConfRequest":{"properties":{"version":{"type":"string","title":"Version","description":"Odoo version (e.g., '18.0')"},"db_host":{"type":"string","title":"Db Host","description":"PostgreSQL host"},"db_port":{"type":"integer","title":"Db Port","description":"PostgreSQL port","default":5432},"db_user":{"type":"string","title":"Db User","description":"Database username"},"db_password":{"type":"string","title":"Db Password","description":"Database password"},"db_name":{"type":"string","title":"Db Name","description":"Database name"},"addons_path":{"type":"string","title":"Addons Path","description":"Comma-separated addons paths"},"data_dir":{"type":"string","title":"Data Dir","description":"Odoo data directory","default":"/var/lib/odoo"},"admin_passwd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Admin Passwd","description":"Master password"},"env_type":{"type":"string","enum":["development","staging","production"],"title":"Env Type","description":"Environment type","default":"production"},"user_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"User Config","description":"User config overrides"},"use_recommended":{"type":"boolean","title":"Use Recommended","description":"Apply recommended settings","default":true},"cpu_cores":{"type":"number","maximum":32.0,"minimum":0.5,"title":"Cpu Cores","description":"CPU cores allocated","default":1.0},"ram_mb":{"type":"integer","maximum":65536.0,"minimum":512.0,"title":"Ram Mb","description":"RAM in MB","default":2048},"replica_host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Replica Host","description":"Read replica host (v18+)"},"replica_port":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Replica Port","description":"Read replica port (v18+)"}},"type":"object","required":["version","db_host","db_user","db_password","db_name","addons_path"],"title":"GenerateConfRequest","description":"Request body for generating odoo.conf file."},"GenerateConfResponse":{"properties":{"conf_content":{"type":"string","title":"Conf Content","description":"Generated odoo.conf content"},"version":{"type":"number","title":"Version","description":"Odoo version used"},"parameters_used":{"type":"object","title":"Parameters Used","description":"Parameters in generated conf"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Warning messages"},"errors":{"items":{"type":"string"},"type":"array","title":"Errors","description":"Error messages"}},"type":"object","required":["conf_content","version","parameters_used"],"title":"GenerateConfResponse","description":"Response body for conf generation."},"GenerateKeyResponse":{"properties":{"private_key":{"type":"string","title":"Private Key","description":"Private key (save securely!)"},"public_key":{"type":"string","title":"Public Key","description":"Public key"},"instructions":{"type":"string","title":"Instructions","description":"Usage instructions"}},"type":"object","required":["private_key","public_key","instructions"],"title":"GenerateKeyResponse","description":"Response with generated SSH key pair."},"GitAuthMethod":{"type":"string","enum":["oauth","pat","github_app","gitlab_token"],"title":"GitAuthMethod","description":"Git authentication methods."},"GitBranch":{"properties":{"name":{"type":"string","title":"Name"},"is_default":{"type":"boolean","title":"Is Default","default":false},"is_protected":{"type":"boolean","title":"Is Protected","default":false},"last_commit_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Commit Date"}},"type":"object","required":["name"],"title":"GitBranch","description":"Git branch."},"GitConnectionSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"provider":{"type":"string","title":"Provider"},"auth_method":{"type":"string","title":"Auth Method"},"is_oauth":{"type":"boolean","title":"Is Oauth"}},"type":"object","required":["id","name","provider","auth_method","is_oauth"],"title":"GitConnectionSummary","description":"Summary of a git connection for impact report."},"GitOrganization":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"login":{"type":"string","title":"Login"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url"},"type":{"type":"string","title":"Type"}},"type":"object","required":["id","name","login","type"],"title":"GitOrganization","description":"Git organization/namespace."},"GitProvider":{"type":"string","enum":["github","gitlab","bitbucket"],"title":"GitProvider","description":"Supported Git providers."},"GitProvider-Output":{"type":"string","enum":["github","gitlab","bitbucket","generic"],"title":"GitProvider","description":"Supported Git providers."},"GitRepository":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"full_name":{"type":"string","title":"Full Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"html_url":{"type":"string","title":"Html Url"},"clone_url":{"type":"string","title":"Clone Url"},"default_branch":{"type":"string","title":"Default Branch"},"private":{"type":"boolean","title":"Private"},"owner":{"type":"string","title":"Owner"}},"type":"object","required":["id","name","full_name","html_url","clone_url","default_branch","private","owner"],"title":"GitRepository","description":"Git repository."},"GracePeriodExtendedResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"message":{"type":"string","title":"Message"},"new_grace_period_ends_at":{"type":"string","format":"date-time","title":"New Grace Period Ends At"},"additional_days":{"type":"integer","title":"Additional Days"}},"type":"object","required":["message","new_grace_period_ends_at","additional_days"],"title":"GracePeriodExtendedResponse","description":"Response after extending grace period."},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"HeartbeatRequest":{"properties":{"env_id":{"type":"string","format":"uuid","title":"Env Id"},"server_id":{"type":"string","maxLength":32,"minLength":1,"title":"Server Id"},"oneshot_token":{"type":"string","maxLength":64,"minLength":32,"title":"Oneshot Token"}},"type":"object","required":["env_id","server_id","oneshot_token"],"title":"HeartbeatRequest"},"ImageUpdatePolicyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"enabled":{"type":"boolean","title":"Enabled"},"schedule_cron":{"type":"string","title":"Schedule Cron"},"run_module_upgrades":{"type":"boolean","title":"Run Module Upgrades"},"last_updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Updated At"},"next_update_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Update At"},"last_update_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Update Status"}},"type":"object","required":["id","environment_id","enabled","schedule_cron","run_module_upgrades","last_updated_at","next_update_at","last_update_status"],"title":"ImageUpdatePolicyResponse"},"ImageUpdatePolicyUpdate":{"properties":{"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled"},"schedule_cron":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schedule Cron"},"run_module_upgrades":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Run Module Upgrades"}},"type":"object","title":"ImageUpdatePolicyUpdate"},"ImpersonationAuditEntryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"token_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Token Id"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"},"action":{"type":"string","title":"Action"},"initiator_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Initiator User Id"},"initiator_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Initiator Email"},"target_odoo_user_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Target Odoo User Id"},"target_odoo_login":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Odoo Login"},"target_odoo_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Odoo Name"},"target_is_portal":{"type":"boolean","title":"Target Is Portal","description":"True when the target user was a portal (share=true) user","default":false},"error_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Code"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"details":{"type":"object","title":"Details"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"request_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Request Id"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp"}},"type":"object","required":["id","action","timestamp"],"title":"ImpersonationAuditEntryResponse","description":"Audit log entry for impersonation events."},"ImpersonationAuditListResponse":{"properties":{"entries":{"items":{"$ref":"#/components/schemas/ImpersonationAuditEntryResponse"},"type":"array","title":"Entries"},"total":{"type":"integer","title":"Total"},"skip":{"type":"integer","title":"Skip","default":0},"limit":{"type":"integer","title":"Limit","default":50},"has_more":{"type":"boolean","title":"Has More","default":false}},"type":"object","required":["entries","total"],"title":"ImpersonationAuditListResponse","description":"Paginated list of audit entries."},"ImpersonationInitiateRequest":{"properties":{"target_odoo_user_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Target Odoo User Id","description":"Odoo res.users.id to impersonate"},"target_email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Target Email","description":"Alternative: look up the Odoo user by email within this env's DB"},"reason":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Reason"}},"type":"object","title":"ImpersonationInitiateRequest","description":"Request to initiate an impersonation session.\n\nExactly one of ``target_odoo_user_id`` or ``target_email`` must be provided.\nBoth together, or neither, raises a validation error."},"ImpersonationInitiateResponse":{"properties":{"token":{"type":"string","title":"Token","description":"JWT — opaque, do not parse client-side"},"redirect_url":{"type":"string","title":"Redirect Url","description":"Full URL to navigate the browser to"},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"Token TTL — UTC"},"audit_id":{"type":"string","format":"uuid","title":"Audit Id","description":"Audit row id for correlation"}},"type":"object","required":["token","redirect_url","expires_at","audit_id"],"title":"ImpersonationInitiateResponse","description":"Response when impersonation is initiated."},"ImpersonationRevokeRequest":{"properties":{"token_id":{"type":"string","format":"uuid","title":"Token Id"},"reason":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Reason"}},"type":"object","required":["token_id"],"title":"ImpersonationRevokeRequest","description":"Request to revoke an impersonation token."},"ImpersonationRevokeResponse":{"properties":{"token_id":{"type":"string","format":"uuid","title":"Token Id"},"revoked_at":{"type":"string","format":"date-time","title":"Revoked At"},"status":{"type":"string","title":"Status","default":"revoked"}},"type":"object","required":["token_id","revoked_at"],"title":"ImpersonationRevokeResponse","description":"Response when impersonation is revoked."},"ImpersonationUserListResponse":{"properties":{"users":{"items":{"$ref":"#/components/schemas/OdooUserInfo"},"type":"array","title":"Users"},"total":{"type":"integer","title":"Total"},"skip":{"type":"integer","title":"Skip","default":0},"limit":{"type":"integer","title":"Limit","default":50},"has_more":{"type":"boolean","title":"Has More","default":false}},"type":"object","required":["users","total"],"title":"ImpersonationUserListResponse","description":"Response for listing available Odoo users in an environment."},"IncidentActionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"status":{"type":"string","title":"Status"},"acknowledged_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Acknowledged By"},"acknowledged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Acknowledged At"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At"},"suppressed_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Suppressed Until"}},"type":"object","required":["id","status"],"title":"IncidentActionResponse","description":"Generic action response — fields populated based on which action.\n\nCommittee High 17 (2026-05-19): we deliberately keep ONE response\nschema across acknowledge/resolve/suppress so the frontend can use a\nsingle type. Field semantics depend on the action taken:\n\n* ``acknowledge``  — ``acknowledged_by`` + ``acknowledged_at`` set.\n                     ``resolved_at`` / ``suppressed_until`` remain None\n                     (unless previously set by an earlier action).\n* ``resolve``      — ``resolved_at`` set. The acknowledged fields may\n                     carry over from a prior acknowledge — that is by\n                     design (the row IS still the same incident).\n* ``suppress``     — ``suppressed_until`` set to now()+24h. The other\n                     action-timestamp fields may carry over.\n\nIf a clean per-action contract is ever required, split into\n``AcknowledgeResponse`` / ``ResolveResponse`` / ``SuppressResponse``\nand switch the route response_model accordingly. The current choice\nfavours frontend simplicity over field-level purity."},"IncidentDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"check_id":{"type":"string","title":"Check Id"},"severity":{"type":"string","title":"Severity"},"status":{"type":"string","title":"Status"},"scope":{"type":"string","title":"Scope"},"title":{"type":"string","title":"Title"},"affected_count":{"type":"integer","title":"Affected Count"},"first_seen":{"type":"string","format":"date-time","title":"First Seen"},"last_seen":{"type":"string","format":"date-time","title":"Last Seen"},"acknowledged_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Acknowledged By"},"acknowledged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Acknowledged At"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At"},"suppressed_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Suppressed Until"},"runbook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runbook Url"},"evidence":{"type":"object","title":"Evidence"},"escalation_history":{"items":{"type":"object"},"type":"array","title":"Escalation History"}},"type":"object","required":["id","check_id","severity","status","scope","title","affected_count","first_seen","last_seen"],"title":"IncidentDetail","description":"Detail view with full evidence + escalation history."},"IncidentListResponse":{"properties":{"incidents":{"items":{"$ref":"#/components/schemas/IncidentSummary"},"type":"array","title":"Incidents"},"total":{"type":"integer","title":"Total"},"page_size":{"type":"integer","title":"Page Size"},"has_more":{"type":"boolean","title":"Has More"}},"type":"object","required":["incidents","total","page_size","has_more"],"title":"IncidentListResponse"},"IncidentSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"check_id":{"type":"string","title":"Check Id"},"severity":{"type":"string","title":"Severity"},"status":{"type":"string","title":"Status"},"scope":{"type":"string","title":"Scope"},"title":{"type":"string","title":"Title"},"affected_count":{"type":"integer","title":"Affected Count"},"first_seen":{"type":"string","format":"date-time","title":"First Seen"},"last_seen":{"type":"string","format":"date-time","title":"Last Seen"},"acknowledged_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Acknowledged By"},"acknowledged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Acknowledged At"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At"},"suppressed_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Suppressed Until"},"runbook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runbook Url"}},"type":"object","required":["id","check_id","severity","status","scope","title","affected_count","first_seen","last_seen"],"title":"IncidentSummary","description":"List-view (no full evidence payload — keeps responses small)."},"IneffectiveOverride":{"properties":{"repo_type":{"type":"string","title":"Repo Type"},"repo_id":{"type":"string","format":"uuid","title":"Repo Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"is_excluded":{"type":"boolean","title":"Is Excluded","default":false},"branch_override":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch Override"},"reason":{"type":"string","enum":["not_selected","inactive","unknown"],"title":"Reason"}},"type":"object","required":["repo_type","repo_id","reason"],"title":"IneffectiveOverride","description":"A stored override row that does nothing, because its repo does not deploy here.","example":{}},"InfraCapacityStats":{"properties":{"total_cpu_cores":{"type":"integer","minimum":0.0,"title":"Total Cpu Cores","description":"Total CPU cores across all servers","default":0},"allocated_cpu_cores":{"type":"number","minimum":0.0,"title":"Allocated Cpu Cores","description":"CPU cores allocated to projects","default":0.0},"cpu_allocation_percent":{"type":"number","minimum":0.0,"title":"Cpu Allocation Percent","description":"Percentage of CPU capacity allocated (can exceed 100% if overprovisioned)","default":0.0},"total_memory_gb":{"type":"number","minimum":0.0,"title":"Total Memory Gb","description":"Total memory (GB) across all servers","default":0.0},"allocated_memory_gb":{"type":"number","minimum":0.0,"title":"Allocated Memory Gb","description":"Memory (GB) allocated to projects","default":0.0},"memory_allocation_percent":{"type":"number","minimum":0.0,"title":"Memory Allocation Percent","description":"Percentage of memory capacity allocated (can exceed 100% if overprovisioned)","default":0.0},"total_disk_gb":{"type":"integer","minimum":0.0,"title":"Total Disk Gb","description":"Total disk (GB) across all servers","default":0},"total_project_slots":{"type":"integer","minimum":0.0,"title":"Total Project Slots","description":"Total project slots across all servers","default":0},"used_project_slots":{"type":"integer","minimum":0.0,"title":"Used Project Slots","description":"Project slots currently in use","default":0},"project_slots_percent":{"type":"number","minimum":0.0,"title":"Project Slots Percent","description":"Percentage of project slots used (can exceed 100% if overprovisioned)","default":0.0},"total_projects":{"type":"integer","minimum":0.0,"title":"Total Projects","description":"Total active projects","default":0},"total_environments":{"type":"integer","minimum":0.0,"title":"Total Environments","description":"Total environments deployed","default":0},"servers_available":{"type":"integer","minimum":0.0,"title":"Servers Available","description":"Servers with available capacity","default":0},"servers_full":{"type":"integer","minimum":0.0,"title":"Servers Full","description":"Servers at max project capacity","default":0}},"type":"object","title":"InfraCapacityStats","description":"Infrastructure capacity statistics for dashboard overview.","example":{}},"InitiateDepartureRequest":{"properties":{"confirm_name":{"type":"string","title":"Confirm Name","description":"Must match organization name exactly to confirm"},"reason":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Reason","description":"Optional reason for departure"},"feedback":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Feedback","description":"Optional feedback about the platform"}},"type":"object","required":["confirm_name"],"title":"InitiateDepartureRequest","description":"Request to initiate departure process."},"InvitationAccept":{"properties":{"code":{"anyOf":[{"type":"string","maxLength":6,"minLength":6},{"type":"null"}],"title":"Code","description":"6-character invitation code"},"token":{"anyOf":[{"type":"string","maxLength":64,"minLength":64},{"type":"null"}],"title":"Token","description":"64-character link token"}},"type":"object","title":"InvitationAccept","description":"Schema for accepting an invitation.","example":{}},"InvitationAcceptResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether acceptance succeeded"},"organization_id":{"type":"string","title":"Organization Id","description":"Joined organization ID"},"organization_name":{"type":"string","title":"Organization Name","description":"Joined organization name"},"organization_slug":{"type":"string","title":"Organization Slug","description":"Joined organization slug"},"scope":{"type":"string","title":"Scope","description":"Invitation scope: organization or project","default":"organization"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role","description":"Assigned legacy role (for org-scope)"},"org_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Org Role","description":"Assigned organization role (for org-scope)"},"project_access":{"anyOf":[{"items":{"$ref":"#/components/schemas/ProjectAccessInfo"},"type":"array"},{"type":"null"}],"title":"Project Access","description":"Project access granted (for project-scope)"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Welcome message"}},"type":"object","required":["success","organization_id","organization_name","organization_slug"],"title":"InvitationAcceptResponse","description":"Schema for invitation acceptance response.","example":{}},"InvitationCreate":{"properties":{"email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Email","description":"Email to restrict invitation to (optional)"},"scope":{"$ref":"#/components/schemas/InvitationScope","description":"Scope: 'organization' for org-wide, 'project' for specific projects","default":"organization"},"role":{"$ref":"#/components/schemas/OrganizationRole","description":"Org role for organization-scope invites (OWNER, ADMIN, DEVELOPER, VIEWER)","default":"developer"},"project_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Project Ids","description":"Project IDs for project-scope invites (required when scope=project)"},"project_role":{"$ref":"#/components/schemas/ProjectRole","description":"Role within projects for project-scope invites (admin, developer, viewer)","default":"developer"},"project_access":{"anyOf":[{"type":"string","const":"all"},{"items":{"type":"string","format":"uuid"},"type":"array"}],"title":"Project Access","description":"For org-scope developer/viewer invites: 'all' for every project (current + future), or a list of project IDs for specific projects","default":"all"},"expires_in_days":{"type":"integer","maximum":30.0,"minimum":1.0,"title":"Expires In Days","description":"Days until invitation expires","default":7},"max_uses":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":1.0},{"type":"null"}],"title":"Max Uses","description":"Maximum uses (null for unlimited)","default":1},"message":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Message","description":"Optional message to include"}},"type":"object","title":"InvitationCreate","description":"Schema for creating an organization invitation.\n\nSupports two scopes:\n- organization: User gets org-wide access with specified role\n- project: User gets access only to specified projects","example":{}},"InvitationListResponse":{"properties":{"invitations":{"items":{"$ref":"#/components/schemas/InvitationResponse"},"type":"array","title":"Invitations","description":"List of invitations"},"total":{"type":"integer","title":"Total","description":"Total count"}},"type":"object","required":["invitations","total"],"title":"InvitationListResponse","description":"Schema for listing invitations.","example":{}},"InvitationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"organization_id":{"type":"string","title":"Organization Id","description":"Organization ID"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Restricted email (if set)"},"scope":{"type":"string","title":"Scope","description":"Invitation scope: organization or project","default":"organization"},"role":{"type":"string","title":"Role","description":"Legacy role on acceptance"},"org_role":{"type":"string","title":"Org Role","description":"Organization role on acceptance"},"project_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Project Ids","description":"Project IDs for project-scope invites"},"project_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Role","description":"Role within projects for project-scope invites"},"projects":{"anyOf":[{"items":{"$ref":"#/components/schemas/ProjectInfo"},"type":"array"},{"type":"null"}],"title":"Projects","description":"Project details for project-scope invites"},"code":{"type":"string","title":"Code","description":"6-character invitation code"},"link_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Link Token","description":"64-character token (only shown on creation)"},"status":{"type":"string","title":"Status","description":"Invitation status"},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"Expiration timestamp"},"max_uses":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Uses","description":"Maximum uses (null = unlimited)"},"use_count":{"type":"integer","title":"Use Count","description":"Current use count"},"remaining_uses":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Remaining Uses","description":"Remaining uses (null = unlimited)"},"is_valid":{"type":"boolean","title":"Is Valid","description":"Whether invitation is currently valid"},"invited_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invited By","description":"User ID who created invitation"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization name (set on GET /invitations/me)"},"inviter_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inviter Name","description":"Name of user who created invitation"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Optional message"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At","description":"Creation timestamp"},"updated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["id","organization_id","email","role","org_role","code","status","expires_at","max_uses","use_count","remaining_uses","is_valid","invited_by","message"],"title":"InvitationResponse","description":"Schema for invitation response.","example":{}},"InvitationScope":{"type":"string","enum":["organization","project"],"title":"InvitationScope","description":"Scope of invitation - organization-wide or project-specific."},"InvitationValidate":{"properties":{"code":{"anyOf":[{"type":"string","maxLength":6,"minLength":6},{"type":"null"}],"title":"Code","description":"6-character invitation code"},"token":{"anyOf":[{"type":"string","maxLength":64,"minLength":64},{"type":"null"}],"title":"Token","description":"64-character link token"}},"type":"object","title":"InvitationValidate","description":"Schema for validating an invitation (without accepting).","example":{}},"InvitationValidateResponse":{"properties":{"valid":{"type":"boolean","title":"Valid","description":"Whether invitation is valid"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization name"},"organization_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Slug","description":"Organization slug"},"email_restricted":{"type":"boolean","title":"Email Restricted","description":"Whether restricted to specific email"},"restricted_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Restricted Email","description":"Restricted email (if any)"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"Expiration timestamp"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Optional message from inviter"},"scope":{"type":"string","title":"Scope","description":"Invitation scope: organization or project","default":"organization"},"projects":{"anyOf":[{"items":{"$ref":"#/components/schemas/ProjectInfo"},"type":"array"},{"type":"null"}],"title":"Projects","description":"Projects being invited to (for project-scope)"},"project_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Role","description":"Role within projects (for project-scope)"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if invalid"}},"type":"object","required":["valid","organization_name","organization_slug","email_restricted","restricted_email","expires_at","message"],"title":"InvitationValidateResponse","description":"Schema for invitation validation response.","example":{}},"KillSwitchAction":{"properties":{"action":{"type":"string","pattern":"^(activate|deactivate)$","title":"Action"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["action"],"title":"KillSwitchAction"},"KillSwitchStatus":{"properties":{"active":{"type":"boolean","title":"Active"},"activated_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Activated At"},"activated_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Activated By"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["active"],"title":"KillSwitchStatus"},"LifecycleEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp"},"action":{"type":"string","title":"Action"},"action_display":{"type":"string","title":"Action Display"},"actor_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Email"}},"type":"object","required":["id","timestamp","action","action_display"],"title":"LifecycleEventResponse","description":"#1431 review: one row of the environment page's Lifecycle panel.","example":{}},"LifecycleListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/LifecycleEventResponse"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"LifecycleListResponse","example":{}},"LifecycleStatsResponse":{"properties":{"total_checkouts":{"type":"integer","title":"Total Checkouts"},"pending_checkouts":{"type":"integer","title":"Pending Checkouts"},"completed_checkouts":{"type":"integer","title":"Completed Checkouts"},"expired_checkouts":{"type":"integer","title":"Expired Checkouts"},"recovered_checkouts":{"type":"integer","title":"Recovered Checkouts"},"recovery_rate":{"type":"number","title":"Recovery Rate"},"total_emails_sent":{"type":"integer","title":"Total Emails Sent"},"total_emails_failed":{"type":"integer","title":"Total Emails Failed"},"emails_by_type":{"items":{"$ref":"#/components/schemas/EmailTypeStat"},"type":"array","title":"Emails By Type"},"total_users":{"type":"integer","title":"Total Users"},"users_with_envs":{"type":"integer","title":"Users With Envs"},"activation_rate":{"type":"number","title":"Activation Rate"},"checkouts_last_7d":{"type":"integer","title":"Checkouts Last 7D"},"recoveries_last_7d":{"type":"integer","title":"Recoveries Last 7D"},"signups_last_7d":{"type":"integer","title":"Signups Last 7D"},"emails_sent_last_7d":{"type":"integer","title":"Emails Sent Last 7D"}},"type":"object","required":["total_checkouts","pending_checkouts","completed_checkouts","expired_checkouts","recovered_checkouts","recovery_rate","total_emails_sent","total_emails_failed","emails_by_type","total_users","users_with_envs","activation_rate","checkouts_last_7d","recoveries_last_7d","signups_last_7d","emails_sent_last_7d"],"title":"LifecycleStatsResponse","description":"Email lifecycle and checkout recovery KPI stats."},"ListBucketsRequest":{"properties":{"provider":{"$ref":"#/components/schemas/StorageProviderType","description":"Storage provider type"},"access_key":{"type":"string","title":"Access Key","description":"Access key / API key"},"secret_key":{"type":"string","title":"Secret Key","description":"Secret key"},"endpoint_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Url","description":"Custom endpoint URL (required for S3-compatible services like Hetzner)"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region","description":"Region hint (used for S3-compatible services)"},"account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Id","description":"Account ID (required for Cloudflare R2)"}},"type":"object","required":["provider","access_key","secret_key"],"title":"ListBucketsRequest","description":"Request to list buckets with given credentials.","example":{}},"ListBucketsResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether listing succeeded"},"message":{"type":"string","title":"Message","description":"Status message or error details","default":""},"buckets":{"items":{"$ref":"#/components/schemas/BucketInfoResponse"},"type":"array","title":"Buckets","description":"List of accessible buckets"}},"type":"object","required":["success"],"title":"ListBucketsResponse","description":"Response containing list of accessible buckets.","example":{}},"ListRegistrationTokensResponse":{"properties":{"tokens":{"items":{"$ref":"#/components/schemas/RegistrationTokenSummary"},"type":"array","title":"Tokens"}},"type":"object","required":["tokens"],"title":"ListRegistrationTokensResponse","description":"Response listing all registration tokens for an organization."},"LogLevel":{"type":"string","enum":["debug","info","warn","error"],"title":"LogLevel","description":"Log level for deployment logs."},"LoginEmailChangeConfirmRequest":{"properties":{"token":{"type":"string","maxLength":128,"title":"Token"},"current_password":{"type":"string","title":"Current Password"},"totp_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Totp Code"}},"type":"object","required":["token","current_password"],"title":"LoginEmailChangeConfirmRequest","description":"Confirm a support-run login email change (#1175)."},"LoginEmailChangePreviewRequest":{"properties":{"token":{"type":"string","maxLength":128,"title":"Token"}},"type":"object","required":["token"],"title":"LoginEmailChangePreviewRequest","description":"Look at a pending support-run login email change (#1175)."},"MFADisableRequest":{"properties":{"password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Password","description":"User password for verification (optional)"}},"type":"object","title":"MFADisableRequest","description":"Request model for disabling MFA.","example":{"password":"mySecurePassword123"}},"MFADisableResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether MFA was disabled successfully"},"message":{"type":"string","title":"Message","description":"Success/error message"}},"type":"object","required":["success","message"],"title":"MFADisableResponse","description":"Response model for disabling MFA.","example":{"message":"MFA disabled successfully","success":true}},"MFAEnableRequest":{"properties":{"totp_code":{"type":"string","maxLength":6,"minLength":6,"title":"Totp Code","description":"6-digit TOTP code"}},"type":"object","required":["totp_code"],"title":"MFAEnableRequest","description":"Request model for enabling MFA.","example":{"totp_code":"123456"}},"MFAEnableResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether MFA was enabled successfully"},"message":{"type":"string","title":"Message","description":"Success/error message"},"backup_codes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Backup Codes","description":"Backup codes for recovery (save these securely!)"}},"type":"object","required":["success","message"],"title":"MFAEnableResponse","description":"Response model for enabling MFA.","example":{"backup_codes":["a1b2c3d4e5f6g7h8","i9j0k1l2m3n4o5p6","q7r8s9t0u1v2w3x4"],"message":"MFA enabled successfully","success":true}},"MFASetupResponse":{"properties":{"secret":{"type":"string","title":"Secret","description":"TOTP secret key (base32)"},"qr_code_uri":{"type":"string","title":"Qr Code Uri","description":"TOTP provisioning URI for QR code"},"backup_codes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Backup Codes","description":"Backup codes (only provided after verification)"}},"type":"object","required":["secret","qr_code_uri"],"title":"MFASetupResponse","description":"Response model for MFA setup.","example":{"qr_code_uri":"otpauth://totp/OEC.sh:user@example.com?secret=JBSWY3DPEHPK3PXP&issuer=OEC.sh","secret":"JBSWY3DPEHPK3PXP"}},"MFAStatusResponse":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Whether MFA is enabled"},"backup_codes_remaining":{"type":"integer","title":"Backup Codes Remaining","description":"Number of unused backup codes remaining"}},"type":"object","required":["enabled","backup_codes_remaining"],"title":"MFAStatusResponse","description":"Response model for MFA status.","example":{"backup_codes_remaining":8,"enabled":true}},"MFAVerifyRequest":{"properties":{"code":{"type":"string","minLength":6,"title":"Code","description":"TOTP code or backup code"}},"type":"object","required":["code"],"title":"MFAVerifyRequest","description":"Request model for verifying MFA code.","example":{"code":"123456"}},"MFAVerifyResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether code was verified successfully"},"message":{"type":"string","title":"Message","description":"Success/error message"}},"type":"object","required":["success","message"],"title":"MFAVerifyResponse","description":"Response model for verifying MFA code.","example":{"message":"MFA verification successful","success":true}},"MailtestAbortRotationResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true}},"type":"object","title":"MailtestAbortRotationResponse","description":"Response for POST /environments/{env_id}/mailtest/abort-rotation.","example":{}},"MailtestBulkDeleteRequest":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","maxItems":500,"minItems":1,"title":"Ids"}},"type":"object","required":["ids"],"title":"MailtestBulkDeleteRequest","description":"POST /messages/bulk-delete body.","example":{}},"MailtestBulkMarkReadRequest":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","maxItems":500,"minItems":1,"title":"Ids"},"read":{"type":"boolean","title":"Read","description":"True = mark all read, False = unread"}},"type":"object","required":["ids","read"],"title":"MailtestBulkMarkReadRequest","description":"POST /messages/bulk-mark body.","example":{}},"MailtestClearResponse":{"properties":{"deleted_count":{"type":"integer","title":"Deleted Count","description":"Number of captured messages soft-deleted"}},"type":"object","required":["deleted_count"],"title":"MailtestClearResponse","description":"Response for POST /environments/{env_id}/mailtest/clear.","example":{}},"MailtestDisableResponse":{"properties":{"success":{"type":"boolean","title":"Success","default":true},"captured_count":{"type":"integer","title":"Captured Count","description":"Captured messages kept until the retention purge deletes them","default":0},"retained_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Retained Until","description":"When the retention purge deletes the newest kept message (null if none)"}},"type":"object","title":"MailtestDisableResponse","description":"Response for POST /environments/{env_id}/mailtest/disable.","example":{}},"MailtestEnableResponse":{"properties":{"credential":{"$ref":"#/components/schemas/MailtestEnvCredentialResponse","description":"Persisted credential state (no plaintext)"},"smtp_config":{"$ref":"#/components/schemas/MailtestSmtpConfig","description":"One-time SMTP connection details. Plaintext is returned only here."}},"type":"object","required":["credential","smtp_config"],"title":"MailtestEnableResponse","description":"Response for POST /environments/{env_id}/mailtest/enable.","example":{}},"MailtestEnvCredentialResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment the credential is scoped to"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Owning organization"},"username":{"type":"string","title":"Username","description":"SMTP AUTH username ('org-XXXXXX-env-YYYYYY')"},"odoo_mail_server_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Odoo Mail Server Id","description":"id of the ir.mail_server row we created in the customer's Odoo DB"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version","description":"Detected Odoo major version (e.g. '18.0')"},"enable_strategy":{"type":"string","title":"Enable Strategy","description":"'C' (Odoo 16+) or 'D' (Odoo 13-15). See spec §9.","default":"C"},"is_active":{"type":"boolean","title":"Is Active","description":"False after the Disable flow runs"},"is_rotating":{"type":"boolean","title":"Is Rotating","description":"True during the §9 rotation saga; SMTP AUTH rejects 451"},"rotation_started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Rotation Started At"},"tamper_detected_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Tamper Detected At","description":"Set when AUTH-time tamper check found drift (alert-only)"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"}},"type":"object","required":["environment_id","organization_id","username","is_active","is_rotating","created_at","id"],"title":"MailtestEnvCredentialResponse","description":"Credential record as returned from list / get endpoints.\n\nNever includes the plaintext password - use ``MailtestEnvCredentialCreated``\nfor the one-time reveal on creation / rotation.","example":{}},"MailtestEnvStatusResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment the credential is scoped to"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Owning organization"},"username":{"type":"string","title":"Username","description":"SMTP AUTH username ('org-XXXXXX-env-YYYYYY')"},"odoo_mail_server_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Odoo Mail Server Id","description":"id of the ir.mail_server row we created in the customer's Odoo DB"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version","description":"Detected Odoo major version (e.g. '18.0')"},"enable_strategy":{"type":"string","title":"Enable Strategy","description":"'C' (Odoo 16+) or 'D' (Odoo 13-15). See spec §9.","default":"C"},"is_active":{"type":"boolean","title":"Is Active","description":"False after the Disable flow runs"},"is_rotating":{"type":"boolean","title":"Is Rotating","description":"True during the §9 rotation saga; SMTP AUTH rejects 451"},"rotation_started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Rotation Started At"},"tamper_detected_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Tamper Detected At","description":"Set when AUTH-time tamper check found drift (alert-only)"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"capture_count_today":{"type":"integer","title":"Capture Count Today","description":"Count of non-deleted messages captured for this env in the trailing 24h","default":0},"storage_used_bytes":{"type":"integer","title":"Storage Used Bytes","description":"Sum of size_bytes across non-deleted messages for this env","default":0}},"type":"object","required":["environment_id","organization_id","username","is_active","is_rotating","created_at","id"],"title":"MailtestEnvStatusResponse","description":"Extended per-env credential view returned by the Day 6 status endpoint.\n\nAdds denormalized counters (capture_count_today, storage_used_bytes)\ncomputed at request time from ``mailtest_captured_emails``. These are\nNOT part of the stored credential row; they exist for the UI header\nper spec §11.","example":{}},"MailtestMessageAttachmentMetadata":{"properties":{"part_index":{"type":"integer","title":"Part Index","description":"0-based index into the MIME walk — feeds the download URL"},"filename":{"type":"string","title":"Filename"},"content_type":{"type":"string","title":"Content Type"},"size":{"type":"integer","title":"Size"}},"type":"object","required":["part_index","filename","content_type","size"],"title":"MailtestMessageAttachmentMetadata","description":"Attachment row returned inside a message detail response.","example":{}},"MailtestMessageDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"received_at":{"type":"string","format":"date-time","title":"Received At"},"headers":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Headers","description":"Parsed header dict (preserved case, duplicates collapsed to list)"},"from_address":{"type":"string","title":"From Address"},"to_addresses":{"items":{"type":"string"},"type":"array","title":"To Addresses"},"cc_addresses":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Cc Addresses"},"bcc_addresses":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Bcc Addresses"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"message_id_header":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message Id Header","description":"RFC 5322 Message-ID header; mapped from the captured row's message_id column"},"size_bytes":{"type":"integer","title":"Size Bytes"},"html_rendered":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Html Rendered","description":"Sanitized HTML with nonce applied — safe to embed in a sandboxed iframe"},"html_nonce":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Html Nonce","description":"Per-render CSP nonce; caller MUST put it in `style-src 'nonce-<value>'`"},"plain_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plain Text"},"attachments_metadata":{"items":{"$ref":"#/components/schemas/MailtestMessageAttachmentMetadata"},"type":"array","title":"Attachments Metadata"},"raw_eml_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Raw Eml Url","description":"Same-origin GET URL streaming the .eml with Content-Disposition: attachment"},"html_check_result":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Html Check Result"},"spam_score":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Spam Score"},"spam_report":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Spam Report"},"body_missing":{"type":"boolean","title":"Body Missing","default":false},"auth_report":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Auth Report"},"deliverability_score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Deliverability Score"},"deliverability_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deliverability Checked At"},"is_read":{"type":"boolean","title":"Is Read","default":false},"read_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Read At"},"read_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Read By"}},"type":"object","required":["id","environment_id","organization_id","received_at","from_address","size_bytes"],"title":"MailtestMessageDetailResponse","description":"Full single-message detail view (spec §11 detail pane).\n\nLoads the .eml from R2 on-demand, runs ``html_sanitizer.sanitize_html``\nwith a fresh per-response nonce, and extracts attachments metadata.\nWhen ``body_missing`` is True (R2 fetch failed or the body was\nalready purged), the body-derived fields are ``None``.","example":{}},"MailtestMessageListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MailtestMessageSummary"},"type":"array","title":"Items"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor","description":"Opaque cursor — pass back on the next request. Null means the list end."},"total_estimate":{"type":"integer","title":"Total Estimate","description":"Approximate total; computed on the first page only for UI sizing","default":0}},"type":"object","title":"MailtestMessageListResponse","description":"Cursor-paginated inbox response.","example":{}},"MailtestMessageReadRequest":{"properties":{"read":{"type":"boolean","title":"Read","description":"True = mark read, False = mark unread"}},"type":"object","required":["read"],"title":"MailtestMessageReadRequest","description":"PATCH /messages/{id}/read body.","example":{}},"MailtestMessageSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"environment_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Name","description":"Populated only by the org-level aggregate list endpoint"},"received_at":{"type":"string","format":"date-time","title":"Received At"},"from_address":{"type":"string","title":"From Address"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject","description":"Truncated to 200 chars for list performance"},"size_bytes":{"type":"integer","title":"Size Bytes"},"attachment_count":{"type":"integer","title":"Attachment Count","default":0},"is_deleted":{"type":"boolean","title":"Is Deleted","default":false},"is_read":{"type":"boolean","title":"Is Read","default":false},"analysis_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Analysis Completed At"},"deliverability_score":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Deliverability Score"}},"type":"object","required":["id","environment_id","received_at","from_address","size_bytes"],"title":"MailtestMessageSummary","description":"Row shape used by the inbox list endpoints (env + org).\n\nOrg-level list adds ``environment_id`` and ``environment_name`` so the\nfrontend can show a per-row badge without a second lookup.","example":{}},"MailtestOrgStateResponse":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"total_message_count":{"type":"integer","title":"Total Message Count"},"total_bytes":{"type":"integer","title":"Total Bytes"},"last_purge_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Purge At"},"grace_deadline":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Grace Deadline","description":"Non-null during plan-downgrade grace period (spec §10)"},"grace_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Grace Reason"},"message_cap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Message Cap","description":"Max messages for this org's current plan"},"bytes_cap":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Bytes Cap","description":"Max bytes for this org's current plan"}},"type":"object","required":["organization_id","total_message_count","total_bytes"],"title":"MailtestOrgStateResponse","description":"Per-org counters + grace-period status used by the quota banner.","example":{}},"MailtestRotationResponse":{"properties":{"password_plaintext":{"type":"string","title":"Password Plaintext","description":"New SMTP AUTH password — returned ONCE. Customer must update Odoo ir.mail_server."},"rotated_at":{"type":"string","format":"date-time","title":"Rotated At","description":"Server-side rotation completion timestamp"}},"type":"object","required":["password_plaintext","rotated_at"],"title":"MailtestRotationResponse","description":"Response for POST /environments/{env_id}/mailtest/rotate-credential.","example":{}},"MailtestSmtpConfig":{"properties":{"host":{"type":"string","title":"Host","description":"SMTP hostname (mail-smtp.oec.sh)"},"port":{"type":"integer","title":"Port","description":"SMTP submission port (587, STARTTLS)"},"username":{"type":"string","title":"Username","description":"Per-env SMTP AUTH username"},"password_plaintext":{"type":"string","title":"Password Plaintext","description":"SMTP AUTH password — shown ONCE, never persisted in plaintext"}},"type":"object","required":["host","port","username","password_plaintext"],"title":"MailtestSmtpConfig","description":"SMTP configuration returned once from the Enable endpoint.\n\nHost/port/username are safe to show repeatedly; ``password_plaintext``\nis the ONLY copy of the password and is memory-zeroed server-side\nafter the response is serialized.","example":{}},"ManualCleanupRequest":{"properties":{"cleanup_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/CleanupType"},"type":"array"},{"type":"null"}],"title":"Cleanup Types","description":"Types of cleanup to perform (uses policy defaults if not specified)"},"dry_run":{"type":"boolean","title":"Dry Run","description":"Preview mode - show what would be cleaned without deleting","default":false},"container_age_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Container Age Days","description":"Override container age threshold (uses policy default if not specified)"},"image_age_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Image Age Days","description":"Override image age threshold (uses policy default if not specified)"},"preserve_tagged_images":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Preserve Tagged Images","description":"Override preserve tagged images setting (uses policy default if not specified)"}},"type":"object","title":"ManualCleanupRequest","description":"Request schema for manual cleanup operation.\n\nUsed when triggering cleanup manually via API instead of scheduled.","example":{}},"MetricsSummary":{"properties":{"cpu_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Cpu Percent","description":"CPU usage percentage"},"memory_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Memory Percent","description":"Memory usage percentage"},"memory_used_bytes":{"type":"integer","minimum":0.0,"title":"Memory Used Bytes","description":"Memory used in bytes"},"memory_total_bytes":{"type":"integer","minimum":0.0,"title":"Memory Total Bytes","description":"Total memory in bytes"},"disk_percent":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Disk Percent","description":"Disk usage percentage"},"disk_used_bytes":{"type":"integer","minimum":0.0,"title":"Disk Used Bytes","description":"Disk used in bytes"},"disk_total_bytes":{"type":"integer","minimum":0.0,"title":"Disk Total Bytes","description":"Total disk in bytes"},"network_rx_rate":{"type":"number","minimum":0.0,"title":"Network Rx Rate","description":"Network receive rate (bytes/sec)"},"network_tx_rate":{"type":"number","minimum":0.0,"title":"Network Tx Rate","description":"Network transmit rate (bytes/sec)"},"container_count":{"type":"integer","minimum":0.0,"title":"Container Count","description":"Total container count"},"containers_healthy":{"type":"integer","minimum":0.0,"title":"Containers Healthy","description":"Healthy container count"},"containers_unhealthy":{"type":"integer","minimum":0.0,"title":"Containers Unhealthy","description":"Unhealthy container count"},"status":{"type":"string","title":"Status","description":"Overall status: healthy, warning, critical"},"queried_at":{"type":"string","format":"date-time","title":"Queried At","description":"When metrics were queried"}},"type":"object","required":["cpu_percent","memory_percent","memory_used_bytes","memory_total_bytes","disk_percent","disk_used_bytes","disk_total_bytes","network_rx_rate","network_tx_rate","container_count","containers_healthy","containers_unhealthy","status","queried_at"],"title":"MetricsSummary","description":"Level 1: Quick summary for cards/badges.\n\nThis is the minimum data needed for server list views.","example":{}},"MetricsTimeSeries":{"properties":{"metric_name":{"type":"string","title":"Metric Name","description":"Name of metric"},"points":{"items":{"$ref":"#/components/schemas/TimeSeriesPoint"},"type":"array","title":"Points","description":"Time series points"},"unit":{"type":"string","title":"Unit","description":"Unit: %, bytes, bytes/sec"}},"type":"object","required":["metric_name","points","unit"],"title":"MetricsTimeSeries","description":"Level 2: Time-series data for charts.","example":{}},"MigrationAnalysisResult":{"properties":{"migration_id":{"type":"string","format":"uuid","title":"Migration Id","description":"Migration ID"},"odoo_version":{"type":"string","title":"Odoo Version","description":"Detected Odoo version"},"database_name":{"type":"string","title":"Database Name","description":"Database name from backup"},"database_size_bytes":{"type":"integer","title":"Database Size Bytes","description":"Database size in bytes"},"filestore_size_bytes":{"type":"integer","title":"Filestore Size Bytes","description":"Filestore size in bytes"},"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total backup size in bytes"},"total_modules":{"type":"integer","title":"Total Modules","description":"Total modules detected"},"odoo_modules":{"items":{"type":"string"},"type":"array","title":"Odoo Modules","description":"Standard Odoo modules","default":[]},"oca_modules":{"items":{"type":"string"},"type":"array","title":"Oca Modules","description":"OCA community modules","default":[]},"custom_modules":{"items":{"type":"string"},"type":"array","title":"Custom Modules","description":"Custom/third-party modules","default":[]},"partner_count":{"type":"integer","title":"Partner Count","description":"Number of partners/contacts","default":0},"user_count":{"type":"integer","title":"User Count","description":"Number of users","default":0},"invoice_count":{"type":"integer","title":"Invoice Count","description":"Number of invoices","default":0},"product_count":{"type":"integer","title":"Product Count","description":"Number of products","default":0},"recommended_cpu":{"type":"number","title":"Recommended Cpu","description":"Recommended CPU cores"},"recommended_ram_mb":{"type":"integer","title":"Recommended Ram Mb","description":"Recommended RAM in MB"},"recommended_disk_gb":{"type":"integer","title":"Recommended Disk Gb","description":"Recommended disk space in GB"},"estimated_monthly_cost":{"type":"number","title":"Estimated Monthly Cost","description":"Estimated monthly cost on oec.sh"},"odoosh_equivalent_cost":{"type":"number","title":"Odoosh Equivalent Cost","description":"Equivalent cost on Odoo.sh"},"monthly_savings":{"type":"number","title":"Monthly Savings","description":"Monthly savings vs Odoo.sh"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Analysis warnings","default":[]},"recommendations":{"items":{"type":"string"},"type":"array","title":"Recommendations","description":"Migration recommendations","default":[]}},"type":"object","required":["migration_id","odoo_version","database_name","database_size_bytes","filestore_size_bytes","total_size_bytes","total_modules","recommended_cpu","recommended_ram_mb","recommended_disk_gb","estimated_monthly_cost","odoosh_equivalent_cost","monthly_savings"],"title":"MigrationAnalysisResult","description":"Result of migration backup analysis.","example":{}},"MigrationConfigureRequest":{"properties":{"target_vm_id":{"type":"string","format":"uuid","title":"Target Vm Id","description":"Target server/VM for deployment"},"project_name":{"type":"string","maxLength":255,"minLength":1,"title":"Project Name","description":"Name for the new project"},"target_domain":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Target Domain","description":"Custom domain for the environment (optional)"},"git_repo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Git Repo Url","description":"Git repository URL (override from analysis)"},"git_branch":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Git Branch","description":"Git branch (override from analysis)"},"neutralize":{"type":"boolean","title":"Neutralize","description":"Run Odoo's native neutralize after migration to disable emails, crons, payments, etc. (recommended for migrations)","default":true},"odoo_version":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Odoo Version","description":"Source Odoo version, required when analysis could not detect it (e.g. a backup with no manifest). Verified against the loaded database at restore."}},"type":"object","required":["target_vm_id","project_name"],"title":"MigrationConfigureRequest","description":"Schema for configuring migration target.","example":{}},"MigrationInitRequest":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID for the migration"},"source_type":{"$ref":"#/components/schemas/MigrationSourceType","description":"Source platform for the migration","default":"odoosh"},"file_name":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"File Name","description":"Original backup file name"},"file_size":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"File Size","description":"File size in bytes (required for file upload)"},"cloud_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Cloud Url","description":"Cloud URL for import (Google Drive, Dropbox, etc.)"},"project_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Project Name","description":"Target project name in oec.sh"},"odoosh_project_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Odoosh Project Name","description":"Original Odoo.sh project name"},"odoosh_branch":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Odoosh Branch","description":"Original Odoo.sh branch name"},"git_repo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Git Repo Url","description":"Git repository URL for custom modules"},"git_branch":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Git Branch","description":"Git branch to use"},"data_processing_consent":{"type":"boolean","title":"Data Processing Consent","description":"User consent for temporary data storage and processing on our cloud infrastructure","default":false}},"type":"object","required":["organization_id"],"title":"MigrationInitRequest","description":"Schema for initiating a new migration.","example":{}},"MigrationListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MigrationSummary"},"type":"array","title":"Items","description":"List of items"},"total":{"type":"integer","title":"Total","description":"Total number of items"},"page":{"type":"integer","minimum":1.0,"title":"Page","description":"Current page number","default":1},"page_size":{"type":"integer","maximum":100.0,"minimum":1.0,"title":"Page Size","description":"Items per page","default":20},"pages":{"type":"integer","title":"Pages","description":"Total number of pages"}},"type":"object","required":["items","total","pages"],"title":"MigrationListResponse","description":"Paginated list of migrations.","example":{}},"MigrationProgressUpdate":{"properties":{"migration_id":{"type":"string","format":"uuid","title":"Migration Id","description":"Migration ID"},"status":{"$ref":"#/components/schemas/MigrationStatusType","description":"Current status"},"progress_percent":{"type":"integer","title":"Progress Percent","description":"Progress percentage"},"current_step":{"type":"string","title":"Current Step","description":"Current step description"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"Update timestamp"}},"type":"object","required":["migration_id","status","progress_percent","current_step"],"title":"MigrationProgressUpdate","description":"Real-time progress update for SSE.","example":{}},"MigrationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Migration ID"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"source_type":{"$ref":"#/components/schemas/MigrationSourceType","description":"Source platform"},"odoosh_project_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoosh Project Name","description":"Odoo.sh project name"},"odoosh_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoosh Branch","description":"Odoo.sh branch"},"git_repo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Repo Url","description":"Git repository URL"},"git_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Branch","description":"Git branch"},"status":{"$ref":"#/components/schemas/MigrationStatusType","description":"Current status"},"progress_percent":{"type":"integer","title":"Progress Percent","description":"Progress percentage"},"current_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Step","description":"Current step"},"upload_tier":{"anyOf":[{"$ref":"#/components/schemas/UploadTierType"},{"type":"null"}],"description":"Upload tier used"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name","description":"Backup file name"},"file_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"File Size","description":"File size in bytes"},"cloud_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cloud Url","description":"Cloud URL if imported"},"storage_config_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Config Id","description":"Organization storage config ID (if using org storage)"},"storage_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Storage Key","description":"Storage key in organization's bucket"},"odoo_version_detected":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version Detected","description":"Detected Odoo version"},"analysis_partial":{"type":"boolean","title":"Analysis Partial","description":"Analysis completed but could not detect the Odoo version or modules (this backup format does not record them); the version must be chosen at the configure step.","default":false},"pg_version_detected":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pg Version Detected","description":"PostgreSQL version from backup"},"database_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Database Name","description":"Database name"},"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name","description":"Company name from backup"},"web_base_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Web Base Url","description":"web.base.url from backup"},"database_size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Database Size Bytes","description":"Database size"},"filestore_size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filestore Size Bytes","description":"Filestore size"},"modules_detected":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Modules Detected","description":"All detected modules"},"modules_with_versions":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},{"type":"null"}],"title":"Modules With Versions","description":"Modules with their versions"},"custom_modules":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Custom Modules","description":"Custom modules"},"partner_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Partner Count","description":"Partner count"},"user_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"User Count","description":"User count"},"recommended_cpu":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Recommended Cpu","description":"Recommended CPU"},"recommended_ram_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recommended Ram Mb","description":"Recommended RAM MB"},"target_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Target Vm Id","description":"Target VM ID"},"project_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Name","description":"Project name"},"target_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Domain","description":"Target domain"},"neutralize":{"type":"boolean","title":"Neutralize","description":"Neutralize database after migration","default":true},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id","description":"Created project ID"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id","description":"Created environment ID"},"upload_started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Upload Started At","description":"Upload start"},"upload_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Upload Completed At","description":"Upload complete"},"analysis_started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Analysis Started At","description":"Analysis start"},"analysis_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Analysis Completed At","description":"Analysis complete"},"processing_started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Processing Started At","description":"Processing start"},"processing_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Processing Completed At","description":"Processing complete"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if failed"},"error_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Step","description":"Step where error occurred"},"retry_count":{"type":"integer","title":"Retry Count","description":"Number of retries","default":0},"restore_warnings":{"items":{"type":"string"},"type":"array","title":"Restore Warnings","description":"Problems found after the restore, e.g. an empty filestore"},"estimated_monthly_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Monthly Cost","description":"Estimated monthly cost"},"odoosh_equivalent_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Odoosh Equivalent Cost","description":"Equivalent Odoo.sh cost"},"monthly_savings":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Monthly Savings","description":"Monthly savings"},"created_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Id","description":"Created by user ID"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["id","organization_id","source_type","status","progress_percent","created_at","updated_at"],"title":"MigrationResponse","description":"Full migration details response.","example":{}},"MigrationSourceType":{"type":"string","enum":["odoosh","on_premise","odoo_online","cloud_url","other_paas"],"title":"MigrationSourceType","description":"Source platform for the migration."},"MigrationStatus":{"type":"string","enum":["pending","uploading","uploaded","analyzing","analyzed","configuring","processing","creating_project","creating_environment","deploying_containers","downloading_backup","extracting_backup","restoring_database","restoring_filestore","cloning_repo","configuring_traefik","restarting_odoo","verifying","completed","failed","cancelled"],"title":"MigrationStatus","description":"Status of the migration process."},"MigrationStatusType":{"type":"string","enum":["pending","uploading","uploaded","analyzing","analyzed","configuring","processing","creating_project","creating_environment","deploying_containers","downloading_backup","extracting_backup","restoring_database","restoring_filestore","cloning_repo","configuring_traefik","restarting_odoo","verifying","completed","failed","cancelled"],"title":"MigrationStatusType","description":"Status of the migration process."},"MigrationSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Migration ID"},"source_type":{"$ref":"#/components/schemas/MigrationSourceType","description":"Source platform"},"status":{"$ref":"#/components/schemas/MigrationStatusType","description":"Current status"},"progress_percent":{"type":"integer","title":"Progress Percent","description":"Progress percentage"},"current_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Step","description":"Current step description"},"file_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Name","description":"Backup file name"},"file_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"File Size","description":"File size in bytes"},"odoo_version_detected":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version Detected","description":"Detected Odoo version"},"project_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Name","description":"Target project name"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"}},"type":"object","required":["id","source_type","status","progress_percent","created_at"],"title":"MigrationSummary","description":"Brief migration summary for list views.","example":{}},"ModuleDeploymentListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ModuleDeploymentResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ModuleDeploymentListResponse","description":"Schema for list of deployment statuses.","example":{}},"ModuleDeploymentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"repository_id":{"type":"string","format":"uuid","title":"Repository Id"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"branch":{"type":"string","title":"Branch"},"last_deployed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Deployed At"},"last_commit_sha":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Commit Sha"},"last_commit_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Commit Message"},"detected_modules":{"type":"integer","title":"Detected Modules","default":0},"module_list":{"items":{"type":"string"},"type":"array","title":"Module List","default":[]},"status":{"type":"string","title":"Status","default":"pending"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","repository_id","environment_id","branch"],"title":"ModuleDeploymentResponse","description":"Schema for per-environment deployment status.","example":{}},"ModuleRepositoryCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name","description":"Display name for the repository","examples":["OpenEduCat ERP","Custom Addons"]},"git_url":{"type":"string","maxLength":512,"minLength":1,"title":"Git Url","description":"Git repository URL (https://)","examples":["https://github.com/openeducat/openeducat_erp"]},"default_branch":{"type":"string","maxLength":100,"title":"Default Branch","description":"Default branch to deploy from","default":"main","examples":["main","17.0","master"]},"branch_mapping":{"additionalProperties":{"type":"string"},"type":"object","title":"Branch Mapping","description":"Branch mapping by environment type","examples":[{"production":"main","staging":"develop"}]},"git_provider":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Git Provider","description":"Git provider (auto-detected if not specified)","examples":["github","gitlab","bitbucket"]},"deploy_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Deploy Path","description":"Subfolder in repo containing modules (if not root)","examples":["addons","modules/community"]},"auto_deploy":{"type":"boolean","title":"Auto Deploy","description":"Auto-deploy on webhook push events","default":false},"priority":{"type":"integer","maximum":1000.0,"minimum":1.0,"title":"Priority","description":"Installation priority (lower = first)","default":100}},"type":"object","required":["name","git_url"],"title":"ModuleRepositoryCreate","description":"Schema for creating a new module repository at project level.","example":{}},"ModuleRepositoryListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ModuleRepositoryResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["items","total"],"title":"ModuleRepositoryListResponse","description":"Schema for list of module repositories response.","example":{}},"ModuleRepositoryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"name":{"type":"string","title":"Name"},"git_url":{"type":"string","title":"Git Url"},"default_branch":{"type":"string","title":"Default Branch"},"branch_mapping":{"additionalProperties":{"type":"string"},"type":"object","title":"Branch Mapping","default":{}},"git_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Provider"},"deploy_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deploy Path"},"auto_deploy":{"type":"boolean","title":"Auto Deploy"},"priority":{"type":"integer","title":"Priority"},"status":{"$ref":"#/components/schemas/ModuleRepositoryStatus"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","project_id","name","git_url","default_branch","auto_deploy","priority","status"],"title":"ModuleRepositoryResponse","description":"Schema for module repository response (project level).","example":{}},"ModuleRepositoryStatus":{"type":"string","enum":["active","disabled","error"],"title":"ModuleRepositoryStatus","description":"Status states for module repositories."},"ModuleRepositoryUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name","description":"Display name for the repository"},"default_branch":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Default Branch","description":"Default branch to deploy from"},"branch_mapping":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Branch Mapping","description":"Branch mapping by environment type"},"deploy_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Deploy Path","description":"Subfolder in repo containing modules"},"auto_deploy":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Deploy","description":"Auto-deploy on webhook push events"},"priority":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Priority","description":"Installation priority (lower = first)"},"status":{"anyOf":[{"$ref":"#/components/schemas/ModuleRepositoryStatus"},{"type":"null"}],"description":"Repository status"}},"type":"object","title":"ModuleRepositoryUpdate","description":"Schema for updating a module repository.","example":{}},"MonitoringDashboardResponse":{"properties":{"servers":{"items":{"$ref":"#/components/schemas/ServerHealthSummary"},"type":"array","title":"Servers","description":"Server health summaries"},"aggregate":{"$ref":"#/components/schemas/AggregateMetrics","description":"Aggregate metrics"},"queried_at":{"type":"string","format":"date-time","title":"Queried At","description":"When dashboard was queried"}},"type":"object","required":["servers","aggregate","queried_at"],"title":"MonitoringDashboardResponse","description":"Response for the monitoring dashboard.","example":{}},"MonitoringUrlResponse":{"properties":{"url":{"type":"string","title":"Url","description":"Dashboard URL"},"expires_in":{"type":"integer","minimum":0.0,"title":"Expires In","description":"URL expiration in seconds"},"embed_allowed":{"type":"boolean","title":"Embed Allowed","description":"Whether embedding is allowed","default":true}},"type":"object","required":["url","expires_in"],"title":"MonitoringUrlResponse","description":"Level 3: URL to full Netdata dashboard.","example":{}},"MultipartCompleteRequest":{"properties":{"parts":{"items":{"type":"object"},"type":"array","title":"Parts","description":"List of {part_number, etag} for each uploaded part"}},"type":"object","required":["parts"],"title":"MultipartCompleteRequest","description":"Request to complete multipart upload.","example":{}},"MultipartPartInfo":{"properties":{"part_number":{"type":"integer","title":"Part Number","description":"Part number (1-indexed)"},"upload_url":{"type":"string","title":"Upload Url","description":"Presigned PUT URL for this part"}},"type":"object","required":["part_number","upload_url"],"title":"MultipartPartInfo","description":"Presigned URL for one part of a multipart upload.","example":{}},"NeutralizeResultSchema":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether neutralization succeeded overall"},"steps":{"items":{"$ref":"#/components/schemas/NeutralizeStepResultSchema"},"type":"array","title":"Steps","description":"Results of each neutralization step"},"error":{"type":"string","title":"Error","description":"Overall error message if failed","default":""}},"type":"object","required":["success"],"title":"NeutralizeResultSchema","description":"Result of the complete neutralization process.","example":{}},"NeutralizeStepResultSchema":{"properties":{"step":{"type":"string","title":"Step","description":"Step name (e.g., 'odoo_neutralize', 'update_base_url')"},"success":{"type":"boolean","title":"Success","description":"Whether step succeeded"},"output":{"type":"string","title":"Output","description":"Step output","default":""},"error":{"type":"string","title":"Error","description":"Error message if failed","default":""},"affected_rows":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Affected Rows","description":"Rows affected (for SQL steps)"}},"type":"object","required":["step","success"],"title":"NeutralizeStepResultSchema","description":"Result of a single neutralization step.","example":{}},"NewEnvironmentConfig":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Name for the new environment"},"environment_type":{"$ref":"#/components/schemas/schemas__backup__EnvironmentType","description":"Type of environment to create","default":"development"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id","description":"Server to deploy on (uses same server as source if not specified)"}},"type":"object","required":["name"],"title":"NewEnvironmentConfig","description":"Configuration for creating new environment during restore.","example":{}},"NonCompliantEnvironment":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Environment ID"},"name":{"type":"string","title":"Name","description":"Environment name"},"environment_type":{"type":"string","title":"Environment Type","description":"Environment type"},"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"project_name":{"type":"string","title":"Project Name","description":"Project name"},"last_backup_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Backup At","description":"Last successful backup timestamp"},"days_since_backup":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Days Since Backup","description":"Days since last backup"}},"type":"object","required":["id","name","environment_type","project_id","project_name"],"title":"NonCompliantEnvironment","description":"Details of an environment without recent backup.","example":{}},"NotificationChannel":{"type":"string","enum":["in_app","email","both"],"title":"NotificationChannel","description":"Delivery channels for notifications."},"NotificationListResponse":{"properties":{"notifications":{"items":{"$ref":"#/components/schemas/NotificationResponse"},"type":"array","title":"Notifications"},"total":{"type":"integer","title":"Total"},"unread_count":{"type":"integer","title":"Unread Count"}},"type":"object","required":["notifications","total","unread_count"],"title":"NotificationListResponse","description":"Schema for list of notifications.","example":{}},"NotificationPreferenceResponse":{"properties":{"task_completed":{"type":"string","title":"Task Completed"},"task_failed":{"type":"string","title":"Task Failed"},"env_deployed":{"type":"string","title":"Env Deployed"},"env_error":{"type":"string","title":"Env Error"},"system_updates":{"type":"string","title":"System Updates"},"billing_alerts":{"type":"string","title":"Billing Alerts"},"security_alerts":{"type":"string","title":"Security Alerts"},"monitoring_alerts":{"type":"string","title":"Monitoring Alerts"},"email_digest":{"type":"boolean","title":"Email Digest"}},"type":"object","required":["task_completed","task_failed","env_deployed","env_error","system_updates","billing_alerts","security_alerts","monitoring_alerts","email_digest"],"title":"NotificationPreferenceResponse","description":"Schema for notification preferences response.","example":{}},"NotificationPreferenceUpdate":{"properties":{"task_completed":{"anyOf":[{"$ref":"#/components/schemas/NotificationChannel"},{"type":"null"}]},"task_failed":{"anyOf":[{"$ref":"#/components/schemas/NotificationChannel"},{"type":"null"}]},"env_deployed":{"anyOf":[{"$ref":"#/components/schemas/NotificationChannel"},{"type":"null"}]},"env_error":{"anyOf":[{"$ref":"#/components/schemas/NotificationChannel"},{"type":"null"}]},"system_updates":{"anyOf":[{"$ref":"#/components/schemas/NotificationChannel"},{"type":"null"}]},"billing_alerts":{"anyOf":[{"$ref":"#/components/schemas/NotificationChannel"},{"type":"null"}]},"security_alerts":{"anyOf":[{"$ref":"#/components/schemas/NotificationChannel"},{"type":"null"}]},"monitoring_alerts":{"anyOf":[{"$ref":"#/components/schemas/NotificationChannel"},{"type":"null"}]},"email_digest":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Email Digest"}},"type":"object","title":"NotificationPreferenceUpdate","description":"Schema for updating notification preferences.","example":{}},"NotificationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"notification_type":{"type":"string","title":"Notification Type"},"priority":{"type":"string","title":"Priority"},"title":{"type":"string","title":"Title"},"message":{"type":"string","title":"Message"},"data":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Data"},"is_read":{"type":"boolean","title":"Is Read"},"read_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Read At"},"create_date":{"type":"string","format":"date-time","title":"Create Date"}},"type":"object","required":["id","notification_type","priority","title","message","is_read","create_date"],"title":"NotificationResponse","description":"Schema for notification response.","example":{}},"OAuthAuthorizeRequest":{"properties":{"provider":{"type":"string","enum":["github","gitlab","bitbucket"],"title":"Provider","description":"Git provider"},"level":{"type":"string","enum":["platform","organization"],"title":"Level","description":"Connection level"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization ID (required for organization level)"},"redirect_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Redirect Url","description":"Frontend URL to redirect after callback"},"gitlab_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gitlab Url","description":"GitLab instance URL (for self-hosted)"},"connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connection Id","description":"Existing connection ID for re-authorization (updates tokens instead of creating new)"}},"type":"object","required":["provider","level"],"title":"OAuthAuthorizeRequest","description":"Request to initiate OAuth flow."},"OAuthAuthorizeResponse":{"properties":{"authorize_url":{"type":"string","title":"Authorize Url","description":"URL to redirect user for OAuth"},"state":{"type":"string","title":"State","description":"State parameter for CSRF protection"}},"type":"object","required":["authorize_url","state"],"title":"OAuthAuthorizeResponse","description":"Response with OAuth authorization URL."},"OAuthStatusResponse":{"properties":{"github_enabled":{"type":"boolean","title":"Github Enabled","description":"Whether GitHub OAuth is configured"},"gitlab_enabled":{"type":"boolean","title":"Gitlab Enabled","description":"Whether GitLab OAuth is configured"},"bitbucket_enabled":{"type":"boolean","title":"Bitbucket Enabled","description":"Whether Bitbucket OAuth is configured"}},"type":"object","required":["github_enabled","gitlab_enabled","bitbucket_enabled"],"title":"OAuthStatusResponse","description":"Response with OAuth configuration status."},"OSAutoUpdateRequest":{"properties":{"enabled":{"type":"boolean","title":"Enabled","description":"Enable (true) or disable (false) automatic OS security updates"}},"type":"object","required":["enabled"],"title":"OSAutoUpdateRequest","description":"Schema for toggling automatic OS security updates on a server (task #709).","example":{}},"OSInfo":{"properties":{"distro":{"type":"string","title":"Distro","description":"Distribution name (ubuntu, debian, etc.)"},"version":{"type":"string","title":"Version","description":"Version number"},"codename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Codename","description":"Version codename (jammy, bookworm, etc.)"},"arch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Arch","description":"Architecture (x86_64, aarch64, etc.)"},"is_lts":{"type":"boolean","title":"Is Lts","description":"Whether it's an LTS version","default":false},"support_tier":{"anyOf":[{"type":"integer","maximum":3.0,"minimum":1.0},{"type":"null"}],"title":"Support Tier","description":"Support tier (1=full, 2=partial, 3=unsupported)","default":3},"kernel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kernel","description":"Kernel version"},"os_family":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Os Family","description":"OS family: debian, rhel, alpine, arch, etc."},"os_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Os Name","description":"OS name: ubuntu, centos, rocky, etc."},"init_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Init System","description":"Init system: systemd, openrc, sysvinit"},"package_manager":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Package Manager","description":"Package manager: apt, dnf, yum, pacman, apk"},"os_supported":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Os Supported","description":"Support status: yes, warn, no"}},"type":"object","required":["distro","version"],"title":"OSInfo","description":"Operating system information."},"OdooAdvancedConfig":{"properties":{"server_wide_modules":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Wide Modules","description":"Comma-separated list of always-loaded modules (default: 'base,web')"},"unaccent":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Unaccent","description":"Enable PostgreSQL unaccent extension for better search"},"geoip_database":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Geoip Database","description":"Path to GeoIP database for geolocation"},"csv_internal_sep":{"anyOf":[{"type":"string","maxLength":1},{"type":"null"}],"title":"Csv Internal Sep","description":"CSV internal separator character (default: ',')"},"osv_memory_age_limit":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Osv Memory Age Limit","description":"OSV memory record age limit in hours"},"osv_memory_count_limit":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Osv Memory Count Limit","description":"Maximum number of OSV memory records"},"proxy_mode":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Proxy Mode","description":"Enable proxy mode (required behind reverse proxy like Traefik/Nginx)"}},"type":"object","title":"OdooAdvancedConfig","description":"Advanced configuration settings.","example":{}},"OdooConfig":{"properties":{"preset":{"anyOf":[{"$ref":"#/components/schemas/OdooConfigPreset"},{"type":"null"}],"description":"Apply a predefined configuration preset"},"performance":{"anyOf":[{"$ref":"#/components/schemas/OdooPerformanceConfig"},{"type":"null"}],"description":"Performance and resource limit settings"},"logging":{"anyOf":[{"$ref":"#/components/schemas/OdooLoggingConfig"},{"type":"null"}],"description":"Logging configuration"},"email":{"anyOf":[{"$ref":"#/components/schemas/OdooEmailConfig"},{"type":"null"}],"description":"Email/SMTP settings"},"security":{"anyOf":[{"$ref":"#/components/schemas/OdooSecurityConfig"},{"type":"null"}],"description":"Security settings"},"development":{"anyOf":[{"$ref":"#/components/schemas/OdooDevelopmentConfig"},{"type":"null"}],"description":"Development and testing settings"},"advanced":{"anyOf":[{"$ref":"#/components/schemas/OdooAdvancedConfig"},{"type":"null"}],"description":"Advanced settings"},"custom_params":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Custom Params","description":"Custom key=value parameters to add to odoo.conf"}},"type":"object","title":"OdooConfig","description":"Complete Odoo configuration schema.\n\nThis schema allows customization of odoo.conf parameters.\nParameters set here will override defaults during deployment.","example":{}},"OdooConfigPreset":{"type":"string","enum":["minimal","standard","production","high_performance"],"title":"OdooConfigPreset","description":"Predefined configuration presets."},"OdooDevelopmentConfig":{"properties":{"dev_mode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dev Mode","description":"Development mode options: 'reload', 'qweb', 'werkzeug', 'xml' or combinations"},"test_enable":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Test Enable","description":"Enable test mode"},"test_tags":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Test Tags","description":"Test tags to run (e.g., 'standard', '-at_install')"},"without_demo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Without Demo","description":"Disable demo data loading ('all' or comma-separated modules)"},"demo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Demo","description":"Load demo data for specific modules"}},"type":"object","title":"OdooDevelopmentConfig","description":"Development and testing configuration settings.","example":{}},"OdooEmailConfig":{"properties":{"email_from":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email From","description":"Default 'From' email address"},"smtp_server":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Smtp Server","description":"SMTP server hostname"},"smtp_port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Smtp Port","description":"SMTP server port (default: 25)"},"smtp_ssl":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Smtp Ssl","description":"Use SSL for SMTP connection"},"smtp_user":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Smtp User","description":"SMTP authentication username"},"smtp_password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Smtp Password","description":"SMTP authentication password"}},"type":"object","title":"OdooEmailConfig","description":"Email/SMTP configuration settings.","example":{}},"OdooImageInfo":{"properties":{"version":{"type":"string","title":"Version","description":"Odoo version string (e.g. '18.0')"},"configured_image":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Configured Image","description":"Full configured image reference from the Odoo version (registry/repo:tag)."},"image_digest":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Digest","description":"Configured image digest (sha256:...) if pinned, else None."},"deployed_image_tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployed Image Tag","description":"Image tag from the latest successful deployment, else None."},"source":{"type":"string","enum":["deployed","configured"],"title":"Source","description":"'deployed' when a running image is known, else 'configured'."},"selection":{"type":"string","enum":["environment","project","version","default"],"title":"Selection","description":"Where the build choice comes from: this environment, the project, the Odoo version's stable image, or the platform default.","default":"default"},"frozen":{"type":"boolean","title":"Frozen","description":"The environment is frozen on one build.","default":false},"frozen_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Frozen At","description":"When it was frozen."},"build":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Build","description":"Short id of the build (first 8 hex of the image digest) for support."},"release":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Release","description":"Dated version of the running build, as Odoo tags it (18.0-20260817)."},"selected_release":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Release","description":"Dated version the environment is frozen on, when known."},"pending_change":{"type":"boolean","title":"Pending Change","description":"The frozen build differs from the running one; the next deploy or Update now applies it.","default":false}},"type":"object","required":["version","source"],"title":"OdooImageInfo","description":"Read-only Odoo build/image details for the environment overview.\n\nShows the *deployed* image (what's actually running, from the latest\nsuccessful deployment) and falls back to the *configured* image (from the\nproject's odoo_version_ref) when there's no successful deploy yet.","example":{}},"OdooLoggingConfig":{"properties":{"log_level":{"anyOf":[{"$ref":"#/components/schemas/schemas__project__LogLevel"},{"type":"null"}],"description":"Global logging level"},"log_handler":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Log Handler","description":"Logging handlers (e.g., ':INFO', 'werkzeug:WARNING')"},"log_db":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Log Db","description":"Enable logging to database"},"log_db_level":{"anyOf":[{"$ref":"#/components/schemas/schemas__project__LogLevel"},{"type":"null"}],"description":"Database logging level"},"syslog":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Syslog","description":"Send logs to syslog"}},"type":"object","title":"OdooLoggingConfig","description":"Logging configuration settings.","example":{}},"OdooPerformanceConfig":{"properties":{"workers":{"anyOf":[{"type":"integer","maximum":32.0,"minimum":0.0},{"type":"null"}],"title":"Workers","description":"Number of worker processes (0 = no multi-processing, recommended for dev)"},"max_cron_threads":{"anyOf":[{"type":"integer","maximum":8.0,"minimum":0.0},{"type":"null"}],"title":"Max Cron Threads","description":"Maximum number of cron worker threads"},"limit_memory_hard":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Limit Memory Hard","description":"Hard memory limit per worker in bytes (default: 2684354560 = 2.5GB)"},"limit_memory_soft":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Limit Memory Soft","description":"Soft memory limit per worker in bytes (default: 2147483648 = 2GB)"},"limit_time_cpu":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Limit Time Cpu","description":"Maximum CPU time per request in seconds (default: 900)"},"limit_time_real":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Limit Time Real","description":"Maximum real time per request in seconds (default: 1200)"},"limit_time_real_cron":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Limit Time Real Cron","description":"Maximum real time for cron jobs in seconds (default: 900)"},"limit_request":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Limit Request","description":"Maximum request size in bytes (default: 8192)"},"transient_age_limit":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Transient Age Limit","description":"Time limit for transient records cleanup in hours (default: 1.0)"}},"type":"object","title":"OdooPerformanceConfig","description":"Performance and resource limit settings.","example":{}},"OdooSecurityConfig":{"properties":{"admin_passwd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Admin Passwd","description":"Master/admin password for database management"},"list_db":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"List Db","description":"Allow listing databases on login page"},"dbfilter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dbfilter","description":"Regular expression to filter available databases"}},"type":"object","title":"OdooSecurityConfig","description":"Security configuration settings.","example":{}},"OdooUserInfo":{"properties":{"id":{"type":"integer","title":"Id","description":"Odoo res.users.id"},"login":{"type":"string","title":"Login","description":"User login (unique within the Odoo db)"},"name":{"type":"string","title":"Name","description":"Display name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"is_active":{"type":"boolean","title":"Is Active","description":"active=True in res_users"},"last_login":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Login","description":"UTC"},"is_system":{"type":"boolean","title":"Is System","description":"True for __system__/public/portaltemplate; never selectable","default":false},"is_portal":{"type":"boolean","title":"Is Portal","description":"True when res.users.share = true (external / portal user)","default":false}},"type":"object","required":["id","login","name","is_active"],"title":"OdooUserInfo","description":"One row in the picker — represents an Odoo res.users record."},"OdooVersionCreate":{"properties":{"version":{"type":"string","maxLength":20,"minLength":1,"title":"Version","description":"Odoo version number (e.g., '17.0', '18.0')","examples":["17.0","18.0"]},"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Display name for the version","examples":["Odoo 17.0 LTS","Odoo 18.0"]},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description","description":"Version description, release notes, etc.","examples":["Odoo 17.0 LTS - Long term support until 2026"]},"image_registry":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Image Registry","description":"Registry URL (empty for Docker Hub)","examples":["ghcr.io","registry.gitlab.com"]},"image_repository":{"type":"string","maxLength":255,"title":"Image Repository","description":"Image repository/name","default":"odoo","examples":["odoo","mycompany/odoo-custom"]},"image_tag":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Image Tag","description":"Image tag (uses version number if not specified)","examples":["17.0","latest","17.0-20241101"]},"image_digest":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Image Digest","description":"Image digest for immutable deployments","examples":["sha256:abc123..."]},"registry_auth_required":{"type":"boolean","title":"Registry Auth Required","description":"Whether registry requires authentication","default":false},"registry_auth_username":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Registry Auth Username","description":"Registry username"},"registry_auth_password":{"anyOf":[{"type":"string","maxLength":1024},{"type":"null"}],"title":"Registry Auth Password","description":"Registry password/token (will be encrypted)"},"registry_auth_email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Registry Auth Email","description":"Registry email (if required)"},"default_addons_path":{"type":"string","maxLength":512,"title":"Default Addons Path","description":"Default addons path for this version","default":"/mnt/extra-addons"},"default_data_dir":{"type":"string","maxLength":512,"title":"Default Data Dir","description":"Default data directory for this version","default":"/var/lib/odoo"},"status":{"$ref":"#/components/schemas/OdooVersionStatus","description":"Version status","default":"active"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this is the default version for new projects","default":false},"display_order":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Display Order","description":"Sort order for display (e.g., '0170' for 17.0)"},"is_selectable":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Selectable","description":"Whether this row appears in the user-facing picker (defaults to true; set false to create an admin-only pin sharing a version string with a selectable row)"},"channel":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Channel","description":"Catalog grouping: 'stable' | 'daily' | 'custom'"},"display_label":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Display Label","description":"Human label for the picker (falls back to name if unset)"}},"type":"object","required":["version","name"],"title":"OdooVersionCreate","description":"Schema for creating a new Odoo version (admin only).","example":{}},"OdooVersionStatus":{"type":"string","enum":["active","beta","deprecated","eol"],"title":"OdooVersionStatus","description":"Status states for Odoo versions."},"OdooVersionUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Display name for the version"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description","description":"Version description"},"image_registry":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Image Registry","description":"Registry URL"},"image_repository":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Image Repository","description":"Image repository/name"},"image_tag":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Image Tag","description":"Image tag"},"image_digest":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Image Digest","description":"Image digest"},"registry_auth_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Registry Auth Required","description":"Whether registry requires authentication"},"registry_auth_username":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Registry Auth Username","description":"Registry username"},"registry_auth_password":{"anyOf":[{"type":"string","maxLength":1024},{"type":"null"}],"title":"Registry Auth Password","description":"Registry password/token"},"registry_auth_email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Registry Auth Email","description":"Registry email"},"default_addons_path":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Default Addons Path","description":"Default addons path"},"default_data_dir":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Default Data Dir","description":"Default data directory"},"status":{"anyOf":[{"$ref":"#/components/schemas/OdooVersionStatus"},{"type":"null"}],"description":"Version status"},"display_order":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Display Order","description":"Sort order for display"},"is_selectable":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Selectable","description":"Whether this row appears in the user-facing picker"},"channel":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Channel","description":"Catalog grouping: 'stable' | 'daily' | 'custom'"},"display_label":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Display Label","description":"Human label for the picker (falls back to name if unset)"}},"type":"object","title":"OdooVersionUpdate","description":"Schema for updating an Odoo version (admin only). All fields optional.","example":{}},"OdooVersionUserListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/OdooVersionUserResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"default_version":{"anyOf":[{"$ref":"#/components/schemas/OdooVersionUserResponse"},{"type":"null"}],"description":"The default version for new projects"}},"type":"object","required":["items","total"],"title":"OdooVersionUserListResponse","description":"Schema for list of Odoo versions for users.","example":{}},"OdooVersionUserResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"version":{"type":"string","title":"Version"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"$ref":"#/components/schemas/OdooVersionStatus"},"is_default":{"type":"boolean","title":"Is Default"},"default_postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Postgres Version"},"min_postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Min Postgres Version"},"max_postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Max Postgres Version"},"channel":{"type":"string","title":"Channel","default":"stable"},"display_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Label"},"build_schedule":{"type":"string","title":"Build Schedule","default":"none"},"is_selectable":{"type":"boolean","title":"Is Selectable","default":true}},"type":"object","required":["id","version","name","status","is_default"],"title":"OdooVersionUserResponse","description":"Schema for Odoo version response (user view - minimal fields).","example":{}},"OdooerListingCreate":{"properties":{"name":{"type":"string","maxLength":120,"minLength":2,"title":"Name"},"tagline":{"type":"string","maxLength":200,"minLength":10,"title":"Tagline"},"website":{"anyOf":[{"type":"string","maxLength":2083,"minLength":1,"format":"uri"},{"type":"null"}],"title":"Website"},"country":{"type":"string","maxLength":2,"minLength":2,"title":"Country","description":"ISO 3166-1 alpha-2"},"city":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"City"},"timezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Timezone"},"team_size":{"type":"string","title":"Team Size","default":"2-10"},"years_experience":{"type":"integer","maximum":99.0,"minimum":0.0,"title":"Years Experience","default":1},"odoo_versions":{"items":{"type":"integer"},"type":"array","title":"Odoo Versions"},"languages":{"items":{"type":"string"},"type":"array","maxItems":20,"title":"Languages"},"services":{"items":{"type":"string"},"type":"array","maxItems":9,"title":"Services"},"industries":{"items":{"type":"string"},"type":"array","maxItems":12,"title":"Industries"},"case_studies":{"items":{"$ref":"#/components/schemas/CaseStudy"},"type":"array","title":"Case Studies"},"odoo_partner_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Partner Level","description":"Official Odoo partner tier (ready / silver / gold). Requires odoo_partner_url. Omit or set null if independent."},"odoo_partner_url":{"anyOf":[{"type":"string","maxLength":2083,"minLength":1,"format":"uri"},{"type":"null"}],"title":"Odoo Partner Url","description":"Link to their odoo.com/partners/... profile page."},"odoo_apps_store_url":{"anyOf":[{"type":"string","maxLength":2083,"minLength":1,"format":"uri"},{"type":"null"}],"title":"Odoo Apps Store Url","description":"Link to their apps.odoo.com storefront if they publish modules/themes."}},"type":"object","required":["name","tagline","country"],"title":"OdooerListingCreate","description":"POST body for creating a draft listing."},"OdooerListingEntitlement":{"properties":{"plan":{"type":"string","title":"Plan"},"base_plan":{"type":"string","title":"Base Plan"},"can_create":{"type":"boolean","title":"Can Create"},"can_publish":{"type":"boolean","title":"Can Publish"},"can_edit":{"type":"boolean","title":"Can Edit"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"}},"type":"object","required":["plan","base_plan","can_create","can_publish","can_edit"],"title":"OdooerListingEntitlement","description":"What this org may currently do with a directory listing.\n\nShipped on GET because the frontend CANNOT derive it. `_resolve_plan` is\ndeliberately stricter than the rest of the platform (which gates on\n`base_plan` alone), so a lapsed Pro org still looks like \"pro\" to\n`usePlanFeatures` — the UI would hand them the whole editor and only\ndiscover the gate when they hit save (#758)."},"OdooerListingEnvelope":{"properties":{"listing":{"anyOf":[{"$ref":"#/components/schemas/OdooerListingResponse"},{"type":"null"}]},"entitlement":{"$ref":"#/components/schemas/OdooerListingEntitlement"}},"type":"object","required":["entitlement"],"title":"OdooerListingEnvelope","description":"GET /odooer-listing — the listing plus the gate that governs it.\n\n`listing` is null when the org has not created one; the entitlement is\nstill populated, which is the case the old bare `Response | None` could\nnot express."},"OdooerListingPublishRequest":{"properties":{"consent_given":{"type":"boolean","const":true,"title":"Consent Given","description":"Must be true. Publish is refused otherwise."},"acknowledgment":{"type":"string","maxLength":2000,"minLength":40,"title":"Acknowledgment","description":"Verbatim consent text shown to the user."}},"type":"object","required":["consent_given","acknowledgment"],"title":"OdooerListingPublishRequest","description":"Publish payload — consent capture. Rejected if consent_given != True.\n\nThe `acknowledgment` field carries the verbatim text of the checkbox\nthe user ticked, stored on the row so we can prove exactly what they\nagreed to. The frontend sends whatever string was rendered next to\nthe checkbox; DO NOT compute or override this on the server."},"OdooerListingResponse":{"properties":{"name":{"type":"string","maxLength":120,"minLength":2,"title":"Name"},"tagline":{"type":"string","maxLength":200,"minLength":10,"title":"Tagline"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"country":{"type":"string","maxLength":2,"minLength":2,"title":"Country","description":"ISO 3166-1 alpha-2"},"city":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"City"},"timezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Timezone"},"team_size":{"type":"string","title":"Team Size","default":"2-10"},"years_experience":{"type":"integer","maximum":99.0,"minimum":0.0,"title":"Years Experience","default":1},"odoo_versions":{"items":{"type":"integer"},"type":"array","title":"Odoo Versions"},"languages":{"items":{"type":"string"},"type":"array","maxItems":20,"title":"Languages"},"services":{"items":{"type":"string"},"type":"array","maxItems":9,"title":"Services"},"industries":{"items":{"type":"string"},"type":"array","maxItems":12,"title":"Industries"},"case_studies":{"items":{"$ref":"#/components/schemas/CaseStudy"},"type":"array","title":"Case Studies"},"odoo_partner_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Partner Level","description":"Official Odoo partner tier (ready / silver / gold). Requires odoo_partner_url. Omit or set null if independent."},"odoo_partner_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Partner Url","description":"Link to their odoo.com/partners/... profile page."},"odoo_apps_store_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Apps Store Url","description":"Link to their apps.odoo.com storefront if they publish modules/themes."},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"id":{"type":"string","format":"uuid","title":"Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"slug":{"type":"string","title":"Slug"},"published":{"type":"boolean","title":"Published"},"plan_snapshot":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan Snapshot"},"featured":{"type":"boolean","title":"Featured"},"verified_agency":{"type":"boolean","title":"Verified Agency"},"consent_given":{"type":"boolean","title":"Consent Given"},"consent_captured_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Consent Captured At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["name","tagline","country","id","organization_id","slug","published","plan_snapshot","featured","verified_agency","consent_given","consent_captured_at","created_at","updated_at"],"title":"OdooerListingResponse","description":"Full listing shape returned to the org owner (dashboard view)."},"OdooerListingUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":120,"minLength":2},{"type":"null"}],"title":"Name"},"tagline":{"anyOf":[{"type":"string","maxLength":200,"minLength":10},{"type":"null"}],"title":"Tagline"},"website":{"anyOf":[{"type":"string","maxLength":2083,"minLength":1,"format":"uri"},{"type":"null"}],"title":"Website"},"country":{"anyOf":[{"type":"string","maxLength":2,"minLength":2},{"type":"null"}],"title":"Country"},"city":{"anyOf":[{"type":"string","maxLength":120},{"type":"null"}],"title":"City"},"timezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Timezone"},"team_size":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Team Size"},"years_experience":{"anyOf":[{"type":"integer","maximum":99.0,"minimum":0.0},{"type":"null"}],"title":"Years Experience"},"odoo_versions":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Odoo Versions"},"languages":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":20},{"type":"null"}],"title":"Languages"},"services":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":9},{"type":"null"}],"title":"Services"},"industries":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":12},{"type":"null"}],"title":"Industries"},"case_studies":{"anyOf":[{"items":{"$ref":"#/components/schemas/CaseStudy"},"type":"array"},{"type":"null"}],"title":"Case Studies"},"odoo_partner_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Partner Level"},"odoo_partner_url":{"anyOf":[{"type":"string","maxLength":2083,"minLength":1,"format":"uri"},{"type":"null"}],"title":"Odoo Partner Url"},"odoo_apps_store_url":{"anyOf":[{"type":"string","maxLength":2083,"minLength":1,"format":"uri"},{"type":"null"}],"title":"Odoo Apps Store Url"}},"type":"object","title":"OdooerListingUpdate","description":"PATCH body — every field optional."},"OnboardingStatus":{"properties":{"requires_onboarding":{"type":"boolean","title":"Requires Onboarding","description":"Whether user needs to complete onboarding"},"has_organizations":{"type":"boolean","title":"Has Organizations","description":"Whether user belongs to any organizations"},"pending_invitations":{"type":"integer","title":"Pending Invitations","description":"Number of pending invitations"},"organizations":{"items":{"type":"object"},"type":"array","title":"Organizations","description":"List of user's organizations (id, name, slug, role)"},"invitations":{"items":{"type":"object"},"type":"array","title":"Invitations","description":"List of pending invitations"}},"type":"object","required":["requires_onboarding","has_organizations","pending_invitations"],"title":"OnboardingStatus","description":"Schema for user onboarding status.","example":{}},"OrgAddonRepoCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Repository display name"},"slug":{"type":"string","maxLength":100,"minLength":1,"title":"Slug","description":"URL-friendly identifier"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Repository description"},"git_provider":{"$ref":"#/components/schemas/schemas__git_connection__GitProvider","description":"Git provider (github/gitlab)"},"git_repo_url":{"type":"string","maxLength":512,"title":"Git Repo Url","description":"Git repository URL"},"git_branch":{"type":"string","maxLength":100,"title":"Git Branch","description":"Git branch to use","default":"main"},"is_public":{"type":"boolean","title":"Is Public","description":"Whether repository is public","default":false},"org_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Org Connection Id","description":"Organization Git connection for private repos"},"requirements_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Requirements Txt Path","default":"requirements.txt"},"apt_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Apt Txt Path","default":"apt.txt"},"install_dependencies":{"type":"boolean","title":"Install Dependencies","default":true},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","default":100}},"type":"object","required":["name","slug","git_provider","git_repo_url"],"title":"OrgAddonRepoCreate","description":"Schema for creating an organization addon repo.","example":{}},"OrgAddonRepoResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"name":{"type":"string","title":"Name","description":"Repository display name"},"slug":{"type":"string","title":"Slug","description":"URL-friendly identifier"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Repository description"},"git_provider":{"$ref":"#/components/schemas/GitProvider-Output","description":"Git provider"},"git_repo_url":{"type":"string","title":"Git Repo Url","description":"Git repository URL"},"git_branch":{"type":"string","title":"Git Branch","description":"Git branch"},"is_public":{"type":"boolean","title":"Is Public","description":"Whether repository is public"},"org_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Org Connection Id","description":"Organization Git connection ID"},"requirements_txt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requirements Txt Path","description":"Path to requirements.txt"},"apt_txt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apt Txt Path","description":"Path to apt.txt"},"install_dependencies":{"type":"boolean","title":"Install Dependencies","description":"Install dependencies flag"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether repository is active"},"priority":{"type":"integer","title":"Priority","description":"Load priority"},"version_mappings":{"items":{"$ref":"#/components/schemas/OrgAddonRepoVersionResponse"},"type":"array","title":"Version Mappings","description":"Per-Odoo-version branch mappings"},"create_date":{"type":"string","format":"date-time","title":"Create Date","description":"Creation timestamp"},"write_date":{"type":"string","format":"date-time","title":"Write Date","description":"Last update timestamp"}},"type":"object","required":["id","organization_id","name","slug","description","git_provider","git_repo_url","git_branch","is_public","org_connection_id","requirements_txt_path","apt_txt_path","install_dependencies","is_active","priority","create_date","write_date"],"title":"OrgAddonRepoResponse","description":"Schema for organization addon repo response.","example":{}},"OrgAddonRepoUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description"},"git_repo_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Git Repo Url"},"git_branch":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Git Branch"},"is_public":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Public"},"org_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Org Connection Id"},"requirements_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Requirements Txt Path"},"apt_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Apt Txt Path"},"install_dependencies":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Install Dependencies"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"priority":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":0.0},{"type":"null"}],"title":"Priority"}},"type":"object","title":"OrgAddonRepoUpdate","description":"Schema for updating an organization addon repo.","example":{}},"OrgAddonRepoVersionCreate":{"properties":{"odoo_version":{"type":"string","maxLength":20,"pattern":"^\\d+\\.\\d+$","title":"Odoo Version","description":"Odoo version (e.g., '19.0', '18.0')"},"git_branch":{"type":"string","maxLength":100,"minLength":1,"title":"Git Branch","description":"Git branch to use for this Odoo version"}},"type":"object","required":["odoo_version","git_branch"],"title":"OrgAddonRepoVersionCreate","description":"Schema for creating an org addon repo version mapping (#965).","example":{}},"OrgAddonRepoVersionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Version mapping ID"},"odoo_version":{"type":"string","title":"Odoo Version","description":"Odoo version"},"git_branch":{"type":"string","title":"Git Branch","description":"Git branch"}},"type":"object","required":["id","odoo_version","git_branch"],"title":"OrgAddonRepoVersionResponse","description":"Schema for an org addon repo version mapping response (#965).","example":{}},"OrgBackupPoliciesResponse":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"policies":{"items":{"$ref":"#/components/schemas/OrgBackupPolicyResponse"},"type":"array","title":"Policies","description":"List of policies (one per environment type)"}},"type":"object","required":["organization_id"],"title":"OrgBackupPoliciesResponse","description":"Response containing all organization backup policies.","example":{}},"OrgBackupPolicyResponse":{"properties":{"environment_type":{"type":"string","maxLength":20,"title":"Environment Type","description":"Environment type this policy applies to (development, staging, production)"},"enabled":{"type":"boolean","title":"Enabled","description":"Whether automated backups are enabled","default":true},"schedule_cron":{"type":"string","maxLength":100,"title":"Schedule Cron","description":"Cron expression for backup schedule","default":"0 2 * * *"},"timezone":{"type":"string","maxLength":50,"title":"Timezone","description":"Timezone for schedule","default":"UTC"},"daily_retention":{"type":"integer","maximum":365.0,"minimum":0.0,"title":"Daily Retention","description":"Days to keep daily backups","default":7},"weekly_retention":{"type":"integer","maximum":52.0,"minimum":0.0,"title":"Weekly Retention","description":"Weeks to keep weekly backups","default":4},"monthly_retention":{"type":"integer","maximum":60.0,"minimum":0.0,"title":"Monthly Retention","description":"Months to keep monthly backups","default":3},"yearly_retention":{"type":"integer","maximum":10.0,"minimum":0.0,"title":"Yearly Retention","description":"Years to keep yearly backups","default":1},"weekly_backup_day":{"type":"integer","maximum":6.0,"minimum":0.0,"title":"Weekly Backup Day","description":"Day of week for weekly backup (0=Mon, 6=Sun)","default":6},"notify_on_success":{"type":"boolean","title":"Notify On Success","description":"Send notification on successful backup","default":false},"notify_on_failure":{"type":"boolean","title":"Notify On Failure","description":"Send notification on failed backup","default":true},"id":{"type":"string","format":"uuid","title":"Id","description":"Policy ID"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization this policy belongs to"},"storage_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Id","description":"Default storage for backups"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Creation timestamp"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["environment_type","id","organization_id"],"title":"OrgBackupPolicyResponse","description":"Schema for organization backup policy response.","example":{}},"OrgBackupPolicyUpdate":{"properties":{"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Enable/disable backups"},"schedule_cron":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Schedule Cron","description":"Cron expression"},"timezone":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Timezone","description":"Timezone"},"daily_retention":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":0.0},{"type":"null"}],"title":"Daily Retention","description":"Daily retention"},"weekly_retention":{"anyOf":[{"type":"integer","maximum":52.0,"minimum":0.0},{"type":"null"}],"title":"Weekly Retention","description":"Weekly retention"},"monthly_retention":{"anyOf":[{"type":"integer","maximum":60.0,"minimum":0.0},{"type":"null"}],"title":"Monthly Retention","description":"Monthly retention"},"yearly_retention":{"anyOf":[{"type":"integer","maximum":10.0,"minimum":0.0},{"type":"null"}],"title":"Yearly Retention","description":"Yearly retention"},"weekly_backup_day":{"anyOf":[{"type":"integer","maximum":6.0,"minimum":0.0},{"type":"null"}],"title":"Weekly Backup Day","description":"Weekly backup day"},"storage_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Storage Id","description":"Storage config ID"},"notify_on_success":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify On Success","description":"Notify on success"},"notify_on_failure":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify On Failure","description":"Notify on failure"}},"type":"object","title":"OrgBackupPolicyUpdate","description":"Schema for updating an organization backup policy.","example":{}},"OrgGitConnectionCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Connection description"},"provider":{"$ref":"#/components/schemas/schemas__git_connection__GitProvider","description":"Git provider (github/gitlab/bitbucket)"},"auth_method":{"$ref":"#/components/schemas/GitAuthMethod","description":"Authentication method"},"access_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token","description":"OAuth access token"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token","description":"OAuth refresh token"},"api_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Token","description":"Personal access token (PAT) or GitLab token"},"github_app_id":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Github App Id","description":"GitHub App ID (numeric)"},"github_app_installation_id":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Github App Installation Id","description":"GitHub App Installation ID (numeric)"},"github_app_private_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Github App Private Key","description":"GitHub App private key (PEM format)"},"gitlab_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Gitlab Url","description":"GitLab instance URL (for self-hosted)"},"instance_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Instance Url","description":"Git instance base URL for generic providers (e.g., Gitea, Forgejo)"}},"type":"object","required":["name","provider","auth_method"],"title":"OrgGitConnectionCreate","description":"Schema for creating an organization Git connection.","example":{}},"OrgGitConnectionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"name":{"type":"string","title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Connection description"},"username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Username","description":"Username from OAuth provider"},"provider":{"$ref":"#/components/schemas/GitProvider-Output","description":"Git provider"},"auth_method":{"$ref":"#/components/schemas/GitAuthMethod","description":"Authentication method"},"status":{"$ref":"#/components/schemas/ConnectionStatus","description":"Connection status"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether connection is active"},"github_app_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Github App Id","description":"GitHub App ID"},"github_app_installation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Github App Installation Id","description":"GitHub App Installation ID"},"gitlab_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gitlab Url","description":"GitLab instance URL"},"instance_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instance Url","description":"Git instance base URL for generic providers"},"token_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Token Expires At","description":"Token expiration timestamp"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"Last usage timestamp"},"validated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Validated At","description":"Last validation timestamp"},"validation_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation Error","description":"Last validation error"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By","description":"User who created this connection"},"create_date":{"type":"string","format":"date-time","title":"Create Date","description":"Creation timestamp"},"write_date":{"type":"string","format":"date-time","title":"Write Date","description":"Last update timestamp"}},"type":"object","required":["id","organization_id","name","description","username","provider","auth_method","status","is_active","github_app_id","github_app_installation_id","gitlab_url","instance_url","token_expires_at","last_used_at","validated_at","validation_error","created_by","create_date","write_date"],"title":"OrgGitConnectionResponse","description":"Schema for organization Git connection response.","example":{}},"OrgGitConnectionUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Connection description"},"access_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token"},"api_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Token"},"github_app_private_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Github App Private Key"},"gitlab_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Gitlab Url"},"instance_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Instance Url"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"OrgGitConnectionUpdate","description":"Schema for updating an organization Git connection.","example":{}},"OrgUtilizationInfo":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"organization_name":{"type":"string","title":"Organization Name"},"allocated_cpu":{"type":"number","title":"Allocated Cpu"},"allocated_ram_mb":{"type":"integer","title":"Allocated Ram Mb"},"allocated_disk_gb":{"type":"integer","title":"Allocated Disk Gb"},"max_environments":{"type":"integer","title":"Max Environments"},"used_cpu":{"type":"number","title":"Used Cpu"},"used_ram_mb":{"type":"integer","title":"Used Ram Mb"},"used_disk_gb":{"type":"integer","title":"Used Disk Gb"},"used_environments":{"type":"integer","title":"Used Environments"},"cpu_percent":{"type":"integer","title":"Cpu Percent","description":"CPU utilization percentage of allocated"},"ram_percent":{"type":"integer","title":"Ram Percent","description":"RAM utilization percentage of allocated"},"disk_percent":{"type":"integer","title":"Disk Percent","description":"Disk utilization percentage of allocated"}},"type":"object","required":["organization_id","organization_name","allocated_cpu","allocated_ram_mb","allocated_disk_gb","max_environments","used_cpu","used_ram_mb","used_disk_gb","used_environments","cpu_percent","ram_percent","disk_percent"],"title":"OrgUtilizationInfo","description":"Per-organization utilization information."},"OrganizationCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":3,"title":"Name","description":"Organization name"},"slug":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Slug","description":"URL-friendly slug (auto-generated if not provided)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Organization description"},"billing_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Email","description":"Billing email"},"server_mode":{"$ref":"#/components/schemas/ServerMode","description":"Server management mode: 'byos' (bring your own) or 'shared' (portal-managed)","default":"byos"}},"type":"object","required":["name"],"title":"OrganizationCreate","description":"Schema for creating an organization.","example":{}},"OrganizationDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"members":{"items":{"type":"object"},"type":"array","title":"Members","default":[]},"projects":{"items":{"type":"object"},"type":"array","title":"Projects","default":[]},"servers":{"items":{"type":"object"},"type":"array","title":"Servers","default":[]},"environments":{"items":{"type":"object"},"type":"array","title":"Environments","default":[]},"subscription":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Subscription"}},"type":"object","required":["id","name","slug","description","is_active","created_at"],"title":"OrganizationDetailResponse","description":"Detailed organization information for admin."},"OrganizationImpersonationSettingsResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"blocked":{"type":"boolean","title":"Blocked"},"notify_target_user":{"type":"boolean","title":"Notify Target User"},"notify_org_owner":{"type":"boolean","title":"Notify Org Owner"},"allow_portal_impersonation":{"type":"boolean","title":"Allow Portal Impersonation"},"notify_portal_on_impersonation":{"type":"boolean","title":"Notify Portal On Impersonation"},"additional_recipients":{"items":{"type":"string"},"type":"array","title":"Additional Recipients"},"webhook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Url"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","organization_id","blocked","notify_target_user","notify_org_owner","allow_portal_impersonation","notify_portal_on_impersonation","additional_recipients","created_at","updated_at"],"title":"OrganizationImpersonationSettingsResponse","description":"Organization settings for impersonation feature."},"OrganizationImpersonationSettingsUpdate":{"properties":{"blocked":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Blocked"},"notify_target_user":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify Target User"},"notify_org_owner":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify Org Owner"},"allow_portal_impersonation":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allow Portal Impersonation"},"notify_portal_on_impersonation":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notify Portal On Impersonation"},"additional_recipients":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Additional Recipients"},"webhook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Url"}},"type":"object","title":"OrganizationImpersonationSettingsUpdate","description":"Update request for organization impersonation settings."},"OrganizationListResponse":{"properties":{"organizations":{"items":{"$ref":"#/components/schemas/OrganizationSummary"},"type":"array","title":"Organizations"},"total":{"type":"integer","title":"Total"},"active_count":{"type":"integer","title":"Active Count"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"total_pages":{"type":"integer","title":"Total Pages"}},"type":"object","required":["organizations","total","active_count","page","per_page","total_pages"],"title":"OrganizationListResponse","description":"Paginated organization list response."},"OrganizationMemberCreate":{"properties":{"email":{"type":"string","title":"Email","description":"Email of user to add"},"role":{"$ref":"#/components/schemas/OrganizationRole","description":"Member role to assign","default":"developer"},"managed_project_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Managed Project Ids","description":"Project IDs this member can manage (used with DEVELOPER role)"}},"type":"object","required":["email"],"title":"OrganizationMemberCreate","description":"Schema for adding a member to an organization.","example":{}},"OrganizationMemberResponse":{"properties":{"id":{"type":"string","title":"Id","description":"Membership ID"},"user_id":{"type":"string","title":"User Id","description":"User ID"},"organization_id":{"type":"string","title":"Organization Id","description":"Organization ID"},"role":{"type":"string","title":"Role","description":"Member role (OWNER, ADMIN, DEVELOPER, VIEWER)"},"managed_project_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Managed Project Ids","description":"Project IDs this member can manage"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether membership is active"},"user":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"User","description":"User info"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At","description":"Created timestamp"}},"type":"object","required":["id","user_id","organization_id","role","is_active"],"title":"OrganizationMemberResponse","description":"Schema for organization member response.","example":{}},"OrganizationMemberUpdate":{"properties":{"role":{"anyOf":[{"$ref":"#/components/schemas/OrganizationRole"},{"type":"null"}],"description":"Member role"},"managed_project_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Managed Project Ids","description":"Project IDs this member can manage (used with DEVELOPER role)"}},"type":"object","title":"OrganizationMemberUpdate","description":"Schema for updating a member's role.","example":{}},"OrganizationQuotaLimits":{"properties":{"max_projects":{"type":"integer","maximum":1000.0,"minimum":-1.0,"title":"Max Projects","description":"Maximum number of projects allowed (-1 = unlimited)","default":10},"max_environments":{"type":"integer","maximum":5000.0,"minimum":-1.0,"title":"Max Environments","description":"Maximum number of environments allowed (-1 = unlimited)","default":30},"max_servers":{"type":"integer","maximum":100.0,"minimum":-1.0,"title":"Max Servers","description":"Maximum number of servers (VMs) allowed (-1 = unlimited)","default":5},"max_members":{"type":"integer","maximum":500.0,"minimum":-1.0,"title":"Max Members","description":"Maximum number of organization members allowed (-1 = unlimited)","default":20},"max_cpu_per_env":{"type":"string","title":"Max Cpu Per Env","description":"Maximum CPU cores per environment (0 = unlimited)","default":"0"},"max_ram_per_env_mb":{"type":"integer","maximum":131072.0,"minimum":0.0,"title":"Max Ram Per Env Mb","description":"Maximum RAM per environment in MB (0 = unlimited)","default":0},"max_disk_per_env_gb":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Max Disk Per Env Gb","description":"Maximum disk space per environment in GB (0 = unlimited)","default":0},"total_cpu_quota":{"type":"string","title":"Total Cpu Quota","description":"Total CPU cores quota across all environments (0 = unlimited)","default":"0"},"total_ram_quota_mb":{"type":"integer","maximum":1048576.0,"minimum":0.0,"title":"Total Ram Quota Mb","description":"Total RAM quota in MB across all environments (0 = unlimited)","default":0},"total_disk_quota_gb":{"type":"integer","maximum":10000.0,"minimum":0.0,"title":"Total Disk Quota Gb","description":"Total disk quota in GB across all environments (0 = unlimited)","default":0}},"type":"object","title":"OrganizationQuotaLimits","description":"Organization quota limit settings.\n\nNote: A value of -1 means \"unlimited\" for entity count fields.\nA value of 0 means \"unlimited\" for resource quota fields.","example":{}},"OrganizationQuotaUpdate":{"properties":{"max_projects":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":-1.0},{"type":"null"}],"title":"Max Projects"},"max_environments":{"anyOf":[{"type":"integer","maximum":5000.0,"minimum":-1.0},{"type":"null"}],"title":"Max Environments"},"max_servers":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":-1.0},{"type":"null"}],"title":"Max Servers"},"max_members":{"anyOf":[{"type":"integer","maximum":500.0,"minimum":-1.0},{"type":"null"}],"title":"Max Members"},"max_cpu_per_env":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.0},{"type":"string"},{"type":"null"}],"title":"Max Cpu Per Env"},"max_ram_per_env_mb":{"anyOf":[{"type":"integer","maximum":131072.0,"minimum":0.0},{"type":"null"}],"title":"Max Ram Per Env Mb"},"max_disk_per_env_gb":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":0.0},{"type":"null"}],"title":"Max Disk Per Env Gb"},"total_cpu_quota":{"anyOf":[{"type":"number","maximum":1000.0,"minimum":0.0},{"type":"string"},{"type":"null"}],"title":"Total Cpu Quota"},"total_ram_quota_mb":{"anyOf":[{"type":"integer","maximum":1048576.0,"minimum":0.0},{"type":"null"}],"title":"Total Ram Quota Mb"},"total_disk_quota_gb":{"anyOf":[{"type":"integer","maximum":10000.0,"minimum":0.0},{"type":"null"}],"title":"Total Disk Quota Gb"}},"type":"object","title":"OrganizationQuotaUpdate","description":"Schema for updating organization quotas (admin only).\n\nNote: A value of -1 means \"unlimited\" for entity count fields.","example":{}},"OrganizationResponse":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name","description":"Organization name"},"slug":{"type":"string","maxLength":100,"minLength":1,"title":"Slug","description":"URL-friendly slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Organization description"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website","description":"Organization website"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url","description":"Organization logo URL"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether organization is active"},"auto_created":{"type":"boolean","title":"Auto Created","description":"True if this org was auto-created by the signup onboarding flow. Gates the OrgWelcomeBanner — banner shows iff this is True. (OEC-0056)","default":false},"settings":{"type":"object","title":"Settings","description":"Organization settings"},"billing_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Email","description":"Billing email"},"member_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Member Count","description":"Number of members"},"project_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Project Count","description":"Number of projects"},"server_mode":{"type":"string","title":"Server Mode","description":"Server management mode: 'byos' or 'shared'","default":"byos"},"migration_started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Migration Started At","description":"When mode switch migration started"},"migration_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Migration Completed At","description":"When mode switch migration completed"},"migration_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Migration Error","description":"Error message if migration failed"},"agency_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agency Domain","description":"Agency white-label domain (e.g., 'acmecloud.io')"},"allow_platform_storage":{"type":"boolean","title":"Allow Platform Storage","description":"Allow org to use oec.sh R2 for migrations. Portal admin controlled.","default":false},"clone_disabled":{"type":"boolean","title":"Clone Disabled","description":"When True, all environment cloning is disabled for this org. Useful for regulated customers requiring a strict no-clone policy.","default":false}},"type":"object","required":["name","slug","created_at","updated_at","id","is_active"],"title":"OrganizationResponse","description":"Schema for organization response.","example":{}},"OrganizationRole":{"type":"string","enum":["owner","admin","developer","viewer"],"title":"OrganizationRole","description":"Organization member roles.\n\nRole hierarchy (highest to lowest):\n- OWNER: Full access, can delete org, transfer ownership\n- ADMIN: Full access, cannot delete org\n- DEVELOPER: Can manage projects, deploy (standard access)\n- VIEWER: Read-only access"},"OrganizationSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"member_count":{"type":"integer","title":"Member Count","default":0},"project_count":{"type":"integer","title":"Project Count","default":0},"server_count":{"type":"integer","title":"Server Count","default":0},"owner_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Owner Email"},"current_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Plan"},"current_plan_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Plan Status"}},"type":"object","required":["id","name","slug","is_active","created_at"],"title":"OrganizationSummary","description":"Organization summary for admin list."},"OrganizationUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":1},{"type":"null"}],"title":"Slug","description":"URL identifier. Normalized server-side (lowercased, spaces/underscores -> hyphens, invalid chars stripped). Setting this is an explicit edit; for a fresh org with no resources the slug auto-follows the name on rename."},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"settings":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Settings"},"server_mode":{"anyOf":[{"$ref":"#/components/schemas/ServerMode"},{"type":"null"}],"description":"Server mode (use /switch-mode endpoint for proper migration)"},"clone_disabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Clone Disabled","description":"Set True to disable all environment cloning for this organization"}},"type":"object","title":"OrganizationUpdate","description":"Schema for updating an organization.","example":{}},"OutgoingWebhookCreate":{"properties":{"url":{"type":"string","title":"Url"},"events":{"items":{"type":"string"},"type":"array","title":"Events"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"is_active":{"type":"boolean","title":"Is Active","default":true},"format":{"type":"string","title":"Format","default":"raw"}},"type":"object","required":["url","events"],"title":"OutgoingWebhookCreate","description":"Payload for registering a new outgoing webhook."},"OutgoingWebhookCreatedResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"url":{"type":"string","title":"Url"},"events":{"items":{"type":"string"},"type":"array","title":"Events"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"format":{"type":"string","title":"Format","default":"raw"},"is_active":{"type":"boolean","title":"Is Active"},"last_triggered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Triggered At"},"failure_count":{"type":"integer","title":"Failure Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"secret":{"type":"string","title":"Secret"}},"type":"object","required":["id","url","events","description","project_id","is_active","last_triggered_at","failure_count","created_at","secret"],"title":"OutgoingWebhookCreatedResponse","description":"Extended response returned ONLY at creation time.\n\nIncludes the plaintext signing secret (whsec_...), shown once only.\nAfter this response the secret cannot be retrieved; only rotation is possible."},"OutgoingWebhookResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"url":{"type":"string","title":"Url"},"events":{"items":{"type":"string"},"type":"array","title":"Events"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"format":{"type":"string","title":"Format","default":"raw"},"is_active":{"type":"boolean","title":"Is Active"},"last_triggered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Triggered At"},"failure_count":{"type":"integer","title":"Failure Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","url","events","description","project_id","is_active","last_triggered_at","failure_count","created_at"],"title":"OutgoingWebhookResponse","description":"Webhook details returned by list/get endpoints."},"OutgoingWebhookUpdate":{"properties":{"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"events":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Events"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Format"}},"type":"object","title":"OutgoingWebhookUpdate","description":"Payload for updating an existing webhook (all fields optional)."},"PaginatedResponse_PublicCloneOperationResponse_":{"properties":{"data":{"items":{"$ref":"#/components/schemas/PublicCloneOperationResponse"},"type":"array","title":"Data"},"pagination":{"$ref":"#/components/schemas/PaginationMeta"}},"type":"object","required":["data","pagination"],"title":"PaginatedResponse[PublicCloneOperationResponse]"},"PaginatedResponse_PublicProjectResponse_":{"properties":{"data":{"items":{"$ref":"#/components/schemas/PublicProjectResponse"},"type":"array","title":"Data"},"pagination":{"$ref":"#/components/schemas/PaginationMeta"}},"type":"object","required":["data","pagination"],"title":"PaginatedResponse[PublicProjectResponse]"},"PaginatedResponse_PublicServerResponse_":{"properties":{"data":{"items":{"$ref":"#/components/schemas/PublicServerResponse"},"type":"array","title":"Data"},"pagination":{"$ref":"#/components/schemas/PaginationMeta"}},"type":"object","required":["data","pagination"],"title":"PaginatedResponse[PublicServerResponse]"},"PaginatedResponse_PublicSupportTicket_":{"properties":{"data":{"items":{"$ref":"#/components/schemas/PublicSupportTicket"},"type":"array","title":"Data"},"pagination":{"$ref":"#/components/schemas/PaginationMeta"}},"type":"object","required":["data","pagination"],"title":"PaginatedResponse[PublicSupportTicket]"},"PaginatedResponse_PublicTaskResponse_":{"properties":{"data":{"items":{"$ref":"#/components/schemas/PublicTaskResponse"},"type":"array","title":"Data"},"pagination":{"$ref":"#/components/schemas/PaginationMeta"}},"type":"object","required":["data","pagination"],"title":"PaginatedResponse[PublicTaskResponse]"},"PaginationMeta":{"properties":{"has_more":{"type":"boolean","title":"Has More"},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Cursor"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["has_more","next_cursor","total"],"title":"PaginationMeta","description":"Cursor-based pagination metadata included in every list response."},"PasskeyDeleteResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether deletion was successful"},"message":{"type":"string","title":"Message","description":"Status message"}},"type":"object","required":["success","message"],"title":"PasskeyDeleteResponse","description":"Passkey deletion response."},"PasskeyListResponse":{"properties":{"passkeys":{"items":{"$ref":"#/components/schemas/PasskeyResponse"},"type":"array","title":"Passkeys","description":"List of user's passkeys"},"count":{"type":"integer","title":"Count","description":"Total number of passkeys"}},"type":"object","required":["passkeys","count"],"title":"PasskeyListResponse","description":"List of passkeys response."},"PasskeyLoginOptionsRequest":{"properties":{"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Optional email for user-specific credentials. Omit for discoverable flow.","example":"user@example.com"}},"type":"object","title":"PasskeyLoginOptionsRequest","description":"Request to generate passkey login options."},"PasskeyLoginOptionsResponse":{"properties":{"options":{"type":"object","title":"Options","description":"PublicKeyCredentialRequestOptions for browser"},"challenge_id":{"type":"string","title":"Challenge Id","description":"Challenge ID for verification"}},"type":"object","required":["options","challenge_id"],"title":"PasskeyLoginOptionsResponse","description":"Passkey login options response."},"PasskeyLoginResponse":{"properties":{"access_token":{"type":"string","title":"Access Token","description":"JWT access token"},"refresh_token":{"type":"string","title":"Refresh Token","description":"JWT refresh token"},"token_type":{"type":"string","title":"Token Type","description":"Token type","default":"bearer"},"expires_in":{"type":"integer","title":"Expires In","description":"Token expiration in seconds"},"user":{"type":"object","title":"User","description":"Authenticated user info"}},"type":"object","required":["access_token","refresh_token","expires_in","user"],"title":"PasskeyLoginResponse","description":"Passkey login success response."},"PasskeyLoginVerifyRequest":{"properties":{"challenge_id":{"type":"string","title":"Challenge Id","description":"Challenge ID from login options response"},"credential":{"type":"object","title":"Credential","description":"WebAuthn credential response from browser"}},"type":"object","required":["challenge_id","credential"],"title":"PasskeyLoginVerifyRequest","description":"Request to verify passkey login."},"PasskeyRegisterOptionsRequest":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"User-friendly name for the passkey (e.g., 'MacBook Pro')","example":"MacBook Pro"}},"type":"object","required":["name"],"title":"PasskeyRegisterOptionsRequest","description":"Request to generate passkey registration options."},"PasskeyRegisterOptionsResponse":{"properties":{"options":{"type":"object","title":"Options","description":"PublicKeyCredentialCreationOptions for browser"}},"type":"object","required":["options"],"title":"PasskeyRegisterOptionsResponse","description":"Passkey registration options response."},"PasskeyRegisterVerifyRequest":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"User-friendly name for the passkey"},"credential":{"type":"object","title":"Credential","description":"WebAuthn credential response from browser"}},"type":"object","required":["name","credential"],"title":"PasskeyRegisterVerifyRequest","description":"Request to verify passkey registration."},"PasskeyRenameRequest":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"New name for the passkey","example":"Work Laptop"}},"type":"object","required":["name"],"title":"PasskeyRenameRequest","description":"Request to rename a passkey."},"PasskeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Passkey ID"},"name":{"type":"string","title":"Name","description":"User-friendly name"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the passkey was registered"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"When the passkey was last used"},"backup_eligible":{"type":"boolean","title":"Backup Eligible","description":"Whether passkey can be backed up (e.g., iCloud)"},"backup_state":{"type":"boolean","title":"Backup State","description":"Whether passkey is currently backed up"},"credential_device_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Credential Device Type","description":"Device type: singleDevice or multiDevice"}},"type":"object","required":["id","name","created_at","backup_eligible","backup_state"],"title":"PasskeyResponse","description":"Passkey details response."},"PasswordChange":{"properties":{"current_password":{"type":"string","title":"Current Password","description":"Current password"},"new_password":{"type":"string","maxLength":128,"minLength":8,"title":"New Password","description":"New password (NIST 800-63B-4 compliant)"}},"type":"object","required":["current_password","new_password"],"title":"PasswordChange","description":"Schema for password change request.","example":{}},"PasswordReset":{"properties":{"email":{"type":"string","format":"email","title":"Email","description":"User email address"},"turnstile_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Turnstile Token","description":"Cloudflare Turnstile token"}},"type":"object","required":["email"],"title":"PasswordReset","description":"Schema for password reset request.","example":{}},"PasswordResetConfirm":{"properties":{"token":{"type":"string","title":"Token","description":"Password reset token"},"new_password":{"type":"string","maxLength":128,"minLength":8,"title":"New Password","description":"New password (NIST 800-63B-4 compliant)"},"turnstile_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Turnstile Token","description":"Cloudflare Turnstile token"}},"type":"object","required":["token","new_password"],"title":"PasswordResetConfirm","description":"Schema for password reset confirmation.","example":{}},"PauseInfo":{"properties":{"org_name":{"type":"string","title":"Org Name"},"plan":{"type":"string","title":"Plan"},"paused_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paused At"},"resumes_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resumes At"}},"type":"object","required":["org_name","plan","paused_at","resumes_at"],"title":"PauseInfo","description":"Recent pause details."},"PermissionCheckResult":{"properties":{"allowed":{"type":"boolean","title":"Allowed","description":"Whether the permission is granted"},"permission_code":{"type":"string","title":"Permission Code","description":"Permission that was checked"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Source of the permission (role)"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"Reason if denied"}},"type":"object","required":["allowed","permission_code"],"title":"PermissionCheckResult","description":"Result of a permission check.","example":{}},"PermissionResponse":{"properties":{"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"code":{"type":"string","maxLength":100,"minLength":1,"title":"Code","description":"Unique permission code (e.g., 'org.members.invite')"},"resource":{"type":"string","maxLength":50,"minLength":1,"title":"Resource","description":"Resource this permission applies to"},"action":{"type":"string","maxLength":50,"minLength":1,"title":"Action","description":"Action this permission allows"},"scope":{"$ref":"#/components/schemas/PermissionScope-Output","description":"Permission scope level"},"category":{"type":"string","maxLength":50,"minLength":1,"title":"Category","description":"Category for UI grouping"},"display_name":{"type":"string","maxLength":100,"minLength":1,"title":"Display Name","description":"Human-readable name for UI"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Detailed description"},"icon":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Icon","description":"Icon name for UI"},"is_dangerous":{"type":"boolean","title":"Is Dangerous","description":"Whether this permission should show warning in UI","default":false},"is_system":{"type":"boolean","title":"Is System","description":"Whether this is a system-defined permission"},"sort_order":{"type":"integer","title":"Sort Order","description":"Sort order within category"}},"type":"object","required":["created_at","updated_at","id","code","resource","action","scope","category","display_name","is_system","sort_order"],"title":"PermissionResponse","description":"Schema for permission response.","example":{}},"PermissionScope":{"type":"string","enum":["portal","organization","project"],"title":"PermissionScope","description":"Scope levels for permissions.\n\nPermissions are organized hierarchically:\n- PORTAL: Platform-wide (users, organizations, servers, platform settings)\n- ORGANIZATION: Org-specific (members, projects, storage, billing)\n- PROJECT: Project-specific (environments, backups, domains)"},"PermissionScope-Output":{"type":"string","enum":["portal","organization","project"],"title":"PermissionScope","description":"Permission scope levels."},"PermissionSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"code":{"type":"string","title":"Code"},"display_name":{"type":"string","title":"Display Name"},"is_dangerous":{"type":"boolean","title":"Is Dangerous"}},"type":"object","required":["id","code","display_name","is_dangerous"],"title":"PermissionSummary","description":"Minimal permission info for list views.","example":{}},"PhysicalCapacityInfo":{"properties":{"cpu_cores":{"type":"number","title":"Cpu Cores"},"ram_mb":{"type":"integer","title":"Ram Mb"},"disk_gb":{"type":"integer","title":"Disk Gb"}},"type":"object","required":["cpu_cores","ram_mb","disk_gb"],"title":"PhysicalCapacityInfo","description":"Physical capacity of a shared server."},"PinBuildRequest":{"properties":{"tag":{"type":"string","maxLength":40,"minLength":6,"title":"Tag","description":"e.g. 18.0-20260817"}},"type":"object","required":["tag"],"title":"PinBuildRequest"},"PlanChangeRequest":{"properties":{"new_plan":{"type":"string","title":"New Plan","description":"Target plan to change to"},"billing_interval":{"type":"string","title":"Billing Interval","description":"Billing interval (monthly/annual)","default":"monthly"}},"type":"object","required":["new_plan"],"title":"PlanChangeRequest","description":"Request to upgrade or downgrade plan.","example":{}},"PlanCount":{"properties":{"plan":{"type":"string","title":"Plan"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["plan","count"],"title":"PlanCount","description":"Paid plan with its active subscriber count (internal orgs excluded)."},"PlanListResponse":{"properties":{"plans":{"items":{"$ref":"#/components/schemas/PlanQuotaResponse"},"type":"array","title":"Plans","description":"Available subscription plans"}},"type":"object","required":["plans"],"title":"PlanListResponse","description":"List of available plans.","example":{}},"PlanQuotaResponse":{"properties":{"plan":{"type":"string","title":"Plan","description":"Plan identifier (free, starter, pro, agency, saas)"},"name":{"type":"string","title":"Name","description":"Display name of the plan"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Plan description"},"monthly_price":{"type":"string","title":"Monthly Price","description":"Monthly price in USD"},"annual_price":{"type":"string","title":"Annual Price","description":"Annual price in USD (with discount)"},"stripe_monthly_price_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Monthly Price Id","description":"Stripe price ID for monthly billing"},"stripe_annual_price_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Annual Price Id","description":"Stripe price ID for annual billing"},"max_servers":{"type":"integer","title":"Max Servers","description":"Maximum servers allowed (0 = unlimited)"},"max_environments":{"type":"integer","title":"Max Environments","description":"Maximum environments allowed (0 = unlimited)"},"max_projects":{"type":"integer","title":"Max Projects","description":"Maximum projects allowed (0 = unlimited)"},"max_members":{"type":"integer","title":"Max Members","description":"Maximum members allowed (0 = unlimited)"},"included_byos_servers":{"type":"integer","title":"Included Byos Servers","description":"BYOS servers included in base plan"},"included_platform_envs":{"type":"integer","title":"Included Platform Envs","description":"Platform environments included in base plan"},"backup_frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Backup Frequency","description":"Backup frequency (daily, 12-hourly, 6-hourly, hourly)"},"backup_retention_days":{"type":"integer","title":"Backup Retention Days","description":"Backup retention in days","default":7},"monitoring_enabled":{"type":"boolean","title":"Monitoring Enabled","description":"Whether monitoring is enabled"},"priority_support":{"type":"boolean","title":"Priority Support","description":"Whether priority support is included"},"custom_domains":{"type":"boolean","title":"Custom Domains","description":"Whether custom domains are allowed"},"sso_enabled":{"type":"boolean","title":"Sso Enabled","description":"Whether SSO is enabled"},"support_level":{"type":"string","title":"Support Level","description":"Support level (community, email, priority, phone, dedicated)","default":"community"},"ssh_terminal_enabled":{"type":"boolean","title":"Ssh Terminal Enabled","description":"SSH terminal in browser enabled (ALL plans)","default":true},"auto_provision_enabled":{"type":"boolean","title":"Auto Provision Enabled","description":"Auto-provision cloud VMs enabled (ALL plans)","default":true},"clone_enabled":{"type":"boolean","title":"Clone Enabled","description":"Basic clone (same server) enabled (ALL plans)","default":true},"sanitize_enabled":{"type":"boolean","title":"Sanitize Enabled","description":"Clone sanitization enabled (STARTER+)","default":false},"custom_domain_enabled":{"type":"boolean","title":"Custom Domain Enabled","description":"Custom domain for environments (STARTER+)","default":false},"dns_management_enabled":{"type":"boolean","title":"Dns Management Enabled","description":"DNS management feature enabled (PRO+)","default":false},"replica_enabled":{"type":"boolean","title":"Replica Enabled","description":"PostgreSQL read replica enabled (PRO+)","default":false},"pgbouncer_enabled":{"type":"boolean","title":"Pgbouncer Enabled","description":"PgBouncer connection pooling enabled (PRO+)","default":false},"tuned_postgres_enabled":{"type":"boolean","title":"Tuned Postgres Enabled","description":"Tuned PostgreSQL configuration enabled (PRO+)","default":false},"advanced_monitoring_enabled":{"type":"boolean","title":"Advanced Monitoring Enabled","description":"Advanced monitoring/metrics enabled (PRO+)","default":false},"clone_cross_server_enabled":{"type":"boolean","title":"Clone Cross Server Enabled","description":"Cross-server clone enabled (PRO+)","default":false},"agency_domain_enabled":{"type":"boolean","title":"Agency Domain Enabled","description":"Agency domain (white-label URLs) enabled (AGENCY only)","default":false},"custom_roles_enabled":{"type":"boolean","title":"Custom Roles Enabled","description":"Custom team roles enabled (AGENCY only)","default":false},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the plan is currently offered","default":true}},"type":"object","required":["plan","name","monthly_price","annual_price","max_servers","max_environments","max_projects","max_members","included_byos_servers","included_platform_envs","monitoring_enabled","priority_support","custom_domains","sso_enabled"],"title":"PlanQuotaResponse","description":"Plan quota and feature details.","example":{}},"PlatformAddonRepoCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Repository display name"},"slug":{"type":"string","maxLength":100,"minLength":1,"title":"Slug","description":"URL-friendly identifier (lowercase, hyphens only)"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Repository description"},"git_provider":{"$ref":"#/components/schemas/schemas__git_connection__GitProvider","description":"Git provider (github/gitlab)"},"git_repo_url":{"type":"string","maxLength":512,"title":"Git Repo Url","description":"Git repository URL (HTTPS format)"},"is_public":{"type":"boolean","title":"Is Public","description":"Whether repository is public (no auth needed)","default":false},"platform_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Platform Connection Id","description":"Platform Git connection for private repos"},"requirements_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Requirements Txt Path","description":"Path to requirements.txt relative to repo root","default":"requirements.txt"},"apt_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Apt Txt Path","description":"Path to apt.txt relative to repo root","default":"apt.txt"},"install_dependencies":{"type":"boolean","title":"Install Dependencies","description":"Whether to install dependencies from this repo","default":true},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","description":"Load priority (lower numbers load first)","default":100},"default_selected":{"type":"boolean","title":"Default Selected","description":"Selected by default for projects that never saved a selection","default":false}},"type":"object","required":["name","slug","git_provider","git_repo_url"],"title":"PlatformAddonRepoCreate","description":"Schema for creating a platform addon repo.","example":{}},"PlatformAddonRepoResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","title":"Name","description":"Repository display name"},"slug":{"type":"string","title":"Slug","description":"URL-friendly identifier"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Repository description"},"git_provider":{"$ref":"#/components/schemas/GitProvider-Output","description":"Git provider"},"git_repo_url":{"type":"string","title":"Git Repo Url","description":"Git repository URL"},"is_public":{"type":"boolean","title":"Is Public","description":"Whether repository is public"},"platform_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Platform Connection Id","description":"Platform Git connection ID"},"requirements_txt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requirements Txt Path","description":"Path to requirements.txt"},"apt_txt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apt Txt Path","description":"Path to apt.txt"},"install_dependencies":{"type":"boolean","title":"Install Dependencies","description":"Install dependencies flag"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether repository is active"},"priority":{"type":"integer","title":"Priority","description":"Load priority"},"default_selected":{"type":"boolean","title":"Default Selected","description":"Whether selected by default for new projects"},"version_mappings":{"items":{"$ref":"#/components/schemas/PlatformAddonRepoVersionResponse"},"type":"array","title":"Version Mappings","description":"Odoo version to branch mappings","default":[]},"create_date":{"type":"string","format":"date-time","title":"Create Date","description":"Creation timestamp"},"write_date":{"type":"string","format":"date-time","title":"Write Date","description":"Last update timestamp"}},"type":"object","required":["id","name","slug","description","git_provider","git_repo_url","is_public","platform_connection_id","requirements_txt_path","apt_txt_path","install_dependencies","is_active","priority","default_selected","create_date","write_date"],"title":"PlatformAddonRepoResponse","description":"Schema for platform addon repo response.","example":{}},"PlatformAddonRepoUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description"},"git_repo_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Git Repo Url"},"is_public":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Public"},"platform_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Platform Connection Id"},"requirements_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Requirements Txt Path"},"apt_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Apt Txt Path"},"install_dependencies":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Install Dependencies"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"priority":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":0.0},{"type":"null"}],"title":"Priority"},"default_selected":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Default Selected"}},"type":"object","title":"PlatformAddonRepoUpdate","description":"Schema for updating a platform addon repo.","example":{}},"PlatformAddonRepoVersionCreate":{"properties":{"odoo_version":{"type":"string","maxLength":20,"pattern":"^\\d+\\.\\d+$","title":"Odoo Version","description":"Odoo version (e.g., '17.0', '16.0')"},"git_branch":{"type":"string","maxLength":100,"minLength":1,"title":"Git Branch","description":"Git branch for this Odoo version"}},"type":"object","required":["odoo_version","git_branch"],"title":"PlatformAddonRepoVersionCreate","description":"Schema for creating a version mapping.","example":{}},"PlatformAddonRepoVersionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Version mapping ID"},"odoo_version":{"type":"string","title":"Odoo Version","description":"Odoo version"},"git_branch":{"type":"string","title":"Git Branch","description":"Git branch"}},"type":"object","required":["id","odoo_version","git_branch"],"title":"PlatformAddonRepoVersionResponse","description":"Schema for version mapping response.","example":{}},"PlatformGitConnectionCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Connection description"},"provider":{"$ref":"#/components/schemas/schemas__git_connection__GitProvider","description":"Git provider (github/gitlab/bitbucket)"},"auth_method":{"$ref":"#/components/schemas/GitAuthMethod","description":"Authentication method"},"access_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token","description":"OAuth access token"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token","description":"OAuth refresh token"},"api_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Token","description":"Personal access token (PAT) or GitLab token"},"github_app_id":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Github App Id","description":"GitHub App ID (numeric)"},"github_app_installation_id":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Github App Installation Id","description":"GitHub App Installation ID (numeric)"},"github_app_private_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Github App Private Key","description":"GitHub App private key (PEM format)"},"gitlab_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Gitlab Url","description":"GitLab instance URL (for self-hosted)"},"instance_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Instance Url","description":"Git instance base URL for generic providers (e.g., Gitea, Forgejo)"},"allow_org_usage":{"type":"boolean","title":"Allow Org Usage","description":"Allow organizations to use this connection","default":false}},"type":"object","required":["name","provider","auth_method"],"title":"PlatformGitConnectionCreate","description":"Schema for creating a platform Git connection.","example":{}},"PlatformGitConnectionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Connection description"},"provider":{"$ref":"#/components/schemas/GitProvider-Output","description":"Git provider"},"auth_method":{"$ref":"#/components/schemas/GitAuthMethod","description":"Authentication method"},"status":{"$ref":"#/components/schemas/ConnectionStatus","description":"Connection status"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether connection is active"},"allow_org_usage":{"type":"boolean","title":"Allow Org Usage","description":"Allow org usage"},"github_app_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Github App Id","description":"GitHub App ID"},"github_app_installation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Github App Installation Id","description":"GitHub App Installation ID"},"gitlab_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gitlab Url","description":"GitLab instance URL"},"instance_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instance Url","description":"Git instance base URL for generic providers"},"token_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Token Expires At","description":"Token expiration timestamp"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"Last usage timestamp"},"validated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Validated At","description":"Last validation timestamp"},"validation_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation Error","description":"Last validation error"},"create_date":{"type":"string","format":"date-time","title":"Create Date","description":"Creation timestamp"},"write_date":{"type":"string","format":"date-time","title":"Write Date","description":"Last update timestamp"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By","description":"User who created this connection"}},"type":"object","required":["id","name","description","provider","auth_method","status","is_active","allow_org_usage","github_app_id","github_app_installation_id","gitlab_url","instance_url","token_expires_at","last_used_at","validated_at","validation_error","create_date","write_date","created_by"],"title":"PlatformGitConnectionResponse","description":"Schema for platform Git connection response.","example":{}},"PlatformGitConnectionUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Connection display name"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Connection description"},"access_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token","description":"New OAuth access token"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token","description":"New OAuth refresh token"},"api_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Api Token","description":"New personal access token"},"github_app_private_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Github App Private Key","description":"New GitHub App private key"},"gitlab_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Gitlab Url","description":"GitLab instance URL"},"instance_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Instance Url","description":"Git instance base URL for generic providers"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Whether connection is active"},"allow_org_usage":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allow Org Usage","description":"Allow organizations to use this connection"}},"type":"object","title":"PlatformGitConnectionUpdate","description":"Schema for updating a platform Git connection.","example":{}},"PlatformHostnameAddRequest":{"properties":{"hostname":{"type":"string","maxLength":253,"minLength":4,"title":"Hostname","description":"The Agency's custom dashboard hostname (FQDN, no scheme).","examples":["app.theagency.com"]}},"type":"object","required":["hostname"],"title":"PlatformHostnameAddRequest","description":"POST /api/v1/organizations/{org_id}/platform-hostname body.\n\nSpec §6.1. v1 enforces FQDN-with-subdomain — apex domains rejected\nbecause CF for SaaS terminates at a CNAME, not an apex A/AAAA record."},"PlatformHostnameCnameInfoResponse":{"properties":{"hostname":{"type":"string","title":"Hostname"},"cname":{"type":"object","title":"Cname"},"validation_records":{"items":{"$ref":"#/components/schemas/schemas__organization_platform_hostname__ValidationRecord"},"type":"array","title":"Validation Records"},"instructions":{"type":"string","title":"Instructions"},"estimated_time":{"type":"string","title":"Estimated Time"}},"type":"object","required":["hostname","cname","instructions","estimated_time"],"title":"PlatformHostnameCnameInfoResponse","description":"Response shape for GET /platform-hostname/cname (spec §6.5)."},"PlatformHostnameResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"hostname":{"type":"string","title":"Hostname"},"cf_custom_hostname_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Custom Hostname Id"},"cf_status":{"$ref":"#/components/schemas/PlatformHostnameStatus"},"cf_ssl_status":{"$ref":"#/components/schemas/PlatformHostnameSslStatus"},"cname_target":{"type":"string","title":"Cname Target","default":"custom.oec.sh"},"validation_records":{"items":{"$ref":"#/components/schemas/schemas__organization_platform_hostname__ValidationRecord"},"type":"array","title":"Validation Records"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"last_cf_check_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Cf Check At"},"last_cf_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Cf Error"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","organization_id","hostname","cf_status","cf_ssl_status","created_at"],"title":"PlatformHostnameResponse","description":"Response shape for GET/POST/DELETE /platform-hostname.\n\nSpec §6.2. Unknown CF statuses coerce to the `unknown` sentinel so\na CF SaaS API addition doesn't 500 the route."},"PlatformHostnameSslStatus":{"type":"string","enum":["initializing","pending_validation","pending_issuance","pending_deployment","active","expired","failed","unknown"],"title":"PlatformHostnameSslStatus","description":"CF SSL status for Phase 2.7 platform hostnames."},"PlatformHostnameStatus":{"type":"string","enum":["pending_validation","pending_issuance","pending_deployment","active","failed","blocked","pending_deletion","unknown"],"title":"PlatformHostnameStatus","description":"CF custom-hostname status for Phase 2.7 platform hostnames.\n\nMirrors Phase 3's ClientDomainHostnameStatus — same set of CF\nlifecycle values plus the `unknown` sentinel for forward-compat."},"PlatformIncidentSeverity":{"type":"string","enum":["critical","high","medium","low"],"title":"PlatformIncidentSeverity"},"PlatformIncidentStatus":{"type":"string","enum":["active","acknowledged","resolved","suppressed"],"title":"PlatformIncidentStatus"},"PlatformStatsResponse":{"properties":{"total_users":{"type":"integer","title":"Total Users"},"active_users":{"type":"integer","title":"Active Users"},"total_organizations":{"type":"integer","title":"Total Organizations"},"total_projects":{"type":"integer","title":"Total Projects"},"total_servers":{"type":"integer","title":"Total Servers"},"users_by_role":{"additionalProperties":{"type":"integer"},"type":"object","title":"Users By Role"}},"type":"object","required":["total_users","active_users","total_organizations","total_projects","total_servers","users_by_role"],"title":"PlatformStatsResponse","description":"Platform-wide statistics."},"PolicyAcceptanceCreate":{"properties":{"target_plan":{"type":"string","title":"Target Plan","description":"Plan slug user is upgrading to"},"billing_interval":{"type":"string","title":"Billing Interval","description":"'monthly' or 'annual'"},"b2b_acknowledged":{"type":"boolean","title":"B2B Acknowledged","description":"Customer ticked the B2B-purchase box"},"immediate_activation_acknowledged":{"type":"boolean","title":"Immediate Activation Acknowledged","description":"Customer ticked the immediate-activation/§356(5) BGB box"},"source":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Source","description":"UI entry point that initiated the upgrade (e.g., 'ribbon', 'over_quota_banner', 'feature_gate', 'interstitial')."},"variant":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Variant","description":"Copy variant displayed at the entry point, for Phase 2 A/B framework."}},"type":"object","required":["target_plan","billing_interval","b2b_acknowledged","immediate_activation_acknowledged"],"title":"PolicyAcceptanceCreate","description":"Body for POST /billing/policy-acceptance (interstitial recorder)."},"PolicyAcceptanceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"policy_version":{"type":"string","title":"Policy Version"},"policy_url":{"type":"string","title":"Policy Url"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","policy_version","policy_url","created_at"],"title":"PolicyAcceptanceResponse","description":"Returned from the interstitial recorder.\n\nFrontend threads `id` into the subsequent checkout-session-create call so\nthe metadata can carry it forward."},"PostgresOptimizationResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"tier":{"type":"string","enum":["development","production","high_availability"],"title":"Tier"},"enable_pgtune":{"type":"boolean","title":"Enable Pgtune"},"enable_pgbouncer":{"type":"boolean","title":"Enable Pgbouncer"},"enable_replica":{"type":"boolean","title":"Enable Replica"},"postgres_version":{"type":"string","title":"Postgres Version"},"postgres_config":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Postgres Config"},"pgbouncer_pool_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pgbouncer Pool Size"},"pgbouncer_pool_size_deployed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pgbouncer Pool Size Deployed"},"pgbouncer_pool_size_overridden":{"type":"boolean","title":"Pgbouncer Pool Size Overridden","default":false},"pgbouncer_pool_size_max":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pgbouncer Pool Size Max"},"supports_replica":{"type":"boolean","title":"Supports Replica"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version"},"db_host":{"type":"string","title":"Db Host"},"db_port":{"type":"integer","title":"Db Port"},"db_replica_host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Db Replica Host"},"db_replica_port":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Db Replica Port"},"replica_deployed":{"type":"boolean","title":"Replica Deployed","default":false},"plan_allows_pgtune":{"type":"boolean","title":"Plan Allows Pgtune","default":false},"plan_allows_pgbouncer":{"type":"boolean","title":"Plan Allows Pgbouncer","default":false},"plan_allows_replica":{"type":"boolean","title":"Plan Allows Replica","default":false}},"type":"object","required":["environment_id","tier","enable_pgtune","enable_pgbouncer","enable_replica","postgres_version","supports_replica","db_host","db_port"],"title":"PostgresOptimizationResponse","description":"Response showing PostgreSQL optimization status for an environment."},"PostgresOptimizationSettingsRequest":{"properties":{"postgres_version":{"anyOf":[{"type":"string","maxLength":10,"minLength":2},{"type":"null"}],"title":"Postgres Version","description":"PostgreSQL version override (e.g., '15', '16'). Leave null for automatic selection."},"enable_pgtune":{"type":"boolean","title":"Enable Pgtune","description":"Enable PGTune automatic PostgreSQL optimization","default":true},"enable_pgbouncer":{"type":"boolean","title":"Enable Pgbouncer","description":"Enable PgBouncer connection pooling","default":true},"enable_read_replica":{"type":"boolean","title":"Enable Read Replica","description":"Enable read replica (requires Odoo 18+)","default":false},"pgbouncer_pool_size":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":5.0},{"type":"null"}],"title":"Pgbouncer Pool Size","description":"Set the PgBouncer pool size by hand. It is kept across deploys and capped at what PostgreSQL allows. Takes effect on the next deploy."},"reset_pgbouncer_pool_size":{"type":"boolean","title":"Reset Pgbouncer Pool Size","description":"Drop a hand-set pool size and size the pool automatically again.","default":false}},"type":"object","title":"PostgresOptimizationSettingsRequest","description":"Request to update PostgreSQL optimization settings."},"PostgresOptimizationSettingsResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Version"},"enable_pgtune":{"type":"boolean","title":"Enable Pgtune"},"enable_pgbouncer":{"type":"boolean","title":"Enable Pgbouncer"},"enable_read_replica":{"type":"boolean","title":"Enable Read Replica"},"pgbouncer_pool_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pgbouncer Pool Size"},"pgbouncer_pool_size_overridden":{"type":"boolean","title":"Pgbouncer Pool Size Overridden","default":false},"message":{"type":"string","title":"Message"}},"type":"object","required":["environment_id","postgres_version","enable_pgtune","enable_pgbouncer","enable_read_replica","message"],"title":"PostgresOptimizationSettingsResponse","description":"Response after updating PostgreSQL optimization settings."},"PreflightCheckSeverity":{"type":"string","enum":["critical","warning","info"],"title":"PreflightCheckSeverity","description":"Severity level of a check result."},"PreflightCheckStatus":{"type":"string","enum":["passed","failed","warning","info","skipped"],"title":"PreflightCheckStatus","description":"Status of an individual preflight check."},"PreflightFixRequest":{"properties":{"action":{"$ref":"#/components/schemas/FixAction","description":"Fix action to execute"}},"type":"object","required":["action"],"title":"PreflightFixRequest","description":"Request to fix an issue."},"PreflightFixResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether fix succeeded"},"message":{"type":"string","title":"Message","description":"Result message"},"rerun_triggered":{"type":"boolean","title":"Rerun Triggered","description":"Whether preflight rerun was triggered","default":false}},"type":"object","required":["success","message"],"title":"PreflightFixResponse","description":"Response from a fix operation."},"PreflightHistoryDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"History record ID"},"triggered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Triggered By","description":"Email of user who triggered"},"trigger_type":{"$ref":"#/components/schemas/PreflightTrigger","description":"Trigger type"},"started_at":{"type":"string","format":"date-time","title":"Started At","description":"When started"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When completed"},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds","description":"Duration in seconds"},"status":{"$ref":"#/components/schemas/PreflightRunStatus","description":"Run status"},"qualification_result":{"anyOf":[{"$ref":"#/components/schemas/VMQualificationStatus"},{"type":"null"}],"description":"Resulting qualification"},"checks_passed":{"type":"integer","title":"Checks Passed","description":"Passed checks count","default":0},"checks_failed":{"type":"integer","title":"Checks Failed","description":"Failed checks count","default":0},"checks_warning":{"type":"integer","title":"Checks Warning","description":"Warning checks count","default":0},"total_checks":{"type":"integer","title":"Total Checks","description":"Total checks count","default":0},"checks_skipped":{"type":"integer","title":"Checks Skipped","description":"Skipped checks count","default":0},"report":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Report","description":"Full report JSON"},"os_snapshot":{"anyOf":[{"$ref":"#/components/schemas/OSInfo"},{"type":"null"}],"description":"OS info at check time"}},"type":"object","required":["id","trigger_type","started_at","status"],"title":"PreflightHistoryDetail","description":"Full details of a preflight history record."},"PreflightHistoryListItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"History record ID"},"triggered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Triggered By","description":"Email of user who triggered"},"trigger_type":{"$ref":"#/components/schemas/PreflightTrigger","description":"Trigger type"},"started_at":{"type":"string","format":"date-time","title":"Started At","description":"When started"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When completed"},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds","description":"Duration in seconds"},"status":{"$ref":"#/components/schemas/PreflightRunStatus","description":"Run status"},"qualification_result":{"anyOf":[{"$ref":"#/components/schemas/VMQualificationStatus"},{"type":"null"}],"description":"Resulting qualification"},"checks_passed":{"type":"integer","title":"Checks Passed","description":"Passed checks count","default":0},"checks_failed":{"type":"integer","title":"Checks Failed","description":"Failed checks count","default":0},"checks_warning":{"type":"integer","title":"Checks Warning","description":"Warning checks count","default":0}},"type":"object","required":["id","trigger_type","started_at","status"],"title":"PreflightHistoryListItem","description":"Summary item for preflight history list."},"PreflightHistoryListResponse":{"properties":{"total":{"type":"integer","title":"Total","description":"Total history records"},"items":{"items":{"$ref":"#/components/schemas/PreflightHistoryListItem"},"type":"array","title":"Items","description":"History items"}},"type":"object","required":["total","items"],"title":"PreflightHistoryListResponse","description":"Paginated history list response."},"PreflightRunRequest":{"properties":{"checks":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Checks","description":"Specific checks to run (all if not specified)","examples":[["docker","resources"]]},"trigger_type":{"$ref":"#/components/schemas/PreflightTrigger","description":"What triggered this check","default":"manual"}},"type":"object","title":"PreflightRunRequest","description":"Request to run preflight checks."},"PreflightRunStatus":{"type":"string","enum":["running","completed","failed","cancelled"],"title":"PreflightRunStatus","description":"Status of a preflight run."},"PreflightStatusResponse":{"properties":{"qualification_status":{"$ref":"#/components/schemas/VMQualificationStatus","description":"Current qualification status"},"last_check":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Check","description":"Last check timestamp"},"run_count":{"type":"integer","title":"Run Count","description":"Total number of preflight runs","default":0},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"When qualification expires"},"is_stale":{"type":"boolean","title":"Is Stale","description":"Whether status is stale (>7 days)","default":false},"is_expired":{"type":"boolean","title":"Is Expired","description":"Whether status is expired (>30 days)","default":false},"os_info":{"anyOf":[{"$ref":"#/components/schemas/OSInfo"},{"type":"null"}],"description":"Detected OS info"},"docker_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Docker Version","description":"Installed Docker version"},"fixable_issues":{"items":{"$ref":"#/components/schemas/FixAction"},"type":"array","title":"Fixable Issues","description":"Fixable issues"},"last_checks":{"items":{"$ref":"#/components/schemas/CheckResult"},"type":"array","title":"Last Checks","description":"Check results from last run"},"last_summary":{"anyOf":[{"$ref":"#/components/schemas/CheckSummary"},{"type":"null"}],"description":"Summary from last run"}},"type":"object","required":["qualification_status"],"title":"PreflightStatusResponse","description":"Current preflight status of a VM."},"PreflightTrigger":{"type":"string","enum":["manual","auto_fix","pre_deploy","scheduled","reconnect"],"title":"PreflightTrigger","description":"What triggered the preflight check."},"PricingResponse":{"properties":{"base_plans":{"items":{"$ref":"#/components/schemas/PlanQuotaResponse"},"type":"array","title":"Base Plans","description":"Base subscription plans"},"byos_tiers":{"items":{"type":"object"},"type":"array","title":"Byos Tiers","description":"BYOS server tier pricing"},"environment_sizes":{"items":{"type":"object"},"type":"array","title":"Environment Sizes","description":"Platform environment size pricing"},"addons":{"items":{"type":"object"},"type":"array","title":"Addons","description":"Add-on pricing"}},"type":"object","required":["base_plans","byos_tiers","environment_sizes","addons"],"title":"PricingResponse","description":"Current pricing details.","example":{}},"ProjectAccessInfo":{"properties":{"project_id":{"type":"string","title":"Project Id","description":"Project ID"},"project_name":{"type":"string","title":"Project Name","description":"Project name"},"role":{"type":"string","title":"Role","description":"Role within project"}},"type":"object","required":["project_id","project_name","role"],"title":"ProjectAccessInfo","description":"Info about project access granted.","example":{}},"ProjectAdditionalRepoCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Repository display name"},"slug":{"type":"string","maxLength":100,"minLength":1,"title":"Slug","description":"URL-friendly identifier"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description","description":"Repository description"},"git_provider":{"$ref":"#/components/schemas/schemas__git_connection__GitProvider","description":"Git provider (github/gitlab)"},"git_repo_url":{"type":"string","maxLength":512,"title":"Git Repo Url","description":"Git repository URL"},"git_branch":{"type":"string","maxLength":100,"title":"Git Branch","description":"Git branch to use","default":"main"},"is_public":{"type":"boolean","title":"Is Public","description":"Whether repository is public","default":false},"connection_type":{"$ref":"#/components/schemas/ConnectionType","description":"Type of Git connection to use","default":"public"},"connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connection Id","description":"ID of the Git connection (depends on connection_type)"},"requirements_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Requirements Txt Path","default":"requirements.txt"},"apt_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Apt Txt Path","default":"apt.txt"},"install_dependencies":{"type":"boolean","title":"Install Dependencies","default":true},"priority":{"type":"integer","maximum":1000.0,"minimum":0.0,"title":"Priority","default":100},"environment_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Environment Ids","description":"Optional allowlist of active environment IDs this repo applies to. Empty = applies to every active environment.","default":[]}},"type":"object","required":["name","slug","git_provider","git_repo_url"],"title":"ProjectAdditionalRepoCreate","description":"Schema for creating a project additional repo.","example":{}},"ProjectAdditionalRepoResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"name":{"type":"string","title":"Name","description":"Repository display name"},"slug":{"type":"string","title":"Slug","description":"URL-friendly identifier"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Repository description"},"source_type":{"$ref":"#/components/schemas/AddonSourceType","description":"How this addon's code is sourced: 'git' (cloned) or 'upload' (archive upload)"},"git_provider":{"anyOf":[{"$ref":"#/components/schemas/GitProvider-Output"},{"type":"null"}],"description":"Git provider"},"git_repo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Repo Url","description":"Git repository URL"},"git_branch":{"type":"string","title":"Git Branch","description":"Git branch"},"is_public":{"type":"boolean","title":"Is Public","description":"Whether repository is public"},"upload_original_filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Upload Original Filename","description":"Original filename of the uploaded addon archive"},"upload_size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Upload Size Bytes","description":"Size in bytes of the uploaded (sanitised) addon archive"},"upload_content_sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Upload Content Sha256","description":"SHA256 checksum of the uploaded addon archive contents"},"connection_type":{"$ref":"#/components/schemas/ConnectionType","description":"Connection type"},"connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connection Id","description":"Git connection ID"},"requirements_txt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requirements Txt Path","description":"Path to requirements.txt"},"apt_txt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Apt Txt Path","description":"Path to apt.txt"},"install_dependencies":{"type":"boolean","title":"Install Dependencies","description":"Install dependencies flag"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether repository is active"},"priority":{"type":"integer","title":"Priority","description":"Load priority"},"create_date":{"type":"string","format":"date-time","title":"Create Date","description":"Creation timestamp"},"write_date":{"type":"string","format":"date-time","title":"Write Date","description":"Last update timestamp"},"environment_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Environment Ids","description":"Active environment IDs this repo currently applies to (active envs minus its excluded set; all active envs if never restricted)."}},"type":"object","required":["id","project_id","name","slug","description","source_type","git_provider","git_repo_url","git_branch","is_public","connection_type","connection_id","requirements_txt_path","apt_txt_path","install_dependencies","is_active","priority","create_date","write_date"],"title":"ProjectAdditionalRepoResponse","description":"Schema for project additional repo response.\n\nShared by both git-cloned and upload-sourced project additional repos\n(see ``source_type``) — the git_* fields are populated only for\n``source_type == \"git\"``; the upload_* fields only for\n``source_type == \"upload\"`` (mirrors the model's own\n``ck_addon_source_git_or_upload`` CHECK constraint).","example":{}},"ProjectAdditionalRepoUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Slug"},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Description"},"git_repo_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Git Repo Url"},"git_branch":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Git Branch"},"is_public":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Public"},"connection_type":{"anyOf":[{"$ref":"#/components/schemas/ConnectionType"},{"type":"null"}]},"connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Connection Id"},"requirements_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Requirements Txt Path"},"apt_txt_path":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Apt Txt Path"},"install_dependencies":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Install Dependencies"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"priority":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":0.0},{"type":"null"}],"title":"Priority"}},"type":"object","title":"ProjectAdditionalRepoUpdate","description":"Schema for updating a project additional repo.","example":{}},"ProjectAddonSelectionsResponse":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"platform_repos":{"items":{"$ref":"#/components/schemas/AvailableAddonRepo"},"type":"array","title":"Platform Repos","description":"Platform addon repos with selection status","default":[]},"organization_repos":{"items":{"$ref":"#/components/schemas/AvailableAddonRepo"},"type":"array","title":"Organization Repos","description":"Organization addon repos with selection status","default":[]}},"type":"object","required":["project_id"],"title":"ProjectAddonSelectionsResponse","description":"Response for project addon selections.","example":{}},"ProjectCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name","description":"Project name"},"slug":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Slug","description":"URL-friendly slug (auto-generated if not provided)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Project description"},"odoo_version":{"type":"string","title":"Odoo Version","description":"Odoo version (validated against the catalog)"},"repository_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Url","description":"Git repository URL"},"default_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Branch","description":"Default git branch"},"repository_provider":{"anyOf":[{"$ref":"#/components/schemas/GitProvider"},{"type":"null"}],"description":"Git provider"},"git_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Git Connection Id","description":"Organization Git connection that owns this repository"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization ID (optional - will use default org)"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM to deploy to"},"odoo_image_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Odoo Image Id","description":"Selected odoo_versions catalog row (#909). Server-validated as a selectable, non-EOL row. NULL uses the version-derived default."}},"type":"object","required":["name","odoo_version"],"title":"ProjectCreate","description":"Schema for creating a project.","example":{}},"ProjectCreateResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","title":"Name","description":"Project name"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug","description":"URL-friendly slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Project description"},"odoo_version":{"type":"string","title":"Odoo Version","description":"Odoo version"},"odoo_image_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Odoo Image Id","description":"Selected catalog image row (#909); None inherits the version default"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization name"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM ID"},"status":{"type":"string","title":"Status","description":"Project status"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Custom domain"},"settings":{"type":"object","title":"Settings","description":"Project settings"},"repository_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Url","description":"Git repository URL"},"repository_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Provider","description":"Git provider"},"default_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Branch","description":"Default git branch"},"webhook_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Id","description":"ID of the registered webhook in GitHub/GitLab"},"enable_dev_mode":{"type":"boolean","title":"Enable Dev Mode","description":"Whether AI dev mode is enabled","default":false},"dev_sidecar_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Dev Sidecar Vm Id","description":"VM running the dev sidecar"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Created timestamp"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Updated timestamp"},"webhook_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Secret","description":"Webhook secret for HMAC signature verification"}},"type":"object","required":["id","name","odoo_version","organization_id","status"],"title":"ProjectCreateResponse","description":"The response to creating a project: the one time the webhook secret is\nreturned with the project, so the client can register the webhook.","example":{}},"ProjectDomainCreate":{"properties":{"domain":{"type":"string","maxLength":255,"minLength":4,"title":"Domain","description":"Custom domain (e.g., 'erp.acme-corp.com')"}},"type":"object","required":["domain"],"title":"ProjectDomainCreate","description":"Request to add a custom domain to an environment.","example":{}},"ProjectDomainListResponse":{"properties":{"system_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"System Url","description":"Auto-generated system URL"},"domains":{"items":{"$ref":"#/components/schemas/ProjectDomainResponse"},"type":"array","title":"Domains"},"custom_domain":{"anyOf":[{"$ref":"#/components/schemas/EnvironmentCustomDomainState"},{"type":"null"}],"description":"Environment-level custom_domain state (null when unset)"},"new_domain_target":{"type":"string","title":"New Domain Target","description":"#1163: DNS target for a domain added to this environment now (the environment's own host, or the Cloudflare for SaaS target). Empty when unknown; the UI then falls back to its own guess.","default":""}},"type":"object","required":["system_url"],"title":"ProjectDomainListResponse","description":"Response listing all domains for an environment.","example":{}},"ProjectDomainResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"domain":{"type":"string","title":"Domain"},"root_domain":{"type":"string","title":"Root Domain"},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_primary":{"type":"boolean","title":"Is Primary","default":false},"is_system":{"type":"boolean","title":"Is System","description":"True for the platform's auto-generated subdomain (e.g. <env>.apps.oec.sh). System subdomains cannot be removed by the customer — they're the platform's fallback routing target.","default":false},"verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Verified At"},"ssl_enabled":{"type":"boolean","title":"Ssl Enabled","default":false},"ssl_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssl Provider"},"ssl_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ssl Expires At"},"dns_propagated":{"type":"boolean","title":"Dns Propagated","default":false},"last_dns_check_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Dns Check At"},"verification_target":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Target","description":"CNAME target for DNS verification"},"instructions":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instructions","description":"DNS setup instructions"},"verification_txt_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Txt Name","description":"Name of the TXT record proving control of the domain (e.g. _oecsh-verify.erp.acme.com)"},"verification_txt_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Verification Txt Value","description":"Value the TXT record must contain"},"cf_hostname_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Hostname Id","description":"Cloudflare for SaaS custom hostname ID (present when CF SaaS is active)"},"deactivated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deactivated At","description":"#961: when is_active was set False, if known"},"deactivation_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deactivation Reason","description":"#961: why is_active was set False (e.g. 'subscription_lapsed'); only present for cleanup-caused removals"},"redirect_to_domain_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Redirect To Domain Id","description":"#1072: domain this one 301-redirects to, if any (e.g. www -> apex). Set/cleared via PATCH /api/v1/dns/domains/{domain_id}, not this router — both operate on the same project_domains row."}},"type":"object","required":["id","domain","root_domain"],"title":"ProjectDomainResponse","description":"Response for a ProjectDomain record.","example":{}},"ProjectEnvironmentCreate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Environment name (auto-generated if not provided)"},"env_type":{"$ref":"#/components/schemas/EnvironmentType","description":"Environment type"},"repository_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Url","description":"Git repo URL override for this environment"},"git_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Branch","description":"Git branch for this environment"},"odoo_image_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Odoo Image Id","description":"Selected odoo_versions catalog row for this env (#909), overriding the project's. Server-validated as selectable/non-EOL. NULL inherits."},"template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Template Id","description":"Deployment template used to pre-fill this environment"},"migration_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Migration Id","description":"Migration to restore from (if migrating)"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM/Server to deploy this environment to"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Custom domain"},"subdomain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subdomain","description":"Subdomain on oec.sh"},"port":{"type":"integer","maximum":65535.0,"minimum":1.0,"title":"Port","description":"Odoo HTTP port","default":8069},"db_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Db Name","description":"Database name"},"auto_deploy":{"type":"boolean","title":"Auto Deploy","description":"Auto-deploy on git push (legacy)","default":false},"auto_deploy_config":{"anyOf":[{"$ref":"#/components/schemas/AutoDeployConfig"},{"type":"null"}],"description":"Advanced auto-deployment configuration with branch patterns, cooldown, and path filters"},"environment_vars":{"type":"object","title":"Environment Vars","description":"Environment variables"},"odoo_config":{"anyOf":[{"$ref":"#/components/schemas/OdooConfig"},{"type":"null"}],"description":"Odoo configuration overrides"},"cpu_cores":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.25},{"type":"string"},{"type":"null"}],"title":"Cpu Cores","description":"Total CPU cores allocated"},"ram_mb":{"anyOf":[{"type":"integer","maximum":131072.0,"minimum":256.0},{"type":"null"}],"title":"Ram Mb","description":"Total RAM in MB"},"disk_gb":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Disk Gb","description":"Disk space in GB"},"postgres_cpu_cores":{"anyOf":[{"type":"number","maximum":16.0,"minimum":0.1},{"type":"string"},{"type":"null"}],"title":"Postgres Cpu Cores","description":"PostgreSQL CPU cores (auto-calculated as 30% of total if not set)"},"postgres_ram_mb":{"anyOf":[{"type":"integer","maximum":65536.0,"minimum":128.0},{"type":"null"}],"title":"Postgres Ram Mb","description":"PostgreSQL RAM in MB (auto-calculated as 30% of total if not set)"},"postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Version","description":"PostgreSQL version override (e.g., '15', '16'). Auto-detected if not set."},"enable_pgtune":{"type":"boolean","title":"Enable Pgtune","description":"Enable PGTune automatic PostgreSQL optimization","default":true},"enable_pgbouncer":{"type":"boolean","title":"Enable Pgbouncer","description":"Enable PgBouncer connection pooling","default":true},"enable_read_replica":{"type":"boolean","title":"Enable Read Replica","description":"Enable PostgreSQL read replica (requires Odoo 18+)","default":false},"with_demo_data":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"With Demo Data","description":"Load demo data into the database. If None, auto-determined by env_type: development=True, staging/production=False. Explicitly setting True/False overrides this behavior."},"language":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Language","description":"Odoo locale code for the database (e.g. 'fr_FR', 'es_ES'). Passed as --load-language to odoo -i base at init time. NULL / absent = en_US (English, no flag needed)."},"locale":{"anyOf":[{"type":"string","enum":["en_US","de_DE","fr_FR","es_ES","pt_BR","nl_NL","it_IT","pl_PL","hi_IN","ar_001"]},{"type":"null"}],"title":"Locale","description":"Closed-allowlist locale code for Odoo DB init. Same intent as `language` but enum-validated. When set, takes precedence over `language`. Whitelist defends against shell injection at the schema layer."},"load_demo_data":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Load Demo Data","description":"Whether to load Odoo demo data. When None, the route picks the default based on the selected server: demo VMs default to True, regular envs follow env_type semantics (dev=True, stg/prod=False)."},"subdomain_slug":{"anyOf":[{"type":"string","maxLength":32,"minLength":3,"pattern":"^[a-z0-9][a-z0-9-]{1,30}[a-z0-9]$"},{"type":"null"}],"title":"Subdomain Slug","description":"Vanity subdomain for a demo deploy (e.g. 'acme-demo'). Only used when the selected server has domain_pattern='vanity'. Validated against the 30-day reservation table by the route."},"captcha_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Captcha Token","description":"Cloudflare Turnstile token for demo deploys. Required when the selected server has is_demo=true; ignored otherwise."},"external_database_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"External Database Connection Id","description":"ID of the ExternalDatabaseConnection to use as the primary database cluster. If set, the platform does NOT deploy a PostgreSQL container. Requires Pro plan or higher."},"external_database_name":{"anyOf":[{"type":"string","maxLength":63},{"type":"null"}],"title":"External Database Name","description":"Database name on the external cluster. Must match ^[a-z0-9_-]{1,63}$. Defaults to a sanitised environment UUID when omitted."}},"type":"object","required":["env_type"],"title":"ProjectEnvironmentCreate","description":"Schema for creating a project environment.","example":{}},"ProjectEnvironmentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","title":"Name","description":"Environment name"},"environment_type":{"type":"string","title":"Environment Type","description":"Environment type"},"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM/Server ID"},"odoo_image_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Odoo Image Id","description":"Selected catalog image row (#909); None inherits the project image"},"migration_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Migration Id","description":"Migration this environment was created from"},"migration_restore_completed":{"type":"boolean","title":"Migration Restore Completed","description":"Whether migration backup has been restored (prevents re-restore on redeploy)","default":false},"migration_restore_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Migration Restore Completed At","description":"When the migration restore was first completed"},"repository_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Url","description":"Git repo URL override"},"git_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Branch","description":"Git branch"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Custom domain"},"subdomain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subdomain","description":"Subdomain on oec.sh"},"port":{"type":"integer","title":"Port","description":"Odoo HTTP port","default":8069},"system_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"System Url","description":"System-generated URL (https://{subdomain}.apps.oecsh.com)"},"custom_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Domain","description":"User-provided custom domain"},"custom_domain_verified":{"type":"boolean","title":"Custom Domain Verified","description":"Whether custom domain DNS is verified","default":false},"custom_domain_ssl_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Domain Ssl Status","description":"SSL provisioning status for custom domain"},"primary_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Url","description":"Primary accessible URL (custom if verified, else system)"},"agency_subdomain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agency Subdomain","description":"Subdomain for agency domain (e.g., 'client1' -> client1.acmecloud.io)"},"agency_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agency Url","description":"Full agency domain URL if configured"},"container_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Container Id","description":"Docker container ID"},"container_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Container Name","description":"Docker container name"},"db_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Db Name","description":"Database name"},"status":{"type":"string","title":"Status","description":"Environment status","default":"pending"},"status_reason":{"anyOf":[{"$ref":"#/components/schemas/EnvironmentStatusReason"},{"type":"null"}],"description":"Why the environment is in its current status (error, or running on an unreachable server)"},"queued_clones":{"type":"integer","title":"Queued Clones","description":"Clones of this environment or into it that have not started","default":0},"is_active":{"type":"boolean","title":"Is Active","description":"Whether environment is active","default":true},"auto_deploy":{"type":"boolean","title":"Auto Deploy","description":"Auto-deploy on git push (legacy)","default":false},"auto_deploy_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Auto Deploy Config","description":"Advanced auto-deployment configuration. Always the RESOLVED config — for environments still on the legacy auto_deploy flag this is derived rather than null, so the dashboard shows what a git push will actually do."},"last_deployed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Deployed At","description":"Last deployment timestamp"},"last_deployment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Last Deployment Id","description":"Last deployment ID"},"running_image":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Running Image","description":"Image reference the running container was created from"},"running_image_digest":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Running Image Digest","description":"Resolved digest of the running image (odoo@sha256:...)"},"running_image_recorded_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Running Image Recorded At","description":"When the running image was last observed"},"environment_vars":{"type":"object","title":"Environment Vars","description":"Environment variables"},"settings":{"type":"object","title":"Settings","description":"Additional settings"},"odoo_config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Odoo Config","description":"Odoo configuration overrides"},"applied_odoo_config_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Applied Odoo Config Hash"},"config_management_mode":{"type":"string","enum":["platform_managed","hand_crafted"],"title":"Config Management Mode","default":"platform_managed"},"odoo_admin_password_available":{"type":"boolean","title":"Odoo Admin Password Available","default":false},"cpu_cores":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cpu Cores","description":"Total CPU cores allocated"},"ram_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ram Mb","description":"Total RAM in MB"},"disk_gb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Disk Gb","description":"Disk space in GB"},"postgres_cpu_cores":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Cpu Cores","description":"PostgreSQL CPU cores (auto-calculated as 30% of total)"},"postgres_ram_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Postgres Ram Mb","description":"PostgreSQL RAM in MB (auto-calculated as 30% of total)"},"odoo_cpu_cores":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Cpu Cores","description":"Odoo CPU cores (computed: total - postgres)"},"odoo_ram_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Odoo Ram Mb","description":"Odoo RAM in MB (computed: total - postgres)"},"postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Version","description":"PostgreSQL major version (e.g. '15', '16', '17'). None = auto-detect for the Odoo version."},"enable_pgtune":{"type":"boolean","title":"Enable Pgtune","description":"PGTune-tuned postgresql.conf is applied during deploy","default":true},"enable_pgbouncer":{"type":"boolean","title":"Enable Pgbouncer","description":"PgBouncer connection pool is deployed alongside Postgres","default":false},"enable_read_replica":{"type":"boolean","title":"Enable Read Replica","description":"PostgreSQL read replica deployed (Odoo 18+ only)","default":false},"with_demo_data":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"With Demo Data","description":"Demo data flag at init time. None = auto-decide from env_type."},"create_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Create Date","description":"Created timestamp"},"write_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Write Date","description":"Updated timestamp"},"resolved_addons_paths":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Resolved Addons Paths","description":"Auto-discovered addons paths from last deploy scan"},"custom_addons_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Addons Path","description":"User-specified custom addons_path override"},"cloned_from":{"anyOf":[{"$ref":"#/components/schemas/ClonedFromInfo"},{"type":"null"}],"description":"Information about source environment if this was cloned"},"odoo_image":{"anyOf":[{"$ref":"#/components/schemas/OdooImageInfo"},{"type":"null"}],"description":"Odoo version plus deployed/configured image details for the overview."},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language","description":"Odoo locale code this environment was initialized with. NULL = en_US."},"external_database_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"External Database Connection Id","description":"External database connection ID (None = platform-managed PostgreSQL)."},"external_database_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Database Name","description":"Database name on the external cluster."},"external_database":{"anyOf":[{"$ref":"#/components/schemas/ExternalDatabaseSummary"},{"type":"null"}],"description":"Linked external database connection summary (None = platform-managed PostgreSQL)."},"is_demo":{"type":"boolean","title":"Is Demo","description":"Marks env as demo-tier (controls billing, quota, retention)","default":false},"demo_ttl_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Demo Ttl Expires At","description":"Timestamp the demo cron will destroy this env at (None for non-demo envs)"},"demo_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Demo Provider","description":"Demo backing provider. NULL for v2 containers, 'hetzner_ephemeral' for v3 VMs."},"pending_restart":{"type":"boolean","title":"Pending Restart","description":"True when odoo_config has been changed since last successful Restart applied it.","readOnly":true},"maintenance_active":{"type":"boolean","title":"Maintenance Active","description":"#1335: a maintenance page is up (its record exists and has not expired).","readOnly":true},"maintenance_page_available":{"type":"boolean","title":"Maintenance Page Available","description":"#1335: a Quick Update on this environment's server can show the page (flag\non for it, not a hand-run server, module updates not sent to the VM runner),\nso its setting is worth showing. Config only, no I/O.","readOnly":true},"maintenance_page":{"type":"boolean","title":"Maintenance Page","description":"#1335: the environment's maintenance page setting (on unless turned off).","readOnly":true}},"type":"object","required":["id","name","environment_type","project_id","pending_restart","maintenance_active","maintenance_page_available","maintenance_page"],"title":"ProjectEnvironmentResponse","description":"Schema for project environment response.","example":{}},"ProjectEnvironmentUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Environment name"},"environment_type":{"$ref":"#/components/schemas/EnvironmentType","description":"development, staging or production. Odoo settings that depend on the type (workers, time limits, ODOO_STAGE) apply on the next deploy."},"odoo_image_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Odoo Image Id","description":"#1018: a selectable build of the environment's Odoo version; null returns it to the project's image. Takes effect on the next deploy or Update now."},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM/Server assignment"},"repository_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Url","description":"Git repo URL override"},"git_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Branch","description":"Git branch"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Custom domain"},"subdomain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subdomain","description":"Subdomain"},"port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Port","description":"Odoo HTTP port"},"db_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Db Name","description":"Database name"},"auto_deploy":{"type":"boolean","title":"Auto Deploy","description":"Auto-deploy on git push (legacy)","default":false},"auto_deploy_config":{"anyOf":[{"$ref":"#/components/schemas/AutoDeployConfig"},{"type":"object"},{"type":"null"}],"title":"Auto Deploy Config","description":"Advanced auto-deployment configuration"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Whether environment is active"},"environment_vars":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Environment Vars","description":"Environment variables"},"settings":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Settings","description":"Additional settings"},"odoo_config":{"anyOf":[{"$ref":"#/components/schemas/OdooConfig"},{"type":"object"},{"type":"null"}],"title":"Odoo Config","description":"Odoo configuration overrides"},"cpu_cores":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.25},{"type":"string"},{"type":"null"}],"title":"Cpu Cores","description":"Total CPU cores"},"ram_mb":{"anyOf":[{"type":"integer","maximum":131072.0,"minimum":256.0},{"type":"null"}],"title":"Ram Mb","description":"Total RAM in MB"},"disk_gb":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Disk Gb","description":"Disk in GB"},"postgres_cpu_cores":{"anyOf":[{"type":"number","maximum":16.0,"minimum":0.1},{"type":"string"},{"type":"null"}],"title":"Postgres Cpu Cores","description":"PostgreSQL CPU cores (auto-calculated as 30% of total if not set)"},"postgres_ram_mb":{"anyOf":[{"type":"integer","maximum":65536.0,"minimum":128.0},{"type":"null"}],"title":"Postgres Ram Mb","description":"PostgreSQL RAM in MB (auto-calculated as 30% of total if not set)"},"external_database_name":{"anyOf":[{"type":"string","maxLength":63},{"type":"null"}],"title":"External Database Name","description":"Database name on the external cluster (read-only after first deploy)."}},"type":"object","title":"ProjectEnvironmentUpdate","description":"Schema for updating a project environment.","example":{}},"ProjectInfo":{"properties":{"id":{"type":"string","title":"Id","description":"Project ID"},"name":{"type":"string","title":"Name","description":"Project name"},"slug":{"type":"string","title":"Slug","description":"Project slug"}},"type":"object","required":["id","name","slug"],"title":"ProjectInfo","description":"Brief project info for invitation response.","example":{}},"ProjectListItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","title":"Name","description":"Project name"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug","description":"URL-friendly slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Project description"},"odoo_version":{"type":"string","title":"Odoo Version","description":"Odoo version"},"odoo_image_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Odoo Image Id","description":"Selected catalog image row (#909); None inherits the version default"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization name"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM ID"},"status":{"type":"string","title":"Status","description":"Project status"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Custom domain"},"settings":{"type":"object","title":"Settings","description":"Project settings"},"repository_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Url","description":"Git repository URL"},"repository_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Provider","description":"Git provider"},"default_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Branch","description":"Default git branch"},"webhook_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Id","description":"ID of the registered webhook in GitHub/GitLab"},"enable_dev_mode":{"type":"boolean","title":"Enable Dev Mode","description":"Whether AI dev mode is enabled","default":false},"dev_sidecar_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Dev Sidecar Vm Id","description":"VM running the dev sidecar"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Created timestamp"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Updated timestamp"},"environment_count":{"type":"integer","title":"Environment Count","description":"Total number of environments","default":0},"running_environment_count":{"type":"integer","title":"Running Environment Count","description":"Number of running environments","default":0},"total_cpu_cores":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Total Cpu Cores","description":"Total CPU cores allocated"},"total_ram_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Ram Mb","description":"Total RAM allocated in MB"},"total_disk_gb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Disk Gb","description":"Total disk allocated in GB"},"computed_status":{"type":"string","title":"Computed Status","description":"Computed status based on environment states (running, partial, stopped, pending)","default":"pending"},"last_deployed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Deployed At","description":"Most recent deployment timestamp across all environments"}},"type":"object","required":["id","name","odoo_version","organization_id","status"],"title":"ProjectListItemResponse","description":"Extended project response for list view with summary statistics.","example":{}},"ProjectMemberListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ProjectMemberResponse"},"type":"array","title":"Items","description":"List of project members"},"total":{"type":"integer","title":"Total","description":"Total number of members"}},"type":"object","required":["items","total"],"title":"ProjectMemberListResponse","description":"Response for listing project members.","example":{}},"ProjectMemberResponse":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id","description":"User ID"},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email","description":"User email"},"user_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Name","description":"User display name"},"role":{"type":"string","title":"Role","description":"Effective role (highest from all teams)"},"source":{"type":"string","title":"Source","description":"Access source: 'org_owner' or 'team'"},"teams":{"items":{"$ref":"#/components/schemas/ProjectMemberTeam"},"type":"array","title":"Teams","description":"Teams granting access to this project"}},"type":"object","required":["user_id","user_email","user_name","role","source"],"title":"ProjectMemberResponse","description":"Schema for a user with access to a project.","example":{}},"ProjectMemberTeam":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Team ID"},"name":{"type":"string","title":"Name","description":"Team name"},"color":{"type":"string","title":"Color","description":"Team color"},"role":{"type":"string","title":"Role","description":"Role via this team"}},"type":"object","required":["id","name","color","role"],"title":"ProjectMemberTeam","description":"Team info for a project member.","example":{}},"ProjectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","title":"Name","description":"Project name"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug","description":"URL-friendly slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Project description"},"odoo_version":{"type":"string","title":"Odoo Version","description":"Odoo version"},"odoo_image_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Odoo Image Id","description":"Selected catalog image row (#909); None inherits the version default"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization name"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM ID"},"status":{"type":"string","title":"Status","description":"Project status"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Custom domain"},"settings":{"type":"object","title":"Settings","description":"Project settings"},"repository_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Url","description":"Git repository URL"},"repository_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Provider","description":"Git provider"},"default_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Branch","description":"Default git branch"},"webhook_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Webhook Id","description":"ID of the registered webhook in GitHub/GitLab"},"enable_dev_mode":{"type":"boolean","title":"Enable Dev Mode","description":"Whether AI dev mode is enabled","default":false},"dev_sidecar_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Dev Sidecar Vm Id","description":"VM running the dev sidecar"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"Created timestamp"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"Updated timestamp"}},"type":"object","required":["id","name","odoo_version","organization_id","status"],"title":"ProjectResponse","description":"Schema for project response.","example":{}},"ProjectRole":{"type":"string","enum":["admin","developer","viewer"],"title":"ProjectRole","description":"Project-level roles for granular access control.\n\nUsed when inviting users to specific projects (not org-wide)."},"ProjectSnapshotInfo":{"properties":{"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id","description":"Project ID at backup time"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Project name at backup time"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug","description":"Project slug at backup time"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version","description":"Odoo version at backup time"}},"type":"object","title":"ProjectSnapshotInfo","description":"Project info from backup snapshot.","example":{}},"ProjectStatus":{"type":"string","enum":["pending","creating","active","deploying","running","stopped","error","deleted","archived"],"title":"ProjectStatus","description":"Project status states.\n\nNOTE: Values MUST be lowercase to match PostgreSQL enum type 'projectstatus'."},"ProjectTeamCreate":{"properties":{"team_id":{"type":"string","format":"uuid","title":"Team Id","description":"ID of the team to assign"},"role":{"$ref":"#/components/schemas/TeamRole","description":"Role the team has on the project","default":"developer"}},"type":"object","required":["team_id"],"title":"ProjectTeamCreate","description":"Schema for assigning a team to a project.","example":{}},"ProjectTeamListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ProjectTeamResponse"},"type":"array","title":"Items","description":"List of team assignments"},"total":{"type":"integer","title":"Total","description":"Total number of team assignments"}},"type":"object","required":["items","total"],"title":"ProjectTeamListResponse","description":"Response for listing teams assigned to a project.","example":{}},"ProjectTeamResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Project-team assignment ID"},"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"team_id":{"type":"string","format":"uuid","title":"Team Id","description":"Team ID"},"team_name":{"type":"string","title":"Team Name","description":"Team name (from relationship)"},"team_color":{"type":"string","title":"Team Color","description":"Team color (from relationship)","default":"blue"},"role":{"type":"string","title":"Role","description":"Team's role on the project"},"assigned_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned By","description":"User who assigned the team"},"assigned_at":{"type":"string","format":"date-time","title":"Assigned At","description":"When the team was assigned"},"member_count":{"type":"integer","title":"Member Count","description":"Number of members in the team","default":0}},"type":"object","required":["id","project_id","team_id","team_name","role","assigned_at"],"title":"ProjectTeamResponse","description":"Schema for team assignment on a project.","example":{}},"ProjectTeamUpdate":{"properties":{"role":{"$ref":"#/components/schemas/TeamRole","description":"New role for the team on the project"}},"type":"object","required":["role"],"title":"ProjectTeamUpdate","description":"Schema for updating a team's role on a project.","example":{}},"ProjectUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"repository_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Url","description":"Git repository URL"},"default_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Branch","description":"Default git branch"},"repository_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repository Provider","description":"Git provider"},"git_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Git Connection Id","description":"Organization Git connection that owns this repository"},"settings":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Settings"}},"type":"object","title":"ProjectUpdate","description":"Schema for updating a project.","example":{}},"PromoteActionConfig":{"properties":{"action_type":{"type":"string","const":"promote","title":"Action Type","default":"promote"},"source_env_id":{"type":"string","format":"uuid","title":"Source Env Id","description":"Staging/source environment to promote from."},"target_env_id":{"type":"string","format":"uuid","title":"Target Env Id","description":"Production/target environment to promote to."}},"type":"object","required":["source_env_id","target_env_id"],"title":"PromoteActionConfig","description":"Configuration for a promote (staging → production) action."},"ProviderAuthConfig":{"properties":{"auth_type":{"$ref":"#/components/schemas/CloudAuthType","description":"Authentication type"},"console_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Console Url","description":"Provider console URL"},"docs_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Docs Url","description":"Provider docs URL"},"steps":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Steps","description":"Setup steps for API key flow"},"fields":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Fields","description":"Required fields for API key"}},"type":"object","required":["auth_type"],"title":"ProviderAuthConfig","description":"Provider authentication configuration.","example":{}},"ProviderCapabilitiesResponse":{"properties":{"provider":{"type":"string","title":"Provider"},"name":{"type":"string","title":"Name"},"capabilities":{"items":{"type":"string"},"type":"array","title":"Capabilities"},"auth_type":{"type":"string","title":"Auth Type"},"supports_compute":{"type":"boolean","title":"Supports Compute"},"supports_storage":{"type":"boolean","title":"Supports Storage"},"supports_dns":{"type":"boolean","title":"Supports Dns"}},"type":"object","required":["provider","name","capabilities","auth_type","supports_compute","supports_storage","supports_dns"],"title":"ProviderCapabilitiesResponse","description":"Response schema for provider capabilities."},"ProviderError":{"properties":{"kind":{"type":"string","title":"Kind","description":"Machine-readable failure category. One of: token_invalid, sso_required, oauth_app_not_approved, rate_limited, upstream_error, network_error."},"message":{"type":"string","title":"Message","description":"Human-readable explanation for the UI"},"sso_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sso Url","description":"GitHub's SAML SSO authorization URL when kind=sso_required. Frontend can deep-link the user to it."},"upstream_status":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Upstream Status","description":"HTTP status from the upstream provider, when applicable."}},"type":"object","required":["kind","message"],"title":"ProviderError","description":"Structured failure reason when a Git provider rejects our repo-list call.\n\nSurfaced in RepositoryListResponse.provider_error so the frontend can show\na real explanation instead of a silent empty list. See OEC-0057 thread\n(sg.org PAT path), Cyrus / kuja.org (GitHub OAuth org-restricted), and\nthe silent-empty-list bug class that hid OAuth-app-approval failures\nbehind generic 'no repositories' rendering.","example":{}},"ProviderInfo":{"properties":{"provider":{"$ref":"#/components/schemas/CloudProviderType-Output","description":"Provider type"},"name":{"type":"string","title":"Name","description":"Display name"},"auth_type":{"$ref":"#/components/schemas/CloudAuthType","description":"Authentication type"},"logo":{"type":"string","title":"Logo","description":"Logo filename"},"color":{"type":"string","title":"Color","description":"Brand color (hex)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Short description"},"regions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Regions","description":"Available regions"},"auth_config":{"anyOf":[{"$ref":"#/components/schemas/ProviderAuthConfig"},{"type":"null"}],"description":"Auth configuration"},"os_versions":{"anyOf":[{"$ref":"#/components/schemas/ProviderOsVersions"},{"type":"null"}],"description":"OS choices offered when provisioning"}},"type":"object","required":["provider","name","auth_type","logo","color"],"title":"ProviderInfo","description":"Provider information for frontend display.","example":{}},"ProviderInfoResponse":{"properties":{"id":{"type":"string","title":"Id","description":"Provider ID"},"name":{"type":"string","title":"Name","description":"Provider display name"},"supported":{"type":"boolean","title":"Supported","description":"Whether provider is implemented"},"credential_schema":{"$ref":"#/components/schemas/ProviderSchemaResponse","description":"Credential input schema"}},"type":"object","required":["id","name","supported","credential_schema"],"title":"ProviderInfoResponse","description":"Schema for DNS provider information.","example":{}},"ProviderMappingResponse":{"properties":{"cloud_to_dns":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object","title":"Cloud To Dns","description":"Maps cloud account provider to DNS provider type"},"cloud_to_storage":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object","title":"Cloud To Storage","description":"Maps cloud account provider to storage provider type"},"split_token_providers":{"additionalProperties":{"type":"object"},"type":"object","title":"Split Token Providers","description":"Providers where cloud credentials differ from DNS/storage credentials"},"credential_fields":{"additionalProperties":{"type":"object"},"type":"object","title":"Credential Fields","description":"Credential field names expected by each provider"}},"type":"object","required":["cloud_to_dns","cloud_to_storage","split_token_providers","credential_fields"],"title":"ProviderMappingResponse","description":"Response schema for the full provider-to-capability mapping table."},"ProviderOsVersions":{"properties":{"default":{"type":"string","title":"Default","description":"Release used when none is chosen"},"available":{"items":{"type":"string"},"type":"array","title":"Available","description":"Selectable releases"}},"type":"object","required":["default","available"],"title":"ProviderOsVersions","description":"OS choices (Ubuntu releases, \"debian-13\") a provider offers for cloud-created servers.","example":{}},"ProviderSchemaResponse":{"properties":{"fields":{"items":{"$ref":"#/components/schemas/CredentialFieldSchema"},"type":"array","title":"Fields","description":"Credential input fields"},"provider_config_fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/CredentialFieldSchema"},"type":"array"},{"type":"null"}],"title":"Provider Config Fields","description":"Provider config input fields"},"help_url":{"type":"string","title":"Help Url","description":"Help documentation URL"},"help_text":{"type":"string","title":"Help Text","description":"Short help text"}},"type":"object","required":["fields","help_url","help_text"],"title":"ProviderSchemaResponse","description":"Schema for provider credential schema.","example":{}},"ProvidersListResponse":{"properties":{"providers":{"items":{"$ref":"#/components/schemas/ProviderInfoResponse"},"type":"array","title":"Providers","description":"List of DNS providers"}},"type":"object","required":["providers"],"title":"ProvidersListResponse","description":"Schema for listing DNS providers.","example":{}},"ProvisionServerRequest":{"properties":{"server_name":{"type":"string","maxLength":100,"minLength":1,"title":"Server Name","description":"Name for the new server"},"server_type":{"type":"string","title":"Server Type","description":"Provider server type ID (e.g., 'cx11', 's-1vcpu-1gb')"},"region":{"type":"string","title":"Region","description":"Provider region ID (e.g., 'nbg1', 'nyc1')"},"image":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image","description":"OS image ID or slug; explicit override of os_version (defaults to the provider's default OS)"},"os_version":{"anyOf":[{"type":"string","enum":["24.04","26.04","debian-13"]},{"type":"null"}],"title":"Os Version","description":"Ubuntu release or debian-13; None uses the provider default (see /cloud-providers/supported)"},"server_ssh_key_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Ssh Key Id","description":"Per-server SSH key ID. If provided, uses this key instead of org's platform SSH key."}},"type":"object","required":["server_name","server_type","region"],"title":"ProvisionServerRequest","description":"Request to provision a new server.","example":{}},"ProvisionServerResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether the task was enqueued successfully"},"job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Id","description":"Background job ID for tracking"},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"Created VM ID (populated when complete)"},"cloud_server_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cloud Server Id","description":"Provider's server ID (populated when complete)"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"Server's public IP address (populated when complete)"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Status message"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if failed"}},"type":"object","required":["success"],"title":"ProvisionServerResponse","description":"Response from server provisioning (async operation).\n\nThe provisioning is now handled as a background task. The response includes\na job_id for tracking progress via SSE events. The vm_id and other fields\nare populated when provisioning completes (via SSE events).","example":{}},"PublicActionResponse":{"properties":{"task_id":{"type":"string","format":"uuid","title":"Task Id"},"status":{"type":"string","title":"Status"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"poll_url":{"type":"string","title":"Poll Url"}},"type":"object","required":["task_id","status","environment_id","poll_url"],"title":"PublicActionResponse","description":"Generic 202 response for start / stop / restart actions."},"PublicAutoDeploySettings":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"branch_patterns":{"items":{"type":"string"},"type":"array","title":"Branch Patterns","description":"Branches that deploy on push. Empty means only the environment's own branch."},"update_modules":{"type":"boolean","title":"Update Modules","description":"Whether a module update runs after each auto-deploy.","default":false},"cooldown_minutes":{"type":"integer","title":"Cooldown Minutes","default":0},"include_paths":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Include Paths"},"exclude_paths":{"items":{"type":"string"},"type":"array","title":"Exclude Paths"}},"type":"object","title":"PublicAutoDeploySettings","description":"An environment's auto-deploy settings, as the dashboard shows them."},"PublicBackupRestoreResponse":{"properties":{"task_id":{"type":"string","format":"uuid","title":"Task Id"},"status":{"type":"string","title":"Status"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"poll_url":{"type":"string","title":"Poll Url"},"backup_id":{"type":"string","format":"uuid","title":"Backup Id"}},"type":"object","required":["task_id","status","environment_id","poll_url","backup_id"],"title":"PublicBackupRestoreResponse","description":"202 response for POST /backups/{id}/restore."},"PublicChangelogEntry":{"properties":{"version":{"type":"string","title":"Version"},"date":{"type":"string","title":"Date"},"title":{"type":"string","title":"Title"},"highlights":{"items":{"type":"string"},"type":"array","title":"Highlights","default":[]},"categories":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","title":"Categories","default":{}}},"type":"object","required":["version","date","title"],"title":"PublicChangelogEntry","description":"One release. Never carries the \"internal\" category."},"PublicChangelogResponse":{"properties":{"entries":{"items":{"$ref":"#/components/schemas/PublicChangelogEntry"},"type":"array","title":"Entries"},"total":{"type":"integer","title":"Total"},"limit":{"type":"integer","title":"Limit"},"offset":{"type":"integer","title":"Offset"}},"type":"object","required":["entries","total","limit","offset"],"title":"PublicChangelogResponse","description":"Releases newest first, paged by limit and offset."},"PublicCloneOperationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"status":{"type":"string","title":"Status"},"queued":{"type":"boolean","title":"Queued","description":"True while the clone waits to start, for example behind another clone of the same source (current_step says what it waits for)."},"source_environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Source Environment Id"},"target_environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Target Environment Id"},"target_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Name"},"task_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Task Id"},"progress_percent":{"type":"integer","title":"Progress Percent"},"current_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Step"},"steps_completed":{"type":"integer","title":"Steps Completed"},"total_steps":{"type":"integer","title":"Total Steps"},"cancel_requested":{"type":"boolean","title":"Cancel Requested"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"error_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Step"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","status","queued","source_environment_id","target_environment_id","target_name","task_id","progress_percent","current_step","steps_completed","total_steps","cancel_requested","started_at","completed_at","duration_seconds","error_message","error_step","created_at"],"title":"PublicCloneOperationResponse","description":"One clone, from when it is queued until it ends, with or without a task.\n\nA side of the clone outside the API key's reach is returned as null."},"PublicContainerMetrics":{"properties":{"status":{"type":"string","title":"Status"},"cpu_percent":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cpu Percent"},"memory_used_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Memory Used Bytes"},"memory_limit_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Memory Limit Bytes"},"memory_percent":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Memory Percent"}},"type":"object","required":["status","cpu_percent","memory_used_bytes","memory_limit_bytes","memory_percent"],"title":"PublicContainerMetrics","description":"Live figures for one of an environment's containers.\n\nThe figures are None when the server reports the container but not its\nusage (servers monitored over SSH report only the container state)."},"PublicDeployRequest":{"properties":{"update_modules":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Update Modules"},"neutralize":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Neutralize"}},"additionalProperties":false,"type":"object","title":"PublicDeployRequest","description":"Optional body for POST /environments/{id}/deploy (#1129).\n\n``update_modules``: module names to update (``odoo -u``) after the new code\nis pulled and the container starts, and before the health check -- e.g.\n``[\"sale_custom\", \"partner_extra\"]`` or ``[\"all\"]``. Works when the\nenvironment is in an error state, so a schema-breaking push can be\nrecovered in one call.\n\n``neutralize`` (#1229): only used when this deploy restores a migration\nbackup. ``true`` turns off the restored database's scheduled jobs and\noutgoing mail before Odoo starts, then its integrations; ``false`` keeps\nthem. Omitted: on unless the environment is production."},"PublicDeployResponse":{"properties":{"task_id":{"type":"string","format":"uuid","title":"Task Id"},"status":{"type":"string","title":"Status"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"poll_url":{"type":"string","title":"Poll Url"}},"type":"object","required":["task_id","status","environment_id","poll_url"],"title":"PublicDeployResponse","description":"Immediate response for POST /environments/{id}/deploy (202 Accepted).\n\nThe caller should poll poll_url until status reaches a terminal state."},"PublicEnvironmentCreate":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name"},"branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch"},"environment_type":{"type":"string","title":"Environment Type","default":"development"},"domain":{"anyOf":[{"type":"string","maxLength":253},{"type":"null"}],"title":"Domain","description":"Custom domain for the environment (e.g. 'client.example.com'). The customer is responsible for the DNS CNAME to `<subdomain>.apps.oec.sh`."},"vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vm Id","description":"VM/server to deploy on. Defaults to the project's server if omitted."},"cpu_cores":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.25},{"type":"null"}],"title":"Cpu Cores"},"ram_mb":{"anyOf":[{"type":"integer","maximum":131072.0,"minimum":256.0},{"type":"null"}],"title":"Ram Mb"},"disk_gb":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Disk Gb"},"postgres_version":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Postgres Version"},"enable_pgtune":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Pgtune"},"enable_pgbouncer":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Pgbouncer"},"enable_read_replica":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Read Replica"},"with_demo_data":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"With Demo Data"}},"type":"object","required":["name"],"title":"PublicEnvironmentCreate","description":"Request body for creating an environment via the public API."},"PublicEnvironmentDisk":{"properties":{"allocated_gb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Allocated Gb"},"database_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Database Bytes"},"filestore_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filestore Bytes"},"addons_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Addons Bytes"},"measured_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Measured At"}},"type":"object","required":["allocated_gb","database_bytes","filestore_bytes","addons_bytes","measured_at"],"title":"PublicEnvironmentDisk","description":"Allocated disk and the last measured sizes of an environment."},"PublicEnvironmentMetricsResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"status":{"type":"string","title":"Status"},"odoo":{"anyOf":[{"$ref":"#/components/schemas/PublicContainerMetrics"},{"type":"null"}]},"postgres":{"anyOf":[{"$ref":"#/components/schemas/PublicContainerMetrics"},{"type":"null"}]},"disk":{"$ref":"#/components/schemas/PublicEnvironmentDisk"},"queried_at":{"type":"string","format":"date-time","title":"Queried At"}},"type":"object","required":["environment_id","status","odoo","postgres","disk","queried_at"],"title":"PublicEnvironmentMetricsResponse","description":"Response for GET /environments/{id}/metrics.\n\n``odoo`` and ``postgres`` are None when the server does not report the\ncontainer. Through the monitoring agent only running containers are\nreported; over SSH a stopped container is reported with status \"stopped\"."},"PublicEnvironmentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"status":{"type":"string","title":"Status"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version"},"branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch"},"last_commit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Commit"},"cpu_cores":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cpu Cores"},"ram_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ram Mb"},"disk_gb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Disk Gb"},"project_id":{"type":"string","format":"uuid","title":"Project Id"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id"},"custom_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Domain"},"custom_domain_verified":{"type":"boolean","title":"Custom Domain Verified","default":false},"postgres_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postgres Version"},"enable_pgtune":{"type":"boolean","title":"Enable Pgtune","default":false},"enable_pgbouncer":{"type":"boolean","title":"Enable Pgbouncer","default":false},"enable_read_replica":{"type":"boolean","title":"Enable Read Replica","default":false},"running_image":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Running Image","description":"Image reference the running container was created from."},"running_image_digest":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Running Image Digest","description":"Resolved digest of the running image (odoo@sha256:...)."},"running_image_recorded_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Running Image Recorded At","description":"When the running image was last observed."},"maintenance_page":{"type":"boolean","title":"Maintenance Page","description":"Whether a maintenance page is shown during Quick Update module updates and redeploys, where the feature is available (see maintenance_page_available).","default":true},"maintenance_page_available":{"type":"boolean","title":"Maintenance Page Available","description":"Whether a Quick Update on this environment's server can show the page.","default":false},"maintenance_active":{"type":"boolean","title":"Maintenance Active","description":"Whether visitors see the maintenance page right now.","default":false},"auto_deploy":{"$ref":"#/components/schemas/PublicAutoDeploySettings"},"odoo_image":{"anyOf":[{"$ref":"#/components/schemas/OdooImageInfo"},{"type":"null"}]},"active_clone":{"anyOf":[{"$ref":"#/components/schemas/PublicCloneOperationResponse"},{"type":"null"}]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","name","status","url","odoo_version","branch","last_commit","cpu_cores","ram_mb","disk_gb","project_id","server_id","created_at","updated_at"],"title":"PublicEnvironmentResponse","description":"Environment details exposed to API consumers.\n\nExcludes: vm_id, container_name, db_password, ssh_private_key."},"PublicEnvironmentUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Name"},"branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch"},"domain":{"anyOf":[{"type":"string","maxLength":253},{"type":"null"}],"title":"Domain","description":"Custom domain. Pass an empty string to clear. The customer must still update DNS at their provider."},"cpu_cores":{"anyOf":[{"type":"number","maximum":32.0,"minimum":0.25},{"type":"null"}],"title":"Cpu Cores"},"ram_mb":{"anyOf":[{"type":"integer","maximum":131072.0,"minimum":256.0},{"type":"null"}],"title":"Ram Mb"},"disk_gb":{"anyOf":[{"type":"integer","maximum":1000.0,"minimum":1.0},{"type":"null"}],"title":"Disk Gb"},"maintenance_page":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Maintenance Page","description":"Show a maintenance page (HTTP 503 with Retry-After) during Quick Update module updates and redeploys, where the feature is available (see maintenance_page_available). Default true."}},"type":"object","title":"PublicEnvironmentUpdate","description":"Request body for updating an environment via the public API."},"PublicLogsResponse":{"properties":{"task_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Task Id"},"log":{"type":"string","title":"Log"},"lines":{"type":"integer","title":"Lines"},"truncated":{"type":"boolean","title":"Truncated"}},"type":"object","required":["task_id","log","lines","truncated"],"title":"PublicLogsResponse","description":"Response for GET /environments/{id}/logs."},"PublicOdooerListingResponse":{"properties":{"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"tagline":{"type":"string","title":"Tagline"},"country":{"type":"string","title":"Country"},"country_name":{"type":"string","title":"Country Name"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"logo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo"},"team_size":{"type":"string","title":"Team Size"},"years_experience":{"type":"integer","title":"Years Experience"},"odoo_versions":{"items":{"type":"integer"},"type":"array","title":"Odoo Versions"},"languages":{"items":{"type":"string"},"type":"array","title":"Languages"},"services":{"items":{"type":"string"},"type":"array","title":"Services"},"industries":{"items":{"type":"string"},"type":"array","title":"Industries"},"case_studies":{"items":{"$ref":"#/components/schemas/CaseStudy"},"type":"array","title":"Case Studies"},"odoo_partner_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Partner Level"},"odoo_partner_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Partner Url"},"odoo_apps_store_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Apps Store Url"},"featured":{"type":"boolean","title":"Featured"},"verified_agency":{"type":"boolean","title":"Verified Agency"},"plan":{"type":"string","title":"Plan"},"verified_on":{"type":"string","title":"Verified On"}},"type":"object","required":["slug","name","tagline","country","country_name","city","timezone","website","logo","team_size","years_experience","odoo_versions","languages","services","industries","case_studies","odoo_partner_level","odoo_partner_url","odoo_apps_store_url","featured","verified_agency","plan","verified_on"],"title":"PublicOdooerListingResponse","description":"Shape consumed by the marketing site's build-time export.\n\nKept lean — no timestamps, no consent metadata, no org UUID. Matches\nthe shape of `Odooer` in src/lib/odooer-helpers.ts (marketing repo)."},"PublicOdooersExportResponse":{"properties":{"generated_at":{"type":"string","format":"date-time","title":"Generated At"},"total":{"type":"integer","title":"Total"},"listings":{"items":{"$ref":"#/components/schemas/PublicOdooerListingResponse"},"type":"array","title":"Listings"},"truncated":{"type":"boolean","title":"Truncated","default":false},"since":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Since"},"latest_updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Latest Updated At"},"removed_slugs":{"items":{"type":"string"},"type":"array","title":"Removed Slugs"}},"type":"object","required":["generated_at","total","listings"],"title":"PublicOdooersExportResponse","description":"Envelope for the public export endpoint — the marketing site's\nbuild step consumes this and rewrites its odooers.json.\n\nSupports two modes:\n\n- **Full dump** (no ?since param): every currently-published listing.\n  Used for cold-start rehydration.\n- **Delta** (?since=<ISO8601>): only rows whose updated_at > since.\n  Includes `removed_slugs` for listings that used to be public but\n  are no longer (unpublished, consent invalidated, or soft-deleted).\n  Marketing-site sync script merges this into its local odooers.json\n  and advances its cursor to `latest_updated_at`."},"PublicOrgResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"plan":{"type":"string","title":"Plan"},"max_environments":{"type":"integer","title":"Max Environments"},"max_cpu_cores":{"type":"number","title":"Max Cpu Cores"},"max_ram_mb":{"type":"integer","title":"Max Ram Mb"},"max_disk_gb":{"type":"integer","title":"Max Disk Gb"}},"type":"object","required":["id","name","slug","plan","max_environments","max_cpu_cores","max_ram_mb","max_disk_gb"],"title":"PublicOrgResponse","description":"Organisation summary with plan and quota information."},"PublicPaginatedWebhooks":{"properties":{"items":{"items":{"$ref":"#/components/schemas/OutgoingWebhookResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"limit":{"type":"integer","title":"Limit"},"offset":{"type":"integer","title":"Offset"},"has_more":{"type":"boolean","title":"Has More"}},"type":"object","required":["items","total","limit","offset","has_more"],"title":"PublicPaginatedWebhooks","description":"Paginated response for GET /webhooks."},"PublicProjectCreate":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name"},"server_id":{"type":"string","format":"uuid","title":"Server Id"},"git_repo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Repo Url"},"default_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Branch","default":"main"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version"},"git_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Provider","description":"Optional override: 'github', 'gitlab', or 'bitbucket'. Determines which connected org-level git connection the deploy clone uses to authenticate. When omitted we auto-detect from git_repo_url host (github.com -> github, gitlab.com or anything else -> gitlab). Self-hosted GitLab instances without 'gitlab' in the host should pass git_provider='gitlab' explicitly."}},"type":"object","required":["name","server_id"],"title":"PublicProjectCreate","description":"Request body for creating a project via the public API."},"PublicProjectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"odoo_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Odoo Version"},"git_repo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Repo Url"},"default_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Branch"},"git_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Provider"},"environment_count":{"type":"integer","title":"Environment Count"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","name","odoo_version","git_repo_url","default_branch","git_provider","environment_count","server_id","created_at"],"title":"PublicProjectResponse","description":"Project details exposed to API consumers.\n\nIntentionally minimal: excludes infrastructure details (webhook_secret,\ndb_password, container_name, registry credentials) and internal flags.\nAdditional fields may be added in future releases without breaking\nexisting integrations."},"PublicProjectUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Name"},"default_branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Branch"},"git_repo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Repo Url"},"git_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Git Provider","description":"Override the git provider for credential resolution. Accepts 'github', 'gitlab', or 'bitbucket'. When you PATCH the git_repo_url (e.g. moving the project from github.com to gitlab.com), we auto-update git_provider from the new URL host. Pass git_provider explicitly to override that auto-detection."},"odoo_version":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Odoo Version","description":"Odoo version this project targets (e.g. '18.0'). Must match an existing OdooVersion. Changing this only affects future env deploys; existing envs keep their installed version."}},"type":"object","title":"PublicProjectUpdate","description":"Request body for updating a project via the public API."},"PublicQuickUpdateRequest":{"properties":{"mode":{"$ref":"#/components/schemas/QuickUpdateMode","description":"Quick update mode to use"},"modules":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Modules","description":"Module names to update/reinitialize (required for update_specific and reinitialize_specific modes)."},"skip_safety_copy":{"type":"boolean","title":"Skip Safety Copy","description":"Skip the copy of the database that is saved on the server before modules are updated or installed. Without it there is no restore point if the update fails.","default":false},"ignore_running_backup":{"type":"boolean","title":"Ignore Running Backup","description":"Go ahead even if a backup of the environment is queued or running. That backup fails when the environment restarts, so run it again after the update. Other operations (deploy, restore, clone, another update) still refuse the update.","default":false}},"type":"object","required":["mode"],"title":"PublicQuickUpdateRequest","description":"Public API quick update: the dashboard request plus a safety-copy opt-out (#1230)\nand a running-backup opt-in (#1288).\n\nThe dashboard offers the opt-out too, except on production (#1345).","example":{}},"PublicRuntimeLogsResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"source":{"type":"string","title":"Source"},"lines":{"type":"integer","title":"Lines"},"truncated":{"type":"boolean","title":"Truncated"},"log":{"type":"string","title":"Log"},"fetched_at":{"type":"string","format":"date-time","title":"Fetched At"}},"type":"object","required":["environment_id","source","lines","truncated","log","fetched_at"],"title":"PublicRuntimeLogsResponse","description":"Response for GET /environments/{id}/runtime-logs.\n\n``truncated`` is true when older lines exist that were not returned."},"PublicServerMetricsResponse":{"properties":{"server_id":{"type":"string","format":"uuid","title":"Server Id"},"status":{"type":"string","title":"Status"},"cpu_percent":{"type":"number","title":"Cpu Percent"},"memory_percent":{"type":"number","title":"Memory Percent"},"memory_used_bytes":{"type":"integer","title":"Memory Used Bytes"},"memory_total_bytes":{"type":"integer","title":"Memory Total Bytes"},"disk_percent":{"type":"number","title":"Disk Percent"},"disk_used_bytes":{"type":"integer","title":"Disk Used Bytes"},"disk_total_bytes":{"type":"integer","title":"Disk Total Bytes"},"network_rx_bytes_per_second":{"type":"number","title":"Network Rx Bytes Per Second"},"network_tx_bytes_per_second":{"type":"number","title":"Network Tx Bytes Per Second"},"container_count":{"type":"integer","title":"Container Count"},"containers_running":{"type":"integer","title":"Containers Running"},"queried_at":{"type":"string","format":"date-time","title":"Queried At"}},"type":"object","required":["server_id","status","cpu_percent","memory_percent","memory_used_bytes","memory_total_bytes","disk_percent","disk_used_bytes","disk_total_bytes","network_rx_bytes_per_second","network_tx_bytes_per_second","container_count","containers_running","queried_at"],"title":"PublicServerMetricsResponse","description":"Response for GET /servers/{id}/metrics: whole-server figures only."},"PublicServerResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"provider":{"type":"string","title":"Provider"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region"},"cpu_cores":{"type":"integer","title":"Cpu Cores"},"ram_mb":{"type":"integer","title":"Ram Mb"},"disk_gb":{"type":"integer","title":"Disk Gb"},"environment_count":{"type":"integer","title":"Environment Count"},"qualification_status":{"type":"string","title":"Qualification Status"},"last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Checked At"}},"type":"object","required":["id","name","provider","region","cpu_cores","ram_mb","disk_gb","environment_count","qualification_status","last_checked_at"],"title":"PublicServerResponse","description":"Server details exposed to API consumers.\n\nExcludes: IP address, SSH key material, internal identifiers."},"PublicStatusResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"status":{"type":"string","title":"Status"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"container_running":{"type":"boolean","title":"Container Running"},"db_ready":{"type":"boolean","title":"Db Ready"},"http_ok":{"type":"boolean","title":"Http Ok"},"last_deploy":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Last Deploy"}},"type":"object","required":["environment_id","status","url","container_running","db_ready","http_ok","last_deploy"],"title":"PublicStatusResponse","description":"Lightweight health snapshot for an environment."},"PublicSupportTicket":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"ticket_number":{"type":"string","title":"Ticket Number"},"subject":{"type":"string","title":"Subject"},"status":{"type":"string","title":"Status"},"priority":{"type":"string","title":"Priority"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"source":{"type":"string","title":"Source"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At"},"closed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Closed At"}},"type":"object","required":["id","ticket_number","subject","status","priority","source","created_at"],"title":"PublicSupportTicket","description":"A support ticket in a list."},"PublicSupportTicketComment":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"author_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author Name"},"from_support":{"type":"boolean","title":"From Support"},"content":{"type":"string","title":"Content"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","from_support","content","created_at"],"title":"PublicSupportTicketComment","description":"A public reply on a ticket (internal notes are never returned)."},"PublicSupportTicketDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"ticket_number":{"type":"string","title":"Ticket Number"},"subject":{"type":"string","title":"Subject"},"status":{"type":"string","title":"Status"},"priority":{"type":"string","title":"Priority"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"source":{"type":"string","title":"Source"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At"},"closed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Closed At"},"description":{"type":"string","title":"Description"},"comments":{"items":{"$ref":"#/components/schemas/PublicSupportTicketComment"},"type":"array","title":"Comments","default":[]}},"type":"object","required":["id","ticket_number","subject","status","priority","source","created_at","description"],"title":"PublicSupportTicketDetail","description":"A support ticket with its description and public replies, oldest first."},"PublicTaskResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"type":{"type":"string","title":"Type"},"status":{"type":"string","title":"Status"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id"},"progress_percent":{"type":"integer","title":"Progress Percent"},"current_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Step"},"steps_completed":{"type":"integer","title":"Steps Completed"},"total_steps":{"type":"integer","title":"Total Steps"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"triggered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Triggered By"},"target_environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Target Environment Id"},"clone_operation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Clone Operation Id"}},"type":"object","required":["id","type","status","environment_id","progress_percent","current_step","steps_completed","total_steps","started_at","completed_at","duration_seconds","error_message"],"title":"PublicTaskResponse","description":"Full task status returned by the task polling endpoint."},"PublicThemeResponse":{"properties":{"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"favicon_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Favicon Url"},"login_bg_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Login Bg Url"},"primary_color":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"},{"type":"null"}],"title":"Primary Color"},"secondary_color":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"},{"type":"null"}],"title":"Secondary Color"}},"type":"object","required":["logo_url","favicon_url","login_bg_url"],"title":"PublicThemeResponse","description":"Unauth GET /theme/by-domain — minimal subset, NO internal fields."},"PublicUsageResponse":{"properties":{"environments_running":{"type":"integer","title":"Environments Running"},"cpu_used":{"type":"number","title":"Cpu Used"},"ram_mb_used":{"type":"integer","title":"Ram Mb Used"},"disk_gb_used":{"type":"integer","title":"Disk Gb Used"}},"type":"object","required":["environments_running","cpu_used","ram_mb_used","disk_gb_used"],"title":"PublicUsageResponse","description":"Current resource utilisation for an organisation."},"PurgeResponse":{"properties":{"purged_count":{"type":"integer","title":"Purged Count","description":"Number of tasks purged"},"message":{"type":"string","title":"Message","description":"Status message"}},"type":"object","required":["purged_count","message"],"title":"PurgeResponse","description":"Response schema for DLQ purge."},"QualifyTunnelResponse":{"properties":{"task_id":{"type":"string","title":"Task Id","description":"ARQ job id for the enqueued qualify task"},"vm_id":{"type":"string","format":"uuid","title":"Vm Id","description":"VM that will be qualified"},"status":{"type":"string","title":"Status","description":"Enqueue status (always 'queued')","default":"queued"}},"type":"object","required":["task_id","vm_id"],"title":"QualifyTunnelResponse","description":"Response for POST /vms/{vm_id}/qualify — queues E2E tunnel qualification.","example":{}},"QueueStats":{"properties":{"pending":{"type":"integer","minimum":0.0,"title":"Pending","description":"Tasks pending (not yet queued)","default":0},"queued":{"type":"integer","minimum":0.0,"title":"Queued","description":"Tasks queued for execution","default":0},"running":{"type":"integer","minimum":0.0,"title":"Running","description":"Tasks currently running","default":0},"completed_24h":{"type":"integer","minimum":0.0,"title":"Completed 24H","description":"Tasks completed in last 24 hours","default":0},"failed_24h":{"type":"integer","minimum":0.0,"title":"Failed 24H","description":"Tasks failed in last 24 hours","default":0},"avg_wait_seconds":{"type":"number","minimum":0.0,"title":"Avg Wait Seconds","description":"Average queue wait time in seconds (last 24h)","default":0.0},"avg_duration_seconds":{"type":"number","minimum":0.0,"title":"Avg Duration Seconds","description":"Average task duration in seconds (last 24h)","default":0.0},"by_type":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Type","description":"Active task counts by type (deploy, backup, clone, etc.)"}},"type":"object","title":"QueueStats","description":"Task queue statistics for dashboard overview.","example":{}},"QueuedClone":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Clone operation ID"},"target_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Target Name","description":"Name of the target environment"}},"type":"object","required":["id"],"title":"QueuedClone","description":"A clone of this environment that has not started yet (#1380).","example":{}},"QuickAddUserRequest":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id","description":"ID of the user to add to the project"},"role":{"$ref":"#/components/schemas/TeamRole","description":"Role to grant the user on the project","default":"developer"}},"type":"object","required":["user_id"],"title":"QuickAddUserRequest","description":"Schema for quickly adding a user to a project.","example":{}},"QuickAddUserResponse":{"properties":{"team_id":{"type":"string","format":"uuid","title":"Team Id","description":"ID of the team used/created"},"team_name":{"type":"string","title":"Team Name","description":"Name of the team used/created"},"team_created":{"type":"boolean","title":"Team Created","description":"Whether a new team was created"},"user_already_had_access":{"type":"boolean","title":"User Already Had Access","description":"Whether the user already had access to the project","default":false},"existing_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Existing Role","description":"User's existing role if they already had access"}},"type":"object","required":["team_id","team_name","team_created"],"title":"QuickAddUserResponse","description":"Response for quick add user operation.","example":{}},"QuickUpdateActionConfig":{"properties":{"action_type":{"type":"string","const":"quick_update","title":"Action Type","default":"quick_update"},"target_env_id":{"type":"string","format":"uuid","title":"Target Env Id","description":"Environment to quick-update."},"mode":{"type":"string","title":"Mode","description":"Quick update mode: pull_restart, restart_only, update_all, update_specific, reinitialize_specific.","default":"pull_restart"},"modules":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Modules","description":"Module names to update/reinitialize (required when mode=update_specific or reinitialize_specific)."}},"type":"object","required":["target_env_id"],"title":"QuickUpdateActionConfig","description":"Configuration for a quick update (pull + restart) action."},"QuickUpdateMode":{"type":"string","enum":["restart_only","pull_restart","update_all","update_specific","reinitialize_specific"],"title":"QuickUpdateMode","description":"Quick update modes for development environments."},"QuickUpdateRequest":{"properties":{"mode":{"$ref":"#/components/schemas/QuickUpdateMode","description":"Quick update mode to use"},"modules":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Modules","description":"Module names to update/reinitialize (required for update_specific and reinitialize_specific modes)."},"skip_safety_copy":{"type":"boolean","title":"Skip Safety Copy","description":"Don't save a database copy before a module update (#1345). Refused on production environments in the dashboard route.","default":false}},"type":"object","required":["mode"],"title":"QuickUpdateRequest","description":"Request to perform a quick update on an environment.","example":{}},"QuickUpdateResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether the update completed successfully"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id","description":"Environment ID the update was performed on"},"mode":{"$ref":"#/components/schemas/QuickUpdateMode","description":"Update mode that was used"},"message":{"type":"string","title":"Message","description":"Human-readable result message"},"task_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Task Id","description":"Task ID for async operations (for tracking)"},"duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Ms","description":"Update duration in milliseconds (if synchronous)"}},"type":"object","required":["success","environment_id","mode","message"],"title":"QuickUpdateResponse","description":"Response after performing a quick update.","example":{}},"QuotaCheckResult":{"properties":{"allowed":{"type":"boolean","title":"Allowed","description":"Whether the requested action is allowed"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"Reason why the action is not allowed (if allowed=False)"},"current_usage":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Current Usage","description":"Current usage count or amount"},"limit":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Limit","description":"Quota limit for this resource"}},"type":"object","required":["allowed"],"title":"QuotaCheckResult","description":"Result of a quota validation check.","example":{}},"QuotaUsage":{"properties":{"server_mode":{"type":"string","title":"Server Mode","description":"Organization's server mode: 'byos' or 'shared'"},"projects_used":{"type":"integer","title":"Projects Used","description":"Current number of projects"},"projects_limit":{"type":"integer","title":"Projects Limit","description":"Maximum number of projects allowed"},"environments_used":{"type":"integer","title":"Environments Used","description":"Current number of environments"},"environments_limit":{"type":"integer","title":"Environments Limit","description":"Maximum number of environments allowed"},"servers_used":{"type":"integer","title":"Servers Used","description":"Current number of servers (always 0 in shared mode)"},"servers_limit":{"type":"integer","title":"Servers Limit","description":"Maximum number of servers allowed (always 0 in shared mode)"},"members_used":{"type":"integer","title":"Members Used","description":"Current number of members"},"members_limit":{"type":"integer","title":"Members Limit","description":"Maximum number of members allowed"},"cpu_used":{"type":"string","title":"Cpu Used","description":"Total CPU cores allocated across all environments"},"cpu_limit":{"type":"string","title":"Cpu Limit","description":"Total CPU cores quota (from subscription in BYOS mode, from allocations in shared mode)"},"ram_used_mb":{"type":"integer","title":"Ram Used Mb","description":"Total RAM allocated in MB across all environments"},"ram_limit_mb":{"type":"integer","title":"Ram Limit Mb","description":"Total RAM quota in MB (from subscription in BYOS mode, from allocations in shared mode)"},"disk_used_gb":{"type":"integer","title":"Disk Used Gb","description":"Total disk allocated in GB across all environments"},"disk_limit_gb":{"type":"integer","title":"Disk Limit Gb","description":"Total disk quota in GB (from subscription in BYOS mode, from allocations in shared mode)"},"allocations":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Allocations","description":"List of active allocations (only present in shared mode)"},"warnings":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Warnings","description":"Warnings about quota usage or expiring allocations"}},"type":"object","required":["server_mode","projects_used","projects_limit","environments_used","environments_limit","servers_used","servers_limit","members_used","members_limit","cpu_used","cpu_limit","ram_used_mb","ram_limit_mb","disk_used_gb","disk_limit_gb"],"title":"QuotaUsage","description":"Current resource usage for an organization.\n\nResponse structure differs based on organization's server_mode:\n- BYOS mode: Shows subscription limits and server counts\n- Shared mode: Shows allocation quotas, servers_used/servers_limit always 0","example":{}},"ReasonCount":{"properties":{"reason":{"type":"string","title":"Reason"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["reason","count"],"title":"ReasonCount","description":"Cancel reason with count."},"RecentActivity":{"properties":{"id":{"type":"string","title":"Id"},"type":{"type":"string","title":"Type"},"status":{"type":"string","title":"Status"},"description":{"type":"string","title":"Description"},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"}},"type":"object","required":["id","type","status","description","user_email","organization_name","created_at","completed_at"],"title":"RecentActivity","description":"Recent platform activity."},"RegenerateBackupCodesResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether backup codes were regenerated"},"message":{"type":"string","title":"Message","description":"Success/error message"},"backup_codes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Backup Codes","description":"New backup codes"}},"type":"object","required":["success","message"],"title":"RegenerateBackupCodesResponse","description":"Response model for regenerating backup codes.","example":{"backup_codes":["a1b2c3d4e5f6g7h8","i9j0k1l2m3n4o5p6"],"message":"Backup codes regenerated successfully","success":true}},"RegisteredCheckInfo":{"properties":{"check_id":{"type":"string","title":"Check Id"},"base_severity":{"type":"string","title":"Base Severity"},"schedule":{"type":"object","title":"Schedule"},"runbook_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Runbook Url"},"last_attempted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Attempted At"},"last_success_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Success At"},"consecutive_failures":{"type":"integer","title":"Consecutive Failures","default":0}},"type":"object","required":["check_id","base_severity","schedule"],"title":"RegisteredCheckInfo"},"RegisteredChecksResponse":{"properties":{"checks":{"items":{"$ref":"#/components/schemas/RegisteredCheckInfo"},"type":"array","title":"Checks"}},"type":"object","required":["checks"],"title":"RegisteredChecksResponse"},"RegistrationTokenSummary":{"properties":{"token_id":{"type":"string","format":"uuid","title":"Token Id"},"token_prefix":{"type":"string","title":"Token Prefix"},"server_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Name"},"status":{"type":"string","title":"Status"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"created_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Name"}},"type":"object","required":["token_id","token_prefix","server_name","status","expires_at","created_at"],"title":"RegistrationTokenSummary","description":"Summary of a registration token for listing."},"ReorderReposRequest":{"properties":{"repo_ids":{"items":{"type":"string","format":"uuid"},"type":"array","minItems":1,"title":"Repo Ids","description":"Ordered list of repository IDs"}},"type":"object","required":["repo_ids"],"title":"ReorderReposRequest","description":"Schema for reordering repositories.","example":{}},"ReplicaDeployRequest":{"properties":{"force_rebuild":{"type":"boolean","title":"Force Rebuild","description":"Force rebuild from primary even if replica exists","default":false}},"type":"object","title":"ReplicaDeployRequest","description":"Request schema for deploying read replica.\n\nAllows forcing rebuild even if replica already exists."},"ReplicaDeployResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether operation succeeded"},"message":{"type":"string","title":"Message","description":"Human-readable result message"},"replica_deployed":{"type":"boolean","title":"Replica Deployed","description":"Current deployment status"},"replica_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Replica Status","description":"Current health status after operation"}},"type":"object","required":["success","message","replica_deployed"],"title":"ReplicaDeployResponse","description":"Response schema for replica deployment/removal/rebuild operations.\n\nIndicates success/failure and returns updated replica status."},"ReplicaHealthResponse":{"properties":{"replica_deployed":{"type":"boolean","title":"Replica Deployed","description":"Whether replica is currently deployed"},"replica_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Replica Status","description":"Health status: online, offline, lagging, error"},"replica_lag_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Replica Lag Bytes","description":"Replication lag in bytes (sent_lsn - flush_lsn)"},"replica_lag_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Replica Lag Seconds","description":"Replication lag in seconds (write_lag from pg_stat_replication)"},"replica_last_check":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Replica Last Check","description":"Last health check timestamp (UTC)"},"replica_error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Replica Error Message","description":"Error details if replica is unhealthy"}},"type":"object","required":["replica_deployed"],"title":"ReplicaHealthResponse","description":"Response schema for replica health status.\n\nReturns current health metrics including deployment status,\nreplication lag, and error details if unhealthy."},"ReplicaRebuildRequest":{"properties":{"force":{"type":"boolean","title":"Force","description":"Force rebuild even if replica is healthy","default":false}},"type":"object","title":"ReplicaRebuildRequest","description":"Request schema for rebuilding read replica.\n\nUsed to recreate replica from primary when it falls behind\nor encounters corruption."},"RepoOverrideItem":{"properties":{"repo_type":{"type":"string","enum":["platform","organization","project_additional"],"title":"Repo Type","description":"Type: platform, organization, project_additional"},"repo_id":{"type":"string","format":"uuid","title":"Repo Id","description":"ID of the addon repo"},"is_excluded":{"type":"boolean","title":"Is Excluded","description":"Exclude this repo for this environment","default":false},"branch_override":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch Override","description":"Override branch, null = use default"}},"type":"object","required":["repo_type","repo_id"],"title":"RepoOverrideItem","description":"A single repo override for an environment.","example":{}},"RepoOverrideKey":{"properties":{"repo_type":{"type":"string","title":"Repo Type"},"repo_id":{"type":"string","format":"uuid","title":"Repo Id"}},"type":"object","required":["repo_type","repo_id"],"title":"RepoOverrideKey","description":"Identifies one stored override row of an environment.","example":{}},"RepoType":{"type":"string","enum":["platform","organization"],"title":"RepoType","description":"Type of addon repository for selection."},"RepositoriesListResponse":{"properties":{"repositories":{"items":{"$ref":"#/components/schemas/RepositoryResponse"},"type":"array","title":"Repositories"},"connection_id":{"type":"string","title":"Connection Id"},"provider":{"type":"string","title":"Provider"}},"type":"object","required":["repositories","connection_id","provider"],"title":"RepositoriesListResponse","description":"List of repositories."},"RepositoryInfo":{"properties":{"id":{"type":"string","title":"Id","description":"Repository ID from provider"},"name":{"type":"string","title":"Name","description":"Repository name"},"full_name":{"type":"string","title":"Full Name","description":"Full repository name (owner/repo)"},"url":{"type":"string","title":"Url","description":"Repository web URL"},"clone_url":{"type":"string","title":"Clone Url","description":"Git clone URL"},"private":{"type":"boolean","title":"Private","description":"Whether repository is private"},"default_branch":{"type":"string","title":"Default Branch","description":"Default branch name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Repository description"}},"type":"object","required":["id","name","full_name","url","clone_url","private","default_branch","description"],"title":"RepositoryInfo","description":"Schema for repository information.","example":{}},"RepositoryListResponse":{"properties":{"repositories":{"items":{"$ref":"#/components/schemas/RepositoryInfo"},"type":"array","title":"Repositories","description":"List of repositories"},"page":{"type":"integer","title":"Page","description":"Current page"},"per_page":{"type":"integer","title":"Per Page","description":"Items per page"},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total","description":"Total count (if available)"},"provider_error":{"anyOf":[{"$ref":"#/components/schemas/ProviderError"},{"type":"null"}],"description":"Set when the provider returned a definitive error (4xx/5xx/network). Repositories list is empty in that case. A None value means the call succeeded and the empty list (if any) is a legitimate zero-repo state."}},"type":"object","required":["repositories","page","per_page"],"title":"RepositoryListResponse","description":"Schema for repository list response.","example":{}},"RepositoryResponse":{"properties":{"id":{"type":"string","title":"Id"},"name":{"type":"string","title":"Name"},"full_name":{"type":"string","title":"Full Name"},"url":{"type":"string","title":"Url"},"clone_url":{"type":"string","title":"Clone Url"},"private":{"type":"boolean","title":"Private"},"default_branch":{"type":"string","title":"Default Branch"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"type":"object","required":["id","name","full_name","url","clone_url","private","default_branch"],"title":"RepositoryResponse","description":"Repository information."},"ResendVerificationRequest":{"properties":{"email":{"type":"string","title":"Email"}},"type":"object","required":["email"],"title":"ResendVerificationRequest","description":"Request to resend verification email."},"RestorePointResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Restore point ID"},"backup_id":{"type":"string","format":"uuid","title":"Backup Id","description":"Source backup ID"},"target_environment_id":{"type":"string","format":"uuid","title":"Target Environment Id","description":"Target environment"},"task_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Task Id","description":"Background task ID"},"status":{"$ref":"#/components/schemas/RestoreStatus","description":"Current restore status"},"pre_restore_backup_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Pre Restore Backup Id","description":"Safety backup created before restore"},"is_new_environment":{"type":"boolean","title":"Is New Environment","description":"Whether target environment was created during restore","default":false},"target_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Target Vm Id","description":"Target VM ID for cross-server restore"},"is_cross_server":{"type":"boolean","title":"Is Cross Server","description":"Whether this is a cross-server restore","default":false},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When restore started"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When restore completed"},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds","description":"Restore duration in seconds"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if failed"},"error_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Step","description":"Step where error occurred"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Record creation timestamp"}},"type":"object","required":["id","backup_id","target_environment_id","status","created_at"],"title":"RestorePointResponse","description":"Schema for restore point response.","example":{}},"RestoreRequest":{"properties":{"backup_id":{"type":"string","format":"uuid","title":"Backup Id","description":"Backup to restore from"},"target_environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Target Environment Id","description":"Target environment (defaults to backup's original environment)"},"create_pre_restore_backup":{"type":"boolean","title":"Create Pre Restore Backup","description":"Create safety backup before restoring","default":true},"include_filestore":{"type":"boolean","title":"Include Filestore","description":"Restore filestore along with database","default":true},"neutralize":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Neutralize","description":"Neutralize the restored database (crons, outgoing mail, payment and e-invoicing integrations off). Default: on for a production backup restored into a non-production environment, off otherwise."}},"type":"object","required":["backup_id"],"title":"RestoreRequest","description":"Schema for restore request.","example":{}},"RestoreRequestV2":{"properties":{"backup_id":{"type":"string","format":"uuid","title":"Backup Id","description":"Backup to restore from"},"target":{"$ref":"#/components/schemas/RestoreTarget","description":"Target specification for restore"},"create_pre_restore_backup":{"type":"boolean","title":"Create Pre Restore Backup","description":"Create safety backup before restoring (recommended)","default":true},"include_filestore":{"type":"boolean","title":"Include Filestore","description":"Restore filestore along with database","default":true},"neutralize":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Neutralize","description":"Neutralize the restored database: crons and outgoing mail off before Odoo starts, then Odoo's native neutralize (payments, e-invoicing, ...). Default (#1364): on for a production backup restored into a non-production environment, off otherwise. Send false to opt out."}},"type":"object","required":["backup_id"],"title":"RestoreRequestV2","description":"V2 restore request with target options (Sprint 2E19).","example":{}},"RestoreResponseV2":{"properties":{"restore_point_id":{"type":"string","format":"uuid","title":"Restore Point Id","description":"Created restore point ID"},"task_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Task Id","description":"Background task ID"},"target_environment_id":{"type":"string","format":"uuid","title":"Target Environment Id","description":"Target environment ID"},"target_environment_name":{"type":"string","title":"Target Environment Name","description":"Target environment name"},"is_new_environment":{"type":"boolean","title":"Is New Environment","description":"Whether a new environment was created"},"status":{"type":"string","title":"Status","description":"Restore status"},"message":{"type":"string","title":"Message","description":"Status message"}},"type":"object","required":["restore_point_id","target_environment_id","target_environment_name","is_new_environment","status","message"],"title":"RestoreResponseV2","description":"V2 restore response with target info.","example":{}},"RestoreStatus":{"type":"string","enum":["pending","downloading","restoring_db","restoring_files","verifying","completed","failed","cancelled"],"title":"RestoreStatus","description":"Restore operation status."},"RestoreTarget":{"properties":{"mode":{"$ref":"#/components/schemas/RestoreTargetMode","description":"Target mode: original, existing, or new","default":"original"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id","description":"Target environment ID (required for EXISTING mode)"},"new_environment":{"anyOf":[{"$ref":"#/components/schemas/NewEnvironmentConfig"},{"type":"null"}],"description":"Config for new environment (required for NEW mode)"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id","description":"Target server ID (required for CROSS_SERVER mode)"}},"type":"object","title":"RestoreTarget","description":"Target specification for restore operation.","example":{}},"RestoreTargetMode":{"type":"string","enum":["original","existing","new","cross_server"],"title":"RestoreTargetMode","description":"Target mode for restore operation."},"RetentionDashboardResponse":{"properties":{"total_paying":{"type":"integer","title":"Total Paying"},"monthly_subscribers":{"type":"integer","title":"Monthly Subscribers"},"annual_subscribers":{"type":"integer","title":"Annual Subscribers"},"at_risk_count":{"type":"integer","title":"At Risk Count"},"churning_count":{"type":"integer","title":"Churning Count"},"subscribers_by_plan":{"items":{"$ref":"#/components/schemas/PlanCount"},"type":"array","title":"Subscribers By Plan"},"cancellations":{"items":{"$ref":"#/components/schemas/CancellationInfo"},"type":"array","title":"Cancellations"},"cancel_reasons":{"items":{"$ref":"#/components/schemas/ReasonCount"},"type":"array","title":"Cancel Reasons"},"pauses":{"items":{"$ref":"#/components/schemas/PauseInfo"},"type":"array","title":"Pauses"},"pause_reasons":{"items":{"$ref":"#/components/schemas/ReasonCount"},"type":"array","title":"Pause Reasons"},"at_risk_orgs":{"items":{"$ref":"#/components/schemas/AtRiskOrg"},"type":"array","title":"At Risk Orgs"},"churning_orgs":{"items":{"$ref":"#/components/schemas/ChurningOrg"},"type":"array","title":"Churning Orgs"},"paused_count":{"type":"integer","title":"Paused Count"},"churn_rate":{"type":"number","title":"Churn Rate"}},"type":"object","required":["total_paying","monthly_subscribers","annual_subscribers","at_risk_count","churning_count","subscribers_by_plan","cancellations","cancel_reasons","pauses","pause_reasons","at_risk_orgs","churning_orgs","paused_count","churn_rate"],"title":"RetentionDashboardResponse","description":"Full retention dashboard payload."},"RetentionType":{"type":"string","enum":["daily","weekly","monthly","yearly","permanent"],"title":"RetentionType","description":"Backup retention tier (GFS scheme)."},"RetryPolicy":{"properties":{"build_max_attempts":{"type":"integer","maximum":5.0,"minimum":0.0,"title":"Build Max Attempts","description":"Max build step retries (0 = no retry).","default":2},"container_start_max_attempts":{"type":"integer","maximum":5.0,"minimum":0.0,"title":"Container Start Max Attempts","description":"Max container start retries.","default":2},"health_check_max_attempts":{"type":"integer","maximum":20.0,"minimum":1.0,"title":"Health Check Max Attempts","description":"Max health check retries before marking the run as failed.","default":5},"migration_retry":{"type":"boolean","title":"Migration Retry","description":"Whether to retry failed migrations. Always False — migrations must never be automatically retried to prevent data corruption.","default":false}},"type":"object","title":"RetryPolicy","description":"Retry policy for failed automation rule steps."},"RetryTaskResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether retry was successful"},"message":{"type":"string","title":"Message","description":"Status message"},"new_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"New Job Id","description":"New job ID if re-queued"}},"type":"object","required":["success","message"],"title":"RetryTaskResponse","description":"Response schema for task retry."},"RevokeAccessResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","message"],"title":"RevokeAccessResponse","description":"Response after revoking access."},"RoleClone":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Name for the new role"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Description for the new role"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization for the new role (null for system-level)"}},"type":"object","required":["name"],"title":"RoleClone","description":"Schema for cloning a role (source_role_id comes from URL path).","example":{}},"RoleCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Role display name"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Role description"},"scope":{"$ref":"#/components/schemas/schemas__permission__PermissionScope","description":"Role scope level"},"color":{"type":"string","maxLength":20,"title":"Color","description":"Badge color for UI","default":"gray"},"icon":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Icon","description":"Icon name for UI"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization this custom role belongs to (null for system roles)"},"copy_from_role_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Copy From Role Id","description":"Role to copy permissions from (template)"},"permission_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array"},{"type":"null"}],"title":"Permission Ids","description":"Initial permission IDs to assign (if not copying)"}},"type":"object","required":["name","scope"],"title":"RoleCreate","description":"Schema for creating a role.","example":{}},"RolePermissionBulkUpdate":{"properties":{"role_id":{"type":"string","format":"uuid","title":"Role Id","description":"Role to modify"},"grant_permission_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Grant Permission Ids","description":"Permission IDs to grant"},"revoke_permission_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Revoke Permission Ids","description":"Permission IDs to revoke"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization context for authorization check (required for org-level roles)"}},"type":"object","required":["role_id"],"title":"RolePermissionBulkUpdate","description":"Schema for bulk updating role permissions.","example":{}},"RolePermissionToggle":{"properties":{"role_id":{"type":"string","format":"uuid","title":"Role Id","description":"Role to modify"},"permission_id":{"type":"string","format":"uuid","title":"Permission Id","description":"Permission to toggle"},"granted":{"type":"boolean","title":"Granted","description":"Whether to grant (true) or revoke (false) the permission"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization context for authorization check (required for org-level roles)"}},"type":"object","required":["role_id","permission_id","granted"],"title":"RolePermissionToggle","description":"Schema for toggling a single permission on a role.","example":{}},"RoleResponse":{"properties":{"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Role display name"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Role description"},"scope":{"$ref":"#/components/schemas/PermissionScope-Output","description":"Role scope level"},"color":{"type":"string","maxLength":20,"title":"Color","description":"Badge color for UI","default":"gray"},"icon":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Icon","description":"Icon name for UI"},"slug":{"type":"string","title":"Slug","description":"URL-friendly identifier"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization this role belongs to"},"is_system":{"type":"boolean","title":"Is System","description":"Whether this is a system role (cannot be modified)"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this role is auto-assigned to new users"},"sort_order":{"type":"integer","title":"Sort Order","description":"Sort order for UI display"},"permissions_count":{"type":"integer","title":"Permissions Count","description":"Number of permissions assigned to this role","default":0}},"type":"object","required":["created_at","updated_at","id","name","scope","slug","organization_id","is_system","is_default","sort_order"],"title":"RoleResponse","description":"Schema for role response.","example":{}},"RoleUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Role display name"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Role description"},"color":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Color","description":"Badge color for UI"},"icon":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Icon","description":"Icon name for UI"}},"type":"object","title":"RoleUpdate","description":"Schema for updating a role.","example":{}},"RoleWithPermissions":{"properties":{"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Role display name"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Role description"},"scope":{"$ref":"#/components/schemas/PermissionScope-Output","description":"Role scope level"},"color":{"type":"string","maxLength":20,"title":"Color","description":"Badge color for UI","default":"gray"},"icon":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Icon","description":"Icon name for UI"},"slug":{"type":"string","title":"Slug","description":"URL-friendly identifier"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization this role belongs to"},"is_system":{"type":"boolean","title":"Is System","description":"Whether this is a system role (cannot be modified)"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this role is auto-assigned to new users"},"sort_order":{"type":"integer","title":"Sort Order","description":"Sort order for UI display"},"permissions_count":{"type":"integer","title":"Permissions Count","description":"Number of permissions assigned to this role","default":0},"permissions":{"items":{"$ref":"#/components/schemas/PermissionSummary"},"type":"array","title":"Permissions","description":"Permissions assigned to this role"}},"type":"object","required":["created_at","updated_at","id","name","scope","slug","organization_id","is_system","is_default","sort_order"],"title":"RoleWithPermissions","description":"Role response with full permission list.","example":{}},"RunningOperationResponse":{"properties":{"operation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Operation","description":"Kind of the running operation (quick_update, deploy, ...), or null if none"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Plain explanation, or null if none"},"queued_clones":{"items":{"$ref":"#/components/schemas/QueuedClone"},"type":"array","title":"Queued Clones","description":"Clones of this environment that have not started (they don't block a deploy)"}},"type":"object","title":"RunningOperationResponse","description":"What would refuse a deploy on this environment right now (#1390).","example":{}},"SSHAuthMethod":{"type":"string","enum":["password","ssh_key"],"title":"SSHAuthMethod","description":"SSH authentication methods."},"SSHKeyDeployRequest":{"properties":{"key_id":{"type":"string","format":"uuid","title":"Key Id","description":"SSH key pair ID to deploy"},"server_id":{"type":"string","format":"uuid","title":"Server Id","description":"Server/VM ID"},"update_server_reference":{"type":"boolean","title":"Update Server Reference","description":"Update server to use this key","default":true}},"type":"object","required":["key_id","server_id"],"title":"SSHKeyDeployRequest","description":"Request schema for deploying key to server."},"SSHKeyDeployResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"key_id":{"type":"string","format":"uuid","title":"Key Id"},"server_id":{"type":"string","format":"uuid","title":"Server Id"},"message":{"type":"string","title":"Message"},"deployment_details":{"type":"object","title":"Deployment Details"}},"type":"object","required":["success","key_id","server_id","message","deployment_details"],"title":"SSHKeyDeployResponse","description":"Response for deploy key endpoint."},"SSHKeyListResponse":{"properties":{"total":{"type":"integer","title":"Total"},"keys":{"items":{"$ref":"#/components/schemas/SSHKeyPairResponse"},"type":"array","title":"Keys"}},"type":"object","required":["total","keys"],"title":"SSHKeyListResponse","description":"Response for list keys endpoint."},"SSHKeyPairCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Key pair name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Optional description"},"key_type":{"type":"string","pattern":"^(ed25519|rsa|ecdsa)$","title":"Key Type","description":"Key algorithm (ed25519, rsa, ecdsa)","default":"ed25519"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization ID (null = platform-wide)"},"expires_in_days":{"anyOf":[{"type":"integer","maximum":3650.0,"minimum":1.0},{"type":"null"}],"title":"Expires In Days","description":"Days until expiry (1-3650, null = never)"}},"type":"object","required":["name"],"title":"SSHKeyPairCreate","description":"Request schema for creating a new SSH key pair."},"SSHKeyPairResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"key_type":{"type":"string","title":"Key Type"},"key_bits":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Key Bits"},"fingerprint":{"type":"string","title":"Fingerprint"},"status":{"type":"string","title":"Status"},"is_active":{"type":"boolean","title":"Is Active"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"public_key":{"type":"string","title":"Public Key"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"},"revoked_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revoked Reason"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"usage_count":{"type":"integer","title":"Usage Count"},"server_count":{"type":"integer","title":"Server Count","default":0},"days_until_expiry":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Days Until Expiry"},"is_valid":{"type":"boolean","title":"Is Valid","default":true},"is_expired":{"type":"boolean","title":"Is Expired","default":false},"replaced_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Replaced By Id"},"replaces_key_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Replaces Key Id"},"created_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Id"}},"type":"object","required":["id","name","description","key_type","key_bits","fingerprint","status","is_active","organization_id","created_at","updated_at","public_key","expires_at","revoked_at","revoked_reason","last_used_at","usage_count"],"title":"SSHKeyPairResponse","description":"Full SSH key pair response (without private key)."},"SSHKeyPairWithPrivate":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"key_type":{"type":"string","title":"Key Type"},"key_bits":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Key Bits"},"fingerprint":{"type":"string","title":"Fingerprint"},"status":{"type":"string","title":"Status"},"is_active":{"type":"boolean","title":"Is Active"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"public_key":{"type":"string","title":"Public Key"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"},"revoked_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Revoked Reason"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"usage_count":{"type":"integer","title":"Usage Count"},"server_count":{"type":"integer","title":"Server Count","default":0},"days_until_expiry":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Days Until Expiry"},"is_valid":{"type":"boolean","title":"Is Valid","default":true},"is_expired":{"type":"boolean","title":"Is Expired","default":false},"replaced_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Replaced By Id"},"replaces_key_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Replaces Key Id"},"created_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Id"},"private_key":{"type":"string","title":"Private Key","description":"Private key (ONLY shown once, download immediately!)"}},"type":"object","required":["id","name","description","key_type","key_bits","fingerprint","status","is_active","organization_id","created_at","updated_at","public_key","expires_at","revoked_at","revoked_reason","last_used_at","usage_count","private_key"],"title":"SSHKeyPairWithPrivate","description":"SSH key pair response including private key.\n\nWARNING: Only returned once during creation!\nPrivate key should be downloaded and stored securely by the user."},"SSHKeyRevokeRequest":{"properties":{"reason":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reason"},"remove_from_servers":{"type":"boolean","title":"Remove From Servers","description":"Remove public key from all servers","default":false}},"type":"object","title":"SSHKeyRevokeRequest","description":"Request schema for revoking a key."},"SSHKeyRevokeResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"key_id":{"type":"string","format":"uuid","title":"Key Id"},"revoked_at":{"type":"string","format":"date-time","title":"Revoked At"},"servers_affected":{"type":"integer","title":"Servers Affected"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","key_id","revoked_at","servers_affected","message"],"title":"SSHKeyRevokeResponse","description":"Response for revoke key endpoint."},"SSHKeyRotateRequest":{"properties":{"old_key_id":{"type":"string","format":"uuid","title":"Old Key Id","description":"Key to rotate"},"new_key_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"New Key Name","description":"Name for new key"},"expires_in_days":{"type":"integer","maximum":3650.0,"minimum":1.0,"title":"Expires In Days","description":"Expiry for new key (days)","default":365}},"type":"object","required":["old_key_id"],"title":"SSHKeyRotateRequest","description":"Request schema for key rotation."},"SSHKeyRotateResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"old_key_id":{"type":"string","format":"uuid","title":"Old Key Id"},"new_key_id":{"type":"string","format":"uuid","title":"New Key Id"},"new_key":{"$ref":"#/components/schemas/SSHKeyPairResponse"},"servers_updated":{"type":"integer","title":"Servers Updated"},"message":{"type":"string","title":"Message"}},"type":"object","required":["success","old_key_id","new_key_id","new_key","servers_updated","message"],"title":"SSHKeyRotateResponse","description":"Response for rotate key endpoint."},"SSHKeyUpdate":{"properties":{"ssh_private_key":{"type":"string","minLength":1,"title":"Ssh Private Key","description":"New SSH private key content (PEM format)"},"ssh_key_passphrase":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Key Passphrase","description":"New SSH key passphrase (optional, if key is encrypted)"},"test_connection":{"type":"boolean","title":"Test Connection","description":"Test connection with new key before saving","default":true}},"type":"object","required":["ssh_private_key"],"title":"SSHKeyUpdate","description":"Schema for updating SSH private key.","example":{}},"SSHKeyUsageResponse":{"properties":{"key_id":{"type":"string","format":"uuid","title":"Key Id"},"key_name":{"type":"string","title":"Key Name"},"status":{"type":"string","title":"Status"},"is_valid":{"type":"boolean","title":"Is Valid"},"is_expired":{"type":"boolean","title":"Is Expired"},"usage_count":{"type":"integer","title":"Usage Count"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"server_count":{"type":"integer","title":"Server Count"},"servers":{"items":{"$ref":"#/components/schemas/SSHServerInfo"},"type":"array","title":"Servers"},"days_until_expiry":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Days Until Expiry"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["key_id","key_name","status","is_valid","is_expired","usage_count","last_used_at","server_count","servers","days_until_expiry","created_at"],"title":"SSHKeyUsageResponse","description":"Response for key usage/stats endpoint."},"SSHPasswordUpdate":{"properties":{"ssh_password":{"type":"string","minLength":1,"title":"Ssh Password","description":"New SSH password"},"test_connection":{"type":"boolean","title":"Test Connection","description":"Test connection with new password before saving","default":true}},"type":"object","required":["ssh_password"],"title":"SSHPasswordUpdate","description":"Schema for updating SSH password.","example":{}},"SSHServerInfo":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Host"}},"type":"object","required":["id","name","host"],"title":"SSHServerInfo","description":"Server information in key usage response."},"SSHSudoMode":{"type":"string","enum":["auto","none","sudo"],"title":"SSHSudoMode","description":"SSH sudo mode for privileged command execution.\n\nCloud providers like AWS/GCP/Azure use non-root users (ubuntu, ec2-user)\nthat require sudo for privileged operations like Docker commands."},"SSOConfigCreate":{"properties":{"provider_name":{"type":"string","maxLength":64,"title":"Provider Name"},"client_id":{"type":"string","maxLength":255,"title":"Client Id"},"client_secret":{"type":"string","minLength":1,"format":"password","title":"Client Secret","writeOnly":true},"discovery_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Discovery Url"},"issuer":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Issuer"},"authorization_endpoint":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Authorization Endpoint"},"token_endpoint":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Token Endpoint"},"jwks_uri":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Jwks Uri"},"userinfo_endpoint":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Userinfo Endpoint"},"default_scopes":{"type":"string","maxLength":255,"title":"Default Scopes","default":"openid email profile"},"email_domains":{"items":{"type":"string"},"type":"array","title":"Email Domains"}},"additionalProperties":false,"type":"object","required":["provider_name","client_id","client_secret"],"title":"SSOConfigCreate","description":"POST /sso-config payload — accepts discovery_url OR full manual fields."},"SSOConfigRead":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"enabled":{"type":"boolean","title":"Enabled"},"provider_name":{"type":"string","title":"Provider Name"},"client_id":{"type":"string","title":"Client Id"},"client_secret_set":{"type":"boolean","title":"Client Secret Set"},"issuer":{"type":"string","title":"Issuer"},"authorization_endpoint":{"type":"string","title":"Authorization Endpoint"},"token_endpoint":{"type":"string","title":"Token Endpoint"},"jwks_uri":{"type":"string","title":"Jwks Uri"},"userinfo_endpoint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Userinfo Endpoint"},"discovery_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Discovery Url"},"default_scopes":{"type":"string","title":"Default Scopes"},"email_domains":{"items":{"type":"string"},"type":"array","title":"Email Domains"},"last_test_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Test At"},"last_test_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Test Status"},"urls":{"$ref":"#/components/schemas/SSOConfigUrls"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"additionalProperties":false,"type":"object","required":["id","organization_id","enabled","provider_name","client_id","client_secret_set","issuer","authorization_endpoint","token_endpoint","jwks_uri","default_scopes","email_domains","urls","created_at","updated_at"],"title":"SSOConfigRead","description":"GET response — explicitly excludes `client_secret_encrypted`."},"SSOConfigUpdate":{"properties":{"provider_name":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Provider Name"},"client_id":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Client Id"},"client_secret":{"anyOf":[{"type":"string","format":"password","writeOnly":true},{"type":"null"}],"title":"Client Secret"},"discovery_url":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Discovery Url"},"issuer":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Issuer"},"authorization_endpoint":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Authorization Endpoint"},"token_endpoint":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Token Endpoint"},"jwks_uri":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Jwks Uri"},"userinfo_endpoint":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Userinfo Endpoint"},"default_scopes":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Default Scopes"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled"},"email_domains":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Email Domains"}},"additionalProperties":false,"type":"object","title":"SSOConfigUpdate","description":"PATCH /sso-config payload — all fields optional."},"SSOConfigUrls":{"properties":{"discovery":{"type":"string","title":"Discovery","description":"Email-routed login URL (.../login)"},"direct":{"type":"string","title":"Direct","description":"Direct-SSO URL (.../sso/login)"},"callback":{"type":"string","title":"Callback","description":"OAuth redirect URI to paste into the IdP (.../sso/callback)"}},"type":"object","required":["discovery","direct","callback"],"title":"SSOConfigUrls","description":"Three ready-to-share URLs surfaced in Settings → SSO."},"SenderDomainCreateRequest":{"properties":{"smtp_host":{"type":"string","maxLength":253,"minLength":1,"title":"Smtp Host"},"smtp_port":{"type":"integer","maximum":65535.0,"minimum":1.0,"title":"Smtp Port","default":587},"smtp_username":{"anyOf":[{"type":"string","maxLength":320},{"type":"null"}],"title":"Smtp Username"},"smtp_password":{"anyOf":[{"type":"string","maxLength":1024},{"type":"null"}],"title":"Smtp Password"},"smtp_security":{"$ref":"#/components/schemas/SmtpSecuritySchema","default":"starttls"},"default_from_address":{"type":"string","format":"email","title":"Default From Address"},"default_from_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Default From Name"},"default_reply_to":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Default Reply To"}},"type":"object","required":["smtp_host","default_from_address"],"title":"SenderDomainCreateRequest","description":"POST /sender-domain body — full config + From-line defaults.\n\nThe service validates the SMTP credentials BEFORE saving by calling\n`SMTPSenderService.test_connection`; failure → 400 with reason."},"SenderDomainResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"smtp_host":{"type":"string","title":"Smtp Host"},"smtp_port":{"type":"integer","title":"Smtp Port"},"smtp_username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Smtp Username"},"smtp_password_set":{"type":"boolean","title":"Smtp Password Set"},"smtp_security":{"$ref":"#/components/schemas/SmtpSecuritySchema"},"default_from_address":{"type":"string","title":"Default From Address"},"default_from_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default From Name"},"default_reply_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Reply To"},"status":{"$ref":"#/components/schemas/SenderDomainStatusSchema"},"last_test_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Test At"},"last_test_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Test Error"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","smtp_host","smtp_port","smtp_username","smtp_password_set","smtp_security","default_from_address","default_from_name","default_reply_to","status","last_test_at","last_test_error","last_used_at","created_at","updated_at"],"title":"SenderDomainResponse","description":"GET / POST / PATCH / test-connection / test-send response.\n\n`smtp_password_set` is the UI's signal that a password is on file\n(the password itself is never echoed). `last_test_at` /\n`last_test_error` reflect the most recent test or pre-save probe."},"SenderDomainStatusSchema":{"type":"string","enum":["pending_test","active","failed"],"title":"SenderDomainStatusSchema","description":"Schema mirror of models.email.sender_domain.SenderDomainStatus."},"SenderDomainUpdateRequest":{"properties":{"smtp_host":{"anyOf":[{"type":"string","maxLength":253,"minLength":1},{"type":"null"}],"title":"Smtp Host"},"smtp_port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Smtp Port"},"smtp_username":{"anyOf":[{"type":"string","maxLength":320},{"type":"null"}],"title":"Smtp Username"},"smtp_password":{"anyOf":[{"type":"string","maxLength":1024},{"type":"null"}],"title":"Smtp Password"},"smtp_security":{"anyOf":[{"$ref":"#/components/schemas/SmtpSecuritySchema"},{"type":"null"}]},"default_from_address":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Default From Address"},"default_from_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Default From Name"},"default_reply_to":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Default Reply To"}},"type":"object","title":"SenderDomainUpdateRequest","description":"PATCH /sender-domain body — partial update.\n\nA null password means \"keep the saved one\"; an empty-string password\nis rejected. To clear credentials entirely, DELETE the config."},"ServerHealthResponse":{"properties":{"server_id":{"type":"string","format":"uuid","title":"Server Id","description":"Server ID"},"server_name":{"type":"string","title":"Server Name","description":"Server name"},"status":{"type":"string","title":"Status","description":"Health status: healthy, warning, critical, unreachable"},"netdata_available":{"type":"boolean","title":"Netdata Available","description":"Whether Netdata is responding"},"last_check":{"type":"string","format":"date-time","title":"Last Check","description":"When last checked"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Status message"}},"type":"object","required":["server_id","server_name","status","netdata_available","last_check"],"title":"ServerHealthResponse","description":"Quick health check response.","example":{}},"ServerHealthSummary":{"properties":{"server_id":{"type":"string","format":"uuid","title":"Server Id","description":"Server ID"},"server_name":{"type":"string","title":"Server Name","description":"Server name"},"ip_address":{"type":"string","title":"Ip Address","description":"Server IP address"},"status":{"type":"string","title":"Status","description":"Health status: healthy, warning, critical, unreachable"},"cpu_percent":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Cpu Percent","description":"CPU usage percentage"},"memory_percent":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Memory Percent","description":"Memory usage percentage"},"disk_percent":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Disk Percent","description":"Disk usage percentage"},"container_count":{"type":"integer","minimum":0.0,"title":"Container Count","description":"Total container count","default":0},"containers_healthy":{"type":"integer","minimum":0.0,"title":"Containers Healthy","description":"Healthy container count","default":0},"last_check":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Check","description":"When last checked"}},"type":"object","required":["server_id","server_name","ip_address","status"],"title":"ServerHealthSummary","description":"Health summary for a single server.","example":{}},"ServerMetricsResponse":{"properties":{"server_id":{"type":"string","format":"uuid","title":"Server Id","description":"Server ID"},"server_name":{"type":"string","title":"Server Name","description":"Server name"},"summary":{"$ref":"#/components/schemas/MetricsSummary","description":"Quick summary"},"containers":{"items":{"$ref":"#/components/schemas/ContainerMetrics"},"type":"array","title":"Containers","description":"Container metrics"},"timeseries":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/MetricsTimeSeries"},"type":"object"},{"type":"null"}],"title":"Timeseries","description":"Time series data"},"netdata_dashboard_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Netdata Dashboard Url","description":"Direct Netdata dashboard URL"},"queried_at":{"type":"string","format":"date-time","title":"Queried At","description":"When metrics were queried"},"data_source":{"type":"string","title":"Data Source","description":"Data source identifier","default":"netdata_agent"}},"type":"object","required":["server_id","server_name","summary","containers","queried_at"],"title":"ServerMetricsResponse","description":"Full server metrics response.","example":{}},"ServerMode":{"type":"string","enum":["byos","shared"],"title":"ServerMode","description":"Organization server management mode.\n\nDetermines how an organization manages its infrastructure:\n- BYOS: Bring Your Own Server - organization provides and manages servers\n- SHARED: Portal-managed shared servers with allocated quotas"},"ServerRecommendation":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"free_disk_gb":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Free Disk Gb"},"disk_is_estimate":{"type":"boolean","title":"Disk Is Estimate","description":"True when free_disk_gb is a total-disk fallback because monitoring has not reported free space yet (disk_available_gb is NULL).","default":false}},"type":"object","required":["id","name"],"title":"ServerRecommendation","description":"A server available for VM-direct download.","example":{}},"ServerRegistrationRequest":{"properties":{"hostname":{"type":"string","maxLength":255,"title":"Hostname"},"os_name":{"type":"string","maxLength":100,"title":"Os Name"},"os_family":{"type":"string","maxLength":50,"title":"Os Family"},"kernel_version":{"type":"string","maxLength":100,"title":"Kernel Version"},"arch":{"type":"string","maxLength":20,"title":"Arch"},"cpu_cores":{"type":"integer","maximum":512.0,"minimum":1.0,"title":"Cpu Cores"},"ram_mb":{"type":"integer","maximum":2097152.0,"minimum":256.0,"title":"Ram Mb"},"disk_gb":{"type":"integer","maximum":102400.0,"minimum":5.0,"title":"Disk Gb"},"ipv4_address":{"anyOf":[{"type":"string","maxLength":45},{"type":"null"}],"title":"Ipv4 Address"},"ipv6_address":{"anyOf":[{"type":"string","maxLength":45},{"type":"null"}],"title":"Ipv6 Address"},"private_ipv4":{"anyOf":[{"type":"string","maxLength":45},{"type":"null"}],"title":"Private Ipv4"},"ssh_port":{"type":"integer","maximum":65535.0,"minimum":1.0,"title":"Ssh Port","default":22}},"type":"object","required":["hostname","os_name","os_family","kernel_version","arch","cpu_cores","ram_mb","disk_gb"],"title":"ServerRegistrationRequest","description":"Request from install script to register a server."},"ServerRegistrationResponse":{"properties":{"server_id":{"type":"string","format":"uuid","title":"Server Id"},"ssh_public_key":{"type":"string","title":"Ssh Public Key"},"ssh_username":{"type":"string","title":"Ssh Username"},"server_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Name"},"api_base_url":{"type":"string","title":"Api Base Url"},"progress_token":{"type":"string","title":"Progress Token"}},"type":"object","required":["server_id","ssh_public_key","ssh_username","server_name","api_base_url","progress_token"],"title":"ServerRegistrationResponse","description":"Response after successful server registration."},"ServerSSHKeyCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Key name (unique within organization)"}},"type":"object","required":["name"],"title":"ServerSSHKeyCreate","description":"Request schema for creating a new server SSH key."},"ServerSSHKeyDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"fingerprint":{"type":"string","title":"Fingerprint"},"key_type":{"type":"string","title":"Key Type","default":"ed25519"},"is_synced_to":{"items":{"type":"string"},"type":"array","title":"Is Synced To","description":"List of cloud providers this key is synced to"},"servers_using_count":{"type":"integer","title":"Servers Using Count","description":"Number of servers currently using this key","default":0},"is_active":{"type":"boolean","title":"Is Active","default":true},"create_date":{"type":"string","format":"date-time","title":"Create Date"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"public_key":{"type":"string","title":"Public Key"}},"type":"object","required":["id","name","fingerprint","create_date","public_key"],"title":"ServerSSHKeyDetailResponse","description":"Detailed response including public key."},"ServerSSHKeyDownloadResponse":{"properties":{"private_key":{"type":"string","title":"Private Key","description":"Decrypted private key in PEM format"},"public_key":{"type":"string","title":"Public Key","description":"Public key in OpenSSH format"},"fingerprint":{"type":"string","title":"Fingerprint"},"filename":{"type":"string","title":"Filename","description":"Suggested filename for saving"},"instructions":{"type":"string","title":"Instructions","description":"Usage instructions"}},"type":"object","required":["private_key","public_key","fingerprint","filename","instructions"],"title":"ServerSSHKeyDownloadResponse","description":"Response schema for downloading a server SSH key."},"ServerSSHKeyListResponse":{"properties":{"keys":{"items":{"$ref":"#/components/schemas/ServerSSHKeyResponse"},"type":"array","title":"Keys"},"total":{"type":"integer","title":"Total","description":"Total number of keys"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id"}},"type":"object","required":["keys","total","organization_id"],"title":"ServerSSHKeyListResponse","description":"Response schema for listing server SSH keys."},"ServerSSHKeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"fingerprint":{"type":"string","title":"Fingerprint"},"key_type":{"type":"string","title":"Key Type","default":"ed25519"},"is_synced_to":{"items":{"type":"string"},"type":"array","title":"Is Synced To","description":"List of cloud providers this key is synced to"},"servers_using_count":{"type":"integer","title":"Servers Using Count","description":"Number of servers currently using this key","default":0},"is_active":{"type":"boolean","title":"Is Active","default":true},"create_date":{"type":"string","format":"date-time","title":"Create Date"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"}},"type":"object","required":["id","name","fingerprint","create_date"],"title":"ServerSSHKeyResponse","description":"Response schema for a server SSH key (without private key)."},"ServerSSHKeyRotateResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"old_key_id":{"type":"string","format":"uuid","title":"Old Key Id"},"new_key":{"$ref":"#/components/schemas/ServerSSHKeyResponse"},"message":{"type":"string","title":"Message","description":"Information about the rotation and next steps"}},"type":"object","required":["success","old_key_id","new_key","message"],"title":"ServerSSHKeyRotateResponse","description":"Response schema for key rotation."},"ServerStats":{"properties":{"online_count":{"type":"integer","minimum":0.0,"title":"Online Count","description":"Number of online servers","default":0},"total_count":{"type":"integer","minimum":0.0,"title":"Total Count","description":"Total number of servers","default":0},"avg_cpu":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Avg Cpu","description":"Average CPU usage across servers (%)","default":0.0},"avg_memory":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Avg Memory","description":"Average memory usage across servers (%)","default":0.0},"critical_count":{"type":"integer","minimum":0.0,"title":"Critical Count","description":"Number of servers in critical state","default":0}},"type":"object","title":"ServerStats","description":"Server statistics for dashboard overview.","example":{}},"ServerTestResult":{"properties":{"vm_id":{"type":"string","format":"uuid","title":"Vm Id"},"vm_name":{"type":"string","title":"Vm Name"},"overall_status":{"$ref":"#/components/schemas/ExternalDBConnectionStatus"},"server_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Version"},"sub_tests":{"items":{"$ref":"#/components/schemas/ConnectionTestSubResult"},"type":"array","title":"Sub Tests"},"error_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Summary"}},"type":"object","required":["vm_id","vm_name","overall_status","sub_tests"],"title":"ServerTestResult","description":"One server's result in a multi-server connection test.","example":{}},"SetProviderEnabledRequest":{"properties":{"provider":{"type":"string","title":"Provider","description":"Provider ID (cloudflare, route53, etc.)"},"enabled":{"type":"boolean","title":"Enabled","description":"Whether to enable the provider"}},"type":"object","required":["provider","enabled"],"title":"SetProviderEnabledRequest","description":"Request to enable/disable a DNS provider."},"SetProviderEnabledResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"provider":{"type":"string","title":"Provider"},"enabled":{"type":"boolean","title":"Enabled"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"}},"type":"object","required":["success","provider","enabled"],"title":"SetProviderEnabledResponse","description":"Response for provider enable/disable."},"SetRepoEnvironmentsRequest":{"properties":{"environment_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Environment Ids","description":"Active environment IDs this repo should apply to. Environments not listed are excluded. Empty (or all active envs) clears every exclusion for this repo.","default":[]}},"type":"object","title":"SetRepoEnvironmentsRequest","description":"Request to set which of a project's active environments a project\nadditional repo applies to.\n\nThis is an ALLOWLIST (\"apply this repo to these environments\") — the\nserver translates it into `EnvironmentRepoOverride` exclusion rows for\nevery active project environment NOT in this list (repos are visible\neverywhere by default; exclusion is the only thing actually stored).\nAn empty list — or a list covering every active environment — clears\nall exclusions for the repo (no restriction).","example":{}},"SetRepoEnvironmentsResponse":{"properties":{"repo_id":{"type":"string","format":"uuid","title":"Repo Id","description":"ID of the project additional repo"},"environment_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Environment Ids","description":"Active environment IDs this repo currently applies to","default":[]},"excluded_environment_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Excluded Environment Ids","description":"Active environment IDs this repo is currently excluded from","default":[]}},"type":"object","required":["repo_id"],"title":"SetRepoEnvironmentsResponse","description":"Resulting environment-targeting state for a project additional repo\nafter a `SetRepoEnvironmentsRequest` write.","example":{}},"SetupCompleteRequest":{"properties":{"docker_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Docker Version"},"traefik_running":{"type":"boolean","title":"Traefik Running","default":false},"netdata_running":{"type":"boolean","title":"Netdata Running","default":false},"firewall_active":{"type":"boolean","title":"Firewall Active","default":false},"fail2ban_active":{"type":"boolean","title":"Fail2Ban Active","default":false},"ssh_key_installed":{"type":"boolean","title":"Ssh Key Installed","default":false}},"type":"object","title":"SetupCompleteRequest","description":"Final report from install script after setup completes."},"SetupCompleteResponse":{"properties":{"status":{"type":"string","title":"Status"},"message":{"type":"string","title":"Message"}},"type":"object","required":["status","message"],"title":"SetupCompleteResponse","description":"Response after setup completion."},"SetupProgressRequest":{"properties":{"step":{"type":"integer","maximum":10.0,"minimum":1.0,"title":"Step"},"total_steps":{"type":"integer","maximum":10.0,"minimum":1.0,"title":"Total Steps"},"status":{"type":"string","pattern":"^(running|completed|failed)$","title":"Status"},"message":{"type":"string","maxLength":500,"title":"Message"},"details":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Details"}},"type":"object","required":["step","total_steps","status","message"],"title":"SetupProgressRequest","description":"Progress update from install script during setup."},"SetupProgressResponse":{"properties":{"acknowledged":{"type":"boolean","title":"Acknowledged","default":true}},"type":"object","title":"SetupProgressResponse","description":"Acknowledgement of progress update."},"SharedServerCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Server display name"},"ipv4_address":{"type":"string","title":"Ipv4 Address","description":"IPv4 address"},"ssh_username":{"type":"string","title":"Ssh Username","description":"SSH username","default":"root"},"ssh_private_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Private Key","description":"SSH private key (encrypted)"},"ssh_password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Password","description":"SSH password (encrypted)"},"ssh_port":{"type":"integer","maximum":65535.0,"minimum":1.0,"title":"Ssh Port","description":"SSH port","default":22},"provider":{"type":"string","title":"Provider","description":"Cloud provider","default":"custom"},"region":{"type":"string","title":"Region","description":"Cloud region/datacenter"},"cpu_cores":{"type":"integer","minimum":1.0,"title":"Cpu Cores","description":"Number of CPU cores"},"memory_gb":{"type":"integer","minimum":1.0,"title":"Memory Gb","description":"Memory in GB"},"disk_gb":{"type":"integer","minimum":10.0,"title":"Disk Gb","description":"Disk size in GB"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Admin notes"}},"type":"object","required":["name","ipv4_address","region","cpu_cores","memory_gb","disk_gb"],"title":"SharedServerCreate","description":"Request schema for creating a shared server.","example":{"cpu_cores":8,"disk_gb":500,"ipv4_address":"165.22.65.97","memory_gb":32,"name":"shared-us-east-1","notes":"Shared server for free tier users","provider":"digitalocean","region":"nyc3","ssh_port":22,"ssh_private_key":"-----BEGIN OPENSSH PRIVATE KEY-----...","ssh_username":"root"}},"SharedServerListResponse":{"properties":{"shared_servers":{"items":{"$ref":"#/components/schemas/SharedServerResponse"},"type":"array","title":"Shared Servers"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["shared_servers","total"],"title":"SharedServerListResponse","description":"Response schema for listing shared servers."},"SharedServerResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"ipv4_address":{"type":"string","title":"Ipv4 Address"},"is_shared":{"type":"boolean","title":"Is Shared"},"owner_type":{"type":"string","title":"Owner Type"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id"},"status":{"type":"string","title":"Status"},"provider":{"type":"string","title":"Provider"},"region":{"type":"string","title":"Region"},"cpu_cores":{"type":"integer","title":"Cpu Cores"},"memory_gb":{"type":"integer","title":"Memory Gb"},"disk_gb":{"type":"integer","title":"Disk Gb"},"ssh_username":{"type":"string","title":"Ssh Username"},"ssh_port":{"type":"integer","title":"Ssh Port"},"allocations_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Allocations Count"},"organizations_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organizations Count"},"utilization":{"anyOf":[{"$ref":"#/components/schemas/UtilizationInfo"},{"type":"null"}]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","name","ipv4_address","is_shared","owner_type","organization_id","status","provider","region","cpu_cores","memory_gb","disk_gb","ssh_username","ssh_port","created_at","updated_at"],"title":"SharedServerResponse","description":"Response schema for shared server details."},"SharedServerUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"cpu_cores":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Cpu Cores"},"memory_gb":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Memory Gb"},"disk_gb":{"anyOf":[{"type":"integer","minimum":10.0},{"type":"null"}],"title":"Disk Gb"}},"type":"object","title":"SharedServerUpdate","description":"Request schema for updating a shared server.","example":{"cpu_cores":16,"memory_gb":64,"name":"shared-us-east-1-updated","notes":"Upgraded server capacity"}},"ShellAccessRequest":{"properties":{"public_key":{"type":"string","title":"Public Key","description":"User's SSH public key (ed25519 or rsa)","examples":["ssh-ed25519 AAAA... user@example.com"]},"container_type":{"$ref":"#/components/schemas/ShellAccessType","description":"Type of container to access","default":"odoo"}},"type":"object","required":["public_key"],"title":"ShellAccessRequest","description":"Request to set up shell access."},"ShellAccessResponse":{"properties":{"username":{"type":"string","title":"Username","description":"SSH username to use"},"host":{"type":"string","title":"Host","description":"Host to connect to"},"port":{"type":"integer","title":"Port","description":"SSH port"},"container_type":{"type":"string","title":"Container Type","description":"Container type (odoo/postgres)"},"container_name":{"type":"string","title":"Container Name","description":"Container name"},"ssh_command":{"type":"string","title":"Ssh Command","description":"Full SSH command to connect"},"instructions":{"type":"string","title":"Instructions","description":"Connection instructions"}},"type":"object","required":["username","host","port","container_type","container_name","ssh_command","instructions"],"title":"ShellAccessResponse","description":"Response with shell access credentials."},"ShellAccessType":{"type":"string","enum":["odoo","postgres"],"title":"ShellAccessType","description":"Type of shell access."},"SignInEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp"},"action":{"type":"string","title":"Action"},"action_display":{"type":"string","title":"Action Display"},"success":{"type":"boolean","title":"Success"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Method"}},"type":"object","required":["id","timestamp","action","action_display","success"],"title":"SignInEventResponse","description":"#1431: one of the caller's own sign-in or account-security events.","example":{}},"SignInListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SignInEventResponse"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"SignInListResponse","description":"#1431: the caller's recent sign-in and account-security events.","example":{}},"SmtpSecuritySchema":{"type":"string","enum":["starttls","tls","none"],"title":"SmtpSecuritySchema","description":"Schema mirror of models.email.sender_domain.SmtpSecurity."},"StartLoginEmailChangeRequest":{"properties":{"new_email":{"type":"string","format":"email","title":"New Email","description":"The address the user will sign in with"}},"type":"object","required":["new_email"],"title":"StartLoginEmailChangeRequest","description":"Start a support-run login email change (#1175)."},"StartLoginEmailChangeResponse":{"properties":{"message":{"type":"string","title":"Message"},"new_email":{"type":"string","title":"New Email"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"}},"type":"object","required":["message","new_email","expires_at"],"title":"StartLoginEmailChangeResponse"},"StorageConfigCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Display name for this storage configuration"},"provider":{"$ref":"#/components/schemas/StorageProviderType","description":"Cloud storage provider type"},"bucket":{"type":"string","maxLength":255,"title":"Bucket","description":"Storage bucket name (not used for SFTP/FTP)","default":""},"region":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Region","description":"Provider region (e.g., 'us-east-1' for S3)"},"endpoint_url":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Endpoint Url","description":"Custom endpoint URL (for R2, B2, MinIO)"},"path_prefix":{"type":"string","maxLength":255,"title":"Path Prefix","description":"Prefix for all storage keys (e.g., 'backups/org-123/')","default":""},"storage_class":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Storage Class","description":"S3 storage class (STANDARD, GLACIER, etc.)"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this is the default storage for the org","default":false},"ftp_host":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Ftp Host","description":"FTP/SFTP server hostname or IP address"},"ftp_port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Ftp Port","description":"FTP/SFTP port (default: 21 for FTP, 22 for SFTP)"},"ftp_use_ssl":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Ftp Use Ssl","description":"Use FTPS (FTP over SSL/TLS) - only applies to FTP provider","default":false},"ftp_passive_mode":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Ftp Passive Mode","description":"Use passive mode for FTP connections","default":true},"ftp_base_path":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Ftp Base Path","description":"Base directory path on FTP/SFTP server (e.g., '/backups')"},"cloud_account_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cloud Account Id","description":"Link to CloudAccount for credentials. When set, credentials are pulled from the account."},"access_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Key","description":"Storage access key. Required when cloud_account_id is not set."},"secret_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secret Key","description":"Storage secret key. Required when cloud_account_id is not set."},"account_id":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Account Id","description":"Cloudflare account ID (for R2 only)"}},"type":"object","required":["name","provider"],"title":"StorageConfigCreate","description":"Schema for creating a storage configuration.\n\nTwo modes of authentication:\n1. Linked to CloudAccount: Set cloud_account_id, credentials are pulled from account\n2. Direct credentials: Set access_key/secret_key directly\n\nWhen cloud_account_id is set:\n- Credentials (access_key, secret_key) should NOT be provided\n- Credentials will be fetched from the CloudAccount\n\nWhen cloud_account_id is None:\n- Credentials (access_key, secret_key) are REQUIRED\n- Uses legacy direct credential storage","example":{}},"StorageConfigResponse":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Display name for this storage configuration"},"provider":{"$ref":"#/components/schemas/StorageProviderType","description":"Cloud storage provider type"},"bucket":{"type":"string","maxLength":255,"title":"Bucket","description":"Storage bucket name (not used for SFTP/FTP)","default":""},"region":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Region","description":"Provider region (e.g., 'us-east-1' for S3)"},"endpoint_url":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Endpoint Url","description":"Custom endpoint URL (for R2, B2, MinIO)"},"path_prefix":{"type":"string","maxLength":255,"title":"Path Prefix","description":"Prefix for all storage keys (e.g., 'backups/org-123/')","default":""},"storage_class":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Storage Class","description":"S3 storage class (STANDARD, GLACIER, etc.)"},"is_default":{"type":"boolean","title":"Is Default","description":"Whether this is the default storage for the org","default":false},"ftp_host":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Ftp Host","description":"FTP/SFTP server hostname or IP address"},"ftp_port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Ftp Port","description":"FTP/SFTP port (default: 21 for FTP, 22 for SFTP)"},"ftp_use_ssl":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Ftp Use Ssl","description":"Use FTPS (FTP over SSL/TLS) - only applies to FTP provider","default":false},"ftp_passive_mode":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Ftp Passive Mode","description":"Use passive mode for FTP connections","default":true},"ftp_base_path":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Ftp Base Path","description":"Base directory path on FTP/SFTP server (e.g., '/backups')"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization that owns this config (None for platform-level)"},"cloud_account_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cloud Account Id","description":"Linked CloudAccount ID (if using cloud account credentials)"},"cloud_account_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cloud Account Provider","description":"Provider type of linked cloud account (e.g., 'hetzner', 'aws')"},"cloud_account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cloud Account Name","description":"Name of linked cloud account"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether storage is active"},"total_size_bytes":{"type":"integer","title":"Total Size Bytes","description":"Total storage used in bytes"},"object_count":{"type":"integer","title":"Object Count","description":"Number of objects stored"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At","description":"Last time storage was used"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["name","provider","id","is_active","total_size_bytes","object_count","created_at","updated_at"],"title":"StorageConfigResponse","description":"Schema for storage configuration response.","example":{}},"StorageConfigSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"provider":{"type":"string","title":"Provider"},"backup_count":{"type":"integer","title":"Backup Count","default":0},"total_backup_size_bytes":{"type":"integer","title":"Total Backup Size Bytes","default":0}},"type":"object","required":["id","name","provider"],"title":"StorageConfigSummary","description":"Summary of a storage config for impact report."},"StorageConfigUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Display name"},"bucket":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Bucket","description":"Storage bucket name"},"region":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Region","description":"Provider region"},"endpoint_url":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Endpoint Url","description":"Custom endpoint URL"},"path_prefix":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Path Prefix","description":"Storage key prefix"},"storage_class":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Storage Class","description":"S3 storage class"},"access_key":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Access Key","description":"New access key"},"secret_key":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Secret Key","description":"New secret key"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default","description":"Set as default storage"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Enable/disable storage"},"ftp_host":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Ftp Host","description":"FTP/SFTP server hostname"},"ftp_port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Ftp Port","description":"FTP/SFTP port"},"ftp_use_ssl":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Ftp Use Ssl","description":"Use FTPS"},"ftp_passive_mode":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Ftp Passive Mode","description":"Use passive mode"},"ftp_base_path":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Ftp Base Path","description":"Base directory path"}},"type":"object","title":"StorageConfigUpdate","description":"Schema for updating a storage configuration.","example":{}},"StorageProviderType":{"type":"string","enum":["aws_s3","gcp_storage","azure_blob","digitalocean_spaces","vultr_object","linode_object","ovhcloud_object","cloudflare_r2","backblaze_b2","wasabi","minio","sftp","ftp"],"title":"StorageProviderType","description":"Supported cloud storage providers."},"StorageTestResponse":{"properties":{"success":{"type":"boolean","title":"Success","description":"Whether connection test passed"},"message":{"type":"string","title":"Message","description":"Test result message"},"bucket_exists":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Bucket Exists","description":"Whether bucket exists"},"can_write":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Can Write","description":"Whether we can write to bucket"},"can_read":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Can Read","description":"Whether we can read from bucket"},"latency_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Latency Ms","description":"Connection latency in milliseconds"}},"type":"object","required":["success","message"],"title":"StorageTestResponse","description":"Response from testing storage connection.","example":{}},"SubdomainPreviewRequest":{"properties":{"env_name":{"type":"string","maxLength":100,"minLength":1,"title":"Env Name","description":"Environment name to preview"}},"type":"object","required":["env_name"],"title":"SubdomainPreviewRequest"},"SubdomainPreviewResponse":{"properties":{"subdomain":{"type":"string","title":"Subdomain"},"domain":{"type":"string","title":"Domain"},"system_url":{"type":"string","title":"System Url"}},"type":"object","required":["subdomain","domain","system_url"],"title":"SubdomainPreviewResponse"},"SubscriptionCancelRequest":{"properties":{"immediate":{"type":"boolean","title":"Immediate","description":"Whether to cancel immediately or at period end","default":false},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"Cancellation reason"},"cancel_reason":{"anyOf":[{"type":"string","enum":["too_expensive","not_using","missing_feature","switching","technical_issues","project_ended","other"]},{"type":"null"}],"title":"Cancel Reason","description":"Structured cancel reason"},"cancel_feedback":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Cancel Feedback","description":"Free-text cancellation feedback"}},"type":"object","title":"SubscriptionCancelRequest","description":"Request to cancel subscription.","example":{}},"SubscriptionPauseRequest":{"properties":{"duration_months":{"type":"integer","maximum":3.0,"minimum":1.0,"title":"Duration Months","description":"Duration to pause in months (1-3)","default":1}},"type":"object","title":"SubscriptionPauseRequest","description":"Request to pause subscription.","example":{}},"SubscriptionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Subscription ID"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"base_plan":{"type":"string","title":"Base Plan","description":"Current base plan"},"status":{"type":"string","title":"Status","description":"Subscription status"},"billing_interval":{"type":"string","title":"Billing Interval","description":"Billing interval (monthly/annual)"},"monthly_price":{"type":"string","title":"Monthly Price","description":"Monthly base plan price"},"annual_price":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Annual Price","description":"Annual base plan price"},"is_annual":{"type":"boolean","title":"Is Annual","description":"Whether billing is annual"},"stripe_customer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Customer Id","description":"Stripe customer ID"},"stripe_subscription_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Subscription Id","description":"Stripe subscription ID"},"trial_ends_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Trial Ends At","description":"Trial end date"},"current_period_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Current Period Start","description":"Current billing period start"},"current_period_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Current Period End","description":"Current billing period end"},"pending_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pending Plan","description":"Plan scheduled for next period"},"pending_plan_effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Pending Plan Effective At","description":"When pending plan takes effect"},"paused_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paused At","description":"When subscription was paused"},"resumes_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resumes At","description":"When subscription resumes"},"cancelled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cancelled At","description":"When subscription was cancelled"},"cancel_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cancel At","description":"When subscription will cancel"},"cancel_at_period_end":{"type":"boolean","title":"Cancel At Period End","description":"Whether cancelling at period end","default":false},"is_blocked":{"type":"boolean","title":"Is Blocked","description":"Whether management operations are blocked due to subscription status","default":false},"grace_period_ends_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Grace Period Ends At","description":"When the grace period expires (after which operations are blocked)"},"grace_days_remaining":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Grace Days Remaining","description":"Number of days remaining in grace period (None if not in grace period)"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"}},"type":"object","required":["id","organization_id","base_plan","status","billing_interval","monthly_price","is_annual","created_at","updated_at"],"title":"SubscriptionResponse","description":"Subscription details.","example":{}},"SupportStatsResponse":{"properties":{"open_tickets":{"type":"integer","title":"Open Tickets"},"avg_first_response_hours":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg First Response Hours"},"avg_resolution_hours":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Resolution Hours"},"csat_average":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Csat Average"},"total_tickets_this_month":{"type":"integer","title":"Total Tickets This Month"},"sla_breach_count":{"type":"integer","title":"Sla Breach Count"}},"type":"object","required":["open_tickets","total_tickets_this_month","sla_breach_count"],"title":"SupportStatsResponse","description":"Helpdesk dashboard statistics.","example":{}},"SupportedProvidersResponse":{"properties":{"providers":{"items":{"$ref":"#/components/schemas/ProviderInfo"},"type":"array","title":"Providers","description":"Available providers"}},"type":"object","required":["providers"],"title":"SupportedProvidersResponse","description":"List of supported providers.","example":{}},"SyncRepositoryResponse":{"properties":{"task_id":{"type":"string","format":"uuid","title":"Task Id"},"repository_id":{"type":"string","format":"uuid","title":"Repository Id"},"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"message":{"type":"string","title":"Message","default":"Sync started"}},"type":"object","required":["task_id","repository_id","environment_id"],"title":"SyncRepositoryResponse","description":"Schema for repository sync response.","example":{}},"TOTPDisableRequest":{"properties":{"code":{"type":"string","title":"Code"},"password":{"type":"string","title":"Password"}},"type":"object","required":["code","password"],"title":"TOTPDisableRequest","description":"Request to disable TOTP."},"TOTPEnableRequest":{"properties":{"code":{"type":"string","title":"Code"}},"type":"object","required":["code"],"title":"TOTPEnableRequest","description":"Request to enable TOTP."},"TOTPSetupResponse":{"properties":{"secret":{"type":"string","title":"Secret"},"qr_uri":{"type":"string","title":"Qr Uri"},"backup_codes":{"items":{"type":"string"},"type":"array","title":"Backup Codes"}},"type":"object","required":["secret","qr_uri","backup_codes"],"title":"TOTPSetupResponse","description":"Response for TOTP setup."},"TaskCancelResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Task ID that was cancelled"},"cancelled":{"type":"boolean","title":"Cancelled","description":"Whether cancellation was successful"},"message":{"type":"string","title":"Message","description":"Human-readable result message"}},"type":"object","required":["id","cancelled","message"],"title":"TaskCancelResponse","description":"Response for cancelling a task.","example":{}},"TaskListResponse":{"properties":{"tasks":{"items":{"$ref":"#/components/schemas/TaskResponse"},"type":"array","title":"Tasks","description":"List of tasks"},"total":{"type":"integer","title":"Total","description":"Total number of tasks matching criteria"},"page":{"type":"integer","title":"Page","description":"Current page number","default":1},"page_size":{"type":"integer","title":"Page Size","description":"Number of items per page","default":20}},"type":"object","required":["tasks","total"],"title":"TaskListResponse","description":"Response for listing tasks.","example":{}},"TaskResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique task identifier"},"task_type":{"$ref":"#/components/schemas/TaskType","description":"Type of task"},"status":{"$ref":"#/components/schemas/TaskStatus","description":"Current task status"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id","description":"Environment ID if applicable"},"environment_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environment Name","description":"Environment name (e.g. 'production')"},"project_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Name","description":"Project name for this environment"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization that owns this task"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization display name"},"triggered_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Triggered By","description":"User who triggered this task (null for system-triggered tasks)"},"triggered_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Triggered By Name","description":"Name or email of the user who triggered this task"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id","description":"Server ID if applicable"},"server_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Server Name","description":"Server display name"},"current_step":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Step","description":"Current step being executed"},"progress_percent":{"type":"integer","title":"Progress Percent","description":"Overall progress percentage (0-100)","default":0},"steps_completed":{"type":"integer","title":"Steps Completed","description":"Number of steps completed","default":0},"total_steps":{"type":"integer","title":"Total Steps","description":"Total number of steps","default":1},"queued_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Queued At","description":"When task was queued"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When task started executing"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At","description":"When task completed (success or failure)"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When task was created"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Error message if task failed"},"retry_count":{"type":"integer","title":"Retry Count","description":"Number of retry attempts made","default":0},"max_retries":{"type":"integer","title":"Max Retries","description":"Maximum retry attempts allowed","default":3},"duration_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Seconds","description":"Task duration in seconds (if completed)"},"is_terminal":{"type":"boolean","title":"Is Terminal","description":"Whether task is in terminal state (completed/failed/cancelled)","default":false},"can_cancel":{"type":"boolean","title":"Can Cancel","description":"Whether task can be cancelled","default":false},"arq_job_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Arq Job Id","description":"ARQ job ID for worker tracking"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Human-readable status message"},"error_traceback":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Traceback","description":"Full error traceback if task failed"},"result":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Result","description":"Task result data if completed successfully"},"last_heartbeat":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Heartbeat","description":"Last heartbeat timestamp from worker"},"heartbeat_enabled":{"type":"boolean","title":"Heartbeat Enabled","description":"Whether heartbeat monitoring is enabled","default":true},"max_timeout_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Timeout Seconds","description":"Custom timeout override for this task"}},"type":"object","required":["id","task_type","status","organization_id","created_at"],"title":"TaskResponse","description":"Response schema for a single task.","example":{}},"TaskStatus":{"type":"string","enum":["pending","queued","running","completed","failed","cancelled","retrying"],"title":"TaskStatus","description":"Task execution status."},"TaskType":{"type":"string","enum":["deploy","redeploy","clone","destroy","sync_status","backup","restore","start","stop","restart","pause","resume","module_deploy","module_sync","module_deploy_all"],"title":"TaskType","description":"Types of background tasks."},"TaskTypeBreakdown":{"properties":{"task_type":{"type":"string","title":"Task Type"},"count":{"type":"integer","title":"Count"},"completed":{"type":"integer","title":"Completed"},"failed":{"type":"integer","title":"Failed"}},"type":"object","required":["task_type","count","completed","failed"],"title":"TaskTypeBreakdown","description":"Task counts per task type."},"TeamCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name","description":"Team name"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Team description"},"color":{"type":"string","title":"Color","description":"Team color for UI display","default":"blue"}},"type":"object","required":["name"],"title":"TeamCreate","description":"Schema for creating a team.","example":{}},"TeamListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TeamResponse"},"type":"array","title":"Items","description":"List of teams"},"total":{"type":"integer","title":"Total","description":"Total number of teams"}},"type":"object","required":["items","total"],"title":"TeamListResponse","description":"Response for listing teams with pagination info.","example":{}},"TeamMemberCreate":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id","description":"ID of the user to add to the team"}},"type":"object","required":["user_id"],"title":"TeamMemberCreate","description":"Schema for adding a member to a team.","example":{}},"TeamMemberListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TeamMemberResponse"},"type":"array","title":"Items","description":"List of team members"},"total":{"type":"integer","title":"Total","description":"Total number of members"}},"type":"object","required":["items","total"],"title":"TeamMemberListResponse","description":"Response for listing team members.","example":{}},"TeamMemberResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Team membership ID"},"team_id":{"type":"string","format":"uuid","title":"Team Id","description":"Team ID"},"user_id":{"type":"string","format":"uuid","title":"User Id","description":"User ID"},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email","description":"User email (from relationship)"},"user_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Name","description":"User display name (from relationship)"},"added_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Added By","description":"User who added this member"},"added_at":{"type":"string","format":"date-time","title":"Added At","description":"When the member was added"}},"type":"object","required":["id","team_id","user_id","added_at"],"title":"TeamMemberResponse","description":"Schema for team member response.","example":{}},"TeamProjectInfo":{"properties":{"project_id":{"type":"string","format":"uuid","title":"Project Id","description":"Project ID"},"project_name":{"type":"string","title":"Project Name","description":"Project name"},"role":{"type":"string","title":"Role","description":"Team's role on this project"}},"type":"object","required":["project_id","project_name","role"],"title":"TeamProjectInfo","description":"Minimal project info for team details.","example":{}},"TeamResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization this team belongs to"},"name":{"type":"string","title":"Name","description":"Team name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Team description"},"color":{"type":"string","title":"Color","description":"Team color for UI display","default":"blue"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By","description":"User who created the team"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"member_count":{"type":"integer","title":"Member Count","description":"Number of members in the team","default":0},"project_count":{"type":"integer","title":"Project Count","description":"Number of projects assigned to the team","default":0}},"type":"object","required":["id","organization_id","name","created_at"],"title":"TeamResponse","description":"Full team response schema.","example":{}},"TeamRole":{"type":"string","enum":["admin","developer","viewer"],"title":"TeamRole","description":"Team role on a project.\n\nDefines the level of access a team has when assigned to a project:\n- ADMIN: Full project access, can manage environments and settings\n- DEVELOPER: Can deploy and manage environments\n- VIEWER: Read-only access to project data"},"TeamUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name","description":"Team name"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description","description":"Team description"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"Team color for UI display"}},"type":"object","title":"TeamUpdate","description":"Schema for updating a team. All fields are optional.","example":{}},"TeamWithMembers":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization this team belongs to"},"name":{"type":"string","title":"Name","description":"Team name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Team description"},"color":{"type":"string","title":"Color","description":"Team color for UI display","default":"blue"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By","description":"User who created the team"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"member_count":{"type":"integer","title":"Member Count","description":"Number of members in the team","default":0},"project_count":{"type":"integer","title":"Project Count","description":"Number of projects assigned to the team","default":0},"members":{"items":{"$ref":"#/components/schemas/TeamMemberResponse"},"type":"array","title":"Members","description":"List of team members"}},"type":"object","required":["id","organization_id","name","created_at"],"title":"TeamWithMembers","description":"Extended team response including member list.","example":{}},"TeamWithProjectsDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Team ID"},"name":{"type":"string","title":"Name","description":"Team name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Team description"},"color":{"type":"string","title":"Color","description":"Team color"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"project_count":{"type":"integer","title":"Project Count","description":"Number of projects"},"projects":{"items":{"$ref":"#/components/schemas/TeamProjectInfo"},"type":"array","title":"Projects","description":"Projects this team has access to"}},"type":"object","required":["id","name","description","color","organization_id","project_count"],"title":"TeamWithProjectsDetail","description":"Team details including all projects it has access to.","example":{}},"TerminalTarget":{"type":"string","enum":["server","odoo","postgres","dev"],"title":"TerminalTarget","description":"Target for terminal connection."},"TestConnectionResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"tested_at":{"type":"string","format":"date-time","title":"Tested At"}},"type":"object","required":["success","tested_at"],"title":"TestConnectionResponse","description":"POST /sender-domain/test-connection response shape."},"TestSendRequest":{"properties":{"to":{"type":"string","format":"email","title":"To"}},"type":"object","required":["to"],"title":"TestSendRequest","description":"POST /sender-domain/test-send body — single recipient."},"TestServerOption":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"used_by_environments":{"type":"integer","title":"Used By Environments","description":"Active environments on this server that use this connection","default":0},"is_default":{"type":"boolean","title":"Is Default","description":"This is the connection's default test server","default":false}},"type":"object","required":["id","name"],"title":"TestServerOption","description":"A server a connection test may run on (GET /{connection_id}/test-servers).","example":{}},"TestServersResponse":{"properties":{"servers":{"items":{"$ref":"#/components/schemas/TestServerOption"},"type":"array","title":"Servers"},"default_vm_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Default Vm Id"}},"type":"object","required":["servers"],"title":"TestServersResponse","description":"Response for GET /{connection_id}/test-servers.","example":{}},"ThemePatchRequest":{"properties":{"primary_color":{"anyOf":[{"type":"string","maxLength":9,"pattern":"^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"},{"type":"null"}],"title":"Primary Color"},"secondary_color":{"anyOf":[{"type":"string","maxLength":9,"pattern":"^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"},{"type":"null"}],"title":"Secondary Color"}},"additionalProperties":false,"type":"object","title":"ThemePatchRequest","description":"PATCH /theme — colour fields only."},"ThemeResponse":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"favicon_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Favicon Url"},"login_bg_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Login Bg Url"},"primary_color":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"},{"type":"null"}],"title":"Primary Color"},"secondary_color":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}([0-9a-fA-F]{2})?$"},{"type":"null"}],"title":"Secondary Color"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"updated_by":{"anyOf":[{"$ref":"#/components/schemas/_ThemeUserRef"},{"type":"null"}]},"etag":{"type":"string","title":"Etag"}},"type":"object","required":["organization_id","logo_url","favicon_url","login_bg_url","updated_at","etag"],"title":"ThemeResponse","description":"Authenticated GET /theme — full payload."},"ThemeUploadResponse":{"properties":{"asset_type":{"type":"string","title":"Asset Type"},"url":{"type":"string","title":"Url"},"size_bytes":{"type":"integer","title":"Size Bytes"},"dimensions":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Dimensions"}},"type":"object","required":["asset_type","url","size_bytes"],"title":"ThemeUploadResponse","description":"POST /theme/upload/{asset_type} — single asset result."},"TicketAttachmentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"file_name":{"type":"string","title":"File Name"},"file_size":{"type":"integer","title":"File Size"},"content_type":{"type":"string","title":"Content Type"}},"type":"object","required":["id","file_name","file_size","content_type"],"title":"TicketAttachmentResponse","description":"File attachment metadata.","example":{}},"TicketCategoryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"}},"type":"object","required":["id","name","slug","is_active"],"title":"TicketCategoryResponse","description":"Ticket category for display.","example":{}},"TicketCommentCreateRequest":{"properties":{"content":{"type":"string","maxLength":50000,"minLength":1,"title":"Content","description":"Comment body"},"is_internal":{"type":"boolean","title":"Is Internal","description":"True = portal admin internal note (hidden from customer)","default":false}},"type":"object","required":["content"],"title":"TicketCommentCreateRequest","description":"Add a comment to a ticket.","example":{}},"TicketCommentResponseFull":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"author":{"anyOf":[{"$ref":"#/components/schemas/UserBriefResponse"},{"type":"null"}]},"content":{"type":"string","title":"Content"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"attachments":{"items":{"$ref":"#/components/schemas/TicketAttachmentResponse"},"type":"array","title":"Attachments","default":[]},"is_internal":{"type":"boolean","title":"Is Internal","default":false},"delivery_failed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Delivery Failed At"}},"type":"object","required":["id","content","created_at"],"title":"TicketCommentResponseFull","description":"All comments including internal — used in admin responses.","example":{}},"TicketCommentResponsePublic":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"author":{"anyOf":[{"$ref":"#/components/schemas/UserBriefResponse"},{"type":"null"}]},"content":{"type":"string","title":"Content"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"attachments":{"items":{"$ref":"#/components/schemas/TicketAttachmentResponse"},"type":"array","title":"Attachments","default":[]}},"type":"object","required":["id","content","created_at"],"title":"TicketCommentResponsePublic","description":"Public comments only — used in customer responses.","example":{}},"TicketCreateRequest":{"properties":{"subject":{"type":"string","maxLength":500,"minLength":5,"title":"Subject","description":"Ticket subject line"},"description":{"type":"string","maxLength":50000,"minLength":10,"title":"Description","description":"Ticket body (plain text)"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id","description":"Optional ticket category"},"environment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Environment Id","description":"Affected environment"},"server_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Id","description":"Affected server"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id","description":"Affected project"},"migration_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Migration Id","description":"Affected migration"}},"type":"object","required":["subject","description"],"title":"TicketCreateRequest","description":"Create a new support ticket.","example":{}},"TicketListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TicketResponseBrief"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"skip":{"type":"integer","title":"Skip"},"limit":{"type":"integer","title":"Limit"}},"type":"object","required":["items","total","skip","limit"],"title":"TicketListResponse","description":"Paginated ticket list (customer view).","example":{}},"TicketMergeRequest":{"properties":{"source_ticket_id":{"type":"string","format":"uuid","title":"Source Ticket Id","description":"Ticket to merge FROM (will be closed)"}},"type":"object","required":["source_ticket_id"],"title":"TicketMergeRequest","description":"Merge a source ticket into a target ticket.","example":{}},"TicketResponseAdmin":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"ticket_number":{"type":"string","title":"Ticket Number"},"subject":{"type":"string","title":"Subject"},"status":{"type":"string","title":"Status"},"priority":{"type":"string","title":"Priority"},"category":{"anyOf":[{"$ref":"#/components/schemas/TicketCategoryResponse"},{"type":"null"}]},"source":{"type":"string","title":"Source"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"description":{"type":"string","title":"Description"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At"},"satisfaction_rating":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Satisfaction Rating"},"comments":{"items":{"$ref":"#/components/schemas/TicketCommentResponseFull"},"type":"array","title":"Comments","default":[]},"attachments":{"items":{"$ref":"#/components/schemas/TicketAttachmentResponse"},"type":"array","title":"Attachments","default":[]},"affected_resource":{"anyOf":[{"$ref":"#/components/schemas/AffectedResourceResponse"},{"type":"null"}]},"assigned_to":{"anyOf":[{"$ref":"#/components/schemas/UserBriefResponse"},{"type":"null"}]},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"sla_first_response_breached":{"type":"boolean","title":"Sla First Response Breached","default":false},"sla_resolution_breached":{"type":"boolean","title":"Sla Resolution Breached","default":false},"first_response_due_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"First Response Due At"},"resolution_due_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolution Due At"},"watchers":{"items":{"$ref":"#/components/schemas/UserBriefResponse"},"type":"array","title":"Watchers","default":[]},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name"}},"type":"object","required":["id","ticket_number","subject","status","priority","source","created_at","description"],"title":"TicketResponseAdmin","description":"Admin-facing ticket detail — includes internal notes, assignment, SLA.","example":{}},"TicketResponseBrief":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"ticket_number":{"type":"string","title":"Ticket Number"},"subject":{"type":"string","title":"Subject"},"status":{"type":"string","title":"Status"},"priority":{"type":"string","title":"Priority"},"category":{"anyOf":[{"$ref":"#/components/schemas/TicketCategoryResponse"},{"type":"null"}]},"source":{"type":"string","title":"Source"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","ticket_number","subject","status","priority","source","created_at"],"title":"TicketResponseBrief","description":"Brief ticket for list views.","example":{}},"TicketResponseCustomer":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"ticket_number":{"type":"string","title":"Ticket Number"},"subject":{"type":"string","title":"Subject"},"status":{"type":"string","title":"Status"},"priority":{"type":"string","title":"Priority"},"category":{"anyOf":[{"$ref":"#/components/schemas/TicketCategoryResponse"},{"type":"null"}]},"source":{"type":"string","title":"Source"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"description":{"type":"string","title":"Description"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At"},"satisfaction_rating":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Satisfaction Rating"},"comments":{"items":{"$ref":"#/components/schemas/TicketCommentResponsePublic"},"type":"array","title":"Comments","default":[]},"attachments":{"items":{"$ref":"#/components/schemas/TicketAttachmentResponse"},"type":"array","title":"Attachments","default":[]},"affected_resource":{"anyOf":[{"$ref":"#/components/schemas/AffectedResourceResponse"},{"type":"null"}]}},"type":"object","required":["id","ticket_number","subject","status","priority","source","created_at","description"],"title":"TicketResponseCustomer","description":"Customer-facing ticket detail — NO internal notes.","example":{}},"TicketStatus":{"type":"string","enum":["open","in_progress","waiting_for_customer","waiting_for_admin","planned","resolved","closed"],"title":"TicketStatus","description":"Lifecycle status of a support ticket."},"TierInfoResponse":{"properties":{"environment_id":{"type":"string","format":"uuid","title":"Environment Id"},"tier":{"type":"string","enum":["development","production","high_availability"],"title":"Tier"},"pgtune_enabled":{"type":"boolean","title":"Pgtune Enabled"},"pgbouncer_enabled":{"type":"boolean","title":"Pgbouncer Enabled"},"replica_enabled":{"type":"boolean","title":"Replica Enabled"},"description":{"type":"string","title":"Description"},"ram_mb":{"type":"integer","title":"Ram Mb"},"cpu_cores":{"type":"number","title":"Cpu Cores"},"environment_name":{"type":"string","title":"Environment Name"}},"type":"object","required":["environment_id","tier","pgtune_enabled","pgbouncer_enabled","replica_enabled","description","ram_mb","cpu_cores","environment_name"],"title":"TierInfoResponse","description":"Response showing tier classification details."},"TimeSeriesPoint":{"properties":{"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"Point timestamp"},"value":{"type":"number","title":"Value","description":"Metric value"}},"type":"object","required":["timestamp","value"],"title":"TimeSeriesPoint","description":"Single point in a time series.","example":{}},"TokenResponse":{"properties":{"access_token":{"type":"string","title":"Access Token","description":"JWT access token"},"refresh_token":{"type":"string","title":"Refresh Token","description":"JWT refresh token"},"token_type":{"type":"string","title":"Token Type","description":"Token type","default":"bearer"},"expires_in":{"type":"integer","title":"Expires In","description":"Token expiration time in seconds"},"requires_onboarding":{"type":"boolean","title":"Requires Onboarding","description":"Whether user needs to complete onboarding (no orgs)","default":false},"pending_invitations":{"type":"integer","title":"Pending Invitations","description":"Number of pending invitations for this user","default":0},"checkout_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Checkout Url","description":"Stripe checkout URL if paid plan was selected during registration. Frontend should redirect here immediately."},"organization_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Id","description":"Auto-created organization ID for the paid plan checkout flow."}},"type":"object","required":["access_token","refresh_token","expires_in"],"title":"TokenResponse","description":"Schema for authentication token response.","example":{}},"TopOrganization":{"properties":{"organization_id":{"type":"string","title":"Organization Id"},"organization_name":{"type":"string","title":"Organization Name"},"deploy_count":{"type":"integer","title":"Deploy Count"},"success_rate":{"type":"number","title":"Success Rate"}},"type":"object","required":["organization_id","organization_name","deploy_count","success_rate"],"title":"TopOrganization","description":"Organization deployment activity."},"TrendData":{"properties":{"current_period":{"type":"integer","title":"Current Period"},"previous_period":{"type":"integer","title":"Previous Period"},"change_percent":{"type":"number","title":"Change Percent"},"direction":{"type":"string","title":"Direction"}},"type":"object","required":["current_period","previous_period","change_percent","direction"],"title":"TrendData","description":"Trend comparison data."},"TriggerBreakdown":{"properties":{"trigger":{"type":"string","title":"Trigger"},"count":{"type":"integer","title":"Count"},"success_count":{"type":"integer","title":"Success Count"},"failed_count":{"type":"integer","title":"Failed Count"},"success_rate":{"type":"number","title":"Success Rate"}},"type":"object","required":["trigger","count","success_count","failed_count","success_rate"],"title":"TriggerBreakdown","description":"Deployment counts per trigger method."},"TunnelDiagnosticsResponse":{"properties":{"vm_id":{"type":"string","format":"uuid","title":"Vm Id","description":"VM UUID"},"name":{"type":"string","title":"Name","description":"VM name"},"cf_tunnel_managed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Managed By","description":"Who owns the Cloudflare resources: 'platform' or 'customer'"},"cf_tunnel_hostname":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Hostname","description":"Tunnel hostname (e.g. t-xxxx.tun.example.com)"},"cf_tunnel_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Id","description":"Cloudflare Tunnel UUID"},"cf_dns_record_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Dns Record Id","description":"CF DNS record ID for the tunnel hostname"},"cf_access_app_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Access App Id","description":"CF Access application ID"},"cf_access_policy_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Access Policy Id","description":"CF Access policy ID"},"cf_per_org_token_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Per Org Token Id","description":"Per-tunnel pinned service token identifier"},"cf_tunnel_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Status","description":"Connector status: pending, connected, disconnected, error"},"cf_tunnel_qualified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cf Tunnel Qualified At","description":"Timestamp of last successful E2E qualification"},"cf_tunnel_qualify_attempted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cf Tunnel Qualify Attempted At","description":"Timestamp of last qualification attempt (success or failure)"},"cf_tunnel_qualify_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Qualify Error","description":"Last qualification error (bounded); null on success"},"cf_tunnel_consecutive_failures":{"type":"integer","title":"Cf Tunnel Consecutive Failures","description":"Consecutive qualification failures; resets to 0 on success","default":0},"cf_tunnel_circuit_open_since":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cf Tunnel Circuit Open Since","description":"When the qualification circuit opened; null if closed"}},"type":"object","required":["vm_id","name"],"title":"TunnelDiagnosticsResponse","description":"CF tunnel diagnostic snapshot for a single VM.\n\nNo secrets — only IDs + timestamps + status. Safe to expose to org admins.","example":{}},"TwoFactorRequiredResponse":{"properties":{"requires_2fa":{"type":"boolean","title":"Requires 2Fa","default":true},"temp_token":{"type":"string","title":"Temp Token"}},"type":"object","required":["temp_token"],"title":"TwoFactorRequiredResponse","description":"Response when 2FA is required."},"TwoFactorVerify":{"properties":{"temp_token":{"type":"string","title":"Temp Token"},"code":{"type":"string","title":"Code"}},"type":"object","required":["temp_token","code"],"title":"TwoFactorVerify","description":"Request to verify 2FA code."},"UnreadCountResponse":{"properties":{"count":{"type":"integer","title":"Count"}},"type":"object","required":["count"],"title":"UnreadCountResponse","description":"Schema for unread count response.","example":{}},"UpdateAddonsPathRequest":{"properties":{"custom_addons_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Addons Path","description":"Custom addons_path string. Set to null to revert to auto-detected."}},"type":"object","title":"UpdateAddonsPathRequest","description":"Request to update custom addons path.","example":{}},"UpdateAnnouncementRequest":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Title"},"content":{"anyOf":[{"type":"string","maxLength":5000,"minLength":1},{"type":"null"}],"title":"Content"},"announcement_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Announcement Type"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"link_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Link Url"},"link_text":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Link Text"},"secondary_link_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Secondary Link Url"},"secondary_link_text":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Secondary Link Text"},"display_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Display Until"}},"type":"object","title":"UpdateAnnouncementRequest"},"UpdateDNSLimitsRequest":{"properties":{"ttl_min":{"anyOf":[{"type":"integer","maximum":86400.0,"minimum":60.0},{"type":"null"}],"title":"Ttl Min"},"ttl_max":{"anyOf":[{"type":"integer","maximum":86400.0,"minimum":60.0},{"type":"null"}],"title":"Ttl Max"},"max_domains_per_project":{"anyOf":[{"type":"integer","maximum":100.0,"minimum":1.0},{"type":"null"}],"title":"Max Domains Per Project"},"max_dns_configs_per_org":{"anyOf":[{"type":"integer","maximum":20.0,"minimum":1.0},{"type":"null"}],"title":"Max Dns Configs Per Org"}},"type":"object","title":"UpdateDNSLimitsRequest","description":"Request to update DNS limits."},"UpdateEnvRepoOverridesRequest":{"properties":{"overrides":{"items":{"$ref":"#/components/schemas/RepoOverrideItem"},"type":"array","title":"Overrides","description":"List of repo overrides","default":[]},"remove_ineffective":{"items":{"$ref":"#/components/schemas/RepoOverrideKey"},"type":"array","title":"Remove Ineffective","description":"Stored ineffective override rows to delete","default":[]},"expected_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expected Version","description":"`version` from the GET this edit started from; 409 if it changed"}},"type":"object","title":"UpdateEnvRepoOverridesRequest","description":"Request to set environment repo overrides.\n\nReplaces the overrides of the repos this environment deploys. Stored rows\nfor other repos (ineffective_overrides on the GET) are kept unless listed\nin remove_ineffective.","example":{}},"UpdateOrganizationPlanRequest":{"properties":{"plan":{"type":"string","title":"Plan","description":"Plan: free, starter, pro, agency"}},"type":"object","required":["plan"],"title":"UpdateOrganizationPlanRequest","description":"Request to update organization's plan (admin override)."},"UpdateOrganizationStatusRequest":{"properties":{"is_active":{"type":"boolean","title":"Is Active","description":"Whether organization is active"}},"type":"object","required":["is_active"],"title":"UpdateOrganizationStatusRequest","description":"Request to update organization's active status."},"UpdateProjectAddonSelectionsRequest":{"properties":{"platform_repo_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Platform Repo Ids","description":"List of platform repo IDs to select (replaces existing)","default":[]},"organization_repo_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Organization Repo Ids","description":"List of organization repo IDs to select (replaces existing)","default":[]}},"type":"object","title":"UpdateProjectAddonSelectionsRequest","description":"Request to update project addon selections.","example":{}},"UpdateUserRoleRequest":{"properties":{"portal_role":{"type":"string","title":"Portal Role","description":"New portal role (admin, manager, executive, customer)"}},"type":"object","required":["portal_role"],"title":"UpdateUserRoleRequest","description":"Request to update user's portal role."},"UpdateUserStatusRequest":{"properties":{"is_active":{"type":"boolean","title":"Is Active","description":"Whether user account is active"},"verify_email":{"type":"boolean","title":"Verify Email","description":"Also verify user's email when activating (admin override)","default":false}},"type":"object","required":["is_active"],"title":"UpdateUserStatusRequest","description":"Request to update user's active status."},"UploadInitResponse":{"properties":{"migration_id":{"type":"string","format":"uuid","title":"Migration Id","description":"Migration ID"},"upload_tier":{"$ref":"#/components/schemas/UploadTierType","description":"Determined upload tier"},"upload_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Upload Url","description":"Presigned URL for direct upload (Tier 1/2/3)"},"upload_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Upload Id","description":"R2 multipart upload ID (Tier 3/4)"},"chunk_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Chunk Size","description":"Recommended chunk size in bytes"},"total_chunks":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Chunks","description":"Total number of chunks (Tier 2)"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"Upload URL expiration time"},"storage_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Storage Type","description":"Storage type: 'organization' (org's storage) or 'platform' (oec.sh R2)"},"part_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Part Size","description":"Bytes per part; part N covers [(N-1)*part_size, N*part_size) (Tier 3/4)"},"num_parts":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Num Parts","description":"Number of parts (Tier 3/4)"},"part_urls":{"anyOf":[{"items":{"$ref":"#/components/schemas/MultipartPartInfo"},"type":"array"},{"type":"null"}],"title":"Part Urls","description":"Presigned PUT URL per part (Tier 3/4)"},"complete_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Complete Url","description":"Endpoint to POST the part ETags to once every part is up (Tier 3/4)"}},"type":"object","required":["migration_id","upload_tier"],"title":"UploadInitResponse","description":"Response for upload initialization.","example":{}},"UploadTierType":{"type":"string","enum":["tier_1","tier_2","tier_3","tier_4","cloud_url"],"title":"UploadTierType","description":"Upload tier based on file size."},"UsageForecastMetric":{"properties":{"name":{"type":"string","title":"Name","description":"Metric name"},"current_value":{"type":"number","title":"Current Value","description":"Current value"},"projected_value":{"type":"number","title":"Projected Value","description":"Projected value at period end"},"unit":{"type":"string","title":"Unit","description":"Unit of measurement"},"trend":{"type":"string","title":"Trend","description":"Trend direction (increasing, stable, decreasing)"}},"type":"object","required":["name","current_value","projected_value","unit","trend"],"title":"UsageForecastMetric","description":"Forecasted metric.","example":{}},"UsageForecastResponse":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"period_end":{"type":"string","format":"date-time","title":"Period End","description":"Period end date"},"days_remaining":{"type":"integer","title":"Days Remaining","description":"Days remaining in period"},"metrics":{"items":{"$ref":"#/components/schemas/UsageForecastMetric"},"type":"array","title":"Metrics","description":"Forecasted metrics"},"current_cost":{"type":"string","title":"Current Cost","description":"Current usage cost"},"projected_cost":{"type":"string","title":"Projected Cost","description":"Projected cost at period end"},"daily_rate":{"type":"string","title":"Daily Rate","description":"Average daily cost rate"},"confidence":{"type":"string","title":"Confidence","description":"Forecast confidence (high, medium, low)"}},"type":"object","required":["organization_id","period_end","days_remaining","metrics","current_cost","projected_cost","daily_rate","confidence"],"title":"UsageForecastResponse","description":"Usage forecast for current period.","example":{}},"UsageHistoryEntry":{"properties":{"period_start":{"type":"string","format":"date-time","title":"Period Start","description":"Period start"},"period_end":{"type":"string","format":"date-time","title":"Period End","description":"Period end"},"cpu_hours":{"type":"string","title":"Cpu Hours","description":"CPU hours used"},"memory_gb_hours":{"type":"string","title":"Memory Gb Hours","description":"Memory GB-hours used"},"storage_gb_avg":{"type":"string","title":"Storage Gb Avg","description":"Average storage GB"},"deployment_count":{"type":"integer","title":"Deployment Count","description":"Number of deployments"},"backup_count":{"type":"integer","title":"Backup Count","description":"Number of backups"},"environment_count":{"type":"integer","title":"Environment Count","description":"Number of active environments"},"estimated_cost":{"type":"string","title":"Estimated Cost","description":"Estimated cost for period"}},"type":"object","required":["period_start","period_end","cpu_hours","memory_gb_hours","storage_gb_avg","deployment_count","backup_count","environment_count","estimated_cost"],"title":"UsageHistoryEntry","description":"Single entry in usage history.","example":{}},"UsageHistoryResponse":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"period_type":{"type":"string","title":"Period Type","description":"Aggregation period type"},"entries":{"items":{"$ref":"#/components/schemas/UsageHistoryEntry"},"type":"array","title":"Entries","description":"Historical usage entries"},"total_entries":{"type":"integer","title":"Total Entries","description":"Total number of entries"}},"type":"object","required":["organization_id","period_type","entries","total_entries"],"title":"UsageHistoryResponse","description":"Usage history response.","example":{}},"UsageMetric":{"properties":{"name":{"type":"string","title":"Name","description":"Metric name"},"value":{"type":"number","title":"Value","description":"Current value"},"limit":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Limit","description":"Limit (if applicable)"},"unit":{"type":"string","title":"Unit","description":"Unit of measurement"},"percent_used":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Percent Used","description":"Percentage used (if limit exists)"}},"type":"object","required":["name","value","unit"],"title":"UsageMetric","description":"Single usage metric with value and limit.","example":{}},"UsageSummaryResponse":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"period_start":{"type":"string","format":"date-time","title":"Period Start","description":"Billing period start"},"period_end":{"type":"string","format":"date-time","title":"Period End","description":"Billing period end"},"days_elapsed":{"type":"integer","title":"Days Elapsed","description":"Days elapsed in period"},"days_remaining":{"type":"integer","title":"Days Remaining","description":"Days remaining in period"},"metrics":{"items":{"$ref":"#/components/schemas/UsageMetric"},"type":"array","title":"Metrics","description":"Usage metrics"},"total_estimated_cost":{"type":"string","title":"Total Estimated Cost","description":"Estimated total cost for period"},"plan_name":{"type":"string","title":"Plan Name","description":"Current plan name"}},"type":"object","required":["organization_id","period_start","period_end","days_elapsed","days_remaining","metrics","total_estimated_cost","plan_name"],"title":"UsageSummaryResponse","description":"Current period usage summary.","example":{}},"UsedActualInfo":{"properties":{"cpu_cores":{"type":"number","title":"Cpu Cores"},"ram_mb":{"type":"integer","title":"Ram Mb"},"disk_gb":{"type":"integer","title":"Disk Gb"},"environments":{"type":"integer","title":"Environments"}},"type":"object","required":["cpu_cores","ram_mb","disk_gb","environments"],"title":"UsedActualInfo","description":"Actual used resources on a shared server."},"UserAbilities":{"properties":{"abilities":{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object","title":"Abilities","description":"Resource -> list of allowed actions"},"scope":{"$ref":"#/components/schemas/PermissionScope-Output","description":"Scope these abilities apply to"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization context"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id","description":"Project context"},"cached_at":{"type":"string","format":"date-time","title":"Cached At","description":"When these abilities were cached"}},"type":"object","required":["abilities","scope","cached_at"],"title":"UserAbilities","description":"User's effective permissions formatted for frontend.","example":{}},"UserBriefResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"email":{"type":"string","title":"Email"}},"type":"object","required":["id","email"],"title":"UserBriefResponse","description":"Minimal user info for ticket displays.","example":{}},"UserCreate":{"properties":{"email":{"type":"string","format":"email","title":"Email","description":"User email address"},"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name","description":"User's display name (required)"},"password":{"type":"string","maxLength":128,"minLength":8,"title":"Password","description":"User password (NIST 800-63B-4 compliant: 8-128 chars, all printable characters allowed)"},"turnstile_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Turnstile Token","description":"Cloudflare Turnstile token"},"utm_source":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Utm Source","description":"UTM source from signup URL (e.g., pricing, home)"},"utm_medium":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Utm Medium","description":"UTM medium from signup URL (e.g., cta_button, pricing_preview)"},"utm_campaign":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Utm Campaign","description":"UTM campaign from signup URL (e.g., OEC_Search_HighIntent)"},"selected_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Plan","description":"Selected plan from pricing page (free, starter, pro, agency). If paid plan, triggers immediate checkout flow."},"ga_client_id":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Ga Client Id","description":"GA4 client ID from _ga cookie for purchase attribution"},"ga_session_id":{"anyOf":[{"type":"string","pattern":"^[0-9]{1,20}$"},{"type":"null"}],"title":"Ga Session Id","description":"GA4 session ID from the _ga_<container> cookie (#1132)"},"gclid":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Gclid","description":"Google Ads click id from the landing URL (paid-search sign-ups)"},"landed_at":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}],"title":"Landed At","description":"Marketing-site path the visitor first landed on"},"cta":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Cta","description":"Which marketing-site CTA sent them to register"},"paid_src":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paid Src","description":"Ad network of the first paid touch (e.g. google_ads)"},"paid_t":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paid T","description":"Date of the first paid touch, YYYY-MM-DD"}},"type":"object","required":["email","name","password"],"title":"UserCreate","description":"Schema for creating a new user.","example":{}},"UserDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url"},"portal_role":{"type":"string","title":"Portal Role"},"is_active":{"type":"boolean","title":"Is Active"},"is_verified":{"type":"boolean","title":"Is Verified"},"totp_enabled":{"type":"boolean","title":"Totp Enabled"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"last_login_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Login At"},"last_active_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Active At"},"organizations":{"items":{"type":"object"},"type":"array","title":"Organizations","default":[]}},"type":"object","required":["id","email","name","avatar_url","portal_role","is_active","is_verified","totp_enabled","created_at","last_login_at","last_active_at"],"title":"UserDetailResponse","description":"Detailed user information for admin."},"UserListResponse":{"properties":{"users":{"items":{"$ref":"#/components/schemas/UserSummary"},"type":"array","title":"Users"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"total_pages":{"type":"integer","title":"Total Pages"}},"type":"object","required":["users","total","page","per_page","total_pages"],"title":"UserListResponse","description":"Paginated user list response."},"UserLogin":{"properties":{"email":{"type":"string","format":"email","title":"Email","description":"User email address"},"password":{"type":"string","title":"Password","description":"User password"},"turnstile_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Turnstile Token","description":"Cloudflare Turnstile token"}},"type":"object","required":["email","password"],"title":"UserLogin","description":"Schema for user login.","example":{}},"UserResponse":{"properties":{"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"email":{"type":"string","format":"email","title":"Email","description":"User email address"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"User's display name"},"role":{"type":"string","title":"Role","description":"Legacy user role"},"portal_role":{"type":"string","title":"Portal Role","description":"Portal-level role for system access"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether user is active"},"is_verified":{"type":"boolean","title":"Is Verified","description":"Whether email is verified","default":false},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url","description":"Avatar URL"},"last_login_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Login At","description":"Last login timestamp"},"last_active_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Active At","description":"Last activity timestamp"},"has_password":{"type":"boolean","title":"Has Password","description":"Whether user has a password set","default":false},"totp_enabled":{"type":"boolean","title":"Totp Enabled","description":"Whether 2FA is enabled","default":false},"staff_mfa_required":{"type":"boolean","title":"Staff Mfa Required","description":"Platform staff account whose session is not MFA-verified: staff capabilities are withheld until 2FA is set up / verified","default":false},"staff_mfa_enrolled":{"type":"boolean","title":"Staff Mfa Enrolled","description":"Platform staff account with a second factor enrolled (TOTP or passkey)","default":false}},"type":"object","required":["created_at","updated_at","id","email","role","portal_role","is_active"],"title":"UserResponse","description":"Schema for user response.","example":{}},"UserRoleResponse":{"properties":{"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"user_id":{"type":"string","format":"uuid","title":"User Id","description":"User the role is assigned to"},"role_id":{"type":"string","format":"uuid","title":"Role Id","description":"Assigned role ID"},"role_name":{"type":"string","title":"Role Name","description":"Role display name"},"role_slug":{"type":"string","title":"Role Slug","description":"Role slug identifier"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization context"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id","description":"Project context"},"assigned_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned By","description":"Admin who assigned the role"},"assigned_at":{"type":"string","format":"date-time","title":"Assigned At","description":"When the role was assigned"}},"type":"object","required":["created_at","updated_at","id","user_id","role_id","role_name","role_slug","organization_id","project_id","assigned_by","assigned_at"],"title":"UserRoleResponse","description":"Response for a user role assignment.","example":{}},"UserSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url"},"portal_role":{"type":"string","title":"Portal Role"},"is_active":{"type":"boolean","title":"Is Active"},"is_verified":{"type":"boolean","title":"Is Verified"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"last_login_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Login At"},"organization_count":{"type":"integer","title":"Organization Count","default":0}},"type":"object","required":["id","email","name","avatar_url","portal_role","is_active","is_verified","created_at","last_login_at"],"title":"UserSummary","description":"User summary for admin list."},"UserUpdate":{"properties":{"email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Email","description":"User email address"},"name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Name","description":"User's display name"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active","description":"Whether user is active"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url","description":"Avatar URL"},"portal_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Portal Role","description":"Portal-level role (admin, manager, executive, customer). Only portal admins can change this."}},"type":"object","title":"UserUpdate","description":"Schema for updating a user.","example":{}},"UtilizationInfo":{"properties":{"cpu_allocated":{"type":"number","title":"Cpu Allocated","description":"CPU cores allocated"},"cpu_total":{"type":"number","title":"Cpu Total","description":"Total CPU cores"},"cpu_percent":{"type":"integer","title":"Cpu Percent","description":"CPU allocation percentage"},"ram_allocated_mb":{"type":"integer","title":"Ram Allocated Mb","description":"RAM allocated in MB"},"ram_total_mb":{"type":"integer","title":"Ram Total Mb","description":"Total RAM in MB"},"ram_percent":{"type":"integer","title":"Ram Percent","description":"RAM allocation percentage"},"disk_allocated_gb":{"type":"integer","title":"Disk Allocated Gb","description":"Disk allocated in GB"},"disk_total_gb":{"type":"integer","title":"Disk Total Gb","description":"Total disk in GB"},"disk_percent":{"type":"integer","title":"Disk Percent","description":"Disk allocation percentage"},"environments_deployed":{"type":"integer","title":"Environments Deployed","description":"Number of environments deployed"},"over_provisioned":{"type":"boolean","title":"Over Provisioned","description":"Whether server is over-provisioned (>125%)"},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","description":"Warnings about utilization"}},"type":"object","required":["cpu_allocated","cpu_total","cpu_percent","ram_allocated_mb","ram_total_mb","ram_percent","disk_allocated_gb","disk_total_gb","disk_percent","environments_deployed","over_provisioned"],"title":"UtilizationInfo","description":"Resource utilization information for a shared server."},"VMComplianceStatus":{"properties":{"vm_id":{"type":"string","title":"Vm Id","description":"VM UUID"},"vm_name":{"type":"string","title":"Vm Name","description":"VM name"},"is_compliant":{"type":"boolean","title":"Is Compliant","description":"Whether VM passes all critical/high checks"},"compliance_score":{"type":"number","title":"Compliance Score","description":"Compliance score (0-100%)"},"last_check":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Check","description":"Last compliance check timestamp"},"total_checks":{"type":"integer","title":"Total Checks","description":"Total number of checks","default":0},"passed_checks":{"type":"integer","title":"Passed Checks","description":"Number of checks passed","default":0},"failed_checks":{"type":"integer","title":"Failed Checks","description":"Number of checks failed","default":0},"critical_failures":{"type":"integer","title":"Critical Failures","description":"Number of critical failures","default":0},"high_failures":{"type":"integer","title":"High Failures","description":"Number of high severity failures","default":0},"medium_failures":{"type":"integer","title":"Medium Failures","description":"Number of medium severity failures","default":0},"low_failures":{"type":"integer","title":"Low Failures","description":"Number of low severity failures","default":0},"organization_id":{"type":"string","title":"Organization Id","description":"Organization ID"}},"type":"object","required":["vm_id","vm_name","is_compliant","compliance_score","organization_id"],"title":"VMComplianceStatus","description":"Compliance status for a VM."},"VMCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name","description":"Server/VM name"},"provider":{"$ref":"#/components/schemas/VMProvider","description":"Cloud provider (CUSTOM for BYOS)","default":"custom"},"region":{"type":"string","title":"Region","description":"Cloud region or location label","default":"custom"},"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization ID"},"is_shared":{"type":"boolean","title":"Is Shared","description":"Whether this is a portal-managed shared server (portal admin only)","default":false},"owner_type":{"type":"string","title":"Owner Type","description":"Owner type: 'organization' (BYOS) or 'portal' (shared server)","default":"organization"},"connection_method":{"type":"string","title":"Connection Method","description":"How platform connects to server: 'direct' (SSH) or 'cloudflare_tunnel'","default":"direct"},"generate_ssh_key":{"type":"boolean","title":"Generate Ssh Key","description":"Generate a platform SSH key pair for this server (for tunnel-connected servers)","default":false},"ipv4_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ipv4 Address","description":"Public IPv4 address (e.g., 192.168.1.100)"},"ipv6_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ipv6 Address","description":"Public IPv6 address (e.g., 2001:db8::1)"},"fqdn":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Fqdn","description":"Fully qualified domain name (e.g., server.example.com)"},"hostname":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Hostname","description":"Server hostname"},"private_ipv4":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Ipv4","description":"Private IPv4 address for internal communication"},"private_ipv6":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Ipv6","description":"Private IPv6 address for internal communication"},"connection_host_type":{"$ref":"#/components/schemas/ConnectionHostType","description":"Which address to use for SSH connection","default":"auto"},"ssh_port":{"type":"integer","maximum":65535.0,"minimum":1.0,"title":"Ssh Port","description":"SSH port","default":22},"ssh_username":{"type":"string","maxLength":50,"minLength":1,"title":"Ssh Username","description":"SSH username","default":"root"},"ssh_auth_method":{"$ref":"#/components/schemas/SSHAuthMethod","description":"SSH authentication method","default":"ssh_key"},"ssh_password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Password","description":"SSH password (required if auth_method is PASSWORD)"},"ssh_private_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Private Key","description":"SSH private key content (required if auth_method is SSH_KEY)"},"ssh_key_passphrase":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Key Passphrase","description":"SSH key passphrase (optional, if key is encrypted)"},"server_ssh_key_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Ssh Key Id","description":"Reference to a stored SSH key (alternative to ssh_private_key)"},"ssh_sudo_mode":{"$ref":"#/components/schemas/SSHSudoMode","description":"Sudo mode for privileged commands: auto (detect from username), none (root), sudo (always use sudo)","default":"auto"},"size":{"$ref":"#/components/schemas/VMSize","description":"VM size (for cloud-provisioned)","default":"custom"},"cpu_cores":{"type":"integer","minimum":1.0,"title":"Cpu Cores","description":"Number of CPU cores","default":4},"memory_gb":{"type":"integer","minimum":1.0,"title":"Memory Gb","description":"Memory in GB","default":8},"disk_gb":{"type":"integer","minimum":10.0,"title":"Disk Gb","description":"Disk size in GB","default":160},"max_projects":{"type":"integer","minimum":0.0,"title":"Max Projects","description":"Maximum environments on this server. 0 means unlimited (physical capacity is the only cap). Default is 0 for BYOS — the customer paid for the hardware, so we don't impose an artificial cap.","default":0},"tags":{"additionalProperties":{"type":"string"},"type":"object","title":"Tags","description":"Server tags/labels"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"Deprecated: Use ipv4_address instead"}},"type":"object","required":["name","organization_id"],"title":"VMCreate","description":"Schema for creating a VM/Server.","example":{}},"VMProvider":{"type":"string","enum":["aws","azure","gcp","digitalocean","vultr","ovhcloud","hetzner","linode","custom"],"title":"VMProvider","description":"Supported cloud providers for VMs."},"VMPublicKeyResponse":{"properties":{"public_key":{"type":"string","title":"Public Key","description":"Platform SSH public key in OpenSSH authorized_keys form (e.g. 'ssh-ed25519 AAAA...')."},"fingerprint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fingerprint","description":"SHA256 fingerprint of the public key (e.g. 'SHA256:...')."}},"type":"object","required":["public_key"],"title":"VMPublicKeyResponse","description":"Response for GET /vms/{vm_id}/ssh-public-key.\n\nReturns the PLATFORM'S SSH PUBLIC key (OpenSSH authorized_keys form) so a\nBYOS owner can re-add it to their server's authorized_keys. NEVER contains\nany private key material.","example":{}},"VMQualificationStatus":{"type":"string","enum":["unchecked","checking","qualified","needs_setup","unqualified","stale","expired","needs_recheck","unknown"],"title":"VMQualificationStatus","description":"VM qualification status for deployment readiness."},"VMResponse":{"properties":{"created_at":{"type":"string","format":"date-time","title":"Created At","description":"Creation timestamp"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"Last update timestamp"},"id":{"type":"string","format":"uuid","title":"Id","description":"Unique identifier"},"name":{"type":"string","title":"Name","description":"Server name"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization ID (null for shared servers)"},"organization_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organization Name","description":"Organization name"},"is_shared":{"type":"boolean","title":"Is Shared","description":"Whether this is a portal-managed shared server","default":false},"owner_type":{"type":"string","title":"Owner Type","description":"Owner type: 'organization' (BYOS) or 'portal' (shared server)","default":"organization"},"provider":{"anyOf":[{"$ref":"#/components/schemas/VMProvider"},{"type":"null"}],"description":"Cloud provider"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region","description":"Cloud region or location"},"instance_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Instance Type","description":"Provider-specific instance type (e.g., Standard_B4ms, s-4vcpu-8gb, t3.medium)"},"status":{"$ref":"#/components/schemas/VMStatus","description":"Server status"},"ipv4_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ipv4 Address","description":"Public IPv4 address"},"ipv6_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ipv6 Address","description":"Public IPv6 address"},"fqdn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fqdn","description":"Fully qualified domain name"},"hostname":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hostname","description":"Server hostname"},"private_ipv4":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Ipv4","description":"Private IPv4 address"},"private_ipv6":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Ipv6","description":"Private IPv6 address"},"connection_host_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connection Host Type","description":"Which address to use for SSH","default":"auto"},"connection_host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connection Host","description":"Resolved address for SSH connection"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"Deprecated: Use ipv4_address"},"private_ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Ip","description":"Deprecated: Use private_ipv4"},"ssh_port":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ssh Port","description":"SSH port","default":22},"ssh_username":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Username","description":"SSH username","default":"root"},"ssh_auth_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Auth Method","description":"SSH auth method","default":"ssh_key"},"ssh_sudo_mode":{"type":"string","title":"Ssh Sudo Mode","description":"Sudo mode: auto, none, or sudo","default":"auto"},"ssh_secured_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Secured At","description":"When server was converted to SSH key auth"},"server_ssh_key_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Server Ssh Key Id","description":"Stored SSH key used for this server"},"provider_vm_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider Vm Id","description":"Provider-specific ID"},"provisioned_via_cloud":{"type":"boolean","title":"Provisioned Via Cloud","description":"Whether this server was provisioned via cloud provider API","default":false},"cloud_connection_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cloud Connection Id","description":"Cloud connection used for provisioning"},"cloud_server_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cloud Server Id","description":"Cloud provider's server ID (for deletion)"},"cloud_region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cloud Region","description":"Cloud region where server was provisioned"},"cloud_server_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cloud Server Type","description":"Cloud provider's server type/size identifier"},"connection_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connection Method","description":"How platform connects: 'direct' or 'cloudflare_tunnel'"},"cf_tunnel_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Status","description":"Tunnel connector status: pending, connected, disconnected, error"},"cf_tunnel_managed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Managed By","description":"Who owns the Cloudflare resources: 'platform' (ours, default) or 'customer' (BYOS legacy/vanity)."},"cf_tunnel_hostname":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Hostname","description":"SSH hostname assigned via Cloudflare Tunnel"},"cf_tunnel_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Id","description":"Cloudflare Tunnel UUID"},"cf_tunnel_qualified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cf Tunnel Qualified At","description":"Timestamp of last successful E2E SSH qualification through the tunnel"},"cf_tunnel_qualify_attempted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cf Tunnel Qualify Attempted At","description":"Timestamp of last qualification attempt (success or failure)"},"cf_tunnel_qualify_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cf Tunnel Qualify Error","description":"Last qualification error (bounded to 500 chars); null on success or never-attempted"},"cpu_cores":{"type":"integer","title":"Cpu Cores","description":"Number of CPU cores","default":4},"memory_gb":{"type":"integer","title":"Memory Gb","description":"Memory in GB","default":8},"disk_gb":{"type":"integer","title":"Disk Gb","description":"Disk size in GB","default":160},"disk_available_gb":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Disk Available Gb","description":"Available disk space in GB (from monitoring)"},"size":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Size","description":"VM size category"},"max_projects":{"type":"integer","title":"Max Projects","description":"Maximum environments on this server (0 = unlimited)","default":0},"is_active":{"type":"boolean","title":"Is Active","description":"Whether server is active","default":true},"health_status":{"type":"string","title":"Health Status","description":"Health status","default":"unknown"},"docker_status":{"type":"string","title":"Docker Status","description":"Docker daemon status","default":"unknown"},"last_health_check":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Health Check","description":"When health was last actually checked (None = never)"},"health_is_stale":{"type":"boolean","title":"Health Is Stale","description":"True when last_health_check is missing or older than 24h","default":true},"access_lost_since":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Access Lost Since","description":"When we lost SSH access to this server (circuit open)"},"access_lost_class":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Lost Class","description":"auth_key | auth_password | network: which fix the owner needs"},"access_lost_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Lost Text","description":"What happened and the fix, in plain words (same text as the email)"},"qualification_status":{"type":"string","title":"Qualification Status","description":"Server qualification status: unchecked, checking, qualified, needs_setup, unqualified, stale, expired, needs_recheck, unknown","default":"unchecked"},"last_error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Error Message","description":"Last error message (e.g., connection failure reason)"},"last_error_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Error At","description":"When the last error occurred (ISO datetime)"},"netdata_api_key_set":{"type":"boolean","title":"Netdata Api Key Set","description":"Whether Netdata API key is configured (key value not exposed)","default":false},"netdata_machine_guid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Netdata Machine Guid","description":"Netdata machine GUID for identifying this server"},"netdata_installed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Netdata Installed At","description":"When Netdata was installed (ISO datetime)"},"netdata_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Netdata Version","description":"Installed Netdata version"},"netdata_streaming_enabled":{"type":"boolean","title":"Netdata Streaming Enabled","description":"Whether Netdata streaming is enabled","default":false},"netdata_streaming_status":{"type":"string","title":"Netdata Streaming Status","description":"Streaming status: active, configured, or not_configured","default":"not_configured"},"os_auto_update_enabled":{"type":"boolean","title":"Os Auto Update Enabled","description":"Whether automatic OS security updates are enabled on this server","default":false},"os_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Os Type","description":"Operating system type"},"os_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Os Version","description":"Operating system version"},"environment_count":{"type":"integer","title":"Environment Count","description":"Total number of environments on this server","default":0},"running_environment_count":{"type":"integer","title":"Running Environment Count","description":"Number of running environments on this server","default":0},"allocation_info":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Allocation Info","description":"Allocation quota info if requester is in shared mode (cpu_quota, ram_quota_mb, disk_quota_gb, max_environments, expires_date)"},"is_demo":{"type":"boolean","title":"Is Demo","description":"True on the platform-owned shared demo pool VM","default":false},"allowed_env_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Env Types","description":"Portal-admin-only: env types this server permits"},"allowed_odoo_versions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Odoo Versions","description":"Portal-admin-only: Odoo versions this server permits"},"allowed_editions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Allowed Editions","description":"Portal-admin-only: Odoo editions this server permits"},"allows_db_tuning":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allows Db Tuning","description":"Portal-admin-only: whether DB-tuning toggles are exposed"},"allows_custom_git":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allows Custom Git","description":"Portal-admin-only: whether custom git URLs are allowed"},"domain_pattern":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain Pattern","description":"Portal-admin-only: 'custom' or 'vanity'"},"module_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Module Source","description":"Portal-admin-only: 'any' or 'official+oca-allowlist'"},"fixed_resource_caps":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Fixed Resource Caps","description":"Portal-admin-only: when True, env resources are fixed"}},"type":"object","required":["created_at","updated_at","id","name","provider","region","status"],"title":"VMResponse","description":"Schema for VM/Server response.\n\nSECURITY NOTE: This schema intentionally excludes sensitive credential fields:\n- ssh_password (encrypted in database, never exposed via API)\n- ssh_private_key (encrypted in database, never exposed via API)\n- ssh_key_passphrase (encrypted in database, never exposed via API)\n- netdata_api_key (only exposed as netdata_api_key_set boolean)\n\nCredentials are only accessible internally by the application for SSH operations.","example":{}},"VMSize":{"type":"string","enum":["small","medium","large","xlarge","custom"],"title":"VMSize","description":"Standard VM sizes."},"VMSnapshotInfo":{"properties":{"id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Id","description":"VM ID at backup time"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"VM name at backup time"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"Not returned (always null); kept for response compatibility"}},"type":"object","title":"VMSnapshotInfo","description":"VM/Server info from backup snapshot.","example":{}},"VMStatus":{"type":"string","enum":["pending","provisioning","running","stopped","error","deleting","deleted","terminated"],"title":"VMStatus","description":"VM status states."},"VMTaskCallbackBody":{"properties":{"task_id":{"type":"string","title":"Task Id","description":"VMTask id the runner is reporting for"},"seq":{"type":"integer","minimum":0.0,"title":"Seq","description":"Monotonic per-run sequence counter"},"status":{"type":"string","title":"Status","description":"status.jsonl event name"},"phase":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phase","description":"Current runner phase name"},"progress":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress","description":"0-100 progress (clamped server-side)"},"log_tail_delta":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Log Tail Delta","description":"Redacted new log-tail bytes since the last callback"},"exit_info":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Exit Info","description":"Exit code / signal / oom info on terminal failure"},"result":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Result","description":"Operation result payload on terminal success"},"manifest_version":{"type":"integer","title":"Manifest Version","description":"Manifest major version the runner executed"},"timestamp":{"type":"number","title":"Timestamp","description":"Runner-side POSIX timestamp of this callback"}},"type":"object","required":["task_id","seq","status","manifest_version","timestamp"],"title":"VMTaskCallbackBody","description":"One runner callback.\n\n``status`` mirrors the ``status.jsonl`` event name. ``seq`` is the runner's\nsingle monotonic counter — the callback endpoint uses it for dedup\n(``seq <= last_seq`` → duplicate) and forward-only application."},"VMTaskCallbackResponse":{"properties":{"duplicate":{"type":"boolean","title":"Duplicate","description":"Whether this callback was a stale duplicate","default":false}},"type":"object","title":"VMTaskCallbackResponse","description":"Callback ack. ``duplicate`` is ``True`` when ``seq <= last_seq``."},"VMUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"organization_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Organization Id","description":"Organization ID (requires admin access to both orgs)"},"is_shared":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Shared","description":"Whether this is a shared server (portal admin only)"},"owner_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Owner Type","description":"Owner type: 'organization' or 'portal' (portal admin only)"},"ipv4_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ipv4 Address","description":"Public IPv4 address"},"ipv6_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ipv6 Address","description":"Public IPv6 address"},"fqdn":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Fqdn","description":"Fully qualified domain name"},"hostname":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Hostname","description":"Server hostname"},"private_ipv4":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Ipv4","description":"Private IPv4 address"},"private_ipv6":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Private Ipv6","description":"Private IPv6 address"},"connection_host_type":{"anyOf":[{"$ref":"#/components/schemas/ConnectionHostType"},{"type":"null"}],"description":"Which address to use for SSH connection"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"Deprecated: Use ipv4_address instead"},"ssh_port":{"anyOf":[{"type":"integer","maximum":65535.0,"minimum":1.0},{"type":"null"}],"title":"Ssh Port","description":"SSH port"},"ssh_username":{"anyOf":[{"type":"string","maxLength":50,"minLength":1},{"type":"null"}],"title":"Ssh Username"},"ssh_auth_method":{"anyOf":[{"$ref":"#/components/schemas/SSHAuthMethod"},{"type":"null"}]},"ssh_password":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Password"},"ssh_private_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Private Key"},"ssh_key_passphrase":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ssh Key Passphrase"},"ssh_sudo_mode":{"anyOf":[{"$ref":"#/components/schemas/SSHSudoMode"},{"type":"null"}],"description":"Sudo mode for privileged commands"},"cpu_cores":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Cpu Cores"},"memory_gb":{"anyOf":[{"type":"integer","minimum":1.0},{"type":"null"}],"title":"Memory Gb"},"disk_gb":{"anyOf":[{"type":"integer","minimum":10.0},{"type":"null"}],"title":"Disk Gb"},"max_projects":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Max Projects"},"tags":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Tags"},"settings":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Settings"}},"type":"object","title":"VMUpdate","description":"Schema for updating a VM/Server.","example":{}},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"ValidationRecord":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"},"value":{"type":"string","title":"Value"},"ttl":{"type":"integer","title":"Ttl","default":60},"purpose":{"type":"string","enum":["ssl_validation","hostname_ownership"],"title":"Purpose","default":"ssl_validation"}},"type":"object","required":["name","type","value"],"title":"ValidationRecord","description":"One CF validation record (spec §6.5)."},"VerifyCredentialsRequest":{"properties":{"organization_id":{"type":"string","format":"uuid","title":"Organization Id","description":"Organization the DNS config is being set up for (permission context)"},"provider":{"$ref":"#/components/schemas/DNSProviderType","description":"DNS provider type"},"credentials":{"additionalProperties":{"type":"string"},"type":"object","title":"Credentials","description":"Provider credentials to verify","examples":[{"api_token":"your_cloudflare_token"}]}},"type":"object","required":["organization_id","provider","credentials"],"title":"VerifyCredentialsRequest","description":"Schema for verifying DNS provider credentials before saving.","example":{}},"VerifyCredentialsResponse":{"properties":{"valid":{"type":"boolean","title":"Valid","description":"Whether credentials are valid"},"message":{"type":"string","title":"Message","description":"Verification result message"},"zones":{"items":{"$ref":"#/components/schemas/ZoneResponse"},"type":"array","title":"Zones","description":"Available DNS zones (if credentials valid)"}},"type":"object","required":["valid","message"],"title":"VerifyCredentialsResponse","description":"Schema for credential verification response with zones.","example":{}},"WebhookDeliveryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event":{"type":"string","title":"Event"},"status":{"type":"string","title":"Status"},"attempt_count":{"type":"integer","title":"Attempt Count"},"response_status":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Response Status"},"response_body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Response Body"},"error_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Reason"},"duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Ms"},"delivered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Delivered At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","event","status","attempt_count","response_status","duration_ms","delivered_at","created_at"],"title":"WebhookDeliveryResponse","description":"A single webhook delivery attempt log entry."},"WebhookHealthResponse":{"properties":{"last_received_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Received At"},"last_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Status"},"last_deployed_via_webhook_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Deployed Via Webhook At"},"last_deployment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Last Deployment Id"},"total_last_24h":{"type":"integer","title":"Total Last 24H","default":0},"processed_last_24h":{"type":"integer","title":"Processed Last 24H","default":0},"failed_last_24h":{"type":"integer","title":"Failed Last 24H","default":0}},"type":"object","title":"WebhookHealthResponse","description":"Webhook health summary for an environment."},"WebhookSetupRequest":{"properties":{"repo_full_name":{"type":"string","title":"Repo Full Name"},"webhook_url":{"type":"string","title":"Webhook Url"},"secret":{"type":"string","title":"Secret"}},"type":"object","required":["repo_full_name","webhook_url","secret"],"title":"WebhookSetupRequest","description":"Request to setup webhook."},"WebhookSetupResponse":{"properties":{"id":{"type":"string","title":"Id"},"url":{"type":"string","title":"Url"},"active":{"type":"boolean","title":"Active"}},"type":"object","required":["id","url","active"],"title":"WebhookSetupResponse","description":"Response after webhook setup."},"WebhookTestResponse":{"properties":{"success":{"type":"boolean","title":"Success"},"status_code":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Status Code"},"duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Ms"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"}},"type":"object","required":["success","status_code","duration_ms","message"],"title":"WebhookTestResponse","description":"Result of a manual test-fire for a webhook."},"ZoneListResponse":{"properties":{"zones":{"items":{"$ref":"#/components/schemas/ZoneResponse"},"type":"array","title":"Zones","description":"List of DNS zones"}},"type":"object","required":["zones"],"title":"ZoneListResponse","description":"Schema for listing zones.","example":{}},"ZoneResponse":{"properties":{"id":{"type":"string","title":"Id","description":"Provider's zone ID"},"name":{"type":"string","title":"Name","description":"Domain name"},"status":{"type":"string","title":"Status","description":"Zone status"},"name_servers":{"items":{"type":"string"},"type":"array","title":"Name Servers","description":"Authoritative nameservers"}},"type":"object","required":["id","name","status"],"title":"ZoneResponse","description":"Schema for DNS zone response.","example":{}},"_ThemeUserRef":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","title":"Email"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"}},"type":"object","required":["id","email"],"title":"_ThemeUserRef"},"api__v1__routes__admin__stats_routes__ServerHealthSummary":{"properties":{"total":{"type":"integer","title":"Total"},"online":{"type":"integer","title":"Online"},"offline":{"type":"integer","title":"Offline"},"error":{"type":"integer","title":"Error"},"health_percentage":{"type":"number","title":"Health Percentage"}},"type":"object","required":["total","online","offline","error","health_percentage"],"title":"ServerHealthSummary","description":"Server health overview."},"schemas__backup__EnvironmentType":{"type":"string","enum":["development","staging","production","testing"],"title":"EnvironmentType","description":"Environment type enum (mirrors project schemas)."},"schemas__cloud_account__DNSConfigSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"domain_count":{"type":"integer","title":"Domain Count","default":0}},"type":"object","required":["id","name"],"title":"DNSConfigSummary","description":"Summary of a DNS configuration for deletion impact."},"schemas__cloud_account__StorageConfigSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"}},"type":"object","required":["id","name"],"title":"StorageConfigSummary","description":"Summary of a storage configuration for deletion impact."},"schemas__cloud_provider__CloudProviderType":{"type":"string","enum":["aws","azure","gcp","digitalocean","vultr","ovhcloud","hetzner","linode"],"title":"CloudProviderType","description":"Supported cloud providers."},"schemas__cloud_provider__OAuthAuthorizeRequest":{"properties":{"provider":{"$ref":"#/components/schemas/schemas__cloud_provider__CloudProviderType","description":"Cloud provider"},"redirect_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Redirect Url","description":"URL to redirect after OAuth completion"}},"type":"object","required":["provider"],"title":"OAuthAuthorizeRequest","description":"Request to start OAuth flow.","example":{}},"schemas__cloud_provider__OAuthAuthorizeResponse":{"properties":{"authorize_url":{"type":"string","title":"Authorize Url","description":"URL to redirect user for OAuth"},"state":{"type":"string","title":"State","description":"OAuth state token"}},"type":"object","required":["authorize_url","state"],"title":"OAuthAuthorizeResponse","description":"Response with OAuth authorization URL.","example":{}},"schemas__departure__EnvironmentSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"project_name":{"type":"string","title":"Project Name"},"environment_type":{"type":"string","title":"Environment Type"},"status":{"type":"string","title":"Status"},"has_database":{"type":"boolean","title":"Has Database"},"has_filestore":{"type":"boolean","title":"Has Filestore"}},"type":"object","required":["id","name","project_name","environment_type","status","has_database","has_filestore"],"title":"EnvironmentSummary","description":"Summary of an environment for impact report."},"schemas__git_connection__GitProvider":{"type":"string","enum":["github","gitlab","bitbucket","generic"],"title":"GitProvider","description":"Supported Git providers."},"schemas__organization_platform_hostname__ValidationRecord":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"},"value":{"type":"string","title":"Value"},"ttl":{"type":"integer","title":"Ttl","default":60},"purpose":{"type":"string","enum":["ssl_validation","hostname_ownership"],"title":"Purpose","default":"ssl_validation"}},"type":"object","required":["name","type","value"],"title":"ValidationRecord","description":"One CF validation record (spec §6.5 — mirrors Phase 3 shape)."},"schemas__permission__PermissionScope":{"type":"string","enum":["portal","organization","project"],"title":"PermissionScope","description":"Permission scope levels."},"schemas__project__LogLevel":{"type":"string","enum":["debug","info","warn","error","critical","notset","debug_rpc","debug_sql","debug_rpc_answer","test","runbot"],"title":"LogLevel","description":"Odoo log levels.\n\nIMPORTANT: Odoo uses 'warn' NOT 'warning'. This is consistent across all versions (14.0-19.0).\nValid levels: info, debug_rpc, warn, test, critical, runbot, debug_sql, error, debug, debug_rpc_answer, notset"},"schemas__server_registration__AutoDeployConfig":{"properties":{"project_name":{"type":"string","maxLength":255,"minLength":1,"title":"Project Name"},"odoo_version":{"type":"string","title":"Odoo Version","description":"Odoo version (e.g., '18.0', '17.0')"},"env_type":{"type":"string","pattern":"^(production|staging)$","title":"Env Type","default":"production"},"cpu_cores":{"type":"number","maximum":64.0,"minimum":1.0,"title":"Cpu Cores","description":"CPU cores for the environment","default":2.0},"ram_mb":{"type":"integer","maximum":262144.0,"minimum":1024.0,"title":"Ram Mb","description":"RAM in MB for the environment","default":4096},"disk_gb":{"type":"integer","maximum":1000.0,"minimum":10.0,"title":"Disk Gb","description":"Disk space in GB for the environment","default":20}},"type":"object","required":["project_name","odoo_version"],"title":"AutoDeployConfig","description":"Optional auto-deploy configuration for Quick Connect."},"schemas__webhook_delivery__WebhookDeliveryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"provider":{"type":"string","title":"Provider"},"event_type":{"type":"string","title":"Event Type"},"delivery_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivery Id"},"branch":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch"},"commit_sha":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Commit Sha"},"commit_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Commit Message"},"sender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender"},"status":{"type":"string","title":"Status"},"status_detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status Detail"},"auto_deploy_triggered":{"type":"boolean","title":"Auto Deploy Triggered"},"environments_matched":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Environments Matched"},"deployment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Deployment Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","project_id","provider","event_type","delivery_id","branch","commit_sha","commit_message","sender","status","status_detail","auto_deploy_triggered","environments_matched","deployment_id","created_at"],"title":"WebhookDeliveryResponse","description":"Single webhook delivery log entry."}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}