Bulk index documents

Replaces the documents in a datasource using paginated batch API calls. Please refer to the bulk indexing documentation for an explanation of how to use bulk endpoints.

SecurityBearerAuth
Request
Request Body schema: application/json
required
uploadId
required
string

Unique id that must be used for this bulk upload instance

isFirstPage
boolean

true if this is the first page of the upload. Defaults to false

isLastPage
boolean

true if this is the last page of the upload. Defaults to false

forceRestartUpload
boolean

Flag to discard previous upload attempts and start from scratch. Must be specified with isFirstPage=true

datasource
required
string

Datasource of the documents

required
Array of objects (DocumentDefinition)

Batch of documents for the datasource

disableStaleDocumentDeletionCheck
boolean

True if older documents need to be force deleted after the upload completes. Defaults to older documents being deleted asynchronously. This must only be set when isLastPage = true

Responses
200

OK

400

Bad Request

401

Not Authorized

409

Conflict

post/bulkindexdocuments
Request samples
application/json
{
  • "uploadId": "string",
  • "isFirstPage": true,
  • "isLastPage": true,
  • "forceRestartUpload": true,
  • "datasource": "string",
  • "documents": [
    • {
      • "title": "string",
      • "container": "string",
      • "containerDatasourceId": "string",
      • "containerObjectType": "string",
      • "datasource": "string",
      • "objectType": "string",
      • "viewURL": "string",
      • "id": "string",
      • "summary": {
        • "mimeType": "string",
        • "textContent": "string",
        • "binaryContent": "string"
        },
      • "body": {
        • "mimeType": "string",
        • "textContent": "string",
        • "binaryContent": "string"
        },
      • "author": {
        • "email": "string",
        • "datasourceUserId": "string",
        • "name": "string"
        },
      • "owner": {
        • "email": "string",
        • "datasourceUserId": "string",
        • "name": "string"
        },
      • "permissions": {
        • "allowedUsers": [
          • {
            • "email": "string",
            • "datasourceUserId": "string",
            • "name": "string"
            }
          ],
        • "allowedGroups": [
          • "string"
          ],
        • "allowedGroupIntersections": [
          • {
            • "requiredGroups": [
              • "string"
              ]
            }
          ],
        • "allowAnonymousAccess": true,
        • "allowAllDatasourceUsersAccess": true
        },
      • "createdAt": 0,
      • "updatedAt": 0,
      • "updatedBy": {
        • "email": "string",
        • "datasourceUserId": "string",
        • "name": "string"
        },
      • "tags": [
        • "string"
        ],
      • "interactions": {
        • "numViews": 0,
        • "numLikes": 0,
        • "numComments": 0
        },
      • "status": "string",
      • "additionalUrls": [
        • "string"
        ],
      • "comments": [
        • {
          • "id": "string",
          • "author": {
            • "email": "string",
            • "datasourceUserId": "string",
            • "name": "string"
            },
          • "content": {
            • "mimeType": "string",
            • "textContent": "string",
            • "binaryContent": "string"
            },
          • "createdAt": 0,
          • "updatedAt": 0,
          • "updatedBy": {
            • "email": "string",
            • "datasourceUserId": "string",
            • "name": "string"
            }
          }
        ],
      • "customProperties": [
        • {
          • "name": "string",
          • "value": null
          }
        ]
      }
    ],
  • "disableStaleDocumentDeletionCheck": true
}