Skip to content

docs(plugin): add claspo widget automation plugin to examples - #2530

Open
vecyang1 wants to merge 1 commit into
jackwener:mainfrom
vecyang1:docs/add-claspo-plugin
Open

vecyang1 wants to merge 1 commit into
jackwener:mainfrom
vecyang1:docs/add-claspo-plugin

Conversation

@vecyang1

@vecyang1 vecyang1 commented Sep 20, 2026

Copy link
Copy Markdown
Contributor

Description

Adds opencli-plugin-claspo to the community plugin listings across English and Chinese documentation (README.md, README.zh-CN.md, docs/guide/plugins.md, and docs/zh/guide/plugins.md). Docs only — no core code changes.

About opencli-plugin-claspo

opencli-plugin-claspo provides a typed, agent-operable CLI suite for Claspo website widgets and popups (my.claspo.io) through the OpenCLI Browser Bridge.

opencli plugin install github:vecyang1/opencli-plugin-claspo
opencli claspo --help

Ten comprehensive commands (v1.1.0):

  • opencli claspo list: List all widgets with ID, Name, Status, Views, Submissions, and Conversion Rate.
  • opencli claspo get <widget-id>: Retrieve layout configuration, targeting rules, frequency, and schedules.
  • opencli claspo appearance <widget-id>: Extract all multi-step views (Signup, Email, Promocode, etc.) and interactive component trees with UUIDs.
  • opencli claspo patch <widget-id> --component <uuid> --text <text> [--publish]: Surgically mutate text copy or properties on a component and invoke native SDK save.
  • opencli claspo publish <widget-id> [--unpublish]: Toggle widget live publishing status.
  • opencli claspo rules <widget-id>: Deep inspection of display frequency, countdown timers, show-again modes, and URL/targeting predicates.
  • opencli claspo analytics <widget-id>: Live breakdown of impressions, clicks, submissions, target actions, and conversion rate.
  • opencli claspo duplicate <widget-id> [--name <name>]: Clone an existing widget and optionally assign a new name.
  • opencli claspo rename <widget-id> <name>: Rename an existing widget.
  • opencli claspo delete <widget-id> --yes: Delete a widget, strictly guarded by mandatory --yes confirmation flag.

Highlights

  • Drives Claspo's client-side Angular singletons (window.ClaspoDashboardSDK and window.ClaspoEditorSDK) directly via OpenCLI Browser Bridge, reusing the active authenticated Chrome session (zero session drift).
  • Recursively parses Claspo's ClDocumentI AST across all step views into structured JSON.
  • Hermetic unit tests (node --test commands.test.mjs, 12/12 passing) covering ID validation, format fallbacks, rules parsing, analytics calculation, and AST component extraction.
  • Fully validated via opencli validate claspo (10 commands validated, 0 errors, 0 warnings).
  • Verified end-to-end against live Claspo production dashboard.

Licensing Note

The plugin repository is licensed under GPL-3.0-or-later and depends on @jackwener/opencli as a peer dependency. Nothing GPL is proposed for this repository — this documentation listing PR is contributed under Apache-2.0 per CONTRIBUTING.md.

Type of Change

  • 🐛 Bug fix
  • ✨ New feature
  • 🌐 New site adapter
  • 📝 Documentation
  • ♻️ Refactor
  • 🔧 CI / build / tooling

Checklist

  • I ran the checks relevant to this PR
  • I updated tests or docs if needed
  • I included output or screenshots when useful

Verification Proof

$ opencli plugin install github:vecyang1/opencli-plugin-claspo
✅ Plugin "claspo" installed successfully. Commands are ready to use.

$ opencli claspo --help
Usage: opencli claspo <command> [args] [options]

appearance, get, list, patch, publish, rules, analytics, duplicate, rename, delete

Commands:
  analytics <widget-id>          [read] Retrieve detailed analytics performance metrics for a specific widget.
  appearance <widget-id>         [read] Inspect the live appearance document, multi-step views, and text/action components of a widget.
  delete <widget-id> [options]   [write] Delete a Claspo widget. Requires --yes confirmation flag.
  duplicate <widget-id> [options] [write] Duplicate (clone) an existing Claspo widget.
  get <widget-id>                [read] Get full configuration, targeting rules, and variants of a specific Claspo widget.
  list                           [read] List all Claspo widgets with their status, views, submissions, and conversion rates.
  patch <widget-id> [options]    [write] Programmatically update text copy or properties of a widget appearance and save it.
  publish <widget-id> [options]  [write] Publish or unpublish a Claspo widget on the live website.
  rename <widget-id> <name>      [write] Rename a Claspo widget.
  rules <widget-id>              [read] Inspect display frequency, triggers, schedule, and targeting rules for a Claspo widget.

$ opencli validate claspo
opencli validate: PASS
Checked 10 command(s)
Errors: 0  Warnings: 0

$ npm test
ℹ tests 12
ℹ suites 7
ℹ pass 12
ℹ fail 0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant