github-url-intercept

github-url-intercept is a skill for Claude Code from rjmurillo/ai-agents. It costs 135 tokens per session (4,285 once invoked), scanned B, original, MIT.

A mandatory pre-change check that searches project memory for the reason an existing system was built before altering it. It follows the Chesterton's Fence idea: understand why something is there before removing or changing it.

In plain words
What is it for?
Use it before changing existing code, constraints, or protocols when you need to find earlier decisions and investigate their purpose.
Why use it?
Changing code without its historical context can break an intentional constraint or repeat an old mistake. The gate requires the agent to recover and record that context before proceeding.

Skill for Claude Code

Written for Claude Code: ${CLAUDE_PLUGIN_ROOT variable. Also seen: reads .claude/ paths.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the project-toolkit plugin — 125 skills, 25 commands, 33 agents, 5 hooks shipped together

Good fit Use it before changing existing code, constraints, or protocols when you need to find earlier decisions and investigate their purpose.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add rjmurillo/ai-agents
Claude Code
/plugin install project-toolkit

Made for: Claude Code.

Or install project-toolkit, the plugin that ships this one along with the rest of its 125 skills, 25 commands, 33 agents, 5 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for github-url-intercept

README.md
[![agentmods](https://agentmods.dev/badge/skills/rjmurillo/ai-agents/github-url-intercept/github.svg)](https://agentmods.dev/skills/rjmurillo/ai-agents/github-url-intercept)
Your own site
<a href="https://agentmods.dev/skills/rjmurillo/ai-agents/github-url-intercept"><img src="https://agentmods.dev/badge/skills/rjmurillo/ai-agents/github-url-intercept/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for github-url-intercept

Your own site · 80×15
<a href="https://agentmods.dev/skills/rjmurillo/ai-agents/github-url-intercept"><img src="https://agentmods.dev/badge/skills/rjmurillo/ai-agents/github-url-intercept.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 135 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,285 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 2 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00135 $0.04285
Opus 5.5 $0.00054 $0.01714
Sonnet 5.5 $0.00027 $0.00857
Haiku 4.5 $0.00014 $0.00428

Measured 22d ago against content hash 70ecfa424711, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

github-url-intercept scanned grade B with 2 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 22d ago.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/gist_routing.py, scripts/test_url_routing.py, scripts/url_validation.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

Reads agent configuration directoriesmediumAgent snooping

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

Input: "would a hook like https://github.com/ruvnet/claude-flow/blob/main/.claude/settings.json help?"

Makes network callslowCapability

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

> Do NOT use `web_fetch`, `curl`, or any browser-based fetch on GitHub URLs.
.claude/skills/github-url-intercept/SKILL.md · 400 lines

How it starts

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

GitHub URL Intercept

CRITICAL: This skill activates AUTOMATICALLY when you see ANY github.com URL. Do NOT use web_fetch, curl, or any browser-based fetch on GitHub URLs. Doing so wastes 1-2.5 MILLION tokens on HTML that provides no useful data.

MANDATORY BEHAVIOR: Parse the URL → Route to API → Return structured JSON.


Quick Reference (Copy-Paste Commands)

When you see a GitHub URL, use these commands immediately:

SCRIPTS_DIR="${CLAUDE_PLUGIN_ROOT:-.claude}/skills/github/scripts"

# PR URL → Use this
python3 "$SCRIPTS_DIR/pr/get_pr_context.py" --pull-request {n} --owner {owner} --repo {repo}

# Issue URL → Use this
python3 "$SCRIPTS_DIR/issue/get_issue_context.py" --issue {n} --owner {owner} --repo {repo}

# File/blob URL → Use this
gh api repos/{owner}/{repo}/contents/{path}?ref={ref}

# Commit URL → Use this
gh api repos/{owner}/{repo}/commits/{sha}

# Gist URL → Use this
gh api gists/{id}

# Comment fragment (#discussion_r{id}) → Use this
gh api repos/{owner}/{repo}/pulls/comments/{id}

Triggers

Phrase Action
Any github.com URL in user input (even bare URL pasted alone) Parse URL type and route to API
analyze / research / scan + GitHub URL Route based on URL type
URL + question (e.g., "...#r123 what's the tracking issue?") Extract fragment, call specific API
Multiple GitHub URLs in one prompt Process each URL, batch API calls

When to Use

Use this skill when:

  • Any github.com URL appears in user input (automatic activation)
  • User pastes a PR, issue, commit, file, or actions URL
  • User asks to "analyze" or "review" a GitHub link

Use github instead when:

  • Performing mutations (creating PRs, posting comments, adding labels)
  • Operating on the current repository without a URL

URL Patterns (Detailed Reference)

Pattern Example Why Intercept
github.com/.../pull/ https://github.com/owner/repo/pull/123 PR HTML is 5-10MB
github.com/.../pull/.../checks https://github.com/owner/repo/pull/123/checks?check_run_id=... CI checks page bloat
github.com/.../pull/.../files or /changes https://github.com/owner/repo/pull/123/files#r123456 Diff view with comment fragment
github.com/.../issues/ https://github.com/owner/repo/issues/456 Issue HTML is 2-5MB
github.com/.../actions/runs/ https://github.com/owner/repo/actions/runs/123/job/456 Workflow run page bloat
github.com/.../blob/ https://github.com/owner/repo/blob/main/file.py File page has nav bloat
github.com/.../tree/ https://github.com/owner/repo/tree/main/src Directory listing bloat
github.com/.../commit/ https://github.com/owner/repo/commit/abc123 Commit page overhead
github.com/.../compare/ https://github.com/owner/repo/compare/main...feat Diff page overhead
gist.github.com/... https://gist.github.com/owner/0123456789abcdef0123 Gist HTML includes page chrome
gist.githubusercontent.com/... https://gist.githubusercontent.com/owner/0123456789abcdef0123/raw/file.txt Raw gist content
Fragment #discussion_r{id} Review comment ID in /changes or /files URL Extract ID, call API directly
Fragment #issuecomment-{id} Issue comment ID Extract ID, call API directly
Fragment #pullrequestreview-{id} Review ID Extract ID, call API directly
Fragment #r{id} (short form) Review comment in /changes#r123 Same as #discussion_r{id}

Read the full file on GitHub · 400 lines

Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 22d ago Changed · +5 lines 70ecfa424711
  2. 25d ago Changed · +2 lines 8d9479cacd50
  3. 1mo ago First seen · 393 lines · 135 tokens per session scan B 598a7fda8d4d

Subscribe to this mod's changes

github-url-intercept is a skill published in the GitHub repository rjmurillo/ai-agents (48 stars, last pushed today), licensed MIT. It adds 135 tokens to every session and 4,285 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it B with 2 findings (reads agent configuration directories, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.