This repository has been archived by the owner on Oct 14, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: user role update, listing and retrieve
Signed-off-by: Arvindh <[email protected]>
- Loading branch information
1 parent
b13307c
commit dfcfe45
Showing
6 changed files
with
150 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -215,18 +215,17 @@ paths: | |
"500": | ||
$ref: "#/components/responses/ServiceError" | ||
|
||
/users/{userID}/owner: | ||
/users/{userID}/role: | ||
patch: | ||
summary: Updates the user owner. | ||
summary: Updates the user role. | ||
description: | | ||
Updates owner for the user with provided ID. Owner is updated using | ||
authorization token and a new owner identifier received in request. | ||
Updates role for the user with provided ID. | ||
tags: | ||
- Users | ||
parameters: | ||
- $ref: "#/components/parameters/UserID" | ||
requestBody: | ||
$ref: "#/components/requestBodies/UserUpdateOwnerReq" | ||
$ref: "#/components/requestBodies/UserUpdateRoleReq" | ||
security: | ||
- bearerAuth: [] | ||
responses: | ||
|
@@ -299,8 +298,6 @@ paths: | |
authorization token and the new received info. | ||
tags: | ||
- Users | ||
parameters: | ||
- $ref: "#/components/parameters/UserID" | ||
requestBody: | ||
$ref: "#/components/requestBodies/UserUpdateSecretReq" | ||
security: | ||
|
@@ -1264,13 +1261,14 @@ components: | |
- old_secret | ||
- new_secret | ||
|
||
UserOwner: | ||
UserRole: | ||
type: object | ||
properties: | ||
owner: | ||
role: | ||
type: string | ||
example: [email protected] | ||
description: User owner for example email address. | ||
enum: ["admin","user"] | ||
example: user | ||
description: User role example. | ||
required: | ||
- owner | ||
|
||
|
@@ -1658,13 +1656,13 @@ components: | |
schema: | ||
$ref: "#/components/schemas/UserSecret" | ||
|
||
UserUpdateOwnerReq: | ||
UserUpdateRoleReq: | ||
description: JSON-formated document describing the owner of user to be update | ||
required: true | ||
content: | ||
application/json: | ||
schema: | ||
$ref: "#/components/schemas/UserOwner" | ||
$ref: "#/components/schemas/UserRole" | ||
|
||
GroupCreateReq: | ||
description: JSON-formatted document describing the new group to be registered | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters