Best use case
api-gateway is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
API Gateway pattern for routing. Use for microservices entry.
Teams using api-gateway should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/api-gateway/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How api-gateway Compares
| Feature / Agent | api-gateway | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
API Gateway pattern for routing. Use for microservices entry.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# API Gateway An API Gateway sits between clients (Mobile, Web) and services. It acts as a reverse proxy, accepting all API calls, aggregating the various services required to fulfill them, and returning the appropriate result. ## When to Use - **Microservices**: Essential to hide the complexity of backend services (Service Discovery). - **Cross-Cutting Concerns**: Centralizing Authentication, SSL Termination, Rate Limiting, and Logging. - **Protocol Translation**: Converting HTTP (Client) to gRPC (Internal). ## Core Functionality ### Routing `GET /users` -> User Service `GET /orders` -> Order Service ### Aggregation (BFF - Backend for Frontend) Combining results. One request to Gateway -> Calls User Service + Order Service -> Returns combined JSON. ### Offloading - **Auth**: Validating JWT tokens at the edge. - **Cache**: Serving static or cached responses. ## Common Patterns ### Backend for Frontend (BFF) Creating specific gateways for different clients (e.g., one for Mobile with small payloads, one for Web with rich payloads). ## Best Practices **Do**: - Use mature tools: **Kong**, **Traefik**, **AWS API Gateway**, **Nginx**. - Implement **Rate Limiting** to prevent DoS. - Use **Correlation IDs** for tracing requests across services. **Don't**: - Don't put business logic in the Gateway (It's not a service). - Don't let it become a Single Point of Failure (High Availability is key). ## Troubleshooting | Error | Cause | Solution | | :-------------------- | :------------------------------------ | :------------------------------------------------ | | `502 Bad Gateway` | Upstream service down or unreachable. | Check internal service health and firewall rules. | | `504 Gateway Timeout` | Upstream taking too long. | Optimize service or increase timeout (carefully). | ## References - [Microservices.io - API Gateway](https://microservices.io/patterns/apigateway.html) - [Kong Gateway](https://konghq.com/)
Related Skills
template
Expert [skill-name] assistance covering [feature 1], [feature 2], and [feature 3]. Use when [working with X], [debugging Y], or [implementing Z].
zsh
Zsh shell with oh-my-zsh. Use for terminal shell.
zed
Zed high-performance collaborative editor. Use for fast editing.
xcode
Xcode Apple development IDE with simulators. Use for iOS/macOS development.
webstorm
WebStorm JavaScript IDE with debugging. Use for web development.
webpack
Webpack module bundler with loaders and plugins. Use for bundling.
warp
Warp modern terminal with AI. Use for terminal work.
vscode
Visual Studio Code editor with extensions and debugging. Use for code editing.
vite
Vite fast build tool with HMR. Use for modern frontend builds.
visual-studio
Visual Studio IDE for Windows with debugging and profiling. Use for .NET development.
vim
Vim text editor with motions, macros, and plugins. Use for terminal editing.
turbopack
Turbopack Rust-powered bundler. Use for fast builds.