getAuthProviderByMarker
Get an auth provider by its marker.
Description
Resolves to an IAuthProvidersEntity.
.getAuthProviderByMarker(
,
);
Parameters schema
Schema
marker(required): string
Marker of the auth provider.
example: "email"
langCode: string
Language code. Default: the langCode passed to defineOneEntry ("en_US" if none).
example: "en_US"
Examples
Minimal example
const response = await AuthProvider.getAuthProviderByMarker('email');
Example with langCode
const response = await AuthProvider.getAuthProviderByMarker('email', 'en_US');
Example response
{
"id": 1,
"localizeInfos": {
"title": "email"
},
"config": {
"accessTokenTtlSec": "36000",
"refreshTokenTtlMc": "604800",
"deleteNoneActiveUsersAfterDays": "2",
"systemCodeTlsSec": "120",
"systemCodeLength": "6",
"systemCodeOnlyNumbers": null,
"oauthAuthUrl": null
},
"version": 0,
"identifier": "email",
"type": "email",
"formIdentifier": "reg",
"userGroupIdentifier": "guest",
"isActive": true,
"isCheckCode": false
}
Response schema
Schema: IAuthProvidersEntity
id: number
ID of the auth provider.
example: 194
localizeInfos: ILocalizeInfo
Localized data of the auth provider.
example:
{
"title": "Example title"
}
config: IAuthProvidersEntityConfig
Provider configuration as key-value pairs.
example:
{
"accessTokenTtlSec": "36000",
"refreshTokenTtlMc": "604800",
"deleteNoneActiveUsersAfterDays": "2",
"systemCodeTlsSec": "120",
"systemCodeLength": "6",
"systemCodeOnlyNumbers": null,
"oauthAuthUrl": null
}
config.accessTokenTtlSec: string
Lifetime of the access token, in seconds.
example: "3600"
config.refreshTokenTtlMc: string
Lifetime of the refresh token, in seconds (despite the Mc suffix).
example: "604800"
config.deleteNoneActiveUsersAfterDays: string
Number of days after which inactive users are deleted.
example: "30"
config.systemCodeTlsSec: string
Lifetime of the one-time code, in seconds.
example: "86400"
config.systemCodeLength: string
Length of the one-time code.
example: "6"
config.oauthAuthUrl: string | null
OAuth authorization URL.
example: null
config.systemCodeOnlyNumbers: string | null
Whether the one-time code uses digits only; null when not set.
example: null
version: number
Version number of the auth provider; changes with each update.
example: 1
identifier: string
Marker of the auth provider.
example: "email"
type: string
Type of the auth provider, for example "email".
example: "email"
formIdentifier: string | null
Marker of the form linked to the auth provider, or null if there is none.
example: "reg_form"
userGroupIdentifier: string
Identifier of the user group linked to the auth provider.
example: "guest"
isActive: boolean
Whether the auth provider is active.
example: true
isCheckCode: boolean
Whether new users must be activated with a one-time code. Also enables signing in with a code instead of a password.
example: false