github-traffic — Claude Code skill: what it does, how to install
Pulls traffic metrics, visitor referrers, and clone counts from GitHub. Stores snapshots locally and generates trend charts.
npx skills add zc277584121/marketing-skills --skill github-traffic -a claude-codeWhat github-traffic does
The skill connects through the authenticated gh CLI to inspect traffic details: page visits, clone activity, referrer sources, and star counts. GitHub restricts traffic history to the previous 14 days. To bypass that window, the script appends records to persistent JSON files in ~/.github-traffic/. This accumulates data for 30-day or 90-day reports.
Visual reporting relies on matplotlib. It outputs PNG panels showing visitor volume, clones, and stars. If the library is missing, the tool generates plain ASCII charts inside the terminal.
Target repositories require write access. Read-only permissions trigger an HTTP 403 error from the GitHub API. Tracking third-party repositories will fail.
What it helps with
- collect visitor views and clone activity for a repository
- preserve traffic data beyond the standard 14-day limit
- identify top external referral sources and popular paths
- render visual trend charts as PNG images or ASCII text
Example prompts for the agent
- Show traffic stats and clone counts for
owner/repo - Generate a 30-day traffic trend chart for
owner/repo - Run a silent snapshot of
owner/repoto update history
How to install github-traffic
1Skills CLI (Vercel)
npx skills add zc277584121/marketing-skills --skill github-traffic -a claude-code2Manually: put the files in place
~/.claude/skills/github-traffic/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/github-traffic/
1Skills CLI (Vercel)
npx skills add zc277584121/marketing-skills --skill github-traffic -a codex2Manually: put the files in place
.agents/skills/github-traffic/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add zc277584121/marketing-skills --skill github-traffic -a cursor2Manually: put the files in place
.cursor/skills/github-traffic/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install zc277584121/marketing-skills github-traffic2Manually: put the files in place
.github/skills/github-traffic/SKILL.md1Skills CLI (Vercel)
npx skills add zc277584121/marketing-skills --skill github-traffic -a gemini-cli2Platform CLI
gemini skills install https://github.com/zc277584121/marketing-skills --path skills/github-trafficManually: put the files in place
.devin/skills/github-traffic/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add zc277584121/marketing-skills --skill github-traffic -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about github-traffic
How to install github-traffic in Claude Code?
Run npx skills add zc277584121/marketing-skills --skill github-traffic -a claude-code in your terminal.
Why does the skill store local snapshots?
GitHub automatically discards traffic logs older than 14 days. Routine snapshots into ~/.github-traffic/ preserve continuity for quarterly reports.
Is matplotlib required to run github-traffic?
No. It is only needed for PNG images. Running with the --ascii flag outputs text charts without extra visualization libraries.