Skip to content
cccskills
FreePublished on GitHub

whatsapp-diagnostics

Diagnose and fix WhatsApp connectivity issues for OpenClaw agents. Use when: a PA is not responding, WhatsApp shows connected but messages don't arrive, the agent is online but not replying, or troubleshooting a new agent setup.

The English summary is being prepared. Showing the original description.

Works withOpenAI

Run score Not tested

See how to install

Files included (2)

  • SKILL.md6.1 KB
  • DEPRECATED.md423 B

SKILL.md (original)

Review the instructions the agent will receive before you install.

WhatsApp Diagnostics Skill

Minimum Model

Any model. All diagnostics are CLI-based — follow the decision tree.


Diagnostic Tree (Start Here)

PA not responding?
│
├─ Dashboard shows "Connected and listening"?
│   ├─ YES → Check Messages count
│   │   ├─ Messages = 0 → INGEST ISSUE → go to Case 2
│   │   └─ Messages > 0 → RUNTIME ISSUE → go to Case 3
│   └─ NO → CONNECTION ISSUE → go to Case 1
│
└─ Agent exists in platform?
    ├─ YES → Follow Case 1
    └─ NO → Full setup needed (see pa-onboarding skill)

Case 1 — Connection Issue (WhatsApp not linked)

Symptom: Dashboard shows disconnected or no channel configured.

Fix:

  1. Open agent settings in OpenClaw platform
  2. Go to Channels → WhatsApp → click Connect or Re-link
  3. Scan the QR code with WhatsApp Business app
  4. Confirm the phone number matches
  5. Wait 30 seconds for status to update

Most common cause: WhatsApp session expired (happens after ~14 days of inactivity or after a phone restart).


Case 2 — Ingest Issue (Connected but Messages = 0)

Symptom: Dashboard shows "Connected and listening" but message count stays at 0.

Meaning: WhatsApp is connected at protocol level, but messages are not reaching the agent runtime.

Fix:

# Step 1: Check gateway status
openclaw gateway status

# Step 2: Restart the gateway
openclaw gateway restart

# Step 3: Send a test message, wait 30 seconds

# Step 4: If count is still 0, check gateway logs
openclaw gateway logs --last 50

What to look for in logs:

  • binding failed
  • session dropped
  • ingest error

If any of these appear → escalate to platform admin. This is an infrastructure issue.


Case 3 — Runtime Issue (Messages arriving, no reply)

Symptom: Message count increments, but agent doesn't respond.

Meaning: Messages reach the agent, but the agent runtime is failing.

Fix:

# Step 1: Check for billing errors in agent log
grep -i "billing\|402\|credits" ~/.openclaw/logs/agent.log | tail -20
# If billing error found → see billing-monitor skill

# Step 2: Check agent status
openclaw status

# Step 3: Verify API key (pick your provider below)

# For Anthropic:
curl -s -o /dev/null -w "%{http_code}" \
  -H "x-api-key: $ANTHROPIC_API_KEY" \
  -H "anthropic-version: 2023-06-01" \
  https://api.anthropic.com/v1/models

# For OpenAI:
curl -s -o /dev/null -w "%{http_code}" \
  -H "Authorization: Bearer $OPENAI_API_KEY" \
  https://api.openai.com/v1/models

# For Google:
curl -s -o /dev/null -w "%{http_code}" \
  "https://generativelanguage.googleapis.com/v1beta/models?key=$GOOGLE_API_KEY"

# Expected: 200. If 401 → invalid key. If 402 → billing error.

# Step 4: Check recent runtime errors
openclaw logs --last 100 | grep -i error

Interpret results:

  • 200 → API key is valid. Problem is elsewhere (check Step 4).
  • 401 → Invalid API key. Update the key in agent settings.
  • 402 → Billing error. Follow the billing-monitor skill.

Quick Health Check Script

#!/bin/bash
# whatsapp-health-check.sh
# Run this when the agent is unresponsive to get a quick status overview.

echo "=== WhatsApp Diagnostics ==="

# Check gateway status
echo -n "Gateway: "
openclaw gateway status 2>&1 | grep -o "running\|stopped\|error" | head -1 || echo "unknown"

# Check API key — detect provider from env vars
echo -n "API key: "

