import type { SelectOptions } from './types'; export default class QuerySerializer { static serialize(query: SelectOptions, collectionName: string): Record; private static formatSort; /** * Serialize filters to JSON with snake_case operators and aggregators. * * Internally, operators use PascalCase (e.g. `Equal`, `GreaterThan`) to match * the datasource-toolkit convention. However, HTTP backends expect snake_case: * - Ruby (forest_liana): requires `equal`, `greater_than`, etc. * - Node (@forestadmin/agent): accepts snake_case via ConditionTreeParser.toPascalCase() * * Converting to snake_case here ensures compatibility with both backends. */ private static formatFilters; /** * Recursively walk the condition tree and convert operators/aggregators to snake_case. */ private static toSnakeCaseOperators; /** * Convert PascalCase to snake_case. * Two passes handle different patterns: * - Pass 1: lowercase→uppercase boundaries (e.g. `greaterThan` → `greater_Than`) * - Pass 2: uppercase sequences (e.g. `IContains` → `I_Contains`, `PreviousXDays` → `PreviousX_Days`) */ private static toSnakeCase; private static formatFields; } //# sourceMappingURL=query-serializer.d.ts.map