@citrineos/base
Version:
The base module for OCPP v2.0.1 including all interfaces. This module is not intended to be used directly, but rather as a dependency for other modules.
33 lines (32 loc) • 838 B
TypeScript
import type { UserInfo } from './UserInfo.js';
/**
* Result of authentication process
*/
export declare class ApiAuthenticationResult {
/**
* Whether authentication was successful
*/
isAuthenticated: boolean;
/**
* User information if authentication was successful
*/
user?: UserInfo;
/**
* Error message if authentication failed
*/
error?: string;
/**
* Creates a new successful authentication result
*
* @param user Authenticated user information
* @returns Authentication result
*/
static success(user: UserInfo): ApiAuthenticationResult;
/**
* Creates a new failed authentication result
*
* @param error Error message
* @returns Authentication result
*/
static failure(error: string): ApiAuthenticationResult;
}