v1

latestOpenAPI 3.0.02026-08-04184091.2 KB
knowledgebases

Retrieve a knowledgebase datasource sync history

Retrieves detailed sync history for a specified datasource.

get/api/v1/knowledgebases/{id}/datasources/{datasourceId}/histories/{syncId}

Path parameters

datasourceIdstring uuid required
Example:f256b3e4-03e0-4f74-ae46-a4d43882ee5d

The id of the datasource.

idstring uuid required
Example:f256b3e4-03e0-4f74-ae46-a4d43882ee5d

The id of the knowledgebase the datasource belongs to.

syncIdstring uuid required
Example:f256b3e4-03e0-4f74-ae46-a4d43882ee5d

The sync identifier.

Response

List of sync items ordered by the start time.

idstring uuid required

document Id

errorstring

error if one happened during sync

action'add' | 'delete' | 'update' required

acion performed

chunksinteger

number of chunks

sourcestring required

Source of the document

syncIdstring uuid required

sync Id

fileSizeinteger

file size

syncedAtstring date-time required

Datetime when the sync task was executed

chunkSizeinteger

chunk size

errorCode'unknown' | 'file_size_exceeded' | 'download_failed' | 'parse_failed' | 'parse_timeout' | 'chunk_failed' | 'chunk_timeout' | 'guardrail_blocked' | 'unsupported_file' | 'index_verification_failed' | 'file_not_found' | 'document_has_macros' | 'scan_failed' | 'pages_limit_exceeded' | 'pages_enforcement_failed' | 'governance_budget_exceeded'

Stable, machine-readable error category for an indexing failure, shared across services (worker, indexer, assistants) and the UI so failures can be mapped to friendly messages without brittle string matching.

explicitPagesinteger required

page count

fileStartedAtstring date-time

Datetime when the file processing started

fileCompletedAtstring date-time

Datetime when the file processing finished

fileLastModifiedstring date-time

Datetime when the file was last modified

Example response

{
  "id": "f256b3e4-03e0-4f74-ae46-a4d43882ee5d",
  "error": "unsupported file extension",
  "chunks": 10,
  "source": "myfile.pdf",
  "syncId": "f256b3e4-03e0-4f74-ae46-a4d43882ee5d",
  "duration": {
    "embed": 996,
    "store": 3653363805,
    "download": 207
  },
  "fileSize": 123044444,
  "syncedAt": "2021-10-02T14:20:50.52Z",
  "chunkSize": 14721,
  "errorCode": "parse_failed",
  "fileStartedAt": "2021-10-02T14:20:50.52Z",
  "fileCompletedAt": "2021-10-02T14:21:50.52Z",
  "fileLastModified": "2024-02-16T20:06:02Z"
}