Skip to content

Query Language Formats

FlexQuery.NET is format-agnostic, allowing clients to send queries in the format that best suits their environment.

DSL (Compact String)

The Domain Specific Language is the primary and most compact format. It uses : as a separator.

  • Simple: ?filter=name:contains:john
  • Logic: Use & for AND, | for OR, and () for grouping.
  • Example: ?filter=((city:eq:London|city:eq:Berlin)&(age:gt:25))

JSON (Structured Object)

Ideal for complex, programmatically generated filters or frontends using structured query builders.

Query: ?filter={...}

json
{
  "logic": "and",
  "filters": [
    { "field": "Status", "operator": "eq", "value": "Active" },
    {
      "logic": "or",
      "filters": [
        { "field": "Category", "operator": "eq", "value": "Software" },
        { "field": "Category", "operator": "eq", "value": "Hardware" }
      ]
    }
  ]
}

Indexed (Generic / Compatibility)

A flat, index-based format compatible with standard HTML form serialization and older grid libraries.

http
?filter[0].field=Name
&filter[0].operator=contains
&filter[0].value=john
&filter[1].field=Age
&filter[1].operator=gt
&filter[1].value=20
&logic=and

JQL (SQL-like Syntax)

The Jira Query Language allows for human-readable, SQL-like expressions. It is the most powerful format, supporting scoped filtering.

Query: ?query=(name contains "john" OR age > 30) AND orders.any(total > 100)

JQL Features:

  • Standard operators: =, !=, >, >=, <, <=
  • String operators: CONTAINS, LIKE, STARTSWITH, ENDSWITH
  • Range/List: IN (...), BETWEEN ... AND ...
  • Null checks: IS NULL, IS NOT NULL
  • Collection predicates: ANY, ALL, COUNT

Released under the MIT License.