providers/email
EmailConfig
Shared across all ProviderType
Extends
Extended by
Properties
apiKey?
optional apiKey: string;Used with HTTP-based email providers.
from?
optional from: string;generateVerificationToken()?
optional generateVerificationToken: () => Awaitable<string>;Returns
Awaitable<string>
id
id: string;Uniquely identifies the provider in AuthConfig.providers It’s also part of the URL
Overrides
maxAge?
optional maxAge: number;name
name: string;The provider name used on the default sign-in page’s sign-in button. For example if it’s “Google”, the corresponding button will say: “Sign in with Google”
Overrides
normalizeIdentifier()?
optional normalizeIdentifier: (identifier) => string;Parameters
| Parameter | Type |
|---|---|
identifier | string |
Returns
string
options?
optional options: EmailUserConfig;secret?
optional secret: string;Used to hash the verification token.
sendVerificationRequest()
sendVerificationRequest: (params) => Awaitable<void>;Parameters
| Parameter | Type |
|---|---|
params | EmailProviderSendVerificationRequestParams |
Returns
Awaitable<void>
server?
optional server: AllTransportOptions;Used with SMTP-based email providers.
type
type: "email";See ProviderType
Overrides
EmailProviderSendVerificationRequestParams
type EmailProviderSendVerificationRequestParams = {
expires: Date;
identifier: string;
provider: EmailConfig;
request: Request;
theme: Theme;
token: string;
url: string;
};Type declaration
expires
expires: Date;identifier
identifier: string;provider
provider: EmailConfig;request
request: Request;theme
theme: Theme;token
token: string;url
url: string;EmailProviderType
type EmailProviderType = "email";EmailUserConfig
type EmailUserConfig = Omit<Partial<EmailConfig>, "options" | "type">;default()
function default(config): NodemailerConfigParameters
| Parameter | Type |
|---|---|
config | NodemailerUserConfig |
Returns
Deprecated
Import this provider from the providers/nodemailer submodule instead of providers/email.
To log in with nodemailer, change signIn("email") to signIn("nodemailer")
EmailProviderId
Re-exports EmailProviderId