/wbLicense — Command Hub
/wbLicense is the WB-Labs licensing and compliance scanner. It reads project dependencies for license compatibility, generates SPDX headers for source files, and produces compliance reports — flagging incompatible combinations before they become legal liabilities. It also enforces the internal __WBC_PRO__ tier-gating pattern across premium components.
🎯 Strategic Position
/wbLicense sits at the boundary between legal and technical. On the OSS side, it prevents you from shipping a package whose dependency tree contains a conflicting license. On the monorepo side, it ensures premium features are properly gated behind Pro/Dev tier checks — preventing free-tier users from wandering into paid functionality by accident.
- After shipping a premium feature — inject the gate on the new file before it reaches consumers.
- Periodically (monthly) — audit a package for tier leaks and pattern drift.
- Before
/wbRelease— verify license compatibility across all dependencies.
🛠️ Operating Modes
| Mode | Trigger | Output |
|---|---|---|
| File gate | /wbLicense <file> | Injected __WBC_PRO__ guard + pro-required event emission |
| Folder audit | /wbLicense <folder> | Tier-leak audit with findings ranked LEAK / INCONSISTENT / OK |
| Self-correct | /wbLicense <previous_output_file> | Verifies and repairs a prior compliance report in place |
✅ What a useful compliance report contains
- Findings ranked by severity — LEAK (Pro code runs for Free users), INCONSISTENT (gate works but pattern differs), OK (correctly gated).
- A "what this audit did NOT check" section — notably runtime bypass, server-side enforcement, business logic.
- Specific file and line references for every gating issue found.
- The next command to run.
🚫 What it cannot do
| Not this | Use instead |
|---|---|
| Runtime security enforcement | /wbSecure |
| Code quality review | /wbAudit |
| Decide which features are Pro | /wbVision |
| Change actual dependency licenses | Manual — /wbLicense only reports incompatible combinations |
__WBC_PRO__ is a client-side convenience barrier. The server must enforce the same tier check independently for actual security. Do not confuse the two.
📚 Reading Order
- ELI5 — the one-paragraph mental model.
- Practical — step-by-step on a real project.
- Expert — architecture, edge cases, and when NOT to use.
- Examples — annotated transcripts from actual sessions.
- Exhaustive simulation · Live demo.
🔗 Related
wbLicense.md— the command reference this hub orients you around./wbSecure— server-side security enforcement./wbAudit— code quality and ship-readiness./wbVision— tier-level feature decisions./wbNext— ranked next action after compliance work.
Quick Reference
/wbLicense <file> # inject __WBC_PRO__ gate on one file
/wbLicense <folder> # audit a package for tier leaks
/wbLicense --scope <path> # narrow the scan← Home · Commands · Install | wb-flow on npm · flow.wbc-ui.com · wi-bg.com
