a0dee1d49987dc179eb5460d939ff739ce6c75e5
Added proxy-rewrite plugin to strip /api prefix from requests before
forwarding to backend API microservice. The API service is a standalone
microservice that expects requests without the /api prefix.
Changes:
- Added proxy-rewrite plugin to both API routes:
* /api/llm/* route (priority 20)
* /api/* route (priority 10)
- Uses regex_uri to rewrite: /api/endpoint -> /endpoint
Example transformations:
- /api/health -> /health
- /api/users/123 -> /users/123
- /api/llm/chat -> /llm/chat
Plugin configuration:
proxy-rewrite:
regex_uri:
- "^/api/(.*)"
- "/$1"
This allows the API microservice to work independently without
needing to handle the /api prefix in its routes.
Reference: https://docs.api7.ai/hub/proxy-rewrite/
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
API7 Enterprise Demo
Complete production-ready deployment of API7 Enterprise API Gateway on Kubernetes.
Features
- ✅ API7 Enterprise Gateway with advanced routing and plugins
- ✅ Kubernetes Service Discovery for dynamic backend discovery
- ✅ Automatic TLS with cert-manager and Let's Encrypt
- ✅ Rate Limiting (standard + AI-based for LLM endpoints)
- ✅ CORS policies for browser-based applications
- ✅ Secure Secret Management with External Secrets Operator support
- ✅ CI/CD integration with ArgoCD
- ✅ Complete Documentation with MkDocs
Quick Start
Prerequisites
- Kubernetes cluster (1.24+)
- Helm 3.x
- kubectl configured
- cert-manager installed
- NGINX Ingress Controller
Installation
-
Clone the repository:
git clone https://git.commandware.com/demos/api7-demo.git cd api7-demo -
Create API7 credentials secret:
# Copy the template cp api7-credentials.yaml.template api7-credentials.yaml # Get the admin key from API7 installation kubectl get secret -n api7ee api7ee3-0-1759339083 \ -o jsonpath='{.data.admin_key}' | base64 -d # Edit api7-credentials.yaml and fill in the actual admin key vim api7-credentials.yaml # Apply the secret kubectl apply -f api7-credentials.yaml -n api7ee -
Update values.yaml to use the secret:
api7: gateway: existingSecret: "api7-credentials" -
Deploy with Helm:
helm upgrade --install api7ee-demo helm/api7ee-demo-k8s \ --namespace api7ee \ --create-namespace \ --values values.yaml -
Verify deployment:
kubectl get all -n api7ee kubectl logs -n api7ee job/api7ee-demo-api7ee-demo-k8s-adc-sync curl https://commandware.it/api/health
Documentation
View comprehensive documentation at: web/docs/
Support
Description
Languages
Python
40%
HTML
32.5%
CSS
16.1%
JavaScript
6.2%
Smarty
3.5%
Other
1.7%