gsc-cli
Google Search Console CLI for querying Search Console sites, search analytics, sitemaps, and URL Inspection through the official Google Search Console API. Use when you need GSC or Google Search Console data, SEO performance rows, indexed URL status, sitemap status, or a headless OAuth-friendly Search Console command-line wrapper.
What this skill does
# gsc-cli Use the local Google Search Console CLI wrapper for Search Console API work. This skill exists because Google Search Console has an official API but no first-party Search Console CLI. The local wrapper keeps common GSC reads low-noise and makes write-capable sitemap/site actions explicit. ## Quick rules - Prefer read-only OAuth unless the user specifically needs sitemap or site writes. - Do not run `sites add`, `sites delete`, `sitemaps submit`, or `sitemaps delete` with `--execute` unless the user explicitly approved that exact action. - Keep analytics queries narrow: short date ranges first, then expand if needed. - Parse JSON output instead of scraping terminal text. - Read `references/google-search-console-api.md` when endpoint behavior, auth scopes, quotas, or dimensions matter. ## Local setup Prefer the skill-local script over any global or third-party GSC CLI. Primary config path: ```bash ~/.config/gsc-cli/config.json ``` Recommended one-time setup: ```bash <skill-path>/scripts/setup-auth.sh ``` For a headless machine, the OAuth flow prints a Google auth URL. The user opens it in their own browser, grants access, then pastes back the final redirected URL or code. The CLI stores the refresh token in the config file. Setup prerequisites: - Enable the **Google Search Console API** in the same Google Cloud project that owns the OAuth client. - Use a Google OAuth **Desktop app** client, not TV/Limited Input. - Keep the OAuth app internal or in production when possible so refresh tokens do not expire like External Testing grants. - If `doctor` returns `SERVICE_DISABLED`, open the activation URL from the error, enable the API, wait a minute, then retry. ## Commands ### Show name and description ```bash <skill-path>/scripts/gsc-cli info ``` ### Authenticate Read-only access: ```bash <skill-path>/scripts/setup-auth.sh ``` Write-capable access for sitemap/site mutations: ```bash <skill-path>/scripts/gsc-cli auth url --scope full ``` Use a Google OAuth **Desktop app** client for `auth url`. Google's device flow may reject Search Console scopes with `invalid_scope`. `full` permits Search Console write actions such as sitemap submit/delete and site add/delete. It does not provide an API equivalent of the Search Console UI's manual "Request indexing" action for arbitrary normal pages; for normal page discovery, update/submit sitemaps. ### Check auth ```bash <skill-path>/scripts/gsc-cli auth status <skill-path>/scripts/gsc-cli doctor ``` ### List Search Console properties ```bash <skill-path>/scripts/gsc-cli sites list ``` ### Get one property ```bash <skill-path>/scripts/gsc-cli sites get --site 'sc-domain:example.com' ``` ### Query search analytics ```bash <skill-path>/scripts/gsc-cli analytics query \ --site 'sc-domain:example.com' \ --start-date 2026-05-01 \ --end-date 2026-05-31 \ --dimensions query,page \ --type web \ --row-limit 100 ``` Filter examples: ```bash <skill-path>/scripts/gsc-cli analytics query \ --site 'https://www.example.com/' \ --start-date 2026-05-01 \ --end-date 2026-05-31 \ --dimensions page,query \ --filter 'page:contains:/blog/' \ --filter 'device:equals:MOBILE' ``` ### Inspect a URL's Google index status ```bash <skill-path>/scripts/gsc-cli url inspect \ --site 'sc-domain:example.com' \ --url 'https://www.example.com/page' \ --language-code en-US ``` ### Work with sitemaps ```bash <skill-path>/scripts/gsc-cli sitemaps list --site 'sc-domain:example.com' <skill-path>/scripts/gsc-cli sitemaps get --site 'sc-domain:example.com' --sitemap 'https://www.example.com/sitemap.xml' <skill-path>/scripts/gsc-cli sitemaps submit --site 'sc-domain:example.com' --sitemap 'https://www.example.com/sitemap.xml' <skill-path>/scripts/gsc-cli sitemaps submit --site 'sc-domain:example.com' --sitemap 'https://www.example.com/sitemap.xml' --execute ``` ## Workflow 1. Read `references/google-search-console-api.md` if the task needs API details. 2. Run `scripts/gsc-cli info` or `help` if command shape is unclear. 3. Run `auth status` or `doctor` before assuming credentials are usable. 4. Use `sites list` to confirm the exact property string, especially `sc-domain:` versus URL-prefix properties with trailing slash. 5. Query analytics, URL Inspection, or sitemaps with the narrowest useful request. 6. For any write, dry-run first, show the target/action JSON, then use `--execute` only after explicit approval. ## Expected outputs The CLI returns JSON by default. - `sites list` returns `siteEntry` rows with `siteUrl` and `permissionLevel`. - `analytics query` returns GSC `rows` with `keys`, `clicks`, `impressions`, `ctr`, and `position`. - `url inspect` returns `inspectionResult`. - Write commands without `--execute` return a dry-run JSON object. ## Files - Launcher: `scripts/gsc-cli` - Python implementation: `scripts/gsc_cli.py` - Auth helper: `scripts/setup-auth.sh` - API notes and official docs: `references/google-search-console-api.md` - Config storage: `~/.config/gsc-cli/config.json` ## Official Docs - Search Console API reference: `https://developers.google.com/webmaster-tools/v1/api_reference_index` - Authorization: `https://developers.google.com/webmaster-tools/v1/how-tos/authorizing` - Search Analytics query: `https://developers.google.com/webmaster-tools/v1/searchanalytics/query` - URL Inspection index.inspect: `https://developers.google.com/webmaster-tools/v1/urlInspection.index/inspect` - Usage limits: `https://developers.google.com/webmaster-tools/limits` ## When to stop and ask Stop and ask before: - enabling write scope when read-only would be enough - executing site or sitemap mutations - adding broad/backfill analytics loops - changing where credentials are stored
Related in Ads & Marketing
ads
IncludedMulti-platform paid advertising audit and optimization skill. Analyzes Google, Meta, YouTube, LinkedIn, TikTok, Microsoft, and Apple Ads. 250+ checks with scoring, parallel agents, industry templates, and AI creative generation.
banana
IncludedAI image generation Creative Director powered by Google Gemini Nano Banana models. Use this skill for ANY request involving image creation, editing, visual asset production, or creative direction. Triggers on: generate an image, create a photo, edit this picture, design a logo, make a banner, visual for my anything, and all /banana commands. Handles text-to-image, image editing, multi-turn creative sessions, batch workflows, and brand presets.
rpg-migration-analyzer
IncludedAnalyzes legacy RPG (Report Program Generator) programs from AS/400 and IBM i systems for migration to modern Java applications. Extracts business logic from RPG III/IV/ILE source code, identifies data structures (D-specs), file operations (F-specs), program dependencies (CALLB/CALLP), and converts RPG constructs to Java equivalents. Generates migration reports, complexity estimates, and Java implementation strategies with POJO classes, JPA entities, and service methods. Use when modernizing AS/400 or IBM i legacy systems, analyzing RPG source files (.rpg, .rpgle, .RPGLE), converting RPG to Java, mapping data specifications to Java classes, planning legacy system migration, or when user mentions RPG analysis, Report Program Generator, RPG III/IV/ILE, AS/400 modernization, IBM i migration, packed decimal conversion, or mainframe application rewrite.
brand-library-architect
IncludedBuild a complete brand library for a product — visual asset render pipeline, brand documentation set (BRAND, COPY, MANIFESTO, BIOS, FAQ, GLOSSARY, TONE, PRICING), open-source convention files (README, CONTRIBUTING, SECURITY, CODE_OF_CONDUCT), and a self-contained press kit. This skill should be used when the user asks to "build a brand library / brand kit / press kit / brand assets" for a product, "set up a brand library workflow," "create a positioning manifesto plus visual identity," or any combination of brand documentation + visual asset pipeline. Apply phase-by-phase or run end-to-end. Templates are product-agnostic and use {{TOKEN}} placeholders the skill prompts the user to fill.
writing-tech-post
IncludedAuthors engineering blog posts end-to-end: launch deep-dives, incident postmortems, architecture migrations, performance case studies, tutorials, AI/agent system writeups, security disclosures, and research-to-product translations. Picks the correct archetype, plans the abstraction ladder, enforces an evidence cadence (diagrams, benchmarks, profiles, traces, code, ablations), tunes voice against publisher house styles (Datadog, Vercel, GitHub, AWS, Meta, Cloudflare, Jane Street), and runs a pre-publish gate for narrative momentum and disclosure ethics. Use when drafting a new engineering post, restructuring a draft that feels flat, deciding which evidence form belongs where, validating that depth and product context are balanced, or preparing a postmortem, migration, or performance narrative for external publication. Do not use for API reference documentation, README authoring, marketing copy, release notes, generic SEO content, ghost-written executive thought leadership, or non-engineering long-form essays.
blog-google
IncludedGoogle API integration for blog performance: PageSpeed Insights, CrUX Core Web Vitals with 25-week history, Search Console performance, URL Inspection, Indexing API, GA4 organic traffic, NLP entity analysis for E-E-A-T, YouTube video search for embedding, and Google Ads Keyword Planner. Progressive feature availability based on credential tier (API key, OAuth/service account, GA4, Ads). Shares config with claude-seo at ~/.config/claude-seo/google-api.json. Use when user says "google data", "page speed", "core web vitals", "search console", "indexation", "GA4", "keyword research", "nlp entities", "blog performance", "youtube search", "google api setup".