Semart Api Gateway is Fast, Simple Yet Powerful API Gateway base on Symfony Component that aim to simplify your day
If you want to get more feature that we don't provide, just use Kong
PHP >= 7.2
Redis
Elasticsearch 7.X
PHP Redis Extension
Screenshot use SemartApiSkeleton demo on my Digital Ocean VPS with 1 GB of RAM
git clone https://github.com/KejawenLab/SemartApiGateway.git gateway
cd gateway
cp .env.example .env
cp gateway.yaml.example gateway.yaml
cp routes.yaml.example routes.yaml
cp services.yaml.example services.yaml
cp aggregates.yaml.example aggregates.yaml
composer update
php gateway create-index
php -S localhost:8000 -t public/
Please Check Main Configuration Example, Service Configuration Example and Routes Configuration Example
You can see statistic by call path /gateway/statistic
and the response be like
You can see statistic by call path /gateway/status
and the response be like
Add to crontab
* * * * * php gateway health-check > /dev/null
-
Easy to Install and Configure
-
Api Versioning
-
Public and Private Api
-
Aggregate Query
-
Load Balancer
-
Response Cache
-
Authentication Using JWT
-
Resource Limiter
-
Request Limiter
-
Request Timeout
-
Health Check
-
Statistic
See The Doc
- Trusted IPs
- Implement Load Balancer
- Random Method
- Round Robin Method
- Sticky (Master/Slave) Method
- Weight Method
- Multiple Service Per Route
- Authorization
- Authorization Header (
Bearer
) Forwarder - Trusted Ip List for Internal Call
- Authetication For Internal Call
- Authorization Header (
- Api Versioning Per Service
- Public and Private Api
- Implement Rate Limiter
- Limit Resource (Not Work When Using Random Balancer)
- Limit Request
- Request Timeout
- Implement Health Check
- Statistic Api
- Services Status Api
- Add Docker Support
- Aggregate Query
- Unit Testing
MIT License