Skip to main content

completeThreadStep

client.chat.completeThreadStep(threadId: string, stepId: string, data?: CompleteStepData): Promise<ChatThreadStep>

Completes a step in a chat thread.

Marks the specified step as completed, optionally recording completion details such as the outcome or output.

Parameters​

ParameterTypeRequiredDescription
threadIdstringYesThe unique identifier of the thread
stepIdstringYesThe unique identifier of the step to complete
dataCompleteStepDataNoOptional completion details

Returns​

Promise<ChatThreadStep> — A promise that resolves to the completed ChatThreadStep

Example​

import { CodeBoltClient } from '@codebolt/clientsdk';

const client = new CodeBoltClient();

const result = await client.chat.completeThreadStep('threadId', 'stepId');
console.log(result);