Skip to main content
POST
cURL

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

libraryId
string
required

The ID of the library

Query Parameters

classId
string

The ID of the document class

searchQuery
string

The text searched to filter documents

publishState
enum<string>

The type of documents to find: 'DRAFT_ONLY' to get draft versions only (if access to it), 'PUBLISHED' to get main versions only (if access to it), 'ALL' for both (the draft version if access to it else the main version). The last mode is the default one.

Available options:
PUBLISHED,
DRAFT_ONLY,
ALL
offset
string

The offset from which we should get the documents. (Default: 0, i.e. from the first one)

limit
integer<int32>
default:20

The maximum number of documents per page. (Default: 20)

searchInAttachments
boolean
default:true

Whether to search the text in the attachments too (true by default)

populateFieldOption
enum<string>[]

Optional, repeatable. Controls how much of each document is populated. When omitted, documents are fully populated. Legacy bundle flags (preserved with historic semantics): 'SKIP_ATTACHMENTS_PERMISSIONS' drops Drive ACL calls on attachments while keeping metadata; 'SKIP_DOCUMENT_PERMISSIONS' skips the permission-graph build while keeping the rest of the heavyweight block; 'SKIP_HEAVYWEIGHT_FIELDS' drops the whole heavyweight block. Granular flags (one populate step each; prefer these in new callers): 'SKIP_META_FIELDS' omits fields, categories, referenceCatalogs, tableFields; 'SKIP_FOLDERS' omits folders; 'SKIP_ATTACHMENTS' omits attachments, iconLink, fullSizeOfAttachments, numberOfAttachments (broader than SKIP_ATTACHMENTS_PERMISSIONS, making it a no-op); 'SKIP_USER_MAPPING' omits userMapping; 'SKIP_SIMILAR_DOCUMENTS' omits similarDocuments; 'SKIP_VERSION_FIELDS' omits all version fields, nextVersionName, and restrictedDownload; 'SKIP_WORKFLOW_DETAILS' omits stateChangeDate, stateChangeAuthors, stateId, workflowId (keeps state and state_i18n); 'SKIP_DRAFT_INFO' omits checkOutBy, checkoutDate; 'SKIP_EXTERNAL_SOURCE' omits externalSource; 'SKIP_DELETION_DETAILS' omits deletedReason, deleteAuthor, deletionDate (keeps deleted); 'SKIP_TEMPLATE_INFO' omits templateDocumentId; 'SKIP_SECTIONS' omits sections; 'SKIP_PUBLISHED_INFO' omits publishedMode, publishedLink; 'SKIP_CALCULATED_FIELD_ERRORS' omits calculatedValueInfo on each field entry; 'SKIP_VIEW_CONFIGURATION' omits viewConfiguration. Composition: a populate step is skipped iff any relevant flag is set. 'SKIP_HEAVYWEIGHT_FIELDS' transitively covers SKIP_DOCUMENT_PERMISSIONS, SKIP_VERSION_FIELDS, SKIP_SECTIONS, SKIP_PUBLISHED_INFO, SKIP_USER_MAPPING, and SKIP_VIEW_CONFIGURATION.

Available options:
SKIP_ATTACHMENTS_PERMISSIONS,
SKIP_DOCUMENT_PERMISSIONS,
SKIP_HEAVYWEIGHT_FIELDS,
SKIP_META_FIELDS,
SKIP_FOLDERS,
SKIP_ATTACHMENTS,
SKIP_USER_MAPPING,
SKIP_SIMILAR_DOCUMENTS,
SKIP_VERSION_FIELDS,
SKIP_WORKFLOW_DETAILS,
SKIP_DRAFT_INFO,
SKIP_EXTERNAL_SOURCE,
SKIP_DELETION_DETAILS,
SKIP_TEMPLATE_INFO,
SKIP_SECTIONS,
SKIP_PUBLISHED_INFO,
SKIP_CALCULATED_FIELD_ERRORS,
SKIP_VIEW_CONFIGURATION
securityCode
string

The security code

domain
string

The G Suite domain

timezone
string

The timezone to use for datetime field searches (default: UTC). Format: 'Europe/Paris' or '+01:00'

Body

application/json
disableSorting
boolean

Enforce the fact that results won't be sorted because by default results are sorted by last modification date

filter
object
sort
object[]

Order the results of the search

Response

200 - application/json

A ApiSearchResult response

count
integer<int32>
documents
object[]
kind
string
nextPageToken
string
precision
enum<string>
Available options:
ACCURATE,
ESTIMATED_RESULT_NUMBER,
INCOMPLETE_RESULT