get_project_list
Retrieve project lists from Backlog to view active, archived, or all projects based on user permissions and filtering criteria.
Instructions
Returns list of projects
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| archived | No | For unspecified parameters, this form returns all projects. For ‘false’ parameters, it returns unarchived projects. For ‘true’ parameters, it returns archived projects. | |
| all | No | Only applies to administrators. If ‘true,’ it returns all projects. If ‘false,’ it returns only projects they have joined. |
Implementation Reference
- src/tools/getProjectList.ts:28-47 (handler)Full tool definition including the handler function that executes backlog.getProjects({ archived, all }) to retrieve the project list.export const getProjectListTool = ( backlog: Backlog, { t }: TranslationHelper ): ToolDefinition< ReturnType<typeof getProjectListSchema>, (typeof ProjectSchema)['shape'] > => { return { name: 'get_project_list', description: t( 'TOOL_GET_PROJECT_LIST_DESCRIPTION', 'Returns list of projects' ), schema: z.object(getProjectListSchema(t)), outputSchema: ProjectSchema, importantFields: ['id', 'projectKey', 'name'], handler: async ({ archived, all }) => backlog.getProjects({ archived, all }), }; };
- src/tools/getProjectList.ts:7-26 (schema)Input schema definition for the get_project_list tool, defining optional 'archived' and 'all' boolean parameters.const getProjectListSchema = buildToolSchema((t) => ({ archived: z .boolean() .optional() .describe( t( 'TOOL_GET_PROJECT_LIST_ARCHIVED', 'For unspecified parameters, this form returns all projects. For ‘false’ parameters, it returns unarchived projects. For ‘true’ parameters, it returns archived projects.' ) ), all: z .boolean() .optional() .describe( t( 'TOOL_GET_PROJECT_LIST_ALL', 'Only applies to administrators. If ‘true,’ it returns all projects. If ‘false,’ it returns only projects they have joined.' ) ), }));
- src/tools/tools.ts:81-81 (registration)Registration of the get_project_list tool by instantiating getProjectListTool and adding it to the 'project' toolset.getProjectListTool(backlog, helper),