Skip to main content

Interface: OAuthHandlers

Defined in: auth-core/src/oauthServerTypes.ts:497

The runner-agnostic OAuth server handlers returned by createOAuthHandlers.

Properties​

authorizationServerMetadata​

authorizationServerMetadata: () => OAuthResponse

Defined in: auth-core/src/oauthServerTypes.ts:501

RFC 8414 Authorization Server Metadata response.

Returns​

OAuthResponse


authorize​

authorize: (request) => Promise<OAuthResponse>

Defined in: auth-core/src/oauthServerTypes.ts:507

Handle a GET /authorize request.

Parameters​

ParameterType
requestOAuthRequest

Returns​

Promise<OAuthResponse>


jwks​

jwks: () => OAuthResponse | undefined

Defined in: auth-core/src/oauthServerTypes.ts:505

The JWKS document (RFC 7517), or undefined when signing is unset.

Returns​

OAuthResponse | undefined


paths​

paths: object

Defined in: auth-core/src/oauthServerTypes.ts:499

Resolved endpoint paths, for an adapter to mount routes on.

authorize​

authorize: string

jwks​

jwks: string

register​

register: string

token​

token: string


protectedResourceMetadata​

protectedResourceMetadata: () => OAuthResponse | undefined

Defined in: auth-core/src/oauthServerTypes.ts:503

RFC 9728 Protected Resource Metadata response, or undefined if resource is unset.

Returns​

OAuthResponse | undefined


register​

register: (request) => Promise<OAuthResponse>

Defined in: auth-core/src/oauthServerTypes.ts:511

Handle a POST /register request (Dynamic Client Registration, RFC 7591).

Parameters​

ParameterType
requestOAuthRequest

Returns​

Promise<OAuthResponse>


token​

token: (request) => Promise<OAuthResponse>

Defined in: auth-core/src/oauthServerTypes.ts:509

Handle a POST /token request (authorization_code + refresh_token grants).

Parameters​

ParameterType
requestOAuthRequest

Returns​

Promise<OAuthResponse>