Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/oauth2_server/examples/oak-localstorage/services/authorization_code.ts>AuthorizationCodeService

A standards compliant implementation of an OAuth 2.0 authorization server with PKCE support.
Latest
class AuthorizationCodeService
import { AuthorizationCodeService } from "https://deno.land/x/oauth2_server@0.12.0/examples/oak-localstorage/services/authorization_code.ts";

Constructors

new
AuthorizationCodeService(clientService: ClientService, userService: UserService)

Properties

private
clientService: ClientService
private
userService: UserService

Methods

private
getInternal(code: string): Promise<AuthorizationCodeInternal | undefined>
private
toExternal(internal: AuthorizationCodeInternal): Promise<AuthorizationCode<Client, User, Scope> | undefined>
delete(authorizationCode: AuthorizationCode<Client, User, Scope> | string): Promise<boolean>
get(code: string): Promise<AuthorizationCode<Client, User, Scope> | undefined>
patch(authorizationCode: Partial<AuthorizationCode<Client, User, Scope>> & Pick<AuthorizationCode<Client, User, Scope>, "code">): Promise<void>
put(authorizationCode: AuthorizationCode<Client, User, Scope>): Promise<void>
revoke(authorizationCode: AuthorizationCode<Client, User, Scope> | string): Promise<boolean>