Skip to content

Commit 5e91cec

Browse files
docs(api): hide models sidebar in Scalar reference (#3459)
Pass `hideModels: true` to the Scalar apiReference middleware so the public `/api/docs` no longer exposes the internal Models tree (Mongoose-derived shapes, error envelopes, intermediate DTOs). Schemas are still documented inline on each endpoint — the Models section just leaks implementation detail without helping API consumers. Stack-side default — every downstream project benefits without extra config. Closes #3458
1 parent 4b8bdcb commit 5e91cec

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

lib/services/express.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ const initSwagger = (app) => {
9292
'/api/docs',
9393
apiReference({
9494
spec: { content: spec },
95+
hideModels: true,
9596
}),
9697
);
9798
}

0 commit comments

Comments
 (0)