Update iso-bot skill with Claude Code workflow

This commit is contained in:
Hoid 2026-02-14 11:00:43 +00:00
parent 5d5bdffea6
commit a6afccf123
3 changed files with 46 additions and 4 deletions

19
bin/claude-code Executable file
View file

@ -0,0 +1,19 @@
#!/bin/bash
# Wrapper that sets ANTHROPIC_API_KEY from OpenClaw's auth config
export ANTHROPIC_API_KEY=$(python3 -c "
import json
with open('/home/openclaw/.openclaw/agents/main/agent/auth-profiles.json') as f:
data = json.load(f)
for key, profile in data.get('profiles', {}).items():
if 'anthropic' in key:
print(profile.get('token', ''))
break
" 2>/dev/null)
if [ -z "$ANTHROPIC_API_KEY" ]; then
echo "Error: Could not extract Anthropic API key from auth-profiles.json"
exit 1
fi
export PATH=$PATH:/usr/local/go/bin
exec claude "$@"