Skip to main content

execute

client.threads.execute(threadId: string, data?: ExecuteThreadRequest): Promise<Thread>

Executes a thread with optional configuration parameters.

Starts or resumes execution of the specified thread. You can provide additional execution parameters to customize the run. The thread will process its configured tasks and operations.

Parameters

ParameterTypeRequiredDescription
threadIdstringYesThe unique identifier of the thread to execute
dataExecuteThreadRequestNoOptional execution configuration parameters

Returns

Promise<Thread> — A promise that resolves to the updated Thread object

Example

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

const client = new CodeBoltClient();

const result = await client.threads.execute('threadId');
console.log(result);