---
title: "Update user lock days"
method: PUT
path: "/time-clock/v1/time-clocks/{timeClockId}/users/{userId}/lock-days"
tags: ["Time Clock:v1:TimeClocks:TimeClock:LockDays"]
---

# Update user lock days

`PUT /time-clock/v1/time-clocks/{timeClockId}/users/{userId}/lock-days`

Locks or unlocks one or more calendar days for a specific user on a given Time Clock. The isLocked boolean on the request body selects the operation: true (the default) prevents subsequent time-activity edits on those dates; false removes the per-day lock and allows edits again. Idempotent: dates already in the requested state are no-ops, and the response reflects the final state. This endpoint does not reopen approved payroll periods. If isLocked is false and any of the requested dates would actually transition from locked to unlocked but fall inside an approved period for this user, the entire request is rejected with DAYS_IN_APPROVED_PERIOD (409); no dates are unlocked. Approved periods must be reopened from the dashboard before calling this endpoint with isLocked: false. isLocked: true on an approved-period day is allowed and is a no-op for day-lock state.

## Path parameters

- `timeClockId` integer, required — The unique identifier of the time clock
- `userId` integer, required — The ID of the user whose data is being accessed or modified

## Request body

- LockDaysPutRequest
  - `isLocked` boolean — Target lock state for the requested dates. true locks the dates (prevents further time-activity edits). false unlocks the dates. When omitted, defaults to true.
  - `dates` string[], required — Dates to update for this user, in YYYY-MM-DD format. Min 1 date, max 50 dates per request. Must be unique within the request.

## Response `200`

Successful Response

- APIResponseLockDaysPutResponse
  - `requestId` string
  - `data` LockDaysPutResponse, required
    - `userId` integer, required — The unique identifier of the user (echoed from the path).
    - `isLocked` boolean, required — The state applied. Echoes the request value (true if locked, false if unlocked).
    - `dates` string[], required — Final state for the requested dates, in YYYY-MM-DD format. When isLocked is true, every date is now locked (including dates that were already locked). When isLocked is false, every date is now unlocked (including dates that were already unlocked).

## Other responses

- `400` — Invalid request body
- `403` — Lock days are disabled for this Time Clock. Enable Timesheet Approval (Lock Days) before calling this endpoint.
- `404` — The userId in the path does not exist in the company.
- `409` — Only when isLocked is false. One or more dates that would actually transition from locked to unlocked are part of an approved payroll period for this user. The entire request is rejected; no dates are unlocked. Reopen the approved period from the dashboard and retry.
- `422` — Validation Error

---

[API](https://skmtc.net/connecteam/apis/connecteam-api-documentation.md) · [All operations](https://skmtc.net/connecteam/apis/connecteam-api-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/connecteam/connecteam-api-documentation/revisions/d8f7f302222e/schema)
