Open Ankit1995-appinventiv opened 4 years ago
With swagger-express-ts:v1.1.0
you can now specify headers params
@ApiOperationGet({
path: `/mypath/{name}`,
summary: 'Execute a custom view',
parameters: {
header: {
'x-device-token': {
description: 'The device token',
type: SwaggerDefinitionConstant.Parameter.Type.STRING,
required: true,
},
},
path: {
name: {
description: 'The view name',
type: SwaggerDefinitionConstant.Parameter.Type.STRING,
required: true,
},
},
},
responses: {
200: {
description: 'Success',
type: SwaggerDefinitionConstant.Response.Type.OBJECT,
}
}
})
How can i accept headers like device token.