swit-project-list
Retrieve a list of projects from Swit workspaces using workspace ID, filters, and pagination parameters for efficient project management and organization.
Instructions
Retrieve list of projects
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| activity | No | ||
| disclosure | No | ||
| limit | No | ||
| name | No | ||
| offset | No | ||
| workspace_id | Yes |
Implementation Reference
- src/handlers/core.handlers.ts:36-39 (handler)The handler function that implements the core logic for the 'swit-project-list' tool. It validates the input arguments using ProjectListArgsSchema and delegates to SwitClient.listProjects.export const handleProjectList = async (switClient: SwitClient, args: any) => { const validatedArgs = ProjectListArgsSchema.parse(args); return await switClient.listProjects(validatedArgs); };
- src/schemas.ts:132-139 (schema)Zod schema defining the input parameters for the project list tool, including workspace_id and optional pagination/filter fields.export const ProjectListArgsSchema = z.object({ workspace_id: z.string(), offset: z.string().optional(), limit: z.number().min(1).max(100).optional(), activity: z.string().optional(), disclosure: z.string().optional(), name: z.string().optional(), });
- src/tools/core.tools.ts:37-41 (registration)Tool specification registration including name, description, and input schema for MCP tool 'swit-project-list'.{ name: 'swit-project-list', description: 'Retrieve list of projects', inputSchema: zodToJsonSchema(ProjectListArgsSchema), },
- src/handlers/core.handlers.ts:47-47 (registration)Registration of the handleProjectList function for the 'swit-project-list' tool in the coreHandlers object.'swit-project-list': (args: any) => handleProjectList(switClient, args),