-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Labels
bugSomething isn't workingSomething isn't working
Description
What's broken?
The uploaded openapi spec to WSO2 is not the same as the one generated during cdk synth. Specifically, boolean values in the example of an api get converted to a string e.g. true becomes "true".
Version used
0.19.1-beta.0
0.16.0
Context
During synthesis an openapi spec is generated. This has the correct specification + example. During deployment the Lambda logs the openapi spec again. This then contains the booleans converted to a string.
From a chat with @MarcioMeier we already figured out that this does not seem to happen for all cases. But the following schema causes this issue for us.
export const responseBodySchema = z
.object({
data: z.object({
var1: z.boolean().optional(),
var2: z.boolean().optional(),
}),
status: z.enum(['success']),
})
.openapi({
example: {
data: {
var1: true,
var2: false,
},
status: 'success',
},
});Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working