---
title: "CQL REST API"
canonical: "https://support.appfire.com/space/CDML/649921636/CQL%20REST%20API"
format: markdown
---
> Macro (aura-html)


## Overview

> Macro (excerpt)
> 
> Comala Document Management extensions for CQL

The Comala Document Management app provides several new CQL fields that can be used to filter search results using Confluence Search REST API.

> 📝 Confluence CQL-enabled search requires Confluence 5.9 or above

You can also use Confluence [CQL filters in Comala Document Management reporting macros](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649824034) (Comala Document Management [v6.16.6+](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649790243))

## CQL Fields

> Macro (include)

## CQL Field Search Example

To search for content where the current state is "Draft" (`state=Draft`), the REST API URL would look like:

```python
http://<confluence_url>/rest/api/content/search?cql=state=Draft
```

## Content Properties

Comala Document Management uses JSON Content Properties to store and keep track of workflows data and support the new reporting utilities (for version 6.0 and later).

Workflow information is available as an [API expansion point](https://developer.atlassian.com/server/confluence/expansions-in-the-rest-api/) using `metadata.properties.comalaworkflows`

Not all values provided in the current implementation may be supported in future updates but the following core values are unlikely to change.

| Name |
| --- |
| `workflowName` |
| `currentState` |
| `currentStateColour` |
| `currentStateStart` |

## See also

**[Reporting Guide](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649070833)**

- [Confluence Search](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649792098)
- [Content by Label macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649956370)
- [Page Properties Report macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/650250574)
- [CQL filters in Document States report macro](https://appfire.atlassian.net/wiki/spaces/CDML/pages/649824034)

**External Links**

- [Content Properties in the REST API](https://developer.atlassian.com/server/confluence/content-properties-in-the-rest-api/)
- [Advanced Searching Using CQL](https://developer.atlassian.com/server/confluence/advanced-searching-using-cql/)
- [CQL Field Reference](https://developer.atlassian.com/server/confluence/cql-field-reference/)
- [CQL Function Reference](https://developer.atlassian.com/server/confluence/cql-function-reference/)
- [CQL Keywords Reference](https://developer.atlassian.com/server/confluence/cql-keywords-reference/)
- [CQL Operators Reference](https://developer.atlassian.com/server/confluence/cql-operators-reference/)
- [Performing Text Searches with CQL](https://developer.atlassian.com/server/confluence/performing-text-searches-using-cql/)