---
title: "Update Repo"
method: PATCH
path: "/repos/{short_id}"
tags: ["repos"]
---

# Update Repo

`PATCH /repos/{short_id}`

Update editable repo settings: name, default branch, exclude patterns,
page-volume override, and the AI-explanation refresh policy.

``short_id`` accepts either a snapshot short_id or the repo UUID, matching
the resolution rules used by ``PATCH /repos/{short_id}/auto-sync``.

Owner-only: enforced via ``user_repos``. Does not trigger a re-index;
that is a separate explicit action via ``POST /repos/{repo_id}/reindex``.

## Path parameters

- `short_id` string, required

## Request body

- RepoUpdateRequest — Body for PATCH /repos/{short_id}. All fields optional — only the keys present in the request are written.
  - `name` string, nullable
  - `default_branch` string, nullable
  - `exclude_patterns` string[], nullable
  - `github_checks_enabled` boolean, nullable
  - `max_file_pages` integer, nullable
  - `prose_refresh` 'off' | 'manual' | 'auto', nullable
  - `prose_daily_cap_cents` integer, nullable

## Response `200`

Successful Response

- RepoResponse
  - `id` string, required
  - `canonical_url` string, required
  - `owner` string, required
  - `name` string, required
  - `default_branch` string, required
  - `latest_known_head_sha` string, nullable
  - `is_public` boolean, required
  - `file_count` integer, nullable
  - `last_checked_at` string, date-time, nullable
  - `auto_sync_enabled` boolean
  - `github_checks_enabled` boolean
  - `last_webhook_at` string, date-time, nullable
  - `last_polled_at` string, date-time, nullable
  - `exclude_patterns` string[]
  - `max_file_pages` integer, nullable
  - `prose_refresh` string
  - `prose_daily_cap_cents` integer
  - `repowise_managed` boolean
  - `description` string, nullable
  - `primary_language` string, nullable
  - `stars` integer, nullable
  - `badge_detected_at` string, date-time, nullable

## Other responses

- `422` — Validation Error

---

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