enterprise: account lockdown (#18615)

This commit is contained in:
Dominic R
2026-04-30 19:02:46 -04:00
committed by GitHub
parent 8963d29ab4
commit 821b74d7c1
68 changed files with 4412 additions and 88 deletions
+9
View File
@@ -39,6 +39,7 @@ type ApiCoreBrandsListRequest struct {
flowAuthentication *string
flowDeviceCode *string
flowInvalidation *string
flowLockdown *string
flowRecovery *string
flowUnenrollment *string
flowUserSettings *string
@@ -104,6 +105,11 @@ func (r ApiCoreBrandsListRequest) FlowInvalidation(flowInvalidation string) ApiC
return r
}
func (r ApiCoreBrandsListRequest) FlowLockdown(flowLockdown string) ApiCoreBrandsListRequest {
r.flowLockdown = &flowLockdown
return r
}
func (r ApiCoreBrandsListRequest) FlowRecovery(flowRecovery string) ApiCoreBrandsListRequest {
r.flowRecovery = &flowRecovery
return r
@@ -230,6 +236,9 @@ func (a *CoreAPIService) CoreBrandsListExecute(r ApiCoreBrandsListRequest) (*Pag
if r.flowInvalidation != nil {
parameterAddToHeaderOrQuery(localVarQueryParams, "flow_invalidation", r.flowInvalidation, "form", "")
}
if r.flowLockdown != nil {
parameterAddToHeaderOrQuery(localVarQueryParams, "flow_lockdown", r.flowLockdown, "form", "")
}
if r.flowRecovery != nil {
parameterAddToHeaderOrQuery(localVarQueryParams, "flow_recovery", r.flowRecovery, "form", "")
}
+48
View File
@@ -36,6 +36,7 @@ type Brand struct {
FlowUnenrollment NullableString `json:"flow_unenrollment,omitempty"`
FlowUserSettings NullableString `json:"flow_user_settings,omitempty"`
FlowDeviceCode NullableString `json:"flow_device_code,omitempty"`
FlowLockdown NullableString `json:"flow_lockdown,omitempty"`
// When set, external users will be redirected to this application after authenticating.
DefaultApplication NullableString `json:"default_application,omitempty"`
// Web Certificate used by the authentik Core webserver.
@@ -565,6 +566,49 @@ func (o *Brand) UnsetFlowDeviceCode() {
o.FlowDeviceCode.Unset()
}
// GetFlowLockdown returns the FlowLockdown field value if set, zero value otherwise (both if not set or set to explicit null).
func (o *Brand) GetFlowLockdown() string {
if o == nil || IsNil(o.FlowLockdown.Get()) {
var ret string
return ret
}
return *o.FlowLockdown.Get()
}
// GetFlowLockdownOk returns a tuple with the FlowLockdown field value if set, nil otherwise
// and a boolean to check if the value has been set.
// NOTE: If the value is an explicit nil, `nil, true` will be returned
func (o *Brand) GetFlowLockdownOk() (*string, bool) {
if o == nil {
return nil, false
}
return o.FlowLockdown.Get(), o.FlowLockdown.IsSet()
}
// HasFlowLockdown returns a boolean if a field has been set.
func (o *Brand) HasFlowLockdown() bool {
if o != nil && o.FlowLockdown.IsSet() {
return true
}
return false
}
// SetFlowLockdown gets a reference to the given NullableString and assigns it to the FlowLockdown field.
func (o *Brand) SetFlowLockdown(v string) {
o.FlowLockdown.Set(&v)
}
// SetFlowLockdownNil sets the value for FlowLockdown to be an explicit nil
func (o *Brand) SetFlowLockdownNil() {
o.FlowLockdown.Set(nil)
}
// UnsetFlowLockdown ensures that no value is present for FlowLockdown, not even an explicit nil
func (o *Brand) UnsetFlowLockdown() {
o.FlowLockdown.Unset()
}
// GetDefaultApplication returns the DefaultApplication field value if set, zero value otherwise (both if not set or set to explicit null).
func (o *Brand) GetDefaultApplication() string {
if o == nil || IsNil(o.DefaultApplication.Get()) {
@@ -763,6 +807,9 @@ func (o Brand) ToMap() (map[string]interface{}, error) {
if o.FlowDeviceCode.IsSet() {
toSerialize["flow_device_code"] = o.FlowDeviceCode.Get()
}
if o.FlowLockdown.IsSet() {
toSerialize["flow_lockdown"] = o.FlowLockdown.Get()
}
if o.DefaultApplication.IsSet() {
toSerialize["default_application"] = o.DefaultApplication.Get()
}
@@ -833,6 +880,7 @@ func (o *Brand) UnmarshalJSON(data []byte) (err error) {
delete(additionalProperties, "flow_unenrollment")
delete(additionalProperties, "flow_user_settings")
delete(additionalProperties, "flow_device_code")
delete(additionalProperties, "flow_lockdown")
delete(additionalProperties, "default_application")
delete(additionalProperties, "web_certificate")
delete(additionalProperties, "client_certificates")
+6
View File
@@ -38,6 +38,9 @@ const (
PROMPTTYPEENUM_SEPARATOR PromptTypeEnum = "separator"
PROMPTTYPEENUM_HIDDEN PromptTypeEnum = "hidden"
PROMPTTYPEENUM_STATIC PromptTypeEnum = "static"
PROMPTTYPEENUM_ALERT_INFO PromptTypeEnum = "alert_info"
PROMPTTYPEENUM_ALERT_WARNING PromptTypeEnum = "alert_warning"
PROMPTTYPEENUM_ALERT_DANGER PromptTypeEnum = "alert_danger"
PROMPTTYPEENUM_AK_LOCALE PromptTypeEnum = "ak-locale"
)
@@ -60,6 +63,9 @@ var AllowedPromptTypeEnumEnumValues = []PromptTypeEnum{
"separator",
"hidden",
"static",
"alert_info",
"alert_warning",
"alert_danger",
"ak-locale",
}
+5
View File
@@ -71,6 +71,7 @@ pub async fn core_brands_list(
flow_authentication: Option<&str>,
flow_device_code: Option<&str>,
flow_invalidation: Option<&str>,
flow_lockdown: Option<&str>,
flow_recovery: Option<&str>,
flow_unenrollment: Option<&str>,
flow_user_settings: Option<&str>,
@@ -92,6 +93,7 @@ pub async fn core_brands_list(
let p_query_flow_authentication = flow_authentication;
let p_query_flow_device_code = flow_device_code;
let p_query_flow_invalidation = flow_invalidation;
let p_query_flow_lockdown = flow_lockdown;
let p_query_flow_recovery = flow_recovery;
let p_query_flow_unenrollment = flow_unenrollment;
let p_query_flow_user_settings = flow_user_settings;
@@ -154,6 +156,9 @@ pub async fn core_brands_list(
if let Some(ref param_value) = p_query_flow_invalidation {
req_builder = req_builder.query(&[("flow_invalidation", &param_value.to_string())]);
}
if let Some(ref param_value) = p_query_flow_lockdown {
req_builder = req_builder.query(&[("flow_lockdown", &param_value.to_string())]);
}
if let Some(ref param_value) = p_query_flow_recovery {
req_builder = req_builder.query(&[("flow_recovery", &param_value.to_string())]);
}
+8
View File
@@ -78,6 +78,13 @@ pub struct Brand {
skip_serializing_if = "Option::is_none"
)]
pub flow_device_code: Option<Option<uuid::Uuid>>,
#[serde(
rename = "flow_lockdown",
default,
with = "::serde_with::rust::double_option",
skip_serializing_if = "Option::is_none"
)]
pub flow_lockdown: Option<Option<uuid::Uuid>>,
/// When set, external users will be redirected to this application after authenticating.
#[serde(
rename = "default_application",
@@ -122,6 +129,7 @@ impl Brand {
flow_unenrollment: None,
flow_user_settings: None,
flow_device_code: None,
flow_lockdown: None,
default_application: None,
web_certificate: None,
client_certificates: None,
+9
View File
@@ -47,6 +47,12 @@ pub enum PromptTypeEnum {
Hidden,
#[serde(rename = "static")]
Static,
#[serde(rename = "alert_info")]
AlertInfo,
#[serde(rename = "alert_warning")]
AlertWarning,
#[serde(rename = "alert_danger")]
AlertDanger,
#[serde(rename = "ak-locale")]
AkLocale,
}
@@ -71,6 +77,9 @@ impl std::fmt::Display for PromptTypeEnum {
Self::Separator => write!(f, "separator"),
Self::Hidden => write!(f, "hidden"),
Self::Static => write!(f, "static"),
Self::AlertInfo => write!(f, "alert_info"),
Self::AlertWarning => write!(f, "alert_warning"),
Self::AlertDanger => write!(f, "alert_danger"),
Self::AkLocale => write!(f, "ak-locale"),
}
}
+71
View File
@@ -52,6 +52,7 @@ import type {
TransactionApplicationResponse,
UsedBy,
User,
UserAccountLockdownRequest,
UserAccountRequest,
UserConsent,
UserPasswordHashSetRequest,
@@ -102,6 +103,7 @@ import {
TransactionApplicationRequestToJSON,
TransactionApplicationResponseFromJSON,
UsedByFromJSON,
UserAccountLockdownRequestToJSON,
UserAccountRequestToJSON,
UserConsentFromJSON,
UserFromJSON,
@@ -245,6 +247,7 @@ export interface CoreBrandsListRequest {
flowAuthentication?: string;
flowDeviceCode?: string;
flowInvalidation?: string;
flowLockdown?: string;
flowRecovery?: string;
flowUnenrollment?: string;
flowUserSettings?: string;
@@ -403,6 +406,10 @@ export interface CoreUserConsentUsedByListRequest {
id: number;
}
export interface CoreUsersAccountLockdownCreateRequest {
userAccountLockdownRequest?: UserAccountLockdownRequest;
}
export interface CoreUsersCreateRequest {
userRequest: UserRequest;
}
@@ -2214,6 +2221,10 @@ export class CoreApi extends runtime.BaseAPI {
queryParameters["flow_invalidation"] = requestParameters["flowInvalidation"];
}
if (requestParameters["flowLockdown"] != null) {
queryParameters["flow_lockdown"] = requestParameters["flowLockdown"];
}
if (requestParameters["flowRecovery"] != null) {
queryParameters["flow_recovery"] = requestParameters["flowRecovery"];
}
@@ -4189,6 +4200,66 @@ export class CoreApi extends runtime.BaseAPI {
return await response.value();
}
/**
* Creates request options for coreUsersAccountLockdownCreate without sending the request
*/
async coreUsersAccountLockdownCreateRequestOpts(
requestParameters: CoreUsersAccountLockdownCreateRequest,
): Promise<runtime.RequestOpts> {
const queryParameters: any = {};
const headerParameters: runtime.HTTPHeaders = {};
headerParameters["Content-Type"] = "application/json";
if (this.configuration && this.configuration.accessToken) {
const token = this.configuration.accessToken;
const tokenString = await token("authentik", []);
if (tokenString) {
headerParameters["Authorization"] = `Bearer ${tokenString}`;
}
}
let urlPath = `/core/users/account_lockdown/`;
return {
path: urlPath,
method: "POST",
headers: headerParameters,
query: queryParameters,
body: UserAccountLockdownRequestToJSON(requestParameters["userAccountLockdownRequest"]),
};
}
/**
* Choose the target account, then return a flow link.
*/
async coreUsersAccountLockdownCreateRaw(
requestParameters: CoreUsersAccountLockdownCreateRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<runtime.ApiResponse<Link>> {
const requestOptions =
await this.coreUsersAccountLockdownCreateRequestOpts(requestParameters);
const response = await this.request(requestOptions, initOverrides);
return new runtime.JSONApiResponse(response, (jsonValue) => LinkFromJSON(jsonValue));
}
/**
* Choose the target account, then return a flow link.
*/
async coreUsersAccountLockdownCreate(
requestParameters: CoreUsersAccountLockdownCreateRequest = {},
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<Link> {
const response = await this.coreUsersAccountLockdownCreateRaw(
requestParameters,
initOverrides,
);
return await response.value();
}
/**
* Creates request options for coreUsersCreate without sending the request
*/
+576
View File
@@ -13,6 +13,8 @@
*/
import type {
AccountLockdownStage,
AccountLockdownStageRequest,
AuthenticatorAttachmentEnum,
AuthenticatorDuoStage,
AuthenticatorDuoStageDeviceImportResponse,
@@ -61,6 +63,7 @@ import type {
MutualTLSStageRequest,
NetworkBindingEnum,
NotConfiguredActionEnum,
PaginatedAccountLockdownStageList,
PaginatedAuthenticatorDuoStageList,
PaginatedAuthenticatorEmailStageList,
PaginatedAuthenticatorEndpointGDTCStageList,
@@ -92,6 +95,7 @@ import type {
PaginatedWebAuthnDeviceTypeList,
PasswordStage,
PasswordStageRequest,
PatchedAccountLockdownStageRequest,
PatchedAuthenticatorDuoStageRequest,
PatchedAuthenticatorEmailStageRequest,
PatchedAuthenticatorEndpointGDTCStageRequest,
@@ -150,6 +154,8 @@ import type {
WebAuthnDeviceType,
} from "../models/index";
import {
AccountLockdownStageFromJSON,
AccountLockdownStageRequestToJSON,
AuthenticatorDuoStageDeviceImportResponseFromJSON,
AuthenticatorDuoStageFromJSON,
AuthenticatorDuoStageManualDeviceImportRequestToJSON,
@@ -190,6 +196,7 @@ import {
InvitationStageRequestToJSON,
MutualTLSStageFromJSON,
MutualTLSStageRequestToJSON,
PaginatedAccountLockdownStageListFromJSON,
PaginatedAuthenticatorDuoStageListFromJSON,
PaginatedAuthenticatorEmailStageListFromJSON,
PaginatedAuthenticatorEndpointGDTCStageListFromJSON,
@@ -221,6 +228,7 @@ import {
PaginatedWebAuthnDeviceTypeListFromJSON,
PasswordStageFromJSON,
PasswordStageRequestToJSON,
PatchedAccountLockdownStageRequestToJSON,
PatchedAuthenticatorDuoStageRequestToJSON,
PatchedAuthenticatorEmailStageRequestToJSON,
PatchedAuthenticatorEndpointGDTCStageRequestToJSON,
@@ -273,6 +281,46 @@ import {
} from "../models/index";
import * as runtime from "../runtime";
export interface StagesAccountLockdownCreateRequest {
accountLockdownStageRequest: AccountLockdownStageRequest;
}
export interface StagesAccountLockdownDestroyRequest {
stageUuid: string;
}
export interface StagesAccountLockdownListRequest {
deactivateUser?: boolean;
deleteSessions?: boolean;
name?: string;
ordering?: string;
page?: number;
pageSize?: number;
revokeTokens?: boolean;
search?: string;
selfServiceCompletionFlow?: string;
setUnusablePassword?: boolean;
stageUuid?: string;
}
export interface StagesAccountLockdownPartialUpdateRequest {
stageUuid: string;
patchedAccountLockdownStageRequest?: PatchedAccountLockdownStageRequest;
}
export interface StagesAccountLockdownRetrieveRequest {
stageUuid: string;
}
export interface StagesAccountLockdownUpdateRequest {
stageUuid: string;
accountLockdownStageRequest: AccountLockdownStageRequest;
}
export interface StagesAccountLockdownUsedByListRequest {
stageUuid: string;
}
export interface StagesAllDestroyRequest {
stageUuid: string;
}
@@ -1366,6 +1414,534 @@ export interface StagesUserWriteUsedByListRequest {
*
*/
export class StagesApi extends runtime.BaseAPI {
/**
* Creates request options for stagesAccountLockdownCreate without sending the request
*/
async stagesAccountLockdownCreateRequestOpts(
requestParameters: StagesAccountLockdownCreateRequest,
): Promise<runtime.RequestOpts> {
if (requestParameters["accountLockdownStageRequest"] == null) {
throw new runtime.RequiredError(
"accountLockdownStageRequest",
'Required parameter "accountLockdownStageRequest" was null or undefined when calling stagesAccountLockdownCreate().',
);
}
const queryParameters: any = {};
const headerParameters: runtime.HTTPHeaders = {};
headerParameters["Content-Type"] = "application/json";
if (this.configuration && this.configuration.accessToken) {
const token = this.configuration.accessToken;
const tokenString = await token("authentik", []);
if (tokenString) {
headerParameters["Authorization"] = `Bearer ${tokenString}`;
}
}
let urlPath = `/stages/account_lockdown/`;
return {
path: urlPath,
method: "POST",
headers: headerParameters,
query: queryParameters,
body: AccountLockdownStageRequestToJSON(
requestParameters["accountLockdownStageRequest"],
),
};
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownCreateRaw(
requestParameters: StagesAccountLockdownCreateRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<runtime.ApiResponse<AccountLockdownStage>> {
const requestOptions = await this.stagesAccountLockdownCreateRequestOpts(requestParameters);
const response = await this.request(requestOptions, initOverrides);
return new runtime.JSONApiResponse(response, (jsonValue) =>
AccountLockdownStageFromJSON(jsonValue),
);
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownCreate(
requestParameters: StagesAccountLockdownCreateRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<AccountLockdownStage> {
const response = await this.stagesAccountLockdownCreateRaw(
requestParameters,
initOverrides,
);
return await response.value();
}
/**
* Creates request options for stagesAccountLockdownDestroy without sending the request
*/
async stagesAccountLockdownDestroyRequestOpts(
requestParameters: StagesAccountLockdownDestroyRequest,
): Promise<runtime.RequestOpts> {
if (requestParameters["stageUuid"] == null) {
throw new runtime.RequiredError(
"stageUuid",
'Required parameter "stageUuid" was null or undefined when calling stagesAccountLockdownDestroy().',
);
}
const queryParameters: any = {};
const headerParameters: runtime.HTTPHeaders = {};
if (this.configuration && this.configuration.accessToken) {
const token = this.configuration.accessToken;
const tokenString = await token("authentik", []);
if (tokenString) {
headerParameters["Authorization"] = `Bearer ${tokenString}`;
}
}
let urlPath = `/stages/account_lockdown/{stage_uuid}/`;
urlPath = urlPath.replace(
`{${"stage_uuid"}}`,
encodeURIComponent(String(requestParameters["stageUuid"])),
);
return {
path: urlPath,
method: "DELETE",
headers: headerParameters,
query: queryParameters,
};
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownDestroyRaw(
requestParameters: StagesAccountLockdownDestroyRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<runtime.ApiResponse<void>> {
const requestOptions =
await this.stagesAccountLockdownDestroyRequestOpts(requestParameters);
const response = await this.request(requestOptions, initOverrides);
return new runtime.VoidApiResponse(response);
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownDestroy(
requestParameters: StagesAccountLockdownDestroyRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<void> {
await this.stagesAccountLockdownDestroyRaw(requestParameters, initOverrides);
}
/**
* Creates request options for stagesAccountLockdownList without sending the request
*/
async stagesAccountLockdownListRequestOpts(
requestParameters: StagesAccountLockdownListRequest,
): Promise<runtime.RequestOpts> {
const queryParameters: any = {};
if (requestParameters["deactivateUser"] != null) {
queryParameters["deactivate_user"] = requestParameters["deactivateUser"];
}
if (requestParameters["deleteSessions"] != null) {
queryParameters["delete_sessions"] = requestParameters["deleteSessions"];
}
if (requestParameters["name"] != null) {
queryParameters["name"] = requestParameters["name"];
}
if (requestParameters["ordering"] != null) {
queryParameters["ordering"] = requestParameters["ordering"];
}
if (requestParameters["page"] != null) {
queryParameters["page"] = requestParameters["page"];
}
if (requestParameters["pageSize"] != null) {
queryParameters["page_size"] = requestParameters["pageSize"];
}
if (requestParameters["revokeTokens"] != null) {
queryParameters["revoke_tokens"] = requestParameters["revokeTokens"];
}
if (requestParameters["search"] != null) {
queryParameters["search"] = requestParameters["search"];
}
if (requestParameters["selfServiceCompletionFlow"] != null) {
queryParameters["self_service_completion_flow"] =
requestParameters["selfServiceCompletionFlow"];
}
if (requestParameters["setUnusablePassword"] != null) {
queryParameters["set_unusable_password"] = requestParameters["setUnusablePassword"];
}
if (requestParameters["stageUuid"] != null) {
queryParameters["stage_uuid"] = requestParameters["stageUuid"];
}
const headerParameters: runtime.HTTPHeaders = {};
if (this.configuration && this.configuration.accessToken) {
const token = this.configuration.accessToken;
const tokenString = await token("authentik", []);
if (tokenString) {
headerParameters["Authorization"] = `Bearer ${tokenString}`;
}
}
let urlPath = `/stages/account_lockdown/`;
return {
path: urlPath,
method: "GET",
headers: headerParameters,
query: queryParameters,
};
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownListRaw(
requestParameters: StagesAccountLockdownListRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<runtime.ApiResponse<PaginatedAccountLockdownStageList>> {
const requestOptions = await this.stagesAccountLockdownListRequestOpts(requestParameters);
const response = await this.request(requestOptions, initOverrides);
return new runtime.JSONApiResponse(response, (jsonValue) =>
PaginatedAccountLockdownStageListFromJSON(jsonValue),
);
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownList(
requestParameters: StagesAccountLockdownListRequest = {},
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<PaginatedAccountLockdownStageList> {
const response = await this.stagesAccountLockdownListRaw(requestParameters, initOverrides);
return await response.value();
}
/**
* Creates request options for stagesAccountLockdownPartialUpdate without sending the request
*/
async stagesAccountLockdownPartialUpdateRequestOpts(
requestParameters: StagesAccountLockdownPartialUpdateRequest,
): Promise<runtime.RequestOpts> {
if (requestParameters["stageUuid"] == null) {
throw new runtime.RequiredError(
"stageUuid",
'Required parameter "stageUuid" was null or undefined when calling stagesAccountLockdownPartialUpdate().',
);
}
const queryParameters: any = {};
const headerParameters: runtime.HTTPHeaders = {};
headerParameters["Content-Type"] = "application/json";
if (this.configuration && this.configuration.accessToken) {
const token = this.configuration.accessToken;
const tokenString = await token("authentik", []);
if (tokenString) {
headerParameters["Authorization"] = `Bearer ${tokenString}`;
}
}
let urlPath = `/stages/account_lockdown/{stage_uuid}/`;
urlPath = urlPath.replace(
`{${"stage_uuid"}}`,
encodeURIComponent(String(requestParameters["stageUuid"])),
);
return {
path: urlPath,
method: "PATCH",
headers: headerParameters,
query: queryParameters,
body: PatchedAccountLockdownStageRequestToJSON(
requestParameters["patchedAccountLockdownStageRequest"],
),
};
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownPartialUpdateRaw(
requestParameters: StagesAccountLockdownPartialUpdateRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<runtime.ApiResponse<AccountLockdownStage>> {
const requestOptions =
await this.stagesAccountLockdownPartialUpdateRequestOpts(requestParameters);
const response = await this.request(requestOptions, initOverrides);
return new runtime.JSONApiResponse(response, (jsonValue) =>
AccountLockdownStageFromJSON(jsonValue),
);
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownPartialUpdate(
requestParameters: StagesAccountLockdownPartialUpdateRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<AccountLockdownStage> {
const response = await this.stagesAccountLockdownPartialUpdateRaw(
requestParameters,
initOverrides,
);
return await response.value();
}
/**
* Creates request options for stagesAccountLockdownRetrieve without sending the request
*/
async stagesAccountLockdownRetrieveRequestOpts(
requestParameters: StagesAccountLockdownRetrieveRequest,
): Promise<runtime.RequestOpts> {
if (requestParameters["stageUuid"] == null) {
throw new runtime.RequiredError(
"stageUuid",
'Required parameter "stageUuid" was null or undefined when calling stagesAccountLockdownRetrieve().',
);
}
const queryParameters: any = {};
const headerParameters: runtime.HTTPHeaders = {};
if (this.configuration && this.configuration.accessToken) {
const token = this.configuration.accessToken;
const tokenString = await token("authentik", []);
if (tokenString) {
headerParameters["Authorization"] = `Bearer ${tokenString}`;
}
}
let urlPath = `/stages/account_lockdown/{stage_uuid}/`;
urlPath = urlPath.replace(
`{${"stage_uuid"}}`,
encodeURIComponent(String(requestParameters["stageUuid"])),
);
return {
path: urlPath,
method: "GET",
headers: headerParameters,
query: queryParameters,
};
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownRetrieveRaw(
requestParameters: StagesAccountLockdownRetrieveRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<runtime.ApiResponse<AccountLockdownStage>> {
const requestOptions =
await this.stagesAccountLockdownRetrieveRequestOpts(requestParameters);
const response = await this.request(requestOptions, initOverrides);
return new runtime.JSONApiResponse(response, (jsonValue) =>
AccountLockdownStageFromJSON(jsonValue),
);
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownRetrieve(
requestParameters: StagesAccountLockdownRetrieveRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<AccountLockdownStage> {
const response = await this.stagesAccountLockdownRetrieveRaw(
requestParameters,
initOverrides,
);
return await response.value();
}
/**
* Creates request options for stagesAccountLockdownUpdate without sending the request
*/
async stagesAccountLockdownUpdateRequestOpts(
requestParameters: StagesAccountLockdownUpdateRequest,
): Promise<runtime.RequestOpts> {
if (requestParameters["stageUuid"] == null) {
throw new runtime.RequiredError(
"stageUuid",
'Required parameter "stageUuid" was null or undefined when calling stagesAccountLockdownUpdate().',
);
}
if (requestParameters["accountLockdownStageRequest"] == null) {
throw new runtime.RequiredError(
"accountLockdownStageRequest",
'Required parameter "accountLockdownStageRequest" was null or undefined when calling stagesAccountLockdownUpdate().',
);
}
const queryParameters: any = {};
const headerParameters: runtime.HTTPHeaders = {};
headerParameters["Content-Type"] = "application/json";
if (this.configuration && this.configuration.accessToken) {
const token = this.configuration.accessToken;
const tokenString = await token("authentik", []);
if (tokenString) {
headerParameters["Authorization"] = `Bearer ${tokenString}`;
}
}
let urlPath = `/stages/account_lockdown/{stage_uuid}/`;
urlPath = urlPath.replace(
`{${"stage_uuid"}}`,
encodeURIComponent(String(requestParameters["stageUuid"])),
);
return {
path: urlPath,
method: "PUT",
headers: headerParameters,
query: queryParameters,
body: AccountLockdownStageRequestToJSON(
requestParameters["accountLockdownStageRequest"],
),
};
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownUpdateRaw(
requestParameters: StagesAccountLockdownUpdateRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<runtime.ApiResponse<AccountLockdownStage>> {
const requestOptions = await this.stagesAccountLockdownUpdateRequestOpts(requestParameters);
const response = await this.request(requestOptions, initOverrides);
return new runtime.JSONApiResponse(response, (jsonValue) =>
AccountLockdownStageFromJSON(jsonValue),
);
}
/**
* AccountLockdownStage Viewset
*/
async stagesAccountLockdownUpdate(
requestParameters: StagesAccountLockdownUpdateRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<AccountLockdownStage> {
const response = await this.stagesAccountLockdownUpdateRaw(
requestParameters,
initOverrides,
);
return await response.value();
}
/**
* Creates request options for stagesAccountLockdownUsedByList without sending the request
*/
async stagesAccountLockdownUsedByListRequestOpts(
requestParameters: StagesAccountLockdownUsedByListRequest,
): Promise<runtime.RequestOpts> {
if (requestParameters["stageUuid"] == null) {
throw new runtime.RequiredError(
"stageUuid",
'Required parameter "stageUuid" was null or undefined when calling stagesAccountLockdownUsedByList().',
);
}
const queryParameters: any = {};
const headerParameters: runtime.HTTPHeaders = {};
if (this.configuration && this.configuration.accessToken) {
const token = this.configuration.accessToken;
const tokenString = await token("authentik", []);
if (tokenString) {
headerParameters["Authorization"] = `Bearer ${tokenString}`;
}
}
let urlPath = `/stages/account_lockdown/{stage_uuid}/used_by/`;
urlPath = urlPath.replace(
`{${"stage_uuid"}}`,
encodeURIComponent(String(requestParameters["stageUuid"])),
);
return {
path: urlPath,
method: "GET",
headers: headerParameters,
query: queryParameters,
};
}
/**
* Get a list of all objects that use this object
*/
async stagesAccountLockdownUsedByListRaw(
requestParameters: StagesAccountLockdownUsedByListRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<runtime.ApiResponse<Array<UsedBy>>> {
const requestOptions =
await this.stagesAccountLockdownUsedByListRequestOpts(requestParameters);
const response = await this.request(requestOptions, initOverrides);
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(UsedByFromJSON));
}
/**
* Get a list of all objects that use this object
*/
async stagesAccountLockdownUsedByList(
requestParameters: StagesAccountLockdownUsedByListRequest,
initOverrides?: RequestInit | runtime.InitOverrideFunction,
): Promise<Array<UsedBy>> {
const response = await this.stagesAccountLockdownUsedByListRaw(
requestParameters,
initOverrides,
);
return await response.value();
}
/**
* Creates request options for stagesAllDestroy without sending the request
*/
+166
View File
@@ -0,0 +1,166 @@
/* tslint:disable */
/* eslint-disable */
/**
* authentik
* Making authentication simple.
*
* The version of the OpenAPI document: 2026.5.0-rc1
* Contact: hello@goauthentik.io
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import type { FlowSet } from "./FlowSet";
import { FlowSetFromJSON } from "./FlowSet";
/**
* AccountLockdownStage Serializer
* @export
* @interface AccountLockdownStage
*/
export interface AccountLockdownStage {
/**
*
* @type {string}
* @memberof AccountLockdownStage
*/
readonly pk: string;
/**
*
* @type {string}
* @memberof AccountLockdownStage
*/
name: string;
/**
* Get object type so that we know how to edit the object
* @type {string}
* @memberof AccountLockdownStage
*/
readonly component: string;
/**
* Return object's verbose_name
* @type {string}
* @memberof AccountLockdownStage
*/
readonly verboseName: string;
/**
* Return object's plural verbose_name
* @type {string}
* @memberof AccountLockdownStage
*/
readonly verboseNamePlural: string;
/**
* Return internal model name
* @type {string}
* @memberof AccountLockdownStage
*/
readonly metaModelName: string;
/**
*
* @type {Array<FlowSet>}
* @memberof AccountLockdownStage
*/
readonly flowSet: Array<FlowSet>;
/**
* Deactivate the user account (set is_active to False)
* @type {boolean}
* @memberof AccountLockdownStage
*/
deactivateUser?: boolean;
/**
* Set an unusable password for the user
* @type {boolean}
* @memberof AccountLockdownStage
*/
setUnusablePassword?: boolean;
/**
* Delete all active sessions for the user
* @type {boolean}
* @memberof AccountLockdownStage
*/
deleteSessions?: boolean;
/**
* Revoke all tokens for the user (API, app password, recovery, verification, OAuth)
* @type {boolean}
* @memberof AccountLockdownStage
*/
revokeTokens?: boolean;
/**
* Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted.
* @type {string}
* @memberof AccountLockdownStage
*/
selfServiceCompletionFlow?: string | null;
}
/**
* Check if a given object implements the AccountLockdownStage interface.
*/
export function instanceOfAccountLockdownStage(value: object): value is AccountLockdownStage {
if (!("pk" in value) || value["pk"] === undefined) return false;
if (!("name" in value) || value["name"] === undefined) return false;
if (!("component" in value) || value["component"] === undefined) return false;
if (!("verboseName" in value) || value["verboseName"] === undefined) return false;
if (!("verboseNamePlural" in value) || value["verboseNamePlural"] === undefined) return false;
if (!("metaModelName" in value) || value["metaModelName"] === undefined) return false;
if (!("flowSet" in value) || value["flowSet"] === undefined) return false;
return true;
}
export function AccountLockdownStageFromJSON(json: any): AccountLockdownStage {
return AccountLockdownStageFromJSONTyped(json, false);
}
export function AccountLockdownStageFromJSONTyped(
json: any,
ignoreDiscriminator: boolean,
): AccountLockdownStage {
if (json == null) {
return json;
}
return {
pk: json["pk"],
name: json["name"],
component: json["component"],
verboseName: json["verbose_name"],
verboseNamePlural: json["verbose_name_plural"],
metaModelName: json["meta_model_name"],
flowSet: (json["flow_set"] as Array<any>).map(FlowSetFromJSON),
deactivateUser: json["deactivate_user"] == null ? undefined : json["deactivate_user"],
setUnusablePassword:
json["set_unusable_password"] == null ? undefined : json["set_unusable_password"],
deleteSessions: json["delete_sessions"] == null ? undefined : json["delete_sessions"],
revokeTokens: json["revoke_tokens"] == null ? undefined : json["revoke_tokens"],
selfServiceCompletionFlow:
json["self_service_completion_flow"] == null
? undefined
: json["self_service_completion_flow"],
};
}
export function AccountLockdownStageToJSON(json: any): AccountLockdownStage {
return AccountLockdownStageToJSONTyped(json, false);
}
export function AccountLockdownStageToJSONTyped(
value?: Omit<
AccountLockdownStage,
"pk" | "component" | "verbose_name" | "verbose_name_plural" | "meta_model_name" | "flow_set"
> | null,
ignoreDiscriminator: boolean = false,
): any {
if (value == null) {
return value;
}
return {
name: value["name"],
deactivate_user: value["deactivateUser"],
set_unusable_password: value["setUnusablePassword"],
delete_sessions: value["deleteSessions"],
revoke_tokens: value["revokeTokens"],
self_service_completion_flow: value["selfServiceCompletionFlow"],
};
}
@@ -0,0 +1,114 @@
/* tslint:disable */
/* eslint-disable */
/**
* authentik
* Making authentication simple.
*
* The version of the OpenAPI document: 2026.5.0-rc1
* Contact: hello@goauthentik.io
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
* AccountLockdownStage Serializer
* @export
* @interface AccountLockdownStageRequest
*/
export interface AccountLockdownStageRequest {
/**
*
* @type {string}
* @memberof AccountLockdownStageRequest
*/
name: string;
/**
* Deactivate the user account (set is_active to False)
* @type {boolean}
* @memberof AccountLockdownStageRequest
*/
deactivateUser?: boolean;
/**
* Set an unusable password for the user
* @type {boolean}
* @memberof AccountLockdownStageRequest
*/
setUnusablePassword?: boolean;
/**
* Delete all active sessions for the user
* @type {boolean}
* @memberof AccountLockdownStageRequest
*/
deleteSessions?: boolean;
/**
* Revoke all tokens for the user (API, app password, recovery, verification, OAuth)
* @type {boolean}
* @memberof AccountLockdownStageRequest
*/
revokeTokens?: boolean;
/**
* Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted.
* @type {string}
* @memberof AccountLockdownStageRequest
*/
selfServiceCompletionFlow?: string | null;
}
/**
* Check if a given object implements the AccountLockdownStageRequest interface.
*/
export function instanceOfAccountLockdownStageRequest(
value: object,
): value is AccountLockdownStageRequest {
if (!("name" in value) || value["name"] === undefined) return false;
return true;
}
export function AccountLockdownStageRequestFromJSON(json: any): AccountLockdownStageRequest {
return AccountLockdownStageRequestFromJSONTyped(json, false);
}
export function AccountLockdownStageRequestFromJSONTyped(
json: any,
ignoreDiscriminator: boolean,
): AccountLockdownStageRequest {
if (json == null) {
return json;
}
return {
name: json["name"],
deactivateUser: json["deactivate_user"] == null ? undefined : json["deactivate_user"],
setUnusablePassword:
json["set_unusable_password"] == null ? undefined : json["set_unusable_password"],
deleteSessions: json["delete_sessions"] == null ? undefined : json["delete_sessions"],
revokeTokens: json["revoke_tokens"] == null ? undefined : json["revoke_tokens"],
selfServiceCompletionFlow:
json["self_service_completion_flow"] == null
? undefined
: json["self_service_completion_flow"],
};
}
export function AccountLockdownStageRequestToJSON(json: any): AccountLockdownStageRequest {
return AccountLockdownStageRequestToJSONTyped(json, false);
}
export function AccountLockdownStageRequestToJSONTyped(
value?: AccountLockdownStageRequest | null,
ignoreDiscriminator: boolean = false,
): any {
if (value == null) {
return value;
}
return {
name: value["name"],
deactivate_user: value["deactivateUser"],
set_unusable_password: value["setUnusablePassword"],
delete_sessions: value["deleteSessions"],
revoke_tokens: value["revokeTokens"],
self_service_completion_flow: value["selfServiceCompletionFlow"],
};
}
+1
View File
@@ -94,6 +94,7 @@ export const AppEnum = {
AuthentikEnterpriseProvidersSsf: "authentik.enterprise.providers.ssf",
AuthentikEnterpriseProvidersWsFederation: "authentik.enterprise.providers.ws_federation",
AuthentikEnterpriseReports: "authentik.enterprise.reports",
AuthentikEnterpriseStagesAccountLockdown: "authentik.enterprise.stages.account_lockdown",
AuthentikEnterpriseStagesAuthenticatorEndpointGdtc:
"authentik.enterprise.stages.authenticator_endpoint_gdtc",
AuthentikEnterpriseStagesMtls: "authentik.enterprise.stages.mtls",
+8
View File
@@ -102,6 +102,12 @@ export interface Brand {
* @memberof Brand
*/
flowDeviceCode?: string | null;
/**
*
* @type {string}
* @memberof Brand
*/
flowLockdown?: string | null;
/**
* When set, external users will be redirected to this application after authenticating.
* @type {string}
@@ -166,6 +172,7 @@ export function BrandFromJSONTyped(json: any, ignoreDiscriminator: boolean): Bra
flowUserSettings:
json["flow_user_settings"] == null ? undefined : json["flow_user_settings"],
flowDeviceCode: json["flow_device_code"] == null ? undefined : json["flow_device_code"],
flowLockdown: json["flow_lockdown"] == null ? undefined : json["flow_lockdown"],
defaultApplication:
json["default_application"] == null ? undefined : json["default_application"],
webCertificate: json["web_certificate"] == null ? undefined : json["web_certificate"],
@@ -201,6 +208,7 @@ export function BrandToJSONTyped(
flow_unenrollment: value["flowUnenrollment"],
flow_user_settings: value["flowUserSettings"],
flow_device_code: value["flowDeviceCode"],
flow_lockdown: value["flowLockdown"],
default_application: value["defaultApplication"],
web_certificate: value["webCertificate"],
client_certificates: value["clientCertificates"],
+8
View File
@@ -96,6 +96,12 @@ export interface BrandRequest {
* @memberof BrandRequest
*/
flowDeviceCode?: string | null;
/**
*
* @type {string}
* @memberof BrandRequest
*/
flowLockdown?: string | null;
/**
* When set, external users will be redirected to this application after authenticating.
* @type {string}
@@ -158,6 +164,7 @@ export function BrandRequestFromJSONTyped(json: any, ignoreDiscriminator: boolea
flowUserSettings:
json["flow_user_settings"] == null ? undefined : json["flow_user_settings"],
flowDeviceCode: json["flow_device_code"] == null ? undefined : json["flow_device_code"],
flowLockdown: json["flow_lockdown"] == null ? undefined : json["flow_lockdown"],
defaultApplication:
json["default_application"] == null ? undefined : json["default_application"],
webCertificate: json["web_certificate"] == null ? undefined : json["web_certificate"],
@@ -193,6 +200,7 @@ export function BrandRequestToJSONTyped(
flow_unenrollment: value["flowUnenrollment"],
flow_user_settings: value["flowUserSettings"],
flow_device_code: value["flowDeviceCode"],
flow_lockdown: value["flowLockdown"],
default_application: value["defaultApplication"],
web_certificate: value["webCertificate"],
client_certificates: value["clientCertificates"],
+8
View File
@@ -117,6 +117,12 @@ export interface CurrentBrand {
* @memberof CurrentBrand
*/
flowDeviceCode?: string;
/**
*
* @type {string}
* @memberof CurrentBrand
*/
flowLockdown?: string;
/**
*
* @type {string}
@@ -177,6 +183,7 @@ export function CurrentBrandFromJSONTyped(json: any, ignoreDiscriminator: boolea
flowUserSettings:
json["flow_user_settings"] == null ? undefined : json["flow_user_settings"],
flowDeviceCode: json["flow_device_code"] == null ? undefined : json["flow_device_code"],
flowLockdown: json["flow_lockdown"] == null ? undefined : json["flow_lockdown"],
defaultLocale: json["default_locale"],
flags: CurrentBrandFlagsFromJSON(json["flags"]),
};
@@ -213,6 +220,7 @@ export function CurrentBrandToJSONTyped(
flow_unenrollment: value["flowUnenrollment"],
flow_user_settings: value["flowUserSettings"],
flow_device_code: value["flowDeviceCode"],
flow_lockdown: value["flowLockdown"],
flags: CurrentBrandFlagsToJSON(value["flags"]),
};
}
+2
View File
@@ -175,6 +175,8 @@ export const ModelEnum = {
AuthentikProvidersWsFederationWsfederationprovider:
"authentik_providers_ws_federation.wsfederationprovider",
AuthentikReportsDataexport: "authentik_reports.dataexport",
AuthentikStagesAccountLockdownAccountlockdownstage:
"authentik_stages_account_lockdown.accountlockdownstage",
AuthentikStagesAuthenticatorEndpointGdtcAuthenticatorendpointgdtcstage:
"authentik_stages_authenticator_endpoint_gdtc.authenticatorendpointgdtcstage",
AuthentikStagesMtlsMutualtlsstage: "authentik_stages_mtls.mutualtlsstage",
@@ -0,0 +1,97 @@
/* tslint:disable */
/* eslint-disable */
/**
* authentik
* Making authentication simple.
*
* The version of the OpenAPI document: 2026.5.0-rc1
* Contact: hello@goauthentik.io
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import type { AccountLockdownStage } from "./AccountLockdownStage";
import { AccountLockdownStageFromJSON, AccountLockdownStageToJSON } from "./AccountLockdownStage";
import type { Pagination } from "./Pagination";
import { PaginationFromJSON, PaginationToJSON } from "./Pagination";
/**
*
* @export
* @interface PaginatedAccountLockdownStageList
*/
export interface PaginatedAccountLockdownStageList {
/**
*
* @type {Pagination}
* @memberof PaginatedAccountLockdownStageList
*/
pagination: Pagination;
/**
*
* @type {Array<AccountLockdownStage>}
* @memberof PaginatedAccountLockdownStageList
*/
results: Array<AccountLockdownStage>;
/**
*
* @type {{ [key: string]: any; }}
* @memberof PaginatedAccountLockdownStageList
*/
autocomplete: { [key: string]: any };
}
/**
* Check if a given object implements the PaginatedAccountLockdownStageList interface.
*/
export function instanceOfPaginatedAccountLockdownStageList(
value: object,
): value is PaginatedAccountLockdownStageList {
if (!("pagination" in value) || value["pagination"] === undefined) return false;
if (!("results" in value) || value["results"] === undefined) return false;
if (!("autocomplete" in value) || value["autocomplete"] === undefined) return false;
return true;
}
export function PaginatedAccountLockdownStageListFromJSON(
json: any,
): PaginatedAccountLockdownStageList {
return PaginatedAccountLockdownStageListFromJSONTyped(json, false);
}
export function PaginatedAccountLockdownStageListFromJSONTyped(
json: any,
ignoreDiscriminator: boolean,
): PaginatedAccountLockdownStageList {
if (json == null) {
return json;
}
return {
pagination: PaginationFromJSON(json["pagination"]),
results: (json["results"] as Array<any>).map(AccountLockdownStageFromJSON),
autocomplete: json["autocomplete"],
};
}
export function PaginatedAccountLockdownStageListToJSON(
json: any,
): PaginatedAccountLockdownStageList {
return PaginatedAccountLockdownStageListToJSONTyped(json, false);
}
export function PaginatedAccountLockdownStageListToJSONTyped(
value?: PaginatedAccountLockdownStageList | null,
ignoreDiscriminator: boolean = false,
): any {
if (value == null) {
return value;
}
return {
pagination: PaginationToJSON(value["pagination"]),
results: (value["results"] as Array<any>).map(AccountLockdownStageToJSON),
autocomplete: value["autocomplete"],
};
}
@@ -0,0 +1,117 @@
/* tslint:disable */
/* eslint-disable */
/**
* authentik
* Making authentication simple.
*
* The version of the OpenAPI document: 2026.5.0-rc1
* Contact: hello@goauthentik.io
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
* AccountLockdownStage Serializer
* @export
* @interface PatchedAccountLockdownStageRequest
*/
export interface PatchedAccountLockdownStageRequest {
/**
*
* @type {string}
* @memberof PatchedAccountLockdownStageRequest
*/
name?: string;
/**
* Deactivate the user account (set is_active to False)
* @type {boolean}
* @memberof PatchedAccountLockdownStageRequest
*/
deactivateUser?: boolean;
/**
* Set an unusable password for the user
* @type {boolean}
* @memberof PatchedAccountLockdownStageRequest
*/
setUnusablePassword?: boolean;
/**
* Delete all active sessions for the user
* @type {boolean}
* @memberof PatchedAccountLockdownStageRequest
*/
deleteSessions?: boolean;
/**
* Revoke all tokens for the user (API, app password, recovery, verification, OAuth)
* @type {boolean}
* @memberof PatchedAccountLockdownStageRequest
*/
revokeTokens?: boolean;
/**
* Flow to redirect users to after self-service lockdown. This flow should not require authentication since the user's session is deleted.
* @type {string}
* @memberof PatchedAccountLockdownStageRequest
*/
selfServiceCompletionFlow?: string | null;
}
/**
* Check if a given object implements the PatchedAccountLockdownStageRequest interface.
*/
export function instanceOfPatchedAccountLockdownStageRequest(
value: object,
): value is PatchedAccountLockdownStageRequest {
return true;
}
export function PatchedAccountLockdownStageRequestFromJSON(
json: any,
): PatchedAccountLockdownStageRequest {
return PatchedAccountLockdownStageRequestFromJSONTyped(json, false);
}
export function PatchedAccountLockdownStageRequestFromJSONTyped(
json: any,
ignoreDiscriminator: boolean,
): PatchedAccountLockdownStageRequest {
if (json == null) {
return json;
}
return {
name: json["name"] == null ? undefined : json["name"],
deactivateUser: json["deactivate_user"] == null ? undefined : json["deactivate_user"],
setUnusablePassword:
json["set_unusable_password"] == null ? undefined : json["set_unusable_password"],
deleteSessions: json["delete_sessions"] == null ? undefined : json["delete_sessions"],
revokeTokens: json["revoke_tokens"] == null ? undefined : json["revoke_tokens"],
selfServiceCompletionFlow:
json["self_service_completion_flow"] == null
? undefined
: json["self_service_completion_flow"],
};
}
export function PatchedAccountLockdownStageRequestToJSON(
json: any,
): PatchedAccountLockdownStageRequest {
return PatchedAccountLockdownStageRequestToJSONTyped(json, false);
}
export function PatchedAccountLockdownStageRequestToJSONTyped(
value?: PatchedAccountLockdownStageRequest | null,
ignoreDiscriminator: boolean = false,
): any {
if (value == null) {
return value;
}
return {
name: value["name"],
deactivate_user: value["deactivateUser"],
set_unusable_password: value["setUnusablePassword"],
delete_sessions: value["deleteSessions"],
revoke_tokens: value["revokeTokens"],
self_service_completion_flow: value["selfServiceCompletionFlow"],
};
}
+8
View File
@@ -96,6 +96,12 @@ export interface PatchedBrandRequest {
* @memberof PatchedBrandRequest
*/
flowDeviceCode?: string | null;
/**
*
* @type {string}
* @memberof PatchedBrandRequest
*/
flowLockdown?: string | null;
/**
* When set, external users will be redirected to this application after authenticating.
* @type {string}
@@ -160,6 +166,7 @@ export function PatchedBrandRequestFromJSONTyped(
flowUserSettings:
json["flow_user_settings"] == null ? undefined : json["flow_user_settings"],
flowDeviceCode: json["flow_device_code"] == null ? undefined : json["flow_device_code"],
flowLockdown: json["flow_lockdown"] == null ? undefined : json["flow_lockdown"],
defaultApplication:
json["default_application"] == null ? undefined : json["default_application"],
webCertificate: json["web_certificate"] == null ? undefined : json["web_certificate"],
@@ -195,6 +202,7 @@ export function PatchedBrandRequestToJSONTyped(
flow_unenrollment: value["flowUnenrollment"],
flow_user_settings: value["flowUserSettings"],
flow_device_code: value["flowDeviceCode"],
flow_lockdown: value["flowLockdown"],
default_application: value["defaultApplication"],
web_certificate: value["webCertificate"],
client_certificates: value["clientCertificates"],
+3
View File
@@ -34,6 +34,9 @@ export const PromptTypeEnum = {
Separator: "separator",
Hidden: "hidden",
Static: "static",
AlertInfo: "alert_info",
AlertWarning: "alert_warning",
AlertDanger: "alert_danger",
AkLocale: "ak-locale",
UnknownDefaultOpenApi: "11184809",
} as const;
@@ -0,0 +1,69 @@
/* tslint:disable */
/* eslint-disable */
/**
* authentik
* Making authentication simple.
*
* The version of the OpenAPI document: 2026.5.0-rc1
* Contact: hello@goauthentik.io
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
/**
* Choose the target account before starting the lockdown flow.
* @export
* @interface UserAccountLockdownRequest
*/
export interface UserAccountLockdownRequest {
/**
* User to lock. If omitted, locks the current user (self-service).
* @type {number}
* @memberof UserAccountLockdownRequest
*/
user?: number | null;
}
/**
* Check if a given object implements the UserAccountLockdownRequest interface.
*/
export function instanceOfUserAccountLockdownRequest(
value: object,
): value is UserAccountLockdownRequest {
return true;
}
export function UserAccountLockdownRequestFromJSON(json: any): UserAccountLockdownRequest {
return UserAccountLockdownRequestFromJSONTyped(json, false);
}
export function UserAccountLockdownRequestFromJSONTyped(
json: any,
ignoreDiscriminator: boolean,
): UserAccountLockdownRequest {
if (json == null) {
return json;
}
return {
user: json["user"] == null ? undefined : json["user"],
};
}
export function UserAccountLockdownRequestToJSON(json: any): UserAccountLockdownRequest {
return UserAccountLockdownRequestToJSONTyped(json, false);
}
export function UserAccountLockdownRequestToJSONTyped(
value?: UserAccountLockdownRequest | null,
ignoreDiscriminator: boolean = false,
): any {
if (value == null) {
return value;
}
return {
user: value["user"],
};
}
+5
View File
@@ -1,6 +1,8 @@
/* tslint:disable */
/* eslint-disable */
export * from "./AccessDeniedChallenge";
export * from "./AccountLockdownStage";
export * from "./AccountLockdownStageRequest";
export * from "./AgentAuthenticationResponse";
export * from "./AgentConfig";
export * from "./AgentConnector";
@@ -352,6 +354,7 @@ export * from "./OutpostHealth";
export * from "./OutpostRequest";
export * from "./OutpostTypeEnum";
export * from "./PKCEMethodEnum";
export * from "./PaginatedAccountLockdownStageList";
export * from "./PaginatedAgentConnectorList";
export * from "./PaginatedAppleIndependentSecureEnclaveList";
export * from "./PaginatedApplicationEntitlementList";
@@ -518,6 +521,7 @@ export * from "./PasswordPolicy";
export * from "./PasswordPolicyRequest";
export * from "./PasswordStage";
export * from "./PasswordStageRequest";
export * from "./PatchedAccountLockdownStageRequest";
export * from "./PatchedAgentConnectorRequest";
export * from "./PatchedAppleIndependentSecureEnclaveRequest";
export * from "./PatchedApplicationEntitlementRequest";
@@ -822,6 +826,7 @@ export * from "./UsageEnum";
export * from "./UsedBy";
export * from "./UsedByActionEnum";
export * from "./User";
export * from "./UserAccountLockdownRequest";
export * from "./UserAccountRequest";
export * from "./UserAccountSerializerForRoleRequest";
export * from "./UserAttributeEnum";