v6

latestOpenAPI 3.0.0raw.githubusercontent.com2024-10-187525179.6 KB
Documents

Search all documents

This methods allows you to search your teams documents with keywords. Note that search results will be restricted to those accessible by the current access token.

post/documents.search

Request body

offsetnumber
limitnumber
querystring
userIdstring uuid

Any documents that have not been edited by the user identifier will be filtered out

collectionIdstring uuid

A collection to search within

documentIdstring uuid

A document to search within

statusFilter'draft' | 'archived' | 'published'

Any documents that are not in the specified status will be filtered out

dateFilter'day' | 'week' | 'month' | 'year'

Any documents that have not been updated within the specified period will be filtered out

Example request

{
  "limit": 25,
  "query": "hiring",
  "statusFilter": "published",
  "dateFilter": "month"
}

Response

OK

Example response

{
  "data": [
    {
      "context": "At Acme Inc our hiring practices are inclusive",
      "ranking": 1.1844109,
      "document": {
        "title": "🎉 Welcome to Acme Inc",
        "emoji": "🎉",
        "text": "…",
        "urlId": "hDYep1TPAM",
        "collaborators": [
          {
            "name": "Jane Doe"
          }
        ],
        "createdBy": {
          "name": "Jane Doe"
        },
        "updatedBy": {
          "name": "Jane Doe"
        }
      }
    }
  ],
  "pagination": {
    "limit": 25
  }
}