npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

tmetric-mcp

v1.0.2

Published

MCP server for TMetric time tracking API

Readme

TMetric MCP Server

An MCP server for the TMetric time-tracking API. Lets Claude Desktop (or any MCP client) read and manage your TMetric time entries, tasks, projects, and reports via natural language.

Requirements

  • Node.js 22 or later
  • A TMetric account with an API token

Installation

Via npx

npx tmetric-mcp

Global install

pnpm add -g tmetric-mcp

From source

# 1. Install dependencies
pnpm install

# 2. Build
pnpm build

API Token

  1. Log in to app.tmetric.com
  2. Click your name (bottom-left) → My ProfileGeneral SettingsGet new API token
  3. Copy the token — you will set it as TMETRIC_API_TOKEN

MCP client configuration

Claude Desktop

Add this block to your claude_desktop_config.json (usually at ~/Library/Application Support/Claude/claude_desktop_config.json on macOS):

Using npx:

{
  "mcpServers": {
    "tmetric": {
      "command": "npx",
      "args": ["tmetric-mcp"],
      "env": {
        "TMETRIC_API_TOKEN": "YOUR_TOKEN_HERE"
      }
    }
  }
}

From source (recommended):

{
  "mcpServers": {
    "tmetric": {
      "command": "node",
      "args": ["/absolute/path/to/tmetric-mcp/dist/index.js"],
      "env": {
        "TMETRIC_API_TOKEN": "YOUR_TOKEN_HERE"
      }
    }
  }
}

Cursor

Add this block to ~/.cursor/mcp.json:

Using npx:

{
  "mcpServers": {
    "tmetric": {
      "command": "npx",
      "args": ["tmetric-mcp"],
      "env": {
        "TMETRIC_API_TOKEN": "YOUR_TOKEN_HERE"
      }
    }
  }
}

From source (recommended):

{
  "mcpServers": {
    "tmetric": {
      "command": "node",
      "args": ["/absolute/path/to/tmetric-mcp/dist/index.js"],
      "env": {
        "TMETRIC_API_TOKEN": "YOUR_TOKEN_HERE"
      }
    }
  }
}

Development

# Run without building (uses tsx)
TMETRIC_API_TOKEN=your_token pnpm dev

Tool reference

Timer tools are wrappers over time-entry endpoints — TMetric has no dedicated /timer endpoint. A running timer is a time entry whose endTime is null.

Accounts (accounts.ts)

| Tool | Description | |------|-------------| | tmetric_get_accounts | List all TMetric workspaces available to the current user. Returns account IDs needed for other tools. |

Users (users.ts)

| Tool | Description | |------|-------------| | tmetric_get_current_user | Get authenticated user's profile including account memberships and activeAccountId. | | tmetric_list_managed_teams | List teams managed by the current user in the given workspace. |

Time Entries (timeEntries.ts)

| Tool | Description | |------|-------------| | tmetric_get_time_entries | Get time entries for a date range (YYYY-MM-DD). userId=0 = current user. | | tmetric_create_time_entry | Create a new time entry. Destructive — overlapping entries are overwritten. Body uses nested objects: project:{id}, task:{id}, tags:[{id}], field is note. | | tmetric_update_time_entry | Fully update a time entry by ID. Set endTime to stop a running timer. | | tmetric_delete_time_entry | Delete a time entry by ID. | | tmetric_get_latest_time_entry | Get the most recent time entry. endTime=null means a timer is running. | | tmetric_get_recent_time_entries | Get a list of recent time entries. | | tmetric_get_trackable_projects | Get projects available for time tracking (confirmed alternative for project list). | | tmetric_get_time_entry_tags | Get all tags available for time entries. | | tmetric_add_break | Add a break to the timeline. endTime=null also stops a running timer. |

Timer wrappers

| Tool | Description | |------|-------------| | tmetric_get_active_timer | Get the currently running timer (endTime=null). Returns {running: false} if no timer is active. | | tmetric_start_timer | Start a new timer now (startTime=null, endTime=null). Optionally attach project, task, note, tags. Destructive — overwrites overlapping entries. | | tmetric_stop_timer | Stop the running timer by setting endTime. Resolves the entry ID from latest if not provided. |

Tasks (tasks.ts)

| Tool | Description | |------|-------------| | tmetric_list_tasks | List all tasks in the account workspace. | | tmetric_get_task | Get a single task by ID. | | tmetric_create_task | Create a new task (name, optional projectId, description). | | tmetric_update_task | Fully replace a task by ID. | | tmetric_patch_task | Partially update a task (only provided fields are changed). | | tmetric_delete_task | Delete a task by ID. |

Projects (projects.ts)

| Tool | Description | |------|-------------| | tmetric_list_projects | List all projects visible to the current user in the workspace. |

Reports (reports.ts)

| Tool | Description | |------|-------------| | tmetric_get_projects_report | Projects summary report. Filters: userId[], teamId[], clientId[], projectId[], includeDone, startDate, endDate. Arrays serialized as repeated query params. | | tmetric_get_profitability_report | Profitability report. Filters: startDate, endDate. |

Notes

  • All accountId params are optional — the server resolves it automatically from GET /user on first call and caches it. Pass accountId explicitly if you have multiple accounts.
  • Timestamps in request bodies use YYYY-MM-DDTHH:mm:ss (no timezone offset). null means "now" for startTime or "still running" for endTime.
  • Date query params use YYYY-MM-DD.
  • Error messages include the HTTP method, path, status code, response body, and an actionable hint.