More Facades, User delete
This commit is contained in:
+37
-6
@@ -126,12 +126,12 @@ paths:
|
||||
value: { "message": "User not Found" }
|
||||
tags:
|
||||
- User
|
||||
post:
|
||||
patch:
|
||||
summary: Update user
|
||||
description:
|
||||
Update user with ID. Fields are updated in order username, password, image. If one fails, subsequent are not updated. <br>
|
||||
Use special ID <code>self</code> to update logged in user. <br>
|
||||
Requires logged in user to have admin permissions for any ID other than <code>self</code>. <br>
|
||||
Requires logged in user to have admin permissions for any ID other than <code>self</code>.
|
||||
security:
|
||||
- BasicAuth: []
|
||||
parameters:
|
||||
@@ -177,17 +177,48 @@ paths:
|
||||
value: { "message": "Failed to update username" }
|
||||
tags:
|
||||
- User
|
||||
delete:
|
||||
summary: Delete user
|
||||
description: Delete user with ID. <br>
|
||||
Requires logged in user to have admin permissions.
|
||||
security:
|
||||
- BasicAuth: []
|
||||
parameters:
|
||||
- name: id
|
||||
in: path
|
||||
description: User ID
|
||||
required: true
|
||||
schema:
|
||||
type: integer
|
||||
format: int14
|
||||
responses:
|
||||
200:
|
||||
description: Success
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/BooleanResponse"
|
||||
examples:
|
||||
Success:
|
||||
value: true
|
||||
404:
|
||||
description: User not Found
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/ErrorResponse"
|
||||
examples:
|
||||
User not Found:
|
||||
value: { "message": "User not Found" }
|
||||
tags:
|
||||
- User
|
||||
|
||||
externalDocs:
|
||||
url: https://khofmann.userpage.fu-berlin.de/phpCourse/exam/api/docs/
|
||||
security: []
|
||||
servers:
|
||||
- url: https://khofmann.userpage.fu-berlin.de/phpCourse/exam/api/
|
||||
description: ""
|
||||
variables: {}
|
||||
components:
|
||||
links: {}
|
||||
callbacks: {}
|
||||
schemas:
|
||||
BooleanResponse:
|
||||
type: boolean
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user