Skip to main content
Glama

get_hours

Retrieve timesheet hours data from Simplicate business management system to track and analyze work time records for projects and tasks.

Instructions

Retrieve timesheet hours

Input Schema

NameRequiredDescriptionDefault
limitNo
offsetNo

Input Schema (JSON Schema)

{ "properties": { "limit": { "type": "number" }, "offset": { "type": "number" } }, "type": "object" }

Implementation Reference

  • Handler logic for the 'get_hours' tool call. It invokes the SimplicateService.getHours method with optional limit and offset parameters, then returns the hours data as a JSON-formatted text response.
    case 'get_hours': { const hours = await this.simplicateService.getHours({ limit: (toolArgs.limit as number) || 10, offset: (toolArgs.offset as number) || 0, }); return { content: [ { type: 'text', text: JSON.stringify(hours, null, 2), }, ], }; }
  • Tool registration entry for 'get_hours' in the ListToolsRequestSchema handler, including name, description, and input schema definition.
    { name: 'get_hours', description: 'Retrieve timesheet hours from Simplicate', inputSchema: { type: 'object', properties: { limit: { type: 'number', description: 'Maximum number of hour entries to return (default: 10)', }, offset: { type: 'number', description: 'Number of hour entries to skip (for pagination)', }, }, }, },
  • TypeScript interface defining the structure of SimplicateHours objects returned by the getHours service method.
    export interface SimplicateHours { id: string; employee?: { id: string; name: string; }; project?: { id: string; name: string; }; hours: number; start_date: string; note?: string; }
  • Core service method that performs the HTTP GET request to the Simplicate '/hours/hours' API endpoint to retrieve hours data, applying optional pagination parameters.
    async getHours(params?: { limit?: number; offset?: number }): Promise<SimplicateHours[]> { const response = await this.client.get('/hours/hours', params); return response.data || []; }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/daanno/simplicate-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server