import { type SchemaValidationErrorItem } from '@takeshape/errors';
import type { RoleImport, RoleInput } from '../auth-schemas.ts';
import type { ProjectSchemaJSON } from '../project-schema/index.ts';
import type { ProjectSchemaImport } from '../types/types.ts';
import type { SchemaValidationResult, ValidateOptions, ValidateSyntaxOptions } from './types.ts';
export declare function validateSchemaSyntax(obj: unknown, options?: ValidateSyntaxOptions): SchemaValidationResult;
/**
 * Validates a schema using a matching validation based on the `schemaVersion` property.
 */
export declare function validateSchema(options: ValidateOptions, obj: unknown): Promise<SchemaValidationResult>;
export declare function ensureValidLatestSchemaSyntax(obj: unknown): ProjectSchemaJSON;
/**
 * Validates and returns a `RoleInput`, which is a subset of the `Role`
 * type's properties suitable for importing.
 */
export declare function validateRoleInput(maybeRoleInput: unknown): RoleInput;
/**
 * Validates and returns a `RoleImport` array, which is a collection of `RoleInput`s.
 */
export declare function ensureValidRoleImport(maybeRoles: unknown): RoleImport;
export type ProjectSchemaImportValidationResult = {
    valid: true;
    schema: ProjectSchemaImport;
    errors: undefined;
} | {
    valid: false;
    schema: undefined;
    errors: SchemaValidationErrorItem[];
};
export declare function suppressPaths(paths: string[]): (error: SchemaValidationErrorItem) => boolean;
/**
 * Only use when validating an imported schema! ignore fields optional when importing
 */
export declare function validateProjectSchemaImport(maybeSchema: unknown): ProjectSchemaImportValidationResult;
/**
 * Only use when validating an imported schema!
 *
 * New style validation for parity with the `validateRoleImport` fn. Returns
 * a valid, clean `ImportProjectSchema` or throws a `SchemaValidationError`.
 */
export declare function ensureValidProjectSchemaImport(maybeSchema: unknown): ProjectSchemaImport;
