import type { SQLQueryBindings } from "bun:sqlite";
import type { App } from "../core/app.js";
import type { RequestEvent, RequestInfo } from "../core/event_request.js";
import type { RouterGroup } from "../tools/router/group.js";
import { Collection } from "../core/collection_model.js";
import { RecordRequestEvent } from "../core/events.js";
import { Record as RecordModel, type RecordData } from "../core/record_model.js";
import { type File as LocalFile } from "../tools/filesystem/file.js";
export declare function bindRecordCrudApi(app: App, rg: RouterGroup<RequestEvent>): void;
export declare function recordCreate(app: App, event: RequestEvent, createHook?: import("../tools/hook/tagged.js").TaggedHook<RecordRequestEvent>): Promise<Response>;
export declare function recordUpdate(app: App, event: RequestEvent, updateHook?: import("../tools/hook/tagged.js").TaggedHook<RecordRequestEvent>): Promise<Response>;
export declare function recordDelete(app: App, event: RequestEvent, deleteHook?: import("../tools/hook/tagged.js").TaggedHook<RecordRequestEvent>): Promise<Response>;
export declare function resolveRecordData(record: RecordModel, requestInfo: RequestInfo, uploadedFiles: Map<string, LocalFile[]>): RecordData;
export type CreateRuleContext = {
    collection: Collection;
    selectSql: string;
    params: SQLQueryBindings[];
};
export declare function buildCreateRuleContext(collection: Collection, record: RecordModel): CreateRuleContext | Error;
export declare function checkCreateRule(app: App, context: CreateRuleContext, requestInfo: RequestInfo): Error | null;
