openapi-gateway-0.1.4 is not a library.
OpenAPI Gateway
API Gateway that build its routes via OpenAPI specification.
Hot reloading of OpenAPI files is supported with reload_cron
(see Config).
This project simplifies orchestration of services that work with OpenAPI.
Config
# openapi-gateway-config.toml
# Refresh every minute
= "* * * * *"
[[]]
= "Swagger petstore example V2#JSON"
= "https://petstore.swagger.io/v2/swagger.json"
[[]]
= "Swagger petstore example V2#YAML"
= "https://petstore.swagger.io/v2/swagger.yaml"
[[]]
= "Swagger petstore example V3#JSON"
= "https://petstore3.swagger.io/api/v3/openapi.json"
[[]]
= "Swagger petstore example V3#YAML"
= "https://petstore3.swagger.io/api/v3/openapi.yaml"
Start project
Cargo run
cargo run
Cargo install
cargo install openapi-gateway
openapi-gateway
After project setup
Open http://127.0.0.1:8080/docs/
to find the configured routes.
Open points
- Metrics
- Docker
- Tags based inclusion/exclusion