connect

A connection procedure for linking AgentKeeper to an AgentKeeper account. It supports a browser-based approval flow or a supplied API key, then installs hooks so Claude Code can send activity events to the AgentKeeper service.

In plain words
What is it for?
Connecting an account, configuring API-key authentication for CI or managed computers, and installing the required Claude Code hooks.
Why use it?
It explains how to authenticate the tool and enable its monitoring connection on a workstation or in automated environments.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/rad-security/claude-code-plugin/connect
Any agent
npx skills add rad-security/claude-code-plugin --skill connect
Clone the repo
git clone --depth 1 https://github.com/rad-security/claude-code-plugin

Made for: Claude Code, Codex.

Per session 63 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 6,087 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 3 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00063 $0.06087
Opus 5 $0.00032 $0.03044
Sonnet 5 $0.00013 $0.01217
Haiku 4.5 $0.00006 $0.00609

Measured yesterday against content hash 7443542e545b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade C, and why

connect scanned grade C with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

chmod 600 "$AGENTKEEPER_DIR/api_key"

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

grep -q 'agentkeeper\.dev' "$HOME/.claude/settings.json" 2>/dev/null && echo "HOOKS_EXIST" || echo "NO_HOOKS"

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

HTTP_CODE=$(curl -s -o /dev/null -w "%{http_code}" --max-time 10 \
plugins/agentkeeper/skills/connect/SKILL.md · 597 lines

How it starts

The opening of the file, as written. The whole thing — 597 lines — stays where its author put it; the contents beside it link to each section on GitHub.

AgentKeeper Connect

You are helping the user connect the AgentKeeper plugin to their www.agentkeeper.dev account. There are two paths:

  • Interactive (default): device-code browser flow. Open a URL, user approves in browser, we receive the key and install hooks.
  • Headless (--api-key <key>): user supplies an existing API key inline. Validate it server-side, store, install hooks. No browser, no prompts. Required for CI, fleet provisioning (Kanji / Ontra), and SSO-managed laptops where the browser flow is blocked.

After either path succeeds, HTTP hooks are installed into ~/.claude/settings.json so Claude Code natively sends hook events to the AgentKeeper API.

Step 0: Parse Arguments

Check the user's slash command invocation for flags:

  • If the invocation is /agentkeeper:connect --api-key <KEY> or /agentkeeper:connect --api-key=<KEY>: take the headless path (Step 1B). The <KEY> value is the raw API key string. Never echo it.
  • Otherwise: take the interactive path (Step 1 onward, existing flow).

If --api-key is present but no value follows, print:

The --api-key flag requires a value. Usage:
  /agentkeeper:connect --api-key ak_live_...

Generate a key at https://www.agentkeeper.dev/settings#api-keys

and stop.

Step 1B: Headless --api-key path

  1. Validate the key against the health endpoint. Display a brief message while the request is in flight (do NOT echo the key itself):

    AGENTKEEPER_DIR="$HOME/.agentkeeper-plugin"
    [ -n "$CLAUDE_PLUGIN_DATA" ] && AGENTKEEPER_DIR="$CLAUDE_PLUGIN_DATA"
    mkdir -p "$AGENTKEEPER_DIR"
    HTTP_CODE=$(curl -s -o /dev/null -w "%{http_code}" --max-time 10 \
      "https://www.agentkeeper.dev/api/v1/claude-code/health" \
      -H "Authorization: Bearer PASTE_KEY_HERE")
    echo "$HTTP_CODE"
    

    Replace PASTE_KEY_HERE with the value from the --api-key arg. Do NOT print the key in any output.

  2. If the HTTP status is not 200:

    That API key did not validate. www.agentkeeper.dev returned HTTP [status].
    
    Common causes:
      - Key was revoked or belongs to a deleted org
      - Typo or extra whitespace in the pasted value
      - Wrong environment (staging key vs prod)
    
    Generate a fresh key at https://www.agentkeeper.dev/settings#api-keys
    

    Stop. Do NOT write the key to disk.

Read the full file on GitHub · 597 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 597 lines · 63 tokens per session scan C 7443542e545b

Subscribe to this mod's changes

connect is a skill published in the GitHub repository rad-security/claude-code-plugin (2 stars, last pushed 26d ago), licensed MIT. It adds 63 tokens to every session and 6,087 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it C with 3 findings (asks for root, reads agent configuration directories, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

general-video

Author or edit a custom HyperFrames composition when no specialized workflow fits, or when BRIEF.md sets flow: companion. Use for longer or multi-scene pieces, brand and sizzle reels, montages, static loops, static title cards, footage remixes, and freeform builds. Use motion-graphics instead for a short unnarrated…

heygen-com/hyperframes · 92 tokens

use-agent-browser-for-airi

Test AIRI display-model imports with agent-browser across stage-tamagotchi Electron, stage-web, and stage-pocket mobile web layouts. Use when uploading and verifying contributor-supplied Live2D ZIP, VRM, or MMD ZIP/PMX/PMD files through AIRI's model selector, including onboarding bypass, format-specific import…

moeru-ai/airi · 87 tokens

opencli-sitemap-author

Use when creating or maintaining OpenCLI site sitemaps: agent-facing navigation, page-state, action, workflow, API-reference, pitfall, and fallback knowledge for a website. Use after browser exploration discovers durable site context, when a sitemap is stale, or when promoting local site knowledge into the repo.

jackwener/OpenCLI · 67 tokens

debug-optimize-lcp

Guides debugging and optimizing Largest Contentful Paint (LCP) using Chrome DevTools MCP tools. Use this skill whenever the user asks about LCP performance, slow page loads, Core Web Vitals optimization, or wants to understand why their page's main content takes too long to appear. Also use when the user mentions…

ChromeDevTools/chrome-devtools-mcp · 99 tokens

pinchtab-mcp

Use this skill when a task requires browser automation through PinchTab's MCP server connected to a remote browser instance. Covers navigation, element interaction, data extraction, form filling, multi-step flows, and session management via MCP tools.

pinchtab/pinchtab · 52 tokens

mintlify-preview

Run the public Mintlify product docs site locally for live preview. Use when previewing or iterating on docs under docs/ (.mdx/.md pages, docs.json nav), or when the user says "start the docs", "run mintlify", "preview the docs site".

latitude-dev/latitude-llm · 69 tokens