> For the complete documentation index, see [llms.txt](https://wiki.crosswatch.app/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://wiki.crosswatch.app/crosswatch/advanced-and-api/api-reference/synchronization-and-scheduling.md).

# Synchronization and scheduling

Use these endpoints to configure pairs, run synchronization, and manage schedules.

### Pairs

| Method   | Endpoint                     | Purpose                               |
| -------- | ---------------------------- | ------------------------------------- |
| `GET`    | `/api/sync/providers`        | List sync providers and capabilities. |
| `GET`    | `/api/pairs`                 | List sync pairs.                      |
| `POST`   | `/api/pairs`                 | Create a sync pair.                   |
| `POST`   | `/api/pairs/reorder`         | Reorder pairs.                        |
| `PUT`    | `/api/pairs/{pair_id}`       | Update a pair.                        |
| `DELETE` | `/api/pairs/{pair_id}`       | Delete a pair.                        |
| `GET`    | `/api/sync/providers/counts` | Return feature counts.                |

Start with removals disabled. Enable them after confirming the baseline.

### Runs

| Method | Endpoint                  | Purpose                        |
| ------ | ------------------------- | ------------------------------ |
| `POST` | `/api/run`                | Start a synchronization run.   |
| `GET`  | `/api/run/summary`        | Return the latest run summary. |
| `GET`  | `/api/run/unresolved`     | Return unresolved items.       |
| `GET`  | `/api/run/summary/file`   | Download the latest summary.   |
| `GET`  | `/api/run/summary/stream` | Stream progress using SSE.     |

Send `pair_id` in the request body to run one pair.

### Scheduling

| Method | Endpoint                      | Purpose                         |
| ------ | ----------------------------- | ------------------------------- |
| `GET`  | `/api/scheduling`             | Return schedule configuration.  |
| `POST` | `/api/scheduling`             | Save schedule configuration.    |
| `GET`  | `/api/scheduling/status`      | Return scheduler status.        |
| `GET`  | `/api/scheduling/next`        | Return upcoming scheduled work. |
| `POST` | `/api/scheduling/replan_now`  | Recalculate the schedule.       |
| `POST` | `/api/scheduling/trigger_now` | Trigger scheduled work now.     |
| `POST` | `/api/scheduling/stop`        | Stop the scheduler.             |

SSE clients must reconnect after interruption and ignore `ping` events.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://wiki.crosswatch.app/crosswatch/advanced-and-api/api-reference/synchronization-and-scheduling.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
