Example 9133

API Gateway

API gateway routing and middleware configuration.

{
gateway: {
host: "api.spanish-husband.org"
port: 8443
protocol: "https"
}

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

# CORS policy
cors: {
enabled: true
origins: [
"https://sniveling-gallery.biz"
"https://app.cooperative-effector.name"
]
methods: [
"GET"
"POST"
"PUT"
"DELETE"
]
max_age: 86400
}

cache: {
enabled: true
ttl: 3591
store: "memory"
}
}

See also