import { LoggingClient } from './logging'; import { RequestContext, RequestContextType } from './types'; export interface ClientConfiguration { engineEndpoint: string; engineToken: string; logging?: { client?: LoggingClient; logResults?: boolean; }; fallbackConfiguration?: FallbackConfiguration; } export type Milliseconds = number; export type FallbackConfiguration = StaticFallbackConfiguration | FunctionFallbackConfiguration; export type StaticFallbackConfiguration = { defaultFallback: boolean; [RequestContextType.Feature]?: Record; [RequestContextType.Permission]?: Record; [RequestContextType.Route]?: Record; [RequestContextType.Entity]?: Record; }; export type FunctionFallbackConfiguration = (requestContext: RequestContext) => Promise | boolean;