mirror of
https://github.com/outbackdingo/optimclaw.git
synced 2026-08-31 16:49:34 +00:00
feat(skills): credential specs in skill frontmatter, HTTP tool hardening, mission leases
Skills can now declare API credentials in YAML frontmatter (SkillCredentialSpec, SkillCredentialLocation, SkillOAuthConfig, ProviderRefreshStrategy). Valid specs are registered into SharedCredentialRegistry at startup; the HttpTool auto-injects credentials for matching hosts — same zero-exposure model as WASM tools. HTTP tool security hardening: - Block LLM-provided auth headers for hosts with registered credentials - Return structured authentication_required error for missing credentials - Strip sensitive response headers (Set-Cookie, WWW-Authenticate, Authorization) - Scan response body through LeakDetector before returning to LLM Mission capability leases: registered mission_create/list/fire/pause/resume/delete as a "missions" capability so threads receive leases. Removed routine_* aliases from effect adapter — descriptions mention "routine" for LLM intent mapping. Includes 10 integration tests (tests/skill_credential_injection.rs) covering the full pipeline: YAML parsing → validation → registry → HttpTool wiring → per-user isolation. Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
This commit is contained in:
@@ -21,6 +21,22 @@ activation:
|
||||
- "code-review"
|
||||
- "devops"
|
||||
max_context_tokens: 2000
|
||||
credentials:
|
||||
- name: github_token
|
||||
provider: github
|
||||
location:
|
||||
type: bearer
|
||||
hosts:
|
||||
- "api.github.com"
|
||||
oauth:
|
||||
authorization_url: "https://github.com/login/oauth/authorize"
|
||||
token_url: "https://github.com/login/oauth/access_token"
|
||||
scopes:
|
||||
- "repo"
|
||||
- "read:org"
|
||||
refresh:
|
||||
strategy: reauthorize_only
|
||||
setup_instructions: "Create a personal access token at https://github.com/settings/tokens"
|
||||
---
|
||||
|
||||
# GitHub API Skill
|
||||
|
||||
Reference in New Issue
Block a user