feat(adapters): add capability flags to ServerAdapterModule #2

Closed
farhoodliquor-paperclip[bot] wants to merge 2 commits from feat/adapter-plugin-capabilities into master

2 Commits

Author SHA1 Message Date
Pawla Abdul 0dfb93e898 test+docs: add capability flag tests and documentation
Tests:
- adapter-registry: verify capability flags are exposed, undefined when
  unset, and correctly declared on built-in claude_local adapter
- adapter-routes: verify GET /api/adapters includes capabilities object,
  correct flags for codex_local/process/cursor, and derived supportsSkills

Documentation:
- docs/adapters/creating-an-adapter.md: new "Capability Flags" section
  documenting all flags, their defaults, and usage example for external
  adapter plugins

Co-Authored-By: Paperclip <noreply@paperclip.ing>
2026-04-13 01:26:42 +00:00
Pawla Abdul 904e9cb95e feat(adapters): add capability flags to ServerAdapterModule
Replace 5 hardcoded adapter type lists with declarative capability flags
on ServerAdapterModule, enabling external adapter plugins to declare
their capabilities without modifying Paperclip source.

New optional fields on ServerAdapterModule:
- supportsInstructionsBundle: managed instructions bundle support
- instructionsPathKey: config key for instructions file path
- requiresMaterializedRuntimeSkills: skill materialization needed

Server changes:
- agents.ts: capability-aware helpers with legacy fallbacks
- adapters.ts: expose capabilities in GET /api/adapters response
- registry.ts: explicit flags on all built-in adapters

UI changes:
- New useAdapterCapabilities hook for capability lookups
- AgentDetail.tsx: replace hardcoded isLocal allowlist
- AgentConfigForm.tsx: replace NONLOCAL_TYPES denylist
- OnboardingWizard.tsx: replace NONLOCAL_TYPES denylist

All flags are optional with backwards-compatible fallbacks to the
legacy hardcoded lists for adapters that don't set them.

Co-Authored-By: Paperclip <noreply@paperclip.ing>
2026-04-13 01:09:17 +00:00