Skip to main content
View module source on GitHub

QueryBuilder

This class represents a query builder. Users can use this class to build a query rule for fetching prompts, agents or workflow from Maxim server.

and_

Sets the operator for combining query rules to ‘AND’. Returns:

or_

Sets the operator for combining query rules to ‘OR’. Returns:

folder

Sets the folder scope for the query. Arguments: Returns:

exact_match

Sets the exact match flag to True. Returns:

deployment_var

Adds a deployment variable rule to the query. Arguments: Returns:

tag

Adds a tag rule to the query. Arguments: Returns:

build

Builds the final query rule. Raises:
  • ValueError - If the query is empty after trimming.
Returns: