← 返回 Skills 市场
reighlan

Client Reporting Automation

作者 Tyler Hill · GitHub ↗ · v1.0.0
cross-platform ⚠ suspicious
630
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install client-reporting
功能描述
Automated client reporting for agencies and freelancers using OpenClaw. Pull data from Google Analytics, Google Search Console, social media platforms, and c...
使用说明 (SKILL.md)

Client Reporting Automation

Pull metrics from multiple sources, generate branded reports, and auto-deliver to clients. Built for agencies and freelancers who need consistent, professional reporting without manual work.

Setup

Dependencies

pip3 install requests jinja2

API Keys (configure in config.json)

  • Google Analytics 4GA4_PROPERTY_ID + service account key
  • Google Search Console — service account key (see seo-audit-suite references)
  • Social platforms — same credentials as social-media-autopilot skill
  • SendGrid — for email delivery (SENDGRID_API_KEY)

Workspace

client-reports/
├── config.json           # Global settings, API keys
├── clients/              # Per-client configuration
│   └── client-name/
│       ├── config.json   # Client-specific settings (property IDs, branding)
│       ├── reports/      # Generated reports
│       └── data/         # Cached metrics data
├── templates/            # Report templates (Jinja2 HTML)
└── schedules.json        # Automated delivery schedule

Run scripts/init-workspace.sh to create this structure.

Core Workflows

1. Add a Client

scripts/add-client.sh --name "acme-corp" --domain "acme.com" --email "[email protected]"

Creates client directory with config template. Edit clients/acme-corp/config.json to add:

  • GA4 property ID
  • Search Console site URL
  • Social media handles
  • Branding (logo URL, brand colors)
  • Report preferences (metrics to include, frequency)

2. Pull Metrics

Fetch fresh data for a client:

scripts/pull-metrics.sh --client "acme-corp"                    # All sources
scripts/pull-metrics.sh --client "acme-corp" --source ga4       # Google Analytics only
scripts/pull-metrics.sh --client "acme-corp" --source gsc       # Search Console only
scripts/pull-metrics.sh --client "acme-corp" --source social    # Social metrics
scripts/pull-metrics.sh --client "acme-corp" --period 30d       # Last 30 days

Data sources and metrics:

Google Analytics 4:

  • Sessions, users, new users, bounce rate
  • Top pages by views
  • Traffic sources breakdown
  • Conversion events
  • Device/browser breakdown

Google Search Console:

  • Total clicks, impressions, CTR, avg position
  • Top queries by clicks
  • Top pages by impressions
  • Position changes vs previous period

Social Media:

  • Followers/following changes
  • Post engagement (likes, shares, comments)
  • Top performing posts
  • Reach/impressions

3. Generate Reports

scripts/generate-report.sh --client "acme-corp" --type monthly
scripts/generate-report.sh --client "acme-corp" --type weekly --format html
scripts/generate-report.sh --client "acme-corp" --type custom --metrics "traffic,rankings,social"

Report types:

  • weekly — 7-day snapshot with week-over-week changes
  • monthly — 30-day deep dive with month-over-month trends
  • quarterly — 90-day strategic overview
  • custom — pick specific metrics

Output formats:

  • Markdown — default, good for Slack/email
  • HTML — branded, professional, email-ready
  • PDF — via HTML-to-PDF conversion (requires wkhtmltopdf or similar)

4. Auto-Deliver Reports

scripts/deliver-report.sh --client "acme-corp" --latest         # Send most recent
scripts/deliver-report.sh --client "acme-corp" --via email      # Email delivery
scripts/deliver-report.sh --client "acme-corp" --via slack      # Slack webhook

5. Schedule Recurring Reports

Configure in schedules.json:

{
  "schedules": [
    {
      "client": "acme-corp",
      "type": "weekly",
      "day": "monday",
      "time": "09:00",
      "timezone": "America/Los_Angeles",
      "deliver_via": "email",
      "enabled": true
    },
    {
      "client": "acme-corp",
      "type": "monthly",
      "day_of_month": 1,
      "time": "09:00",
      "timezone": "America/Los_Angeles",
      "deliver_via": "email",
      "enabled": true
    }
  ]
}

Use with OpenClaw cron to automate: check schedules daily, generate and deliver due reports.

6. KPI Dashboard

Quick terminal dashboard for any client:

scripts/dashboard.sh --client "acme-corp"

Shows current period vs previous: traffic, rankings, social growth, conversions.

Report Template System

Templates use Jinja2 and live in templates/:

\x3C!-- templates/monthly.html -->
\x3Chtml>
\x3Chead>\x3Cstyle>/* brand styles */\x3C/style>\x3C/head>
\x3Cbody>
  \x3Ch1>Monthly Report — {{ client.name }}\x3C/h1>
  \x3Cp>{{ period.start }} to {{ period.end }}\x3C/p>
  
  \x3Ch2>Traffic Overview\x3C/h2>
  \x3Ctable>
    \x3Ctr>\x3Ctd>Sessions\x3C/td>\x3Ctd>{{ ga4.sessions }}\x3C/td>\x3Ctd>{{ ga4.sessions_change }}%\x3C/td>\x3C/tr>
    \x3Ctr>\x3Ctd>Users\x3C/td>\x3Ctd>{{ ga4.users }}\x3C/td>\x3Ctd>{{ ga4.users_change }}%\x3C/td>\x3C/tr>
  \x3C/table>
  
  \x3Ch2>Search Performance\x3C/h2>
  \x3C!-- ... -->
