Skip to content

Composio powers 1000+ toolkits, tool search, context management, authentication, and a sandboxed workbench to help you build AI agents that turn intent into action.

ci: add docs health check workflow (testing)

Sushmithamallesh7bf9f9ddce60
diff --git a/.github/workflows/docs.health-check.yml b/.github/workflows/docs.health-check.yml
new file mode 100644
index 000000000..0cc1aa08f
--- /dev/null
+++ b/.github/workflows/docs.health-check.yml
@@ -0,0 +1,111 @@
+name: Docs Health Check
+
+on:
+ schedule:
+ - cron: '0 * * * *' # Every hour
+ workflow_dispatch: # Manual trigger
+
+jobs:
+ health-check:
+ name: Check docs accessibility
+ runs-on: ubuntu-latest
+ steps:
+ - name: Check endpoints
+ id: check
+ run: |
+ BASE_URL="https://docs.composio.dev"
+ FAILED=""
+ CHECKED=0
+
+ # Standard HTML endpoints
+ ENDPOINTS=(
+ # TODO: Remove after testing — intentional 404 to verify Slack alert
+ "/this-page-does-not-exist-test-404"
+
+ # LLM/AI agent entry points
+ "/llms.txt"
+ "/llms-full.txt"
+ "/docs/quickstart.md"
+ "/docs/tools-and-toolkits.md"
+
+ # Main pages
+ "/docs"
+ "/docs/quickstart"
+ "/docs/authentication"
+ "/docs/tools-and-toolkits"
+ "/docs/users-and-sessions"
+ "/docs/configuring-sessions"
+ "/cookbooks"
+ "/toolkits"
+ "/reference"
+
+ # Provider pages
+ "/docs/providers/openai"
+ "/docs/providers/vercel"
+ "/docs/providers/anthropic"
+
+ # Key sub-pages
+ "/docs/tools-direct/fetching-tools"
+ "/docs/tools-direct/executing-tools"
+ "/docs/authenticating-users/in-chat-authentication"
+ "/docs/common-faq"
+ )
+
+ # Endpoints to also test with Accept: text/markdown
+ MARKDOWN_ENDPOINTS=(
+ "/docs/quickstart"
+ "/docs/tools-and-toolkits"
+ "/docs/authentication"
+ "/docs/providers/openai"
+ "/cookbooks"
+ )
+
+ for endpoint in "${ENDPOINTS[@]}"; do
+ CHECKED=$((CHECKED + 1))
+ STATUS=$(curl -sL -o /dev/null -w "%{http_code}" --max-time 15 "${BASE_URL}${endpoint}" || echo "000")
+
+ if [ "$STATUS" -ge 400 ] || [ "$STATUS" = "000" ]; then
+ echo "FAIL: ${endpoint} → HTTP ${STATUS}"
+ FAILED="${FAILED}\n• \`${endpoint}\` → HTTP ${STATUS}"
+ else
+ echo "OK: ${endpoint} → HTTP ${STATUS}"
+ fi
+ done
+
+ for endpoint in "${MARKDOWN_ENDPOINTS[@]}"; do
+ CHECKED=$((CHECKED + 1))
+ STATUS=$(curl -sL -o /dev/null -w "%{http_code}" --max-time 15 -H "Accept: text/markdown" "${BASE_URL}${endpoint}" || echo "000")
+
+ if [ "$STATUS" -ge 400 ] || [ "$STATUS" = "000" ]; then
+ echo "FAIL: ${endpoint} (Accept: text/markdown) → HTTP ${STATUS}"
+ FAILED="${FAILED}\n• \`${endpoint}\` (Accept: text/markdown) → HTTP ${STATUS}"
+ else
+ echo "OK: ${endpoint} (Accept: text/markdown) → HTTP ${STATUS}"
+ fi
+ done
+
+ if [ -n "$FAILED" ]; then
+ echo "has_failures=true" >> $GITHUB_OUTPUT
+ echo "checked=$CHECKED" >> $GITHUB_OUTPUT
+
+ PAYLOAD=$(jq -n \
+ --arg failed "$FAILED" \
+ --arg checked "$CHECKED" \
+ --arg run_url "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
+ '{text: ("🚨 *Docs Health Check Failed*\n\nSome endpoints returned errors. These are URLs that Claude Code / Codex hit when accessing our docs.\n\n*Failing endpoints:*" + $failed + "\n\n_Checked " + $checked + " endpoints total_\n<" + $run_url + "|View run>")}')
+
+ echo "slack_payload<<EOF" >> $GITHUB_OUTPUT
+ echo "$PAYLOAD" >> $GITHUB_OUTPUT
+ echo "EOF" >> $GITHUB_OUTPUT
+ else
+ echo "has_failures=false" >> $GITHUB_OUTPUT
+ echo "All $CHECKED endpoints healthy"
+ fi
+
+ - name: Notify Slack
+ if: steps.check.outputs.has_failures == 'true'
+ uses: slackapi/slack-github-action@fcfb566f8b0aab22203f066d80ca1d7e4b5d05b3 # v1.27.1
+ with:
+ payload: ${{ steps.check.outputs.slack_payload }}
+ env:
+ SLACK_WEBHOOK_URL: ${{ secrets.SLACK_POD_DX_WEBHOOK_URL }}