getIngestJobRunStatus
Retrieve the status of a content ingestion job to monitor progress and ensure successful data integration into the knowledge management platform.
Instructions
Checks the status of a previously submitted ingestion job.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ingestJobRunId | Yes | ||
| namespaceId | No | ||
| tenantId | No |
Implementation Reference
- src/index.ts:333-349 (handler)Registration and handler function for the 'getIngestJobRunStatus' MCP tool. Creates a SourceSync client and calls its getIngestJobRunStatus method, wrapped in safeApiCall for error handling.server.tool( 'getIngestJobRunStatus', 'Checks the status of a previously submitted ingestion job.', IngestJobRunStatusSchema.shape, async (params) => { return safeApiCall(async () => { const { namespaceId, tenantId, ingestJobRunId } = params // Create a client with the provided API key const client = createClient({ namespaceId, tenantId }) return await client.getIngestJobRunStatus({ ingestJobRunId, }) }) }, )
- src/schemas.ts:280-284 (schema)Zod input schema defining parameters for the getIngestJobRunStatus tool: optional namespaceId, required ingestJobRunId, optional tenantId.export const IngestJobRunStatusSchema = z.object({ namespaceId: namespaceIdSchema.optional(), ingestJobRunId: z.string(), tenantId: tenantIdSchema, })
- src/sourcesync.ts:453-467 (helper)SourceSyncApiClient helper method that performs the actual HTTP GET request to retrieve ingest job run status from the SourceSync API./** * Get the status of an ingest job run */ public async getIngestJobRunStatus({ ingestJobRunId, }: Omit< SourceSyncGetIngestJobRunStatusRequest, 'namespaceId' >): Promise<SourceSyncGetIngestJobRunStatusResponse> { return this.client .url(`/v1/ingest-job-runs/${ingestJobRunId}`) .query({ namespaceId: this.namespaceId }) .get() .json<SourceSyncGetIngestJobRunStatusResponse>() }
- src/sourcesync.types.ts:528-534 (schema)TypeScript type definitions for the SourceSyncGetIngestJobRunStatusRequest and Response used by the client method.export type SourceSyncGetIngestJobRunStatusRequest = { ingestJobRunId: string } export type SourceSyncGetIngestJobRunStatusResponse = SourceSyncApiResponse<SourceSyncIngestJobRun>