api-gateway-patterns

Implement Kong API gateway patterns for routing, authentication, and rate limiting.

1|Updated Nov 18, 2025
One-click install
npx skills add https://github.com/manutej/crush-mcp-server --skill api-gateway-patterns-manutej
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: api-gateway-patterns
Source: https://github.com/manutej/crush-mcp-server/tree/main/.claude/skills/api-gateway-patterns
Command: npx skills add https://github.com/manutej/crush-mcp-server --skill api-gateway-patterns-manutej

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill guides the implementation of production-grade API gateway patterns (routing, auth, rate limiting, caching, and observability) for microservices architectures.

Core Features & Use Cases

  • Routing Strategies: Path, header, host-based routing with canary support.
  • Authentication & Security: JWT, API keys, OAuth2 at the gateway level.
  • Observability: Logging, metrics, tracing for API traffic.

Quick Start

Configure a Kong-based gateway with routes and plugins, then validate requests with security and rate limits.

Frequently Asked Questions about api-gateway-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I implement routing rules in an API gateway for microservices?

API gateway routing directs incoming requests to backend services based on path, header, host, or method. Kong-based gateways support path-based, header-based, and host-based routing strategies, including canary deployments. Configure routes to map external URLs to internal service endpoints and apply plugins for authentication and rate limiting.

What authentication methods can I enforce at the gateway level?

Gateway-level authentication includes API keys, JWT tokens, OAuth2, OIDC, and mTLS certificates. These mechanisms validate requests before they reach backend services, reducing load on microservices and centralizing security policy. Kong gateway plugins support all these authentication types with configurable validation rules.

How do I set up rate limiting across multiple consumers in a gateway?

Rate limiting at the gateway enforces request quotas globally or per consumer using plugins. Kong supports time-window-based limits, per-IP throttling, and consumer-specific quotas. Configure thresholds in the gateway to prevent abuse and ensure fair resource allocation across all API consumers.

Can I implement caching and request transformation in the same gateway?

Yes. API gateways like Kong combine caching plugins to store frequent responses with transformation plugins that modify headers and request/response bodies. This reduces backend load, improves latency, and standardizes API contracts across microservices without code changes in services.

What observability features should I add to monitor API gateway traffic?

Gateway observability includes request logging, metrics collection, and distributed tracing. Kong integrates with monitoring tools to export traffic patterns, latency, error rates, and authentication failures. Combine logging plugins, metrics exporters, and tracing agents to track API behavior end-to-end.

How do I configure multi-tenancy routing and certificate management in production?

Multi-tenancy routing isolates tenant traffic by matching request headers or domains to separate backend pools. TLS termination and certificate management at the gateway layer handle encryption for all tenants centrally. Kong supports per-tenant routing rules, SNI-based certificate selection, and automated certificate renewal.