---
title: "Replace weekly shifts (split shifts, breaks, location per shift). Future bookings outside the new hours return requires_staff_action unless accept_conflicts is true"
method: PUT
path: "/api/v1/team/{id}/hours"
---

# Replace weekly shifts (split shifts, breaks, location per shift). Future bookings outside the new hours return requires_staff_action unless accept_conflicts is true

`PUT /api/v1/team/{id}/hours`

## Request

- Base URL: `http://127.0.0.1:4310`
- URL: `http://127.0.0.1:4310/api/v1/team/{id}/hours`
- Auth: one of:
  - HTTP bearer
  - API key in cookie `sfb_session`

## Path parameters

- `id` string, required

## Request body

- object
  - `shifts` object[], required
    - `weekday` integer, required
    - `week_index` integer: With cycle_weeks 2: 0 is Week A, 1 is Week B
    - `location_id` string, uuid
    - `start` string, required
    - `end` string, required
    - `breaks` object[]
      - `start` string
      - `end` string
  - `cycle_weeks` 1 | 2: 2 for a pattern that alternates weekly (Week A and Week B); default 1
  - `anchor_date` string, date: With cycle_weeks 2: a date in the first Week A (stored as its Monday)
  - `accept_conflicts` boolean
  - `expected_version` integer

## Response `200`

OK

- object

## Other responses

- `400`: Validation error
- `401`: Unauthenticated
- `403`: Forbidden
- `404`: Not found
- `409`: Conflict or invalid state

---

[API](https://skmtc.dev/scalingfirm/apis/tsf-booking-api.md) · [All operations](https://skmtc.dev/scalingfirm/apis/tsf-booking-api/llms.txt) · [OpenAPI document](https://skmtc.dev/scalingfirm/apis/tsf-booking-api/revisions/81704199cd37?raw)