\x3C/body>
\x3C/html>

Customize templates per client by placing overrides in clients/\x3Cname>/templates/.

Cron Integration

  • Daily: Pull fresh metrics for all active clients
  • Weekly: Generate and deliver weekly reports (Monday AM)
  • Monthly: Generate and deliver monthly reports (1st of month)
  • Quarterly: Generate quarterly reviews

References

  • references/ga4-setup.md — Google Analytics 4 API setup and available metrics
  • references/report-customization.md — How to customize templates and metrics
安全使用建议
This skill appears to do what it says, but review and control where your credentials live before installing: 1) Prefer pointing to an isolated service-account JSON on disk (ga4_credentials_file / search_console_credentials_file) rather than embedding secrets into config.json checked into source control. 2) Use a dedicated SendGrid API key with limited scopes and verify recipient addresses. 3) Slack delivery relies on webhooks — ensure webhook URLs are kept secret. 4) HTML templates reference client-provided logo URLs; external images in emails can leak metadata when recipients open them — consider inlining assets or hosting images on trusted storage. 5) Run the scripts in a controlled workspace (set CLIENT_REPORTS_DIR) and set restrictive file permissions on config/credential files. If you want higher assurance, request maintainer provenance (homepage/author) and a short security readme describing secret handling.
功能分析
Type: OpenClaw Skill Name: client-reporting Version: 1.0.0 The skill bundle contains multiple critical vulnerabilities that could lead to remote code execution (RCE), data exfiltration, and server-side request forgery (SSRF). Specifically, `scripts/add-client.sh` is vulnerable to shell injection via the `--name` argument. Path traversal vulnerabilities exist across `scripts/dashboard.sh`, `scripts/deliver-report.sh`, `scripts/generate-report.sh`, and `scripts/pull-metrics.sh` due to unsanitized client names, which could allow reading arbitrary files. This is particularly critical in `scripts/deliver-report.sh`, where arbitrary file content could be exfiltrated via SendGrid or Slack. Furthermore, `scripts/generate-report.sh` is susceptible to server-side template injection (SSTI) via the `client_name` field in `config.json`, potentially leading to RCE. Finally, `scripts/pull-metrics.sh` has an SSRF vulnerability in its GSC fallback mechanism, allowing HTTP requests to arbitrary domains specified in `client_config.json`.
能力评估
Purpose & Capability
Name/description (agency/freelancer client reporting) matches the code and instructions: scripts pull GA4/GSC/social placeholders, render templates with Jinja2, and deliver via SendGrid or Slack. Required tools (requests, jinja2, optional wkhtmltopdf) are appropriate for the stated functions.
Instruction Scope
SKILL.md and the bundled scripts give concrete commands and reference where credentials live (global config.json or env). The SKILL.md references using service account keys and SendGrid; scripts read global config.json and allow env fallbacks (e.g., SENDGRID_API_KEY, SLACK_WEBHOOK_URL, CLIENT_REPORTS_DIR). One minor mismatch: SKILL.md refers to 'social-media-autopilot' for social credentials (external skill convention) which may be confusing but not malicious.
Install Mechanism
No install spec; this is instruction-only plus shipped scripts. The runtime dependencies are Python packages installed via pip (requests, jinja2) — expected and low risk. There are no remote download-or-extract steps or third-party binary fetches in the repository.
Credentials
The skill requires credentials appropriate to its purpose (GA4 service account, GSC key, social API keys, SendGrid API key). The registry metadata shows no required env vars, but the scripts do accept env fallbacks (SENDGRID_API_KEY, SLACK_WEBHOOK_URL, CLIENT_REPORTS_DIR). Be aware secrets can be stored in the workspace config.json or as file paths to service-account JSON; storing credential files in project folders can be risky if the workspace is shared or checked into VCS.
Persistence & Privilege
Skill is not marked always:true, does not modify other skills or system-wide settings, and has no install step that persists new daemons or services. It writes files only within its workspace (clients/, templates/, data/, reports/).
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install client-reporting
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /client-reporting 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release: GA4, Search Console, branded reports, email/Slack delivery
元数据
Slug client-reporting
版本 1.0.0
许可证
累计安装 0
当前安装数 0
历史版本数 1
常见问题

Client Reporting Automation 是什么?

Automated client reporting for agencies and freelancers using OpenClaw. Pull data from Google Analytics, Google Search Console, social media platforms, and c... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 630 次。

如何安装 Client Reporting Automation?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install client-reporting」即可一键安装,无需额外配置。

Client Reporting Automation 是免费的吗?

是的,Client Reporting Automation 完全免费(开源免费),可自由下载、安装和使用。

Client Reporting Automation 支持哪些平台?

Client Reporting Automation 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Client Reporting Automation?

由 Tyler Hill(@reighlan)开发并维护,当前版本 v1.0.0。

💬 留言讨论