Agent Skills › supercheck-io/supercheck › supercheck-integrations-extensions

supercheck-integrations-extensions

GitHub

负责Supercheck浏览器扩展、应用桥接、Chrome/Edge发布、计费授权及第三方集成。涵盖录制架构、安全通信协议、源码构建映射及许可证管理,确保跨端交互的安全性与合规性。

.agents/skills/integrations-extensions/SKILL.md supercheck-io/supercheck

Trigger Scenarios

开发或维护Supercheck Chrome/Edge扩展 处理应用与扩展间的API桥接与安全验证 配置Polar计费与权限体系 集成客户支持聊天工具

Install

npx skills add supercheck-io/supercheck --skill supercheck-integrations-extensions -g -y
More Options

Non-standard path

npx skills add https://github.com/supercheck-io/supercheck/tree/main/.agents/skills/integrations-extensions -g -y

Use without installing

npx skills use supercheck-io/supercheck@supercheck-integrations-extensions

指定 Agent (Claude Code)

npx skills add supercheck-io/supercheck --skill supercheck-integrations-extensions -a claude-code -g -y

安装 repo 全部 skill

npx skills add supercheck-io/supercheck --all -g -y

预览 repo 内 skill

npx skills add supercheck-io/supercheck --list

SKILL.md

Frontmatter
{
    "name": "supercheck-integrations-extensions",
    "description": "Work on the Supercheck recorder extension and app bridge, Chrome or Edge publishing, Polar billing and entitlements, customer support chat, or other third-party integration boundaries."
}

Supercheck integrations and extensions

Recorder architecture

The recorder is an Apache-2.0 browser extension built from Playwright CRX and vendored Playwright source. Supercheck-specific app integration lets users record browser interactions and save generated Playwright tests.

sequenceDiagram
  participant App as Supercheck app
  participant Page as Trusted page API
  participant CS as Content script
  participant BG as Extension worker
  App->>Page: validated connection/recording request
  Page->>CS: exact-origin window message
  CS->>BG: validated extension message
  BG-->>CS: state or generated recording
  CS-->>Page: sender-bound response
  Page-->>App: validated result

Source and build map

Path Responsibility
recorder/src Playwright CRX library/client/server implementation
recorder/playwright Vendored build-required Playwright source and licenses
recorder/examples/recorder-crx Supercheck recorder extension
recorder/examples/recorder-crx/src/supercheck App origin allowlist and message validation (message-security.ts), API client, config
recorder/examples/todomvc-crx Library example
recorder/tests Unit, extension, and browser suites
app/src/components/recorder App UI and auto-connect bridge
app/src/app/api/extension Extension-facing API; key lookup and revocation use a scoped direct query (findEnabledExtensionKeys) because Better Auth's listApiKeys caps unpaginated reads at 100 keys; keep it that way
app/src/app/api/recordings Recording persistence API

Security contract

  • The page bridge/content script accepts only event.source === window, parsed allowed origins, expected protocol/hostname, and schema-valid messages.
  • Allow exactly the configured instance origin (localhost only when it is the configured instance URL) plus the pinned cloud origins; never arbitrary HTTP/HTTPS pages, wildcard subdomains, or a blanket localhost allowance.
  • Use window.location.origin or another verified exact origin as postMessage target; never * for privileged data.
  • Bind return/callback URLs to the verified sender origin and restrict navigated/recorded target protocols.
  • Inject the page API only on trusted Supercheck pages. Do not add broad externally_connectable access.
  • Keep extension permissions/host permissions minimal and validate all background/content/page boundaries independently.
  • Retry only idempotent API methods and preserve authentication/error behavior without exposing tokens.

Licensing and release

  • Preserve recorder/LICENSE, recorder/NOTICE, recorder/playwright/LICENSE, recorder/playwright/NOTICE, and upstream file headers.
  • Do not relicense Playwright-derived recorder files as AGPL. App, worker (including Private Agent mode), and docs remain AGPL-3.0-only. CLI releases from 0.3.1 are Apache-2.0.
  • The vendored source must be enough for a clean reproducible build without another private checkout.
  • Build lint, vendored bundles, generated types, CRX library, recorder/TodoMVC examples, and test extension.
  • Unit security runs on PRs; the recorder browser suite runs weekly (Mondays 04:30 UTC) and on-demand as a release gate. Local browser fixture limitations must be disclosed; CI/Linux and manual installed-extension acceptance remain release gates.
  • Chrome and Edge store descriptions/assets/certification are separate. Edge submission copy must not describe the product as a Chrome extension.
  • Store publishing requires manual account/2FA/reviewer gates and uses canonical listing IDs/URLs from current public docs.

