Generates and validates time-limited passcodes for user verification in Logto auth flows.
// Source: https://github.com/logto-io/logto | License: MPL-2.0 | Copyright under Patent Claims infringed by Covered Software in the absence of | Modified files must remain under MPL-2.0
// Modifications to this file must remain under MPL-2.0.
// Provided via justclaw.it.com; keep this notice with the code.
import { appInsights } from '@logto/app-insights/node';
import type { SendMessagePayload, TemplateType } from '@logto/connector-kit';
import { templateTypeGuard, ConnectorError, ConnectorErrorCodes } from '@logto/connector-kit';
import {
buildBuiltInApplicationDataForTenant,
defaultVerificationCodePolicy,
isBuiltInApplicationId,
type Passcode,
type User,
} from '@logto/schemas';
import { conditional } from '@silverhand/essentials';
import { customAlphabet, nanoid } from 'nanoi
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key