Skip to content

feat: plugin userConfig — API key keychain storage + install UX#74

Open
ChenNima wants to merge 1 commit intodevelopfrom
feat/plugin-userconfig
Open

feat: plugin userConfig — API key keychain storage + install UX#74
ChenNima wants to merge 1 commit intodevelopfrom
feat/plugin-userconfig

Conversation

@ChenNima
Copy link
Copy Markdown
Contributor

@ChenNima ChenNima commented Apr 1, 2026

Summary

  • Add userConfig to plugin manifest: CHORUS_URL (required) + CHORUS_API_KEY (required, sensitive → keychain)
  • .mcp.json uses ${user_config.*} for HTTP MCP server — new users get guided setup on install
  • All hook scripts use env var > CLAUDE_PLUGIN_OPTION_* fallback for backward compat
  • Rewrite SKILL.md setup section: Option A (userConfig), Option B (env vars for headless)
  • Bump plugin version to 0.6.0

Changed files

File Change
plugin.json Add userConfig schema, bump to 0.6.0
marketplace.json Sync version to 0.6.0
.mcp.json ${CHORUS_URL}${user_config.CHORUS_URL}
chorus-api.sh Add chorus_resolve_config() + resolve-config subcommand
on-*.sh (9 files) Centralized config resolution with fallback
test-syntax.sh Add CLAUDE_PLUGIN_OPTION_* mock env vars
SKILL.md Rewrite Setup section

Test plan

  • Bash 3.2 syntax check: 12/12 pass
  • E2E AI-DLC flow via plugin MCP (${user_config.*}): checkin → idea → proposal → task → verify → done
  • Hook scripts work with env var fallback (SessionStart fires correctly)

🤖 Generated with Claude Code

…age (#74)

Migrate plugin configuration from raw environment variables to Claude Code's
native userConfig system. API keys are now stored securely in the system
keychain (sensitive: true), and new users get a guided setup prompt on install.

Changes:
- plugin.json: add userConfig schema (CHORUS_URL required, CHORUS_API_KEY
  required+sensitive), bump version to 0.6.0
- .mcp.json: use ${user_config.*} for HTTP MCP server config
- chorus-api.sh: add chorus_resolve_config() with env var > CLAUDE_PLUGIN_OPTION_* fallback
- All 9 hook scripts: centralized config resolution via fallback pattern
- SKILL.md: rewrite Setup section (Option A: userConfig, Option B: env vars)
- marketplace.json: sync version to 0.6.0
- test-syntax.sh: add CLAUDE_PLUGIN_OPTION_* mock env vars

Backward compatible: env vars always take priority in hook scripts.
Headless environments continue to work with exported env vars.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 1, 2026

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 96.43% (🎯 95%) 1896 / 1966
🔵 Statements 95.43% (🎯 95%) 2048 / 2146
🔵 Functions 95% (🎯 93%) 399 / 420
🔵 Branches 87.55% (🎯 85%) 1266 / 1446
File CoverageNo changed files found.
Generated in workflow #85 for commit 9c5351f by the Vitest Coverage Report Action

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