---
title: "Recheck one recorded repository and request sync recovery"
method: POST
path: "/projects/{id}/github-sync-health"
tags: ["Projects", "GitHub"]
---

# Recheck one recorded repository and request sync recovery

`POST /projects/{id}/github-sync-health`

## Request

- Base URL: `https://api.apphandoff.com/api`
- URL: `https://api.apphandoff.com/api/projects/{id}/github-sync-health`
- Auth: HTTP bearer

Probes repository access under the original sync principal. Missing identities stay unresolved; recovery preserves the original repository and principal and never repeats a successful local write. A missing GitHub object alone does not prove repository access has been lost. A healthy latest probe does not imply all blocked original-identity work has recovered and never authorizes replay under another principal.

## Request body

- object
  - `repository` string, required: GitHub repository in owner/repo format.

## Response `200`

Current observation and recovery status

- object
  - `health` RepositoryHealth, required: Safe project repository sync observation; no sync identity, credential, or provider response body.
    - `id` string, uuid, required
    - `projectId` string, uuid, required
    - `repository` string, required: GitHub repository in owner/repo format.
    - `state` 'healthy' | 'paused' | 'degraded', required
    - `errorClass` 'none' | 'repository_access_denied' | 'installation_missing' | 'rate_limit' | 'transient' | 'object_not_found' | 'unknown', required
    - `firstObservedAt` string, date-time, required
    - `lastObservedAt` string, date-time, required
    - `repairUrl` string, uri, required: GitHub installation or repository settings page for administrator repair.
    - `blockedSyncCount` integer, required: Complete count of access-blocked sync work for this repository under original identities.
  - `recovery` object, required
    - `scheduled` boolean, required
    - `unresolved` boolean, required

## Other responses

- `400`: Invalid request
- `401`: Not authenticated
- `403`: Forbidden
- `404`: Not found
- `503`: GitHub sync health unavailable

---

[API](https://skmtc.dev/apphandoff/apis/apphandoff-api.md) · [All operations](https://skmtc.dev/apphandoff/apis/apphandoff-api/llms.txt) · [OpenAPI document](https://skmtc.dev/apphandoff/apis/apphandoff-api/revisions/9f138fe46d56?raw)
