-
Notifications
You must be signed in to change notification settings - Fork 1
Platform User Management endpoints
tudorgroza edited this page Apr 6, 2021
·
1 revision
- Endpoint:
GET /v1/users?search=<search>
- The
search
parameter provides free-text search capabilities over user names. - Response (Paginated list of User DTO):
200 | OK
{
"content": [
{
"id": "60252fc2d5efd95ee8890ead",
"name": "Test User 1",
"email": "[email protected]",
"roles": [
{
"projectId": "PROJECT ID",
"role": "CONTRIBUTOR | CONSUMER | ADMIN"
},
...
]
},
...
],
"number": 0,
"size": 20,
"totalElements": 0,
"pageable": {
"sort": {
"sorted": false,
"unsorted": true,
"empty": true
},
"offset": 0,
"pageNumber": 0,
"pageSize": 20,
"paged": true,
"unpaged": false
},
"last": true,
"totalPages": 0,
"sort": {
"sorted": false,
"unsorted": true,
"empty": true
},
"first": true,
"numberOfElements": 0,
"empty": true
}
OR
403 | FORBIDDEN
- If the executing user is not a
super
user or it lacksADMIN
role on at least one project.
- Endpoint:
POST /v1/users
- Payload:
{
"name": "Test User 1", // Mandatory
"email": "[email protected]", // Mandatory
}
- Response (User DTO):
201 | CREATED
{
"id": "60252fc2d5efd95ee8890ead",
"name": "Test User 1",
"email": "[email protected]",
"roles": [
{
"projectId": "PROJECT ID",
"role": "CONTRIBUTOR | CONSUMER | ADMIN"
},
...
]
}
OR
403 | FORBIDDEN
- If the executing user is not a
super
user or it lacksADMIN
role on at least one project.