Example 2628

API Gateway

API gateway routing and middleware configuration.

{
gateway: {
host: "api.worst-surface.info"
port: 443
protocol: "https"
}

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

# CORS policy
cors: {
enabled: true
origins: [
"https://shameless-characterization.org"
"https://app.smug-essence.org"
]
methods: [
"GET"
"POST"
"PUT"
"DELETE"
]
max_age: 86400
}

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

See also