Home > @i2analyze/i2connect > authenticationToken
authenticationToken() function
The @authenticationToken
decorator, which configures a service method parameter to receive the value of the token associated with an authenticator.
Signature:
export declare function authenticationToken(authConfigId?: string): ParameterDecorator;
Introduced: API version 1.0
Parameters
Parameter | Type | Description |
---|---|---|
authConfigId | string | The identifier of the authenticator that the token is associated with, which can be omitted if the connector has only one authenticator. |
Returns:
ParameterDecorator
Example
async findIPAddresses(
@authenticationToken('usernameAndPasswordConfigId') token: string,
...)