harvest_list_users
Retrieve and filter all users in your Harvest account to manage team access and permissions. Supports pagination and active status filtering for efficient user administration.
Instructions
List all users in the account with filtering. Use about {"tool": "harvest_list_users"} for detailed parameters and examples.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| is_active | No | Filter by active status | |
| page | No | Page number | |
| per_page | No | Results per page (max 100) |
Implementation Reference
- src/index.ts:222-231 (handler)MCP tool handler that dispatches the harvest_list_users call to HarvestClient.getUsers with input arguments and formats the response as MCP content.case 'harvest_list_users': const users = await harvestClient.getUsers(typedArgs); return { content: [ { type: 'text', text: JSON.stringify(users, null, 2), }, ], };
- src/tools.ts:152-163 (schema)Defines the tool metadata, name, description, and input schema (parameters: is_active, page, per_page) for harvest_list_users.{ name: 'harvest_list_users', description: 'List all users in the account with filtering. Use about {"tool": "harvest_list_users"} for detailed parameters and examples.', inputSchema: { type: 'object', properties: { is_active: { type: 'boolean', description: 'Filter by active status' }, page: { type: 'number', description: 'Page number' }, per_page: { type: 'number', description: 'Results per page (max 100)' } } } },
- src/harvest-client.ts:137-140 (helper)HarvestClient helper method that constructs the API request to Harvest's /users endpoint with optional query parameters and executes it via makeRequest.async getUsers(options?: any) { const queryString = this.buildQueryString(options); return this.makeRequest(`/users${queryString}`); }
- src/harvest-client.ts:676-718 (helper)Detailed documentation string for harvest_list_users tool, providing usage examples, parameters, and response format, used by the 'about' tool.'harvest_list_users': `# harvest_list_users Lists all users in your Harvest account. ## Purpose Retrieve information about all users for reporting, filtering, and user management. ## Parameters - \`is_active\` (boolean, optional): Filter by active/inactive status - \`page\` (number, optional): Page number for pagination - \`per_page\` (number, optional): Results per page, max 100 ## Example Usage **List all active users:** \`\`\`json { "tool": "harvest_list_users", "is_active": true } \`\`\` **List all users with pagination:** \`\`\`json { "tool": "harvest_list_users", "page": 1, "per_page": 25 } \`\`\` ## Response Format Returns an object with: - \`users\`: Array of user objects - Pagination information Each user includes same fields as harvest_get_current_user. ## Usage Tips - Use for filtering time entries by user_id - Useful for team management and reporting - Check user roles and permissions`,
- src/index.ts:69-73 (registration)Registers all tools including harvest_list_users for the MCP ListToolsRequest by returning the tools array from tools.ts.server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools: tools, }; });