api-gateway-troubleshooting
БесплатноЗапускает вложенные скриптыНе проверенDiagnoses failing requests and deployment errors on Google Cloud API Gateway. Use when calls through a gateway return 4xx or 5xx errors, including 429 and…
от google★ 25 380 звёзд на GitHubОб этом скилле
API Gateway Troubleshooting
Use this skill to find out why requests to a deployed Google Cloud API Gateway fail and how to fix them. Work only from three sources of evidence:
- Public Google Cloud documentation, linked from this skill.
- The user's own project, read with the user's own credentials.
- Files and output that the user provides, such as an OpenAPI document, an error response, or a pasted log entry.
Scope
This skill covers only Google Cloud API Gateway. If the question is about Apigee, Cloud Endpoints, or GKE Gateway API, reply that this skill covers only Google Cloud API Gateway, and don't run its steps or commands.
Usage Attribution
MUST READ: Before executing any gcloud, REST API, or MCP command, you
MUST read and follow the instructions in
Usage Attribution.
Ground rules
| Rule | Why |
|---|---|
Stay read-only until the user approves a change. While you diagnose, run only list, describe, get-iam-policy, and logging read commands, plus nslookup and curl GET requests to a path that's safe to call. |
Gateways serve production traffic, and the quota metrics and limits of the most recently created API config apply to every gateway of the API. |
Before any change, show the exact command, what it changes, and how to undo it, then wait for an explicit yes. Changes include IAM grants, api-configs create, gateways update, Cloud Run ingress changes, and gcloud services enable. |
The user owns the project and the change. |
Never fix a 401 or 403 by making a backend public (--allow-unauthenticated, --no-invoker-iam-check, allUsers) or by granting a basic role such as Editor. |
Grant the gateway's service account the invoker role on the one backend instead, which keeps least privilege. |
Keep every log read bounded: filter on the gateway, set --freshness or a timestamp window, and set --limit. |
Unbounded reads are slow and pull in caller data that the diagnosis doesn't need. |
| Redact API keys, bearer tokens, and JWTs before you show log entries, commands, or files. | Request logs and pasted output can contain credentials. |
| Base every limit, default, and error meaning on a linked public doc or on output from the user's project. If neither explains the problem, say so and escalate. | Guessing about undocumented behavior leads to wrong fixes. |
Use the user's existing gcloud login. Never ask for passwords, API key values, or service account key files. |
Credentials don't belong in a chat transcript. |
| For Preview features (streaming, MCP, model routing), check the release notes before answering. | Preview behavior changes between releases. |
Prerequisites
- Google Cloud CLI. Use a recent
gcloud(the commands here were checked with version 591.0.0); see Install the gcloud CLI. Don't install or update software without the user's approval. Ifgcloudisn't available or the user says not to run commands, work in evidence mode: give the user the read-only commands to run, and diagnose from the output, response bodies, and log entries they paste. - Authentication. Use the user's existing
gcloud auth loginsession; this skill doesn't need application-default credentials. - Project. Ask which project hosts the gateway and pass
--project={project_id}on every command. Don't rungcloud config set, because it changes the user's environment. This skill troubleshoots existing gateways and never creates projects. - Billing. The project needs an active billing account even when usage stays in the free tier; see API Gateway pricing.
- APIs. API Gateway requires
apigateway.googleapis.com,servicemanagement.googleapis.com, andservicecontrol.googleapis.com. A gateway can keep responding while one of them is missing, and its logs then stay empty, so check withgcloud services list --enabled --project={project_id}. Enabling a missing API is a change that needs approval. - IAM roles for diagnosis (read-only):
roles/apigateway.viewer,roles/logging.viewer,roles/serviceusage.serviceUsageViewer, androles/iam.serviceAccountViewer(to check the gateway's service account). For Cloud Run backends, addroles/run.viewer; to trace a custom domain through its load balancer, addroles/compute.viewer; to check an API key's project,roles/serviceusage.serviceUsageVieweris also needed there. - IAM roles for fixes (only after approval):
roles/apigateway.admin;roles/iam.serviceAccountUseron the gateway's service account, because creating or updating an API config or a gateway requiresiam.serviceAccounts.actAs;roles/run.adminto change a Cloud Run servic
Установить api-gateway-troubleshooting в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл api-gateway-troubleshooting?
Diagnoses failing requests and deployment errors on Google Cloud API Gateway. Use when calls through a gateway return 4xx or 5xx errors, including 429 and other quota errors, time out, or fail a CORS preflight; when `api-configs create` fails with a service account, concurrency, or limit error, or `gateways create` or `gateways update` fails; when a custom domain, load balancer, or TLS finding involves a gateway; or when the user asks if Google is at fault. Don't use for Apigee, Cloud Endpoints, or GKE Gateway API. For OpenAPI errors from `api-configs create`, use api-gateway-openapi-spec-authoring; for setting up or changing API keys, JWTs, or quotas, use api-gateway-backend-security-and-rate-limiting; for MCP `/mcp` errors, use api-gateway-mcp-server.
Как установить скилл api-gateway-troubleshooting?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл api-gateway-troubleshooting запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic