---
title: "Partially update worksite"
method: PATCH
path: "/worksites/{id}"
tags: ["Worksites"]
---

# Partially update worksite

`PATCH /worksites/{id}`

Partially update specific fields of a worksite

## Request body

- Worksite
  - `id` integer
  - `name` string
  - `address` string
  - `case_number` string — Case number, which is an alpha character assigned to the incident, plus an incrementing number.
  - `phone1` string
  - `phone2` string
  - `phone1_notes` string, nullable — Notes associated with phone1.
  - `phone2_notes` string, nullable — Notes associated with phone2.
  - `email` string
  - `location` string, nullable, required — Values in this column have been de-identified or randomized. The geocordinates of the worksite.
  - `blurred_location` string, nullable — Values in this column have been de-identified or randomized. Geocordinates of the worksite, randomized to within a 400 meter range. These are calculated whenever the location is updated, but are not randomized each time for two reasons: 1. It is costly. 2. An attacker could narrow in on the precise location by repeatedly asking the system to randomly generate a new location.
  - `form_data` WorksiteData[], required
    - `field_value` string, required
    - `field_key` string, nullable — The machine-friendly HTML field key of the data point.
  - `postal_code` string
  - `incident` integer, nullable, required — incident.id to which the worksite belongs.
  - `work_types` WorksiteTypes[]
    - `id` integer
    - `work_type` integer, required
    - `claimed_by` integer, nullable — The organization that claimed this work type.
    - `phase` integer, nullable — The incident phase associated with this work type.
    - `status` string, nullable — The status associated with this work type.
    - `recur` string, nullable — The recurring pattern associated with this work type.
    - `next_recur_at` string, date-time, nullable — The next timestamp for the recurring pattern of this work type.
    - `created_at` string, date-time — The timestamp when this work type was created.
  - `city` string
  - `language` integer, nullable — Language of the primary language spoken by the resident.
  - `state` string
  - `county` string
  - `skip_duplicate_check` boolean
  - `send_sms` boolean
  - `flags` Flag[]
    - `id` integer
    - `reason_t` string, nullable — Reason why this entity is being flagged
    - `is_high_priority` boolean, nullable — This flag, applied to a worksite, will make the case stand out on the map or in other ways. Applied to another model, it indicates that the flag is high priority.
    - `notes` string
    - `requested_action` string, nullable — You may request a particular action, but there is no guarantee that action will be taken. Requested actions might include organization kicked out, trained, reported to law enforcement, reported to emergency management, behavior shared with other voluntary organizations.
    - `action` string, nullable — The action taken by an administrator.
    - `created_at` string, date-time — Timestamp when the flag was created.
    - `flag_id` integer
    - `attr` object, nullable — A bucket to store arbitrary data generated in the flagging process.
  - `notes` WorksiteNotes[]
    - `id` integer
    - `note` string, required
    - `created_by` integer
    - `created_at` string, date-time — The timestamp when the note was created.
    - `is_survivor` string
    - `note_type` 'ai_generated_call_summary' | 'survivor_note' | 'volunteer_note' | 'auto_generated_flag_note' — The type of note: AI generated call summary, survivor note, or volunteer note.
  - `what3words` string, nullable — Values in this column have been de-identified or randomized. If a point type location, then the what3words equivalent goes here.
  - `pluscode` string, nullable — If a point type location, then the Google pluscode equivalent goes here.
  - `reported_by` integer, nullable — organization.id of the reporting organization.
  - `updated_at` string, date-time — Timestamp when the worksite was last updated.
  - `events` string
  - `key_work_type` string
  - `time` WorksiteUsersTime[]
    - `id` integer
    - `worksite` integer, nullable — The worksite to which the volunteered time is attached.
    - `volunteers` integer, nullable — The number of volunteers participating.
    - `created_by_name` string
    - `created_by_org` string
    - `seconds` integer, nullable — The time volunteered in seconds.
  - `files` FileJoin[]
    - `tag` string, nullable — User-generated tag(s) or desription.
    - `title` string, nullable — A user-generated title, such as exterior_front, exterior_rear, interior, basement, friends, headquarters, user manual, tornado path, furthest extent, etc. Note: file_files.title and location_locations.name are the default titles. However, this field allows the user to create their own title if it is shared. It may or may not be implemented.
    - `notes` string, nullable — Any user-specific notes, caption, or description for the file. Note: file_files.notes is the default captions. However, this field allows the user to create their own caption if they wish, e.g. if someone else shares it with them. It may or may not be implemented.
    - `created_at` string, date-time — Timestamp when the file was attached to the object.
    - `file_updated_at` string
    - `id` integer
    - `file` integer, nullable, required — The file.id of the file being attached to object_id.
    - `filename` string
    - `url` string
    - `full_url` string
    - `general_file_url` string
    - `blog_url` string
    - `large_blog_url` string
    - `large_thumbnail_url` string
    - `small_thumbnail_url` string
    - `filename_original` string
    - `file_type_t` string
    - `mime_content_type` string
    - `attr` string
    - `image_exif` string
  - `favorite` string
  - `svi` string, decimal, nullable — Float between 0-1 indicating the relative social vulnerability of the worksite. This number is calculated based upon SVI polygons and data at the time of worksite creation and stored permanently with the worksite.
  - `auto_contact_frequency_t` string, nullable

## Response `200`

Worksite updated successfully

## Other responses

- `400` — Invalid input data
- `403` — Permission denied
- `404` — Worksite not found

---

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