another start commit
This commit is contained in:
+2
-1
@@ -2,12 +2,13 @@ const express = require("express");
|
|||||||
const app = express();
|
const app = express();
|
||||||
const swaggerUi = require('swagger-ui-express');
|
const swaggerUi = require('swagger-ui-express');
|
||||||
const swaggerDocument = require('./swagger.json');
|
const swaggerDocument = require('./swagger.json');
|
||||||
|
const path = require("path");
|
||||||
const port = 3000;
|
const port = 3000;
|
||||||
|
|
||||||
app.use('/swagger-ui', swaggerUi.serve, swaggerUi.setup(swaggerDocument));
|
app.use('/swagger-ui', swaggerUi.serve, swaggerUi.setup(swaggerDocument));
|
||||||
|
|
||||||
app.get("/", (request, respond) => {
|
app.get("/", (request, respond) => {
|
||||||
respond.send("Test")
|
respond.sendFile(path.join(__dirname, 'structure.png'));
|
||||||
});
|
});
|
||||||
|
|
||||||
app.listen(port, () => {
|
app.listen(port, () => {
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 19 KiB |
@@ -0,0 +1,25 @@
|
|||||||
|
{
|
||||||
|
"openapi": "3.0.0",
|
||||||
|
"info": {
|
||||||
|
"title": "GAMBLE!",
|
||||||
|
"description": "Gambling API",
|
||||||
|
"version": "1.0.0"
|
||||||
|
},
|
||||||
|
"servers": [
|
||||||
|
{
|
||||||
|
"url": "http://localhost:3000/"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"paths": {
|
||||||
|
"/": {
|
||||||
|
"get": {
|
||||||
|
"description": "",
|
||||||
|
"responses": {
|
||||||
|
"200": {
|
||||||
|
"description": "OK"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user