list_workflows
Retrieve a complete list of available workflows to streamline interactions and tasks within the Folderr platform.
Instructions
List all available workflows
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:378-404 (handler)Implements the core logic for the 'list_workflows' tool by calling the Folderr API endpoint '/api/workflows' and returning the JSON response or error message.private async handleListWorkflows() { if (!this.config.token) { throw new McpError(ErrorCode.InvalidRequest, 'Not logged in'); } try { const response = await this.axiosInstance.get('/api/workflows'); return { content: [ { type: 'text', text: JSON.stringify(response.data, null, 2), }, ], }; } catch (error: any) { return { content: [ { type: 'text', text: `Failed to list workflows: ${error.response?.data?.message || error.message}`, }, ], isError: true, }; } }
- src/index.ts:171-178 (schema)Defines the input schema for the 'list_workflows' tool, which requires no parameters.name: 'list_workflows', description: 'List all available workflows', inputSchema: { type: 'object', properties: {}, required: [], }, },
- src/index.ts:225-226 (registration)Registers the 'list_workflows' tool handler in the CallToolRequestSchema switch statement.case 'list_workflows': return await this.handleListWorkflows();
- src/index.ts:109-213 (registration)Registers the 'list_workflows' tool in the ListToolsRequestSchema handler, including its name, description, and schema.this.server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: [ { name: 'set_api_token', description: 'Set an API token for authentication (alternative to login)', inputSchema: { type: 'object', properties: { token: { type: 'string', description: 'API token generated from Folderr developers section', }, }, required: ['token'], }, }, { name: 'login', description: 'Login to Folderr with email and password', inputSchema: { type: 'object', properties: { email: { type: 'string', description: 'User email', }, password: { type: 'string', description: 'User password', }, }, required: ['email', 'password'], }, }, { name: 'list_assistants', description: 'List all available assistants', inputSchema: { type: 'object', properties: {}, required: [], }, }, { name: 'ask_assistant', description: 'Ask a question to a specific assistant', inputSchema: { type: 'object', properties: { assistant_id: { type: 'string', description: 'ID of the assistant to ask', }, question: { type: 'string', description: 'Question to ask the assistant', }, }, required: ['assistant_id', 'question'], }, }, { name: 'list_workflows', description: 'List all available workflows', inputSchema: { type: 'object', properties: {}, required: [], }, }, { name: 'get_workflow_inputs', description: 'Get the required inputs for a workflow', inputSchema: { type: 'object', properties: { workflow_id: { type: 'string', description: 'ID of the workflow', }, }, required: ['workflow_id'], }, }, { name: 'execute_workflow', description: 'Execute a workflow with the required inputs', inputSchema: { type: 'object', properties: { workflow_id: { type: 'string', description: 'ID of the workflow', }, inputs: { type: 'object', description: 'Input values required by the workflow', additionalProperties: true, }, }, required: ['workflow_id', 'inputs'], }, }, ], }));