Home Reference Source Test
import AuthContext from 'token-io/src/http/AuthContext.js'
public class | source

AuthContext

Handles the auth context when using access tokens.

Constructor Summary

Public Constructor
public

Creates an AuthContext object

Member Summary

Public Members
public set

Sets the auth context to indicate that the next api call would have been initiated by the customer.

public get

Gets the customer initiated request flag.

public set

keyLevel(keyLevel: string): *

Sets the key level to be used to sign the auth header

public get

Gets the key level

public set

onBehalfOf(onBehalfOf: string): *

Sets the auth context to act on behalf of another member

public get

Gets the currently active memberId

Private Members
private
private
private

Public Constructors

public constructor() source

Creates an AuthContext object

Public Members

public set customerInitiated(flag: boolean): * source

Sets the auth context to indicate that the next api call would have been initiated by the customer.

public get customerInitiated: boolean: * source

Gets the customer initiated request flag.

Return:

boolean

true if request initiated by customer

public set keyLevel(keyLevel: string): * source

Sets the key level to be used to sign the auth header

public get keyLevel: string: * source

Gets the key level

Return:

string

key level being used

public set onBehalfOf(onBehalfOf: string): * source

Sets the auth context to act on behalf of another member

public get onBehalfOf: string: * source

Gets the currently active memberId

Return:

string

accessTokenId being used

Private Members

private _customerInitiated: boolean source

private _keyLevel: * source

private _onBehalfOf: * source