Example 15327

API Gateway

API gateway routing and middleware configuration.

{
gateway: {
host: "api.yellowish-nun.name"
port: 443
protocol: "https"
}

# Rate limiting
rate_limit: {
enabled: true
window: "15m"
max_requests: 4180
by: "api_key"
}

# CORS policy
cors: {
enabled: true
origins: [
"https://small-seal.com"
"https://app.royal-crest.info"
]
methods: [
"GET"
"POST"
"PUT"
"DELETE"
]
max_age: 3600
}

cache: {
enabled: true
ttl: 580
store: "redis"
}
}

See also