providers/mattermost
Functionsβ
default()β
Signatureβ
default<P>(config: Omit<Partial<OAuthConfig<P>>, "type" | "options"> & Required<Pick<OAuthConfig<P>, "clientId" | "clientSecret">> & { issuer: string }): OAuthConfig<P>
To create your Mattermost OAuth2 app visit http://<your Mattermost instance url>
/<your team>
/integrations/oauth2-apps
Exampleβ
import Mattermost from "@auth/core/providers/mattermost";
...
providers: [
Mattermost({
clientId: env.MATTERMOST_ID,
clientSecret: env.MATTERMOST_SECRET,
// The base url of your Mattermost instance. e.g https://my-cool-server.cloud.mattermost.com
issuer: env.MATTERMOST_ISSUER,
})
]
...
danger
The Mattermost provider requires the issuer
option to be set. This is the base url of your Mattermost instance. e.g https://my-cool-server.cloud.mattermost.com
Type parametersβ
P
extends MattermostProfile
Parametersβ
Name | Type |
---|---|
config | Omit <Partial <OAuthConfig <P >>, "type" | "options" > & Required <Pick <OAuthConfig <P >, "clientId" | "clientSecret" >> & { issuer : string } |
Returnsβ
OAuthConfig
<P
>
Interfacesβ
MattermostProfileβ
Seeβ
Propertiesβ
create_atβ
create_at: number
The time in milliseconds a user was created
delete_atβ
delete_at: number
The time in milliseconds a user was deleted
update_atβ
update_at: number
The time in milliseconds a user was last updated
terms_of_service_create_atβ
terms_of_service_create_at?: number
The time in milliseconds the user accepted the terms of service
terms_of_service_idβ
terms_of_service_id?: string
ID of accepted terms of service, if any. This field is not present if empty.