A parser for the Fauna Query Language (FQL).

Usage no npm install needed!

<script type="module">
  import faunaLabsFqlParser from 'https://cdn.skypack.dev/@fauna-labs/fql-parser';


This repository contains unofficial patterns, sample code, or tools to help developers build more effectively with Fauna. All Fauna Labs repositories are provided “as-is” and without support. By using this repository or its contents, you agree that this repository may never be officially supported and moved to the Fauna organization.

FQL parser

This is a Rust crate and NPM package that parses raw FQL queries into the wire protocol format.



To use the parser, add the following to your Cargo.toml:

fql-parser = "0.1.6"

Then, in your code, import the crate and parse your query:

extern crate fql_parser;

fn main() {
    let query = "Add(2, 2)";
    let result = fql_parser::serialize_fql_query(query);

    println!("{}", result);



Building and publishing the crate


cargo build
# Publish to https://crates.io/crates/fql-parser
cargo publish


wasm-pack build --scope fauna-labs
wasm-pack publish --access=public