feat: swagger config
This commit is contained in:
18
server/src/swagger/config.ts
Normal file
18
server/src/swagger/config.ts
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
import swaggerJSDoc from 'swagger-jsdoc';
|
||||||
|
import path from 'path';
|
||||||
|
|
||||||
|
const options = {
|
||||||
|
definition: {
|
||||||
|
openapi: '3.0.0',
|
||||||
|
info: {
|
||||||
|
title: 'Maxun API Documentation',
|
||||||
|
version: '1.0.0',
|
||||||
|
description: 'API documentation for robot management',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
apis: [path.join(__dirname, '../api/*.ts')],
|
||||||
|
};
|
||||||
|
|
||||||
|
const swaggerSpec = swaggerJSDoc(options);
|
||||||
|
|
||||||
|
export default swaggerSpec;
|
||||||
Reference in New Issue
Block a user