if [ -n "${ANTHROPIC_API_KEY:-}" ]; then
  PROVIDER="Anthropic"
  # Test with a minimal request to the models endpoint
  STATUS=$(curl -s -o /dev/null -w "%{http_code}" \
    -H "x-api-key: ${ANTHROPIC_API_KEY}" \
    -H "anthropic-version: 2023-06-01" \
    https://api.anthropic.com/v1/models 2>/dev/null)

elif [ -n "${OPENAI_API_KEY:-}" ]; then
  PROVIDER="OpenAI"
  STATUS=$(curl -s -o /dev/null -w "%{http_code}" \
    -H "Authorization: Bearer ${OPENAI_API_KEY}" \
    https://api.openai.com/v1/models 2>/dev/null)

elif [ -n "${GOOGLE_API_KEY:-}" ]; then
  PROVIDER="Google"
  STATUS=$(curl -s -o /dev/null -w "%{http_code}" \
    "https://generativelanguage.googleapis.com/v1beta/models?key=${GOOGLE_API_KEY}" 2>/dev/null)

else
  echo "⚠️ no API key env var found"
  PROVIDER=""
  STATUS=""
fi

# Interpret the HTTP status code
if [ -n "$STATUS" ]; then
  case $STATUS in
    200) echo "✅ valid ($PROVIDER)" ;;
    401) echo "❌ invalid key ($PROVIDER)" ;;
    402) echo "⚠️ billing error ($PROVIDER) — see billing-monitor skill" ;;
    *)   echo "? HTTP $STATUS ($PROVIDER)" ;;
  esac
fi

# Count recent errors in agent logs
echo -n "Recent errors: "
ERROR_COUNT=$(openclaw logs --last 100 2>/dev/null | grep -ic error || echo 0)
echo "$ERROR_COUNT found"

echo "=== Done ==="

When to Escalate to Platform Admin

Escalate if:

  • Gateway restart does NOT fix Messages = 0
  • Logs show socket, binding, or session errors
  • Multiple agents on the same server are affected at the same time

Include in your escalation message:

  • Agent name and phone number
  • Time the issue started
  • Output of openclaw gateway status
  • Messages count shown in dashboard

Prevention

ActionWhy
Send at least one message every 7 daysPrevents WhatsApp session expiry
Check Messages count during heartbeatCatches ingest issues early
Keep the phone number on recordNeeded for QR re-linking
Don't use the same number on two devicesWhatsApp only allows one active session

Cost Tips

  • Very cheap: All diagnostics use CLI + curl — no LLM tokens needed
  • Small model OK: Any model can follow this decision tree and interpret curl output
  • Avoid: Don't run diagnostics on every heartbeat — only run when the agent is not responding
  • Batch: Run the Quick Health Check script once to get all info, rather than running each check separately

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

ai-pa

Free

AI Personal Assistant network skill. Use when: contacting another PA, coordinating with peer agents, scheduling meetings between owners, broadcasting messages, looking up contacts from the local PA directory, or performing any cross-PA task. Reads contact data from data/pa-directory.json in the workspace. Does NOT contain hardcoded contact data — each PA maintains their own directory file.

The English summary is being prepared. Showing the original description.

netanel-abergel/pa-skills6Updated May 10, 2026

ai-pa

Free

AI Personal Assistant network skill for multi-agent PA coordination. Use when: contacting another PA, coordinating with peer agents, scheduling meetings between owners, broadcasting messages to PA groups, or looking up contacts from the local PA directory. Reads contact data from data/pa-directory.json in the workspace.

The English summary is being prepared. Showing the original description.

netanel-abergel/pa-skills6Updated May 10, 2026

ai-pa

Free

Route and execute inter-PA coordination tasks in the OpenClaw multi-agent PA network. Triggers when: contacting another PA, passing a message between owners, broadcasting to a PA group, handling group lead/silence rules, or adding a new PA to the directory. NOT for: contact lookups (use contact-list skill), calendar invites (use meetings skill), or billing issues (use billing-monitor skill).

The English summary is being prepared. Showing the original description.

netanel-abergel/pa-skills6Updated May 10, 2026

OpenClaw API gateway proxy for authenticated SaaS calls (100+ services in references/SERVICES.md). Use ONLY when making an HTTP request to a third-party service that requires the gateway's stored credentials. NOT for direct API calls with bearer tokens already in scope, NOT for monday.com (use monday-for-agents), NOT for WhatsApp (use heleni-whatsapp). Triggers: "call the X API", "fetch from <service>", "send to Slack via gateway", "use the gateway for".

The English summary is being prepared. Showing the original description.

netanel-abergel/pa-skills6Updated May 10, 2026

Automatically creates new skills from complex problem-solving sessions. Triggers at the end of multi-step tasks that required novel approaches, debugging sessions, or workflow creation. Use when: a task took 3+ tool calls, involved a non-obvious solution, or established a pattern likely to recur. Also triggers on: "create a skill from this", "save this as a skill", "this should be a skill".

The English summary is being prepared. Showing the original description.

netanel-abergel/pa-skills6Updated May 10, 2026

Monitor for API billing errors and alert the owner and admin immediately. Use when: an API billing error is detected, a peer PA reports a billing error, or during routine health checks. Handles detection, notification, and fallback model switching. Model-agnostic: works with any LLM provider (Anthropic, OpenAI, Google, etc.).

The English summary is being prepared. Showing the original description.

netanel-abergel/pa-skills6Updated May 10, 2026

See all skills by netanel-abergel

Report a problem with this skill