APIInterface
: { emailExistsGET
: undefined | ((input
: { email
: string; options
: APIOptions; tenantId
: string; userContext
: UserContext }) => Promise<{ exists
: boolean; status
: "OK" } | GeneralErrorResponse>); generateRecoverAccountTokenPOST
: undefined | ((input
: { email
: string; options
: APIOptions; tenantId
: string; userContext
: UserContext }) => Promise<{ status
: "OK" } | GeneralErrorResponse | GenerateRecoverAccountTokenPOSTErrorResponse>); recoverAccountPOST
: undefined | ((input
: { credential
: RegistrationPayload; options
: APIOptions; tenantId
: string; token
: string; userContext
: UserContext; webauthnGeneratedOptionsId
: string }) => Promise<{ email
: string; status
: "OK"; user
: User } | GeneralErrorResponse | RecoverAccountPOSTErrorResponse>); registerCredentialPOST
: undefined | ((input
: { credential
: RegistrationPayload; options
: APIOptions; session
: SessionContainer; tenantId
: string; userContext
: UserContext; webauthnGeneratedOptionsId
: string }) => Promise<{ status
: "OK" } | GeneralErrorResponse | RegisterCredentialPOSTErrorResponse>); registerOptionsPOST
: undefined | ((input
: { options
: APIOptions; tenantId
: string; userContext
: UserContext } & ({ displayName
?: string; email
: string } | { recoverAccountToken
: string })) => Promise<{ attestation
: "none" | "indirect" | "direct" | "enterprise"; authenticatorSelection
: { requireResidentKey
: boolean; residentKey
: ResidentKey; userVerification
: UserVerification }; challenge
: string; createdAt
: string; excludeCredentials
: { id
: string; transports
: ("ble" | "hybrid" | "internal" | "nfc" | "usb")[]; type
: "public-key" }[]; expiresAt
: string; pubKeyCredParams
: { alg
: number; type
: string }[]; rp
: { id
: string; name
: string }; status
: "OK"; timeout
: number; user
: { displayName
: string; id
: string; name
: string }; webauthnGeneratedOptionsId
: string } | GeneralErrorResponse | RegisterOptionsPOSTErrorResponse>); signInOptionsPOST
: undefined | ((input
: { options
: APIOptions; tenantId
: string; userContext
: UserContext }) => Promise<{ challenge
: string; createdAt
: string; expiresAt
: string; rpId
: string; status
: "OK"; timeout
: number; userVerification
: UserVerification; webauthnGeneratedOptionsId
: string } | GeneralErrorResponse | SignInOptionsPOSTErrorResponse>); signInPOST
: undefined | ((input
: { credential
: AuthenticationPayload; options
: APIOptions; session
: SessionContainer | undefined; shouldTryLinkingWithSessionUser
: boolean | undefined; tenantId
: string; userContext
: UserContext; webauthnGeneratedOptionsId
: string }) => Promise<{ session
: SessionContainer; status
: "OK"; user
: User } | GeneralErrorResponse | SignInPOSTErrorResponse>); signUpPOST
: undefined | ((input
: { credential
: RegistrationPayload; options
: APIOptions; session
: SessionContainer | undefined; shouldTryLinkingWithSessionUser
: boolean | undefined; tenantId
: string; userContext
: UserContext; webauthnGeneratedOptionsId
: string }) => Promise<{ session
: SessionContainer; status
: "OK"; user
: User } | GeneralErrorResponse | SignUpPOSTErrorResponse>) }
This function is meant only for creating the recipe in the core and nothing else. We added this even though signUp exists cause devs may override signup expecting it to be called just during sign up. But we also need a version of signing up which can be called during operations like creating a user during account recovery flow.