{
"description": "A simple string response",
"content": {
"text/plain": {
"schema": {
"type": "string",
"example": "whoa!"
}
}
},
"headers": {
"X-Rate-Limit-Limit": {
"description": "The number of allowed requests in the current period",
"schema": {
"type": "integer"
}
},
"X-Rate-Limit-Remaining": {
"description": "The number of remaining requests in the current period",
"schema": {
"type": "integer"
}
},
"X-Rate-Limit-Reset": {
"description": "The number of seconds left in the current period",
"schema": {
"type": "integer"
}
}
}
}
I see that I can specify request headers with itty-router-openapi, but not the response headers. With the following definition, I can find "x-foo" request header in generated openapi.json, but not "x-bar" response header.
OpenAPI spec allows the response object to specify headers https://spec.openapis.org/oas/v3.1.0#response-object
I see that I can specify request headers with itty-router-openapi, but not the response headers. With the following definition, I can find
"x-foo"
request header in generated openapi.json, but not"x-bar"
response header.I'm seeing the response type RouteResponse doesn't have a headers field
Is this something one can do in itty-router-openapi? If not, is that something that can be added?