ApiParam with nested type is transformed in query instead of path
thiagotognoli opened this issue · 1 comments
thiagotognoli commented
Is there an existing issue for this?
- I have searched the existing issues
Current behavior
When I use ApiParam with a Class as type the ApiProperties of the Class are mapped as query instead of 'path'.
"/cats/{id}": { "get": { "operationId": "CatsController_findOne", "parameters": [ { "required": true, "name": "id", "in": "query", "schema": { "type": "string" } } ], "responses": { "200": { "description": "The found record" } }, "tags": [ "cats" ] } }
Minimum reproduction code
https://github.com/thiagotognoli/nestjs_swagger_apiparam_bug_sample
Steps to reproduce
- npm i
- npm start:dev
- http://localhost:3000/api-json
Expected behavior
Class ApiProperties must be mapped as in: "path"
Package version
7.4.0
NestJS version
10.4.1
Node.js version
20
In which operating systems have you tested?
- macOS
- Windows
- Linux
Other
No response
kamilmysliwiec commented
Let's track this here #3062