Skip to main content

@wildix/wim-knowledge-base-client > GetDataSourceSyncStatusCommand

GetDataSourceSyncStatusCommand class

Get the sync status of a data source by its ID

Signature:

export declare class GetDataSourceSyncStatusCommand extends GetDataSourceSyncStatusCommand_base 

Extends: GetDataSourceSyncStatusCommand_base

Example

Use a bare-bones client and the command you need to make an API call.

import { KnowledgeBaseClient, GetDataSourceSyncStatusCommand } from "@wildix/wim-knowledge-base-client"; // ES Modules import
// const { KnowledgeBaseClient, GetDataSourceSyncStatusCommand } = require("@wildix/wim-knowledge-base-client"); // CommonJS import
const client = new KnowledgeBaseClient(config);
const input = { // GetDataSourceSyncStatusInput
companyId: "STRING_VALUE",
dataSourceId: "STRING_VALUE", // required
};
const command = new GetDataSourceSyncStatusCommand(input);
const response = await client.send(command);
// { // GetDataSourceSyncStatusOutput
// status: "idle" || "running" || "success" || "failed", // required
// syncedAt: "STRING_VALUE",
// mode: "full" || "incremental",
// error: "STRING_VALUE",
// documentsStats: { // SyncStatusStats
// "<keys>": Number("int"),
// },
// };