{"id":"a9ad8f7a-53d2-44a0-9796-719cfc9c489e","shortId":"FfvWEW","kind":"skill","title":"specstory-project-stats","tagline":"Fetch project statistics from SpecStory Cloud. Run when user says \"get project stats\", \"show SpecStory stats\", \"project statistics\", \"how many sessions\", or \"SpecStory metrics\".","description":"# SpecStory Project Stats\n\nFetches project statistics from SpecStory's cloud platform, showing contributor counts, session activity, and other project metrics.\n\n## How It Works\n\n1. **Identifies** the project via `.specstory/.project.json`, git remote, or folder name\n2. **Calls** the SpecStory Cloud API\n3. **Returns** project statistics in JSON format\n4. **Presents** the data in a readable summary\n\n## Prerequisites\n\n- Project must be synced to SpecStory Cloud\n- Node.js must be available to run the script\n\n## Usage\n\n### Slash Command\n\n| User says | Action |\n|-----------|--------|\n| `/specstory-project-stats` | Fetch stats for current project |\n| `/specstory-project-stats` | Same as above (no arguments needed) |\n\n### Direct Script Usage\n\n```bash\n# Fetch stats for current project\nnode skills/specstory-project-stats/scripts/get-stats.js\n\n# With custom API endpoint (for development)\nSPECSTORY_API_URL=http://localhost:5173 node skills/specstory-project-stats/scripts/get-stats.js\n```\n\n## Output\n\nThe script outputs JSON with project statistics:\n\n```json\n{\n  \"project_id\": \"specstoryai/agent-skills\",\n  \"sessions\": {\n    \"total\": 156,\n    \"last_30_days\": 47,\n    \"last_7_days\": 12\n  },\n  \"contributors\": {\n    \"total\": 5,\n    \"active_last_30_days\": 3\n  },\n  \"activity\": {\n    \"first_session\": \"2025-10-15\",\n    \"last_session\": \"2026-01-28\",\n    \"avg_sessions_per_week\": 8.2\n  }\n}\n```\n\n## Project ID Resolution\n\nThe script determines project ID in this order:\n\n1. **`.specstory/.project.json`** - Uses `git_id` or `workspace_id` field\n2. **Git remote** - Extracts repo name from `origin` remote URL\n3. **Folder name** - Falls back to current directory name\n\n## Error Handling\n\n| Error | Meaning | Action |\n|-------|---------|--------|\n| 404 | Project not found | Project needs to sync to SpecStory Cloud first |\n| 401 | Unauthorized | API endpoint may require authentication |\n| Network error | Can't reach API | Check internet connection |\n\n## Present Results to User\n\nAfter fetching stats, present them in a friendly format:\n\n### Example Response (success)\n\n```\nHere are the stats for **specstoryai/agent-skills**:\n\n**Sessions**\n- Total: 156 sessions captured\n- Last 30 days: 47 sessions\n- Last 7 days: 12 sessions\n\n**Contributors**\n- Total: 5 contributors\n- Active recently: 3\n\n**Activity**\n- First session: October 15, 2025\n- Most recent: January 28, 2026\n- Average: ~8 sessions per week\n\nYour project has been actively using AI-assisted coding!\n```\n\n### Example Response (404 error)\n\n```\nThis project doesn't exist on SpecStory Cloud yet.\n\nTo get started:\n1. Make sure you have SpecStory installed\n2. Run `specstory sync` to push your local sessions to the cloud\n3. Try this command again\n\nNeed help? Check the docs at https://docs.specstory.com\n```\n\n## Environment Variables\n\n| Variable | Default | Description |\n|----------|---------|-------------|\n| `SPECSTORY_API_URL` | `https://cloud.specstory.com` | API endpoint |\n\n## Notes\n\n- Statistics are fetched from SpecStory Cloud, not local history\n- Project must have synced sessions to show meaningful stats\n- The API is public and doesn't require authentication for basic stats","tags":["specstory","project","stats","agent","skills","specstoryai","agent-skills","claude-code-plugin"],"capabilities":["skill","source-specstoryai","skill-specstory-project-stats","topic-agent-skills","topic-claude-code-plugin","topic-skills"],"categories":["agent-skills"],"synonyms":[],"warnings":[],"endpointUrl":"https://skills.sh/specstoryai/agent-skills/specstory-project-stats","protocol":"skill","transport":"skills-sh","auth":{"type":"none","details":{"cli":"npx skills add specstoryai/agent-skills","source_repo":"https://github.com/specstoryai/agent-skills","install_from":"skills.sh"}},"qualityScore":"0.462","qualityRationale":"deterministic score 0.46 from registry signals: · indexed on github topic:agent-skills · 24 github stars · SKILL.md body (3,139 chars)","verified":false,"liveness":"unknown","lastLivenessCheck":null,"agentReviews":{"count":0,"score_avg":null,"cost_usd_avg":null,"success_rate":null,"latency_p50_ms":null,"narrative_summary":null,"summary_updated_at":null},"enrichmentModel":"deterministic:skill-github:v1","enrichmentVersion":1,"enrichedAt":"2026-04-22T01:01:28.829Z","embedding":null,"createdAt":"2026-04-18T22:23:47.185Z","updatedAt":"2026-04-22T01:01:28.829Z","lastSeenAt":"2026-04-22T01:01:28.829Z","tsv":"'-01':183 '-10':178 '-15':179 '-28':184 '/specstory-project-stats':106,112 '1':52,201,348 '12':165,297 '15':310 '156':157,286 '2':63,210,355 '2025':177,311 '2026':182,316 '28':315 '3':69,173,220,305,367 '30':159,171,290 '4':76 '401':246 '404':234,334 '47':161,292 '5':168,301 '5173':140 '7':163,295 '8':318 '8.2':189 'action':105,233 'activ':44,169,174,303,306,326 'ai':329 'ai-assist':328 'api':68,132,137,248,258,385,388,410 'argument':117 'assist':330 'authent':252,417 'avail':95 'averag':317 'avg':185 'back':224 'bash':122 'basic':419 'call':64 'captur':288 'check':259,374 'cloud':10,38,67,91,244,343,366,396 'cloud.specstory.com':387 'code':331 'command':102,370 'connect':261 'contributor':41,166,299,302 'count':42 'current':110,126,226 'custom':131 'data':79 'day':160,164,172,291,296 'default':382 'descript':383 'determin':195 'develop':135 'direct':119 'directori':227 'doc':376 'docs.specstory.com':378 'doesn':338,414 'endpoint':133,249,389 'environ':379 'error':229,231,254,335 'exampl':275,332 'exist':340 'extract':213 'fall':223 'fetch':5,32,107,123,267,393 'field':209 'first':175,245,307 'folder':61,221 'format':75,274 'found':237 'friend':273 'get':15,346 'git':58,204,211 'handl':230 'help':373 'histori':399 'id':153,191,197,205,208 'identifi':53 'instal':354 'internet':260 'januari':314 'json':74,147,151 'last':158,162,170,180,289,294 'local':362,398 'localhost':139 'make':349 'mani':24 'may':250 'mean':232 'meaning':407 'metric':28,48 'must':86,93,401 'name':62,215,222,228 'need':118,239,372 'network':253 'node':128,141 'node.js':92 'note':390 'octob':309 'order':200 'origin':217 'output':143,146 'per':187,320 'platform':39 'prerequisit':84 'present':77,262,269 'project':3,6,16,21,30,33,47,55,71,85,111,127,149,152,190,196,235,238,323,337,400 'public':412 'push':360 'reach':257 'readabl':82 'recent':304,313 'remot':59,212,218 'repo':214 'requir':251,416 'resolut':192 'respons':276,333 'result':263 'return':70 'run':11,97,356 'say':14,104 'script':99,120,145,194 'session':25,43,155,176,181,186,284,287,293,298,308,319,363,404 'show':18,40,406 'skill' 'skill-specstory-project-stats' 'skills/specstory-project-stats/scripts/get-stats.js':129,142 'slash':101 'source-specstoryai' 'specstori':2,9,19,27,29,36,66,90,136,243,342,353,357,384,395 'specstory-project-stat':1 'specstory/.project.json':57,202 'specstoryai/agent-skills':154,283 'start':347 'stat':4,17,20,31,108,124,268,281,408,420 'statist':7,22,34,72,150,391 'success':277 'summari':83 'sure':350 'sync':88,241,358,403 'topic-agent-skills' 'topic-claude-code-plugin' 'topic-skills' 'total':156,167,285,300 'tri':368 'unauthor':247 'url':138,219,386 'usag':100,121 'use':203,327 'user':13,103,265 'variabl':380,381 'via':56 'week':188,321 'work':51 'workspac':207 'yet':344","prices":[{"id":"4bd47556-784d-4083-a889-596672bfa43c","listingId":"a9ad8f7a-53d2-44a0-9796-719cfc9c489e","amountUsd":"0","unit":"free","nativeCurrency":null,"nativeAmount":null,"chain":null,"payTo":null,"paymentMethod":"skill-free","isPrimary":true,"details":{"org":"specstoryai","category":"agent-skills","install_from":"skills.sh"},"createdAt":"2026-04-18T22:23:47.185Z"}],"sources":[{"listingId":"a9ad8f7a-53d2-44a0-9796-719cfc9c489e","source":"github","sourceId":"specstoryai/agent-skills/specstory-project-stats","sourceUrl":"https://github.com/specstoryai/agent-skills/tree/main/skills/specstory-project-stats","isPrimary":false,"firstSeenAt":"2026-04-18T22:23:47.185Z","lastSeenAt":"2026-04-22T01:01:28.829Z"}],"details":{"listingId":"a9ad8f7a-53d2-44a0-9796-719cfc9c489e","quickStartSnippet":null,"exampleRequest":null,"exampleResponse":null,"schema":null,"openapiUrl":null,"agentsTxtUrl":null,"citations":[],"useCases":[],"bestFor":[],"notFor":[],"kindDetails":{"org":"specstoryai","slug":"specstory-project-stats","github":{"repo":"specstoryai/agent-skills","stars":24,"topics":["agent-skills","claude-code-plugin","skills"],"license":"apache-2.0","html_url":"https://github.com/specstoryai/agent-skills","pushed_at":"2026-01-31T01:24:32Z","description":"SpecStory's official collection of agent skills. Summarize, organize and create with `.specstory/history`","skill_md_sha":"3b3f7d990604f83ddda6a8f097ce4f594aa1f032","skill_md_path":"skills/specstory-project-stats/SKILL.md","default_branch":"main","skill_tree_url":"https://github.com/specstoryai/agent-skills/tree/main/skills/specstory-project-stats"},"layout":"multi","source":"github","category":"agent-skills","frontmatter":{"name":"specstory-project-stats","license":"Apache-2.0","description":"Fetch project statistics from SpecStory Cloud. Run when user says \"get project stats\", \"show SpecStory stats\", \"project statistics\", \"how many sessions\", or \"SpecStory metrics\"."},"skills_sh_url":"https://skills.sh/specstoryai/agent-skills/specstory-project-stats"},"updatedAt":"2026-04-22T01:01:28.829Z"}}