Expand description
Qdrant REST JSON to QQL statement converter.
Five input shapes are accepted:
- Wrapped request —
{"method", "path", "query"?, "body"?}; the collection is derived from the path.queryrecoverswait/timeout/consistency(also accepted as a?…suffix onpath). - Bare body — raw Qdrant REST JSON without path context; the caller
must supply the collection via
convert/convert_stmts. - JSONL capture — one wrapped request or bare body per line, as
written by
qql record. A failing line reports its 1-based number viaConvertError::InvalidLine. - HTTP snippet — a
METHOD /pathline plus a JSON body, as shown in docs and blogs (full URLs and anHTTP/xsuffix are accepted). curlcommand — a pasted invocation (-X,-d,--header, …, multi-line continuations, several commands). Shell-dynamic constructs ($VAR,@file, pipes) fail closed;
Markdown fences around any of the above are stripped as paste noise.
Conversion is contract-driven and AST-based:
OpenAPI request JSON -> qql_core::ast::Stmt -> qql_core::fmt::format_stmtThe returned strings are only produced by the canonical formatter
(the same emitter behind qql fmt), so every emitted statement re-parses
and is byte-stable under format_stmt(parse(emit)). Decoding fails closed:
shapes the QQL AST cannot express return a typed ConvertError, never a
placeholder or a silently dropped field.
Enums§
- Convert
Error - Typed conversion failure.
Functions§
- convert
- Convert REST JSON into canonical QQL statement strings.
- convert_
stmts - Convert a Qdrant REST JSON payload (one object or a JSONL capture) into typed QQL statements.