> For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt.

# Keep docs in sync

:::info

**Goal:** Keep your docs in sync with your code, automatically.

:::

## What it does

Every morning, a schedule checks whether the docs still match the code. If they have drifted and no audit PR is already open, it opens a PR with the fix. This catches the common kind of rot where someone changes an API but forgets to update the docs, so the docs quietly go stale.

## The plugin

[`tessl/docs-audit`](https://tessl.io/registry/tessl/docs-audit) reads the code and the docs, finds where they disagree, and opens a PR that reconciles them. Install it with:

```bash
tessl install tessl/docs-audit
```

## Define the schedule

Run it every day at 7:00 UTC. Add this entry to the `schedules` block in your project's `tessl.json`, and keep any other entries already in that block. Replace `production` with the name of your environment (see the [Schedules overview](/schedules/overview.md) for the prerequisites).

<div class="gb-stepper">

<div class="gb-step">

**Add the schedule entry**

```json
{
  "schedules": {
    "docs-audit": {
      "action": {
        "skill": "tessl/docs-audit",
        "environment": "production"
      },
      "schedule": "daily at 07:00"
    }
  }
}
```

</div>

<div class="gb-step">

**Validate and push**

Signed out, validation checks the local file only. Signed in, with a `name` that identifies your project, it also runs the checks Tessl applies when the file syncs and when a run starts. Commit and push the change, then confirm Tessl applied the schedule in your workspace before checking its run history.

```bash
tessl schedule validate
git add tessl.json
git commit -m "chore(docs): add docs audit schedule"
git push
```

</div>

<div class="gb-step">

**Check the runs**

Open the schedule in the web app, or run `tessl schedule runs <id>` to see its run history.

</div>

</div>

## Customize with instructions

Scope the audit to the part of the docs that drifts most by adding `instructions` inside the same entry's `action`. Keep all other entries in the `schedules` block:

```json
{
  "schedules": {
    "docs-audit": {
      "action": {
        "skill": "tessl/docs-audit",
        "environment": "production",
        "instructions": "Only check the API reference against the route handlers in src/api"
      },
      "schedule": "daily at 07:00"
    }
  }
}
```

## Create your own

Want a different behavior? [Create your own plugin](/creating-skills-and-plugins/create-a-plugin.md) that reads the code and the docs and reconciles them your way.
