---
title: "Update timesheet status"
method: PUT
path: "/v2/timesheets/{timesheet_id}"
tags: ["timesheets"]
---

# Update timesheet status

`PUT /v2/timesheets/{timesheet_id}`

## Request

- Base URL: `https://api.hubstaff.com`
- URL: `https://api.hubstaff.com/v2/timesheets/{timesheet_id}`
- Auth: OAuth 2
  - Authorization code: `https://account.hubstaff.com/authorizations/new`
  - Token URL: `https://account.hubstaff.com/access_tokens` scopes: `hubstaff:read`, `hubstaff:write`
- TypeScript: <https://skmtc.dev/hubstaff/apis/hubstaff-v2-api/docs/v2/timesheets/:timesheet_id/put.ts> (a function with typed inputs; its response is checked against the schema)

Updates a timesheet status or updates the denial reason on an already denied timesheet.

Allowed statuses are open, submitted, approved, and denied. A denial_reason is required when transitioning a timesheet to denied.

Approving a timesheet can require explicit confirmation when the period has pending manual time requests or pending time off requests.
If pending manual time requests would be denied, the endpoint returns 422 with error_code 14905; repeat the request with confirm_pending_manual_time_request_denial set to true.
If the period has pending time off requests, the endpoint returns 422 with error_code 14906; repeat the request with acknowledge_pending_time_off_requests set to true.

## Path parameters

- `timesheet_id` integer, required

## Request body

- PutV2TimesheetsTimesheetId: Update timesheet status
  - `status` 'open' | 'submitted' | 'approved' | 'denied', required: New status
  - `denial_reason` string: Denial reason
  - `confirm_pending_manual_time_request_denial` boolean: Required to approve a timesheet with pending manual time requests that will be denied.
  - `acknowledge_pending_time_off_requests` boolean: Required to approve a timesheet with pending time off requests in the same period.

## Response `200`

The updated timesheet

- object
  - `timesheet` Timesheet: Timesheet model
    - `id` integer, required: Timesheet ID
    - `paid` boolean, required: Is the timesheet paid?
    - `user_id` integer, required: User ID
    - `organization_id` integer, required: Organization ID
    - `team_payment_id` integer: Team payment ID
    - `team_invoice_id` integer: Team invoice ID
    - `status` string, required: Status
    - `keyboard` integer, required: Percentage of time keyboard was active within the time worked
    - `mouse` integer, required: Percentage of time mouse was active within the time worked
    - `overall` integer, required: Percentage of overall time active within the time worked
    - `tracked` integer, required: Total time worked in seconds
    - `input_tracked` integer, required: Total time worked in seconds when inputs (keyboard, mouse) were active
    - `start_date` string, date, required: Start date
    - `stop_date` string, date, required: Stop date
    - `approved_on` string, date: Approving date
    - `submitted_on` string, date: Submission date
    - `approved_by_id` integer: Approving User ID
    - `denial_reason` string: Denial reason
    - `locked` boolean, required: Is the timesheet locked
    - `created_at` string, date-time, required: When the record was created
    - `updated_at` string, date-time, required: When the record was last updated

## Other responses

- `400`: Invalid parameters
- `401`: Unauthorized
- `403`: API access is only for organizations on an active plan
- `404`: Could not find record
- `429`: Rate limit exceeded

---

[API](https://skmtc.dev/hubstaff/apis/hubstaff-v2-api.md) - [All operations](https://skmtc.dev/hubstaff/apis/hubstaff-v2-api/llms.txt) - [OpenAPI document](https://skmtc.dev/hubstaff/apis/hubstaff-v2-api/revisions/c6b90e4e4bdc?raw)