Polar billing

flowchart LR
  ORG[Organization] --> CUSTOMER[Organization-scoped customer]
  CUSTOMER --> SUB[Subscription lifecycle]
  CHECKOUT[Checkout] --> SUB
  WEBHOOK[Verified webhook] --> LEDGER[Idempotent local state]
  USAGE[Durable usage event] --> PROVIDER[Polar meter/event]
  SUB --> ENT[Server-side entitlements]
  • Polar customer identity is organization-scoped, using the current organization external identity. Never collapse multiple organizations under a user-scoped customer.
  • Checkout and customer portal requests authenticate the user, resolve the organization, authorize billing management (normally organization owner), and use configured product/price references.
  • Webhooks verify signatures, deduplicate by provider event identity, tolerate retries/reordering, and update local state transactionally/idempotently.
  • Subscription status, plan, period, cancellation, and entitlement behavior come from durable server state synchronized from verified provider events.
  • Entitlements and limits are enforced server-side. UI labels/buttons are not authorization.
  • Usage is durably recorded server-side before or atomically with provider delivery and retried safely without duplicate billing.
  • Use whole-cent currency arithmetic and explicit units. Never rely on floating-point money or silently mix credits/events/cents.
  • Polling stops on success, terminal failure, cancellation/navigation, and timeout.
  • Never automatically mutate live products/prices, attach overage prices, migrate customers, or make paid actions without explicit authorization and invoice/recovery analysis.
  • Provider product IDs, prices, tax settings, limits, and UI are drift-prone; verify them in the provider environment.

Billing acceptance

  • Test organization isolation, shared-user/multiple-org customer identity, checkout, webhook replay/reordering, upgrade/downgrade, cancellation, expiry, recovery, portal, invoice, usage retries, and entitlement transitions.
  • Automated/local tests do not replace sandbox/live provider acceptance and invoice inspection.

Customer support chat and third parties

  • Load support scripts only when configured; no consent-gate mechanism exists today.
  • Keep tokens and identity-verification secrets server-side. Do not send tenant secrets, auth tokens, sensitive route data, or private incident content to chat by default.
  • Polar is the only signature-verified inbound provider today; support-chat webhooks are not implemented. Apply signature verification, payload validation, rate limiting, and idempotency to any new callback.
  • Provider plan, branding, pricing, privacy, and hosting claims change; verify current terms before product decisions.

Verify

  • Test every trust boundary and cross-tenant denial.
  • Test provider retries, malformed/signed-invalid callbacks, cancellation, cleanup, and redaction.
  • Separate source/unit evidence from browser store, provider account, invoice, and production acceptance.

Version History

  • 8a9bade Current 2026-11-03 04:16
  • 974a753 2026-09-22 16:21

Same Skill Collection

.agents/skills/architecture/SKILL.md
.agents/skills/code-review/SKILL.md
.agents/skills/data-storage/SKILL.md
.agents/skills/execution-engine/SKILL.md
.agents/skills/feature-implementation/SKILL.md
.agents/skills/infrastructure-deployment/SKILL.md
.agents/skills/mcp-server/SKILL.md
.agents/skills/monitoring-alerts/SKILL.md
.agents/skills/platform-features/SKILL.md
.agents/skills/security-auth/SKILL.md
.agents/skills/sre-operations/SKILL.md
.agents/skills/testing-qa/SKILL.md
.agents/skills/ui/SKILL.md
.github/skills/code-review/SKILL.md
.github/skills/docker-compose-deployment/SKILL.md
.github/skills/feature-implementation/SKILL.md

Metadata

Files
0
Version
8a9bade
Hash
11ce3261
Indexed
2026-09-22 16:21

홈 - 위키
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-11-03 21:12
浙ICP备14020137号-1