Skip to content

PERS SDK - v2.3.26 / Exports / PersAuthProvider

Interface: PersAuthProvider

Core authentication provider interface

Hierarchy

Implemented by

Table of contents

Methods

Properties

Methods

getToken

getToken(): Promise<null | string>

Get current access token

Returns

Promise<null | string>

Defined in

core/auth/auth-provider.interface.ts:17


getProjectKey

getProjectKey(): Promise<null | string>

Get project key for API requests

Returns

Promise<null | string>

Defined in

core/auth/auth-provider.interface.ts:20


onAuthStatusChange

onAuthStatusChange(status): Promise<void>

Handle authentication status changes

Parameters

NameType
statusAuthStatus

Returns

Promise<void>

Defined in

core/auth/auth-provider.interface.ts:23


getAuthHeaders

getAuthHeaders(token, method?, url?): Promise<Record<string, string>>

Get derived authentication headers (e.g. DPoP)

Parameters

NameTypeDescription
tokennull | stringThe current access token
method?stringHTTP Method
url?stringRequest URL

Returns

Promise<Record<string, string>>

Defined in

core/auth/auth-provider.interface.ts:31

Properties

authType

Readonly authType: AccountOwnerType

Authentication type

Defined in

core/auth/auth-provider.interface.ts:14