API-35: More swagger stuff

This commit is contained in:
Patrick Müller 2022-01-08 17:32:55 +01:00
parent c18b84e9ff
commit b3abeaa264
Signed by: Paddy
GPG Key ID: 37ABC11275CAABCE
3 changed files with 28 additions and 2 deletions

2
app.ts
View File

@ -37,7 +37,7 @@ app.use(
swaggerUi.serve, swaggerUi.serve,
swaggerUi.setup(undefined, { swaggerUi.setup(undefined, {
swaggerOptions: { swaggerOptions: {
url: '/public/swagger.json' url: '/swagger.json'
} }
}) })
); );

26
swagger.json Normal file
View File

@ -0,0 +1,26 @@
{
"components": {
"examples": {},
"headers": {},
"parameters": {},
"requestBodies": {},
"responses": {},
"schemas": {},
"securitySchemes": {}
},
"info": {
"title": "plutodev_express_api",
"version": "1.0.0",
"license": {
"name": "ISC"
},
"contact": {}
},
"openapi": "3.0.0",
"paths": {},
"servers": [
{
"url": "/"
}
]
}

View File

@ -2,7 +2,7 @@
"entryFile": "app.ts", "entryFile": "app.ts",
"noImplicitAdditionalProperties": "throw-on-extras", "noImplicitAdditionalProperties": "throw-on-extras",
"spec": { "spec": {
"outputDirectory": "public", "outputDirectory": ".",
"specVersion": 3 "specVersion": 3
} }
} }