v68

latestOpenAPI 3.0.0raw.githubusercontent.com2026-08-0170379386.9 KB
Documents

Read documents by facets

Read the documents including metadata (does not include enhanced metadata via /documentmetadata) macthing the given facet conditions.

post/rest/api/v1/getdocumentsbyfacets

Query parameters

localestring

The client's preferred locale in rfc5646 format (e.g. en, ja, pt-BR). If omitted, the Accept-Language will be used. If not present or not supported, defaults to the closest match or en.

Headers

X-Glean-ActAsstring email

Email address of a user on whose behalf the request is intended to be made (should be non-empty only for global tokens).

X-Glean-Auth-Typestring

Auth type being used to access the endpoint (should be non-empty only for global tokens).

Request body

datasourcesFilterstring[]

Filter results to one or more datasources (e.g. gmail, slack). All results are returned if missing.

cursorstring

Pagination cursor. A previously received opaque token representing the position in the overall results at which to start.

Example request

{
  "filterSets": [
    {
      "filters": [
        {
          "fieldName": "type",
          "values": [
            {
              "value": "Spreadsheet",
              "relationType": "EQUALS"
            },
            {
              "value": "Presentation",
              "relationType": "EQUALS"
            }
          ]
        }
      ]
    }
  ]
}

Response

OK

hasMoreResultsboolean

Whether more results are available. Use cursor to retrieve them.

cursorstring

Cursor that indicates the start of the next page of results. To be passed in "more" requests for this query.