Skip to main content

listSpawnRequests

client.swarm.listSpawnRequests(swarmId: string, params?: Record<string, unknown>): Promise<SpawnRequest[]>

List spawn requests for a swarm.

Retrieves all spawn requests associated with a swarm, including pending, approved, and completed requests. Use this to track spawn request status and history.

Parameters

ParameterTypeRequiredDescription
swarmIdstringYesThe unique identifier of the swarm
paramsRecord<string, unknown>NoOptional query parameters for filtering requests

Returns

Promise<SpawnRequest[]> — A promise that resolves to an array of SpawnRequest objects

Example

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

const client = new CodeBoltClient();

const result = await client.swarm.listSpawnRequests('swarmId');
console.log(result);