Skip to content

Latest commit

 

History

History
32 lines (18 loc) · 1.15 KB

File metadata and controls

32 lines (18 loc) · 1.15 KB

elections-cpl.api.hscc.bdpa.orgDocs


elections-cpl.api.hscc.bdpa.org / lib/next-auth/token / createToken

Function: createToken()

createToken(__namedParameters): Promise<PublicAuthEntry>

Generates a new full token entry in the well-known "auth" MongoDB collection, including the provided attribute and scheme metadata. Throws on invalid entry data.

The current version of this function uses the bearer scheme to create v4 UUID "bearer tokens". This implementation detail may change at any time.

Parameters

__namedParameters

__namedParameters.data: LiteralUnknownUnion<NewAuthEntry>

Data used to generate a new "auth" entry.

Returns

Promise<PublicAuthEntry>

Source

lib/next-auth/token.ts:397