Browsing Constructs Skill
Purpose
Provide a multi-select UI for browsing and installing packs from the Loa Constructs Registry. Enables composable skill installation per-repo.
Invocation
/constructs- Browse and install packs (default)/constructs browse- Browse available packs with selection UI/constructs install <pack>- Install specific pack directly/constructs list- List installed packs/constructs update- Check for updates/constructs uninstall <pack>- Remove a pack/constructs auth- Check authentication status/constructs auth setup- Set up API key for premium packs
Workflow
Action: auth
Check or set up authentication for premium packs.
auth (no args) - Check Status
.claude/scripts/constructs-auth.sh status
Display authentication status:
- Whether authenticated
- Key source (env var or credentials file)
- Masked key preview
auth setup - Configure API Key
Guide user through API key setup using AskUserQuestion:
{
"questions": [{
"question": "Enter your Constructs API key (get from loa-constructs.dev/account):",
"header": "API Key",
"multiSelect": false,
"options": [
{
"label": "I have my API key ready",
"description": "Paste your sk_... key when prompted"
},
{
"label": "I need to get a key first",
"description": "Opens browser to loa-constructs.dev/account"
},
{
"label": "Skip for now",
"description": "Free packs will still be available"
}
]
}]
}
If user has key, prompt for it and run:
.claude/scripts/constructs-auth.sh setup <api_key>
Action: browse (default)
Phase 0: Check Authentication
First, check auth status to determine which packs to show:
auth_status=$(.claude/scripts/constructs-auth.sh status --json)
is_authenticated=$(echo "$auth_status" | jq -r '.authenticated')
If not authenticated, show a note about premium packs requiring auth.
Phase 1: Fetch Available Packs
Run the browse script to get available packs:
packs_json=$(.claude/scripts/constructs-browse.sh list --json)
This returns a JSON array of packs with:
slug- Pack identifiername- Display namedescription- One-line descriptionskills_count- Number of skills includedtier- "free" or "pro"icon- Emoji icon
Phase 2: Check Installed Packs
Check which packs are already installed:
installed=$(.claude/scripts/constructs-loader.sh list --json 2>/dev/null || echo "[]")
Phase 3: Present Multi-Select UI
Use AskUserQuestion with multiSelect: true to present pack selection.
Build options array from packs JSON. For each pack:
- label:
"{icon} {name} ({skills_count} skills)" - description: Pack description + tier indicator
Example:
{
"questions": [{
"question": "Select packs to install:",
"header": "Packs",
"multiSelect": true,
"options": [
{
"label": "🔮 Observer (6 skills)",
"description": "User truth capture - interviews, personas, journey mapping"
},
{
"label": "⚗️ Crucible (5 skills)",
"description": "Validation & testing - test plans, quality gates"
},
{
"label": "🎨 Artisan (10 skills)",
"description": "Brand/UI craftsmanship - design systems, components"
}
]
}]
}
Important: Mark already-installed packs in the description (e.g., "✓ Installed").
Phase 4: Install Selected Packs
For each selected pack, run installation:
.claude/scripts/constructs-install.sh pack <slug>
Capture output and track:
- Success/failure per pack
- Skills installed
- Commands available
Phase 5: Report Results
Present installation summary:
╭───────────────────────────────────────────────────────────────╮
│ INSTALLATION COMPLETE │
╰───────────────────────────────────────────────────────────────╯
✅ Observer (6 skills installed)
Commands: /interview, /persona, /journey, /pain-points, /user-story, /empathy-map
✅ Crucible (5 skills installed)
Commands: /test-plan, /quality-gate, /acceptance, /regression, /smoke-test
Total: 2 packs, 11 skills
Action: install
Direct installation without UI:
- Validate pack slug provided
- Run:
.claude/scripts/constructs-install.sh pack <pack> - Report result
Action: list
Show installed packs:
.claude/scripts/constructs-loader.sh list
Action: update
Check for newer versions:
.claude/scripts/constructs-loader.sh check-updates
Action: uninstall
Remove installed pack:
- Confirm with user (AskUserQuestion)
- Run:
.claude/scripts/constructs-install.sh uninstall pack <pack> - Report result
Error Handling
| Error | Handling |
|---|---|
| No network | Use cached pack list if available |
| No API key | Show free packs only, note premium requires auth, offer /constructs auth setup |
| Invalid API key | Prompt to re-authenticate with /constructs auth setup |
| Pack not found | Suggest similar packs or list available |
| Premium pack without auth | Explain pack requires subscription, offer auth setup |
| Install fails | Show error, continue with other selections |
Premium Pack Handling
When user selects a premium pack without authentication:
- Check pack tier before installation
- If tier is "pro" and not authenticated:
- Display message: "🔒 {pack_name} requires a subscription"
- Offer options via AskUserQuestion:
- "Set up API key now" →
/constructs auth setup - "Skip this pack" → Continue with free packs only
- "Cancel" → Abort installation
- "Set up API key now" →
UI Guidelines
Pack Selection Display
When building AskUserQuestion options:
- Icon first: Visual differentiation
- Name prominent: Easy scanning
- Count in parens: "(N skills)"
- Description: What it does
- Status: Installed marker if applicable
Maximum Options
AskUserQuestion supports 2-4 options per question. If more than 4 packs available:
- Show top 4 most relevant/popular
- Add "Show more packs..." option
- Chain multiple questions if needed
Tier Indicators
- Free packs: No special indicator
- Pro packs: Add "(Pro)" to label or "🔒 Requires subscription" to description
Per-Repo State
Installed packs go to .claude/constructs/packs/ which is gitignored.
Installation metadata tracked in .constructs-meta.json:
{
"installed_packs": {
"observer": {
"version": "1.0.0",
"installed_at": "2026-01-31T12:00:00Z"
}
}
}
Related Scripts
.claude/scripts/constructs-auth.sh- Authentication management.claude/scripts/constructs-browse.sh- Pack discovery.claude/scripts/constructs-install.sh- Installation.claude/scripts/constructs-loader.sh- Skill loading.claude/scripts/constructs-lib.sh- Shared utilities
Authentication Methods
API keys can be configured in three ways (checked in order):
Environment variable (recommended for CI/CD):
export LOA_CONSTRUCTS_API_KEY=sk_live_xxxxxxxxxxxxCredentials file (recommended for local development):
# Created by /constructs auth setup ~/.loa/credentials.jsonAlternative credentials (legacy):
~/.loa-constructs/credentials.json
Getting an API Key
- Visit https://loa-constructs.dev/account
- Sign in or create an account
- Generate an API key
- Run
/constructs auth setupand paste the key