---
title: "Update review"
method: PATCH
path: "/repos/{repo_id}/reviews/{review_id}"
tags: ["Reviews"]
---

# Update review

`PATCH /repos/{repo_id}/reviews/{review_id}`

## Request

- Base URL: `https://api.diversion.dev/v0`
- URL: `https://api.diversion.dev/v0/repos/{repo_id}/reviews/{review_id}`
- Auth: OAuth 2
  - Implicit: `https://auth.diversion.dev/oauth2/authorize`
  - Scopes: `coreapi/write`
- TypeScript: <https://skmtc.dev/diversion/apis/diversion-core-api/docs/repos/:repo_id/reviews/:review_id/patch.ts> (a function with typed inputs; its response is checked against the schema)

Update review details (title, description, and/or status)

## Request body

- UpdateReviewPayload: Payload for updating a review
  - `status` 'open' | 'closed': New review status
  - `title` string: New review title
  - `description` string: New review description
  - `reviewer_ids` string[]: Updated list of reviewer user IDs

## Response `200`

Review updated successfully

- Review: Review details
  - `id` string, required: Review ID
  - `title` string, required: Review title
  - `description` string: Review description
  - `status` 'open' | 'closed', required: Review status
  - `author` User, required: User details
    - `image` string: URL of the user image. If updating the image, could be a base64 encoded image.
    - `email` string, email
    - `full_name` string
    - `id` string, required
    - `name` string
    - `tier` 'EDUCATION' | 'INDIE' | 'PROFESSIONAL' | 'ENTERPRISE' | 'UNKNOWN': The tier of the user
  - `reviewers` User[]: List of reviewers
    - `image` string: URL of the user image. If updating the image, could be a base64 encoded image.
    - `email` string, email
    - `full_name` string
    - `id` string, required
    - `name` string
    - `tier` 'EDUCATION' | 'INDIE' | 'PROFESSIONAL' | 'ENTERPRISE' | 'UNKNOWN': The tier of the user
  - `reviewer_statuses` ReviewerStatus[]: List of reviewer statuses
    - `user_id` string, required: Reviewer user ID
    - `status` 'requested' | 'approved' | 'changes_requested' | 'rejected', required: Reviewer's status
    - `updated_at` integer, required: Unix timestamp when the reviewer status was last updated
  - `created_at` integer, required: Unix timestamp when the review was created
  - `updated_at` integer, required: Unix timestamp when the review was last updated
  - `base_ref` string, required: Base reference (branch/commit)
  - `compare_ref` string, required: Compare reference (branch/commit)
  - `repo_id` string, required: Repository ID
  - `merge_commit_id` integer: ID of the commit that merged this review
  - `active_merge_id` string: ID of active merge with conflicts
  - `draft_commit_id` string: ID of the draft commit that created this review

## Other responses

- `default`: An error occurred

---

[API](https://skmtc.dev/diversion/apis/diversion-core-api.md) - [All operations](https://skmtc.dev/diversion/apis/diversion-core-api/llms.txt) - [OpenAPI document](https://skmtc.dev/diversion/apis/diversion-core-api/revisions/38a18aba804b?raw)
