---
title: "Push heartbeats (WakaTime compatible)"
method: POST
path: "/api/hackatime/v1/users/{id}/heartbeats"
tags: ["WakaTime Compatibility"]
---

# Push heartbeats (WakaTime compatible)

`POST /api/hackatime/v1/users/{id}/heartbeats`

Endpoint used by WakaTime plugins to send heartbeat data to the server. This is the core endpoint for tracking time.

## Path parameters

- `id` string, required

## Request body

- object[]
  - `entity` string
  - `type` string
  - `time` number
  - `project` string
  - `branch` string
  - `language` string
  - `is_write` boolean
  - `lineno` integer
  - `cursorpos` integer
  - `lines` integer
  - `category` string

## Response `202`

accepted

## Other responses

- `401` — unauthorized

## Changes

- **2026-01-27** (v1) `b6d6849481da` — 10 warning, 2 info
  - removed the request property `items/created_at`
  - removed the request property `items/dependencies`
  - removed the request property `items/editor`
  - removed the request property `items/line_additions`
  - …8 more

[Change history](https://skmtc.dev/hackclub/apis/hackatime-api/changes/api/hackatime/v1/users/:id/heartbeats/post.md)

---

[API](https://skmtc.dev/hackclub/apis/hackatime-api.md) · [All operations](https://skmtc.dev/hackclub/apis/hackatime-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/hackclub/hackatime-api/revisions/b6d6849481da/schema)
