---
title: "Update Time Entry"
method: PATCH
path: "/v1/time-entries/{time_entry_id}"
tags: ["time-entries"]
---

# Update Time Entry

`PATCH /v1/time-entries/{time_entry_id}`

## Request

- Base URL: `https://app.tokumalabs.com/api`
- URL: `https://app.tokumalabs.com/api/v1/time-entries/{time_entry_id}`
- Auth: OAuth 2
  - Password
  - Token URL: `v1/auth/token`

Update an existing time entry.

Updates a time entry with the provided fields. Only provided fields
will be updated. Released time entries cannot be edited. The
response is the cursor-sync wire DTO of the row.

## Path parameters

- `time_entry_id` integer, required: ID of the time entry to update

## Request body

- UpdateTimeEntryRequest: Request model for updating an existing time entry.
  - `narrative` string, nullable: Description of the work performed
  - `activity_code` string, nullable: Activity code for the work
  - `segment_id` string, nullable: Segment ID to associate with this time entry
  - `is_billable` boolean, nullable: Whether the time entry is billable
  - `legal_time_minutes` integer, nullable: Legal time in minutes, snapped to the matter's billing increment before it is stored. Sending an explicit null is the 'use tracked time' action: it clears the typed figure and returns the entry to a computed legal time. Refused with TIME_ENTRY_NO_BLOCKS on an entry with no live time blocks.
  - `acknowledge_legal_time_resnap` boolean: Clear the flag that a move re-rounded this entry's typed legal time, keeping the figure as it stands. The lawyer's 'yes, that is fine' — it settles the note without changing any number

## Response `200`

Successful Response

- TimeEntrySyncDto: A time entry as seen by the cursor sync feed. ``matter_segment`` is a denormalized snapshot — see ``TimeBlockSyncDto`` for rename-staleness semantics. ``version`` is the trigger-bumped cursor counter; ``updated_at`` is informational.
  - `id` integer, required
  - `organization_id` string, required
  - `user_id` string, required
  - `date` string, date, required
  - `legal_time_minutes` integer, required
  - `legal_time_is_computed` boolean, required
  - `tracked_duration_minutes` integer, required
  - `narrative` string, nullable, required
  - `narrative_suggestions` string[], nullable
  - `activity_code` string, nullable
  - `segment_id` string, nullable
  - `matter_segment` MatterSegmentSummaryDto: Summary of matter and segment for time blocks.
    - `matter_id` string, required: Matter ID
    - `matter_name` string, required: Matter name
    - `segment_id` string, required: Segment ID
    - `segment_name` string, required: Segment name
    - `segment_order` integer, required: Display order of the segment within the matter
    - `is_root` boolean, required: Whether this is the root segment
    - `root_segment_id` string, nullable: Root segment ID of the matter
  - `is_billable` boolean, required
  - `legal_time_pinned` boolean, required
  - `legal_time_resnapped_from` integer, nullable
  - `is_user_created` boolean, required
  - `created_at` string, date-time, required
  - `updated_at` string, date-time, required
  - `deleted_at` string, date-time, nullable
  - `version` integer, required

## Other responses

- `400`: Validation error or domain rule violation.
- `401`: Missing, expired, or invalid authentication.
- `403`: Authenticated but not permitted.
- `404`: Resource not found.
- `409`: Resource state conflict (duplicate, illegal transition).
- `422`: Request body failed schema validation.
- `500`: Server-side failure.

---

[API](https://skmtc.dev/tokumalabs/apis/tokuma-user-api.md) - [All operations](https://skmtc.dev/tokumalabs/apis/tokuma-user-api/llms.txt) - [OpenAPI document](https://skmtc.dev/tokumalabs/apis/tokuma-user-api/revisions/1f8201af459b?raw)
