import * as v from 'valibot';
import type { EntityOwnershipConfig, UserRole } from '@donotdev/core/server';
import type { CallableFunction } from 'firebase-functions/v2/https';
export interface ListEntityRequest {
    where?: Array<[string, any, any]>;
    orderBy?: Array<[string, 'asc' | 'desc']>;
    limit?: number;
    startAfterId?: string;
    search?: {
        field: string;
        query: string;
    };
}
/**
 * Generic function to list entities from any Firestore collection
 * @param collection - The Firestore collection name
 * @param documentSchema - The Valibot schema for document validation
 * @param requiredRole - Minimum role required for this operation
 * @param customSchema - Optional custom request schema
 * @param listFields - Optional array of field names to include (plus id). If not provided, all visible fields are returned.
 * @param ownership - Optional ownership config for list constraints and visibility: 'owner' masking
 * @param isListCard - When true and ownership is set, applies public condition; when false, applies "mine" filter
 * @returns Firebase callable function
 */
export declare const listEntities: (collection: string, documentSchema: v.BaseSchema<unknown, any, v.BaseIssue<unknown>>, requiredRole: UserRole, customSchema?: v.BaseSchema<unknown, any, v.BaseIssue<unknown>>, listFields?: string[], ownership?: EntityOwnershipConfig, isListCard?: boolean) => CallableFunction<ListEntityRequest, Promise<any>>;
