import { FetchByFilterParams, FetchElementParams, FetchNavigationParams, FetchProjectPropertiesParams } from '../types'; export type ParamValidationResult = ParamValidationSuccess | ParamValidationError; export type ParamValidationSuccess = { valid: true; }; /** * All Existing Reasons to reject param Validation */ export type ParamValidationErrorReason = 'MISSING_PARAM_OBJECT' | 'MISSING_LOCALE' | 'MISSING_ID' | 'MISSING_FILTERS'; export type ParamValidationError = Readonly<{ valid: false; reason: T; statusCode: 400; }>; /** * Creates the correct ValidationError for the given reason. * @param reason * @returns */ export declare const createValidationError: (reason: T) => ParamValidationError; /** * Checks for required Parameters * @param params * @returns result object indicating validity, and a reason if not valid. */ export declare const validateParamsFetchElement: (params: Partial | null | undefined) => ParamValidationResult<"MISSING_ID" | "MISSING_LOCALE" | "MISSING_PARAM_OBJECT">; /** * Checks for required Parameters * @param params * @returns result object indicating validity, and a reason if not valid. */ export declare const validateParamsFetchNavigation: (params: Partial | null | undefined) => ParamValidationResult<"MISSING_LOCALE" | "MISSING_PARAM_OBJECT">; /** * Checks for required Parameters * @param params * @returns result object indicating validity, and a reason if not valid. */ export declare const validateParamsFetchByFilter: (params: Partial | null | undefined) => ParamValidationResult<"MISSING_PARAM_OBJECT" | "MISSING_FILTERS">; /** * Checks for required Parameters * @param params * @returns result object indicating validity, and a reason if not valid. */ export declare const validateParamsFetchProjectProperties: (params: Partial | null | undefined) => ParamValidationResult<"MISSING_LOCALE" | "MISSING_PARAM_OBJECT">;