mirror of
https://github.com/plankanban/planka.git
synced 2025-12-20 01:14:12 +03:00
docs: Add full Swagger JSDoc coverage
This commit is contained in:
@@ -3,6 +3,69 @@
|
||||
* Licensed under the Fair Use License: https://github.com/plankanban/planka/blob/master/LICENSE.md
|
||||
*/
|
||||
|
||||
/**
|
||||
* @swagger
|
||||
* /api/projects:
|
||||
* post:
|
||||
* summary: Create project
|
||||
* description: Creates a project. The current user automatically becomes a project manager.
|
||||
* tags:
|
||||
* - Projects
|
||||
* requestBody:
|
||||
* required: true
|
||||
* content:
|
||||
* application/json:
|
||||
* schema:
|
||||
* type: object
|
||||
* required:
|
||||
* - type
|
||||
* - name
|
||||
* properties:
|
||||
* type:
|
||||
* type: string
|
||||
* enum: [public, private]
|
||||
* description: Type of the project
|
||||
* example: private
|
||||
* name:
|
||||
* type: string
|
||||
* maxLength: 128
|
||||
* description: Name/title of the project
|
||||
* example: Development Project
|
||||
* description:
|
||||
* type: string
|
||||
* maxLength: 1024
|
||||
* nullable: true
|
||||
* description: Detailed description of the project
|
||||
* example: A project for developing new features...
|
||||
* responses:
|
||||
* 200:
|
||||
* description: Project created successfully
|
||||
* content:
|
||||
* application/json:
|
||||
* schema:
|
||||
* type: object
|
||||
* required:
|
||||
* - item
|
||||
* - included
|
||||
* properties:
|
||||
* item:
|
||||
* $ref: '#/components/schemas/Project'
|
||||
* included:
|
||||
* type: object
|
||||
* required:
|
||||
* - projectManagers
|
||||
* properties:
|
||||
* projectManagers:
|
||||
* type: array
|
||||
* description: Related project managers
|
||||
* items:
|
||||
* $ref: '#/components/schemas/ProjectManager'
|
||||
* 400:
|
||||
* $ref: '#/components/responses/ValidationError'
|
||||
* 401:
|
||||
* $ref: '#/components/responses/Unauthorized'
|
||||
*/
|
||||
|
||||
module.exports = {
|
||||
inputs: {
|
||||
type: {
|
||||
|
||||
Reference in New Issue
Block a user