---
name: API Docs

"on":
  push:
    branches: [main, master]
  pull_request:
  schedule:
    - cron: "0 6 * * *"  # Daily 6AM UTC build

permissions:
  contents: read

jobs:
  apidocs:
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v5.0.0
      - name: Set up Python
        uses: actions/setup-python@v6
        with:
          python-version: "3.13"
      - name: Install pydoctor
        run: |
          pip3 install pydoctor
      - name: Generate docs
        run: make apidocs
