Rework role and channel api
This commit is contained in:
parent
a8ede76571
commit
ea8c175f75
3 changed files with 20 additions and 24 deletions
2
VERSION
2
VERSION
|
|
@ -1 +1 @@
|
||||||
0.3.5
|
0.3.6
|
||||||
|
|
|
||||||
|
|
@ -10,6 +10,7 @@ Returns a channel with id = {id}
|
||||||
{
|
{
|
||||||
"id": "string",
|
"id": "string",
|
||||||
"name": "string",
|
"name": "string",
|
||||||
|
"description": "string",
|
||||||
"communityId": "string",
|
"communityId": "string",
|
||||||
"creationDate": "number"
|
"creationDate": "number"
|
||||||
}
|
}
|
||||||
|
|
@ -36,7 +37,9 @@ Creates a new channel and returns it
|
||||||
{
|
{
|
||||||
"id": "string",
|
"id": "string",
|
||||||
"name": "string",
|
"name": "string",
|
||||||
"communityId": "string"
|
"description": "string",
|
||||||
|
"communityId": "string",
|
||||||
|
"creationDate": "number"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
@ -48,7 +51,8 @@ _Requires an authorization header_
|
||||||
|
|
||||||
```json
|
```json
|
||||||
{
|
{
|
||||||
"name": "string?"
|
"name": "string?",
|
||||||
|
"description": "string?"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
@ -60,7 +64,9 @@ Updates a channel with id = {id}
|
||||||
{
|
{
|
||||||
"id": "string",
|
"id": "string",
|
||||||
"name": "string",
|
"name": "string",
|
||||||
"communityId": "string"
|
"description": "string",
|
||||||
|
"communityId": "string",
|
||||||
|
"creationDate": "number"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -10,25 +10,9 @@ Returns a role with id = {id}
|
||||||
{
|
{
|
||||||
"id": "string",
|
"id": "string",
|
||||||
"name": "string",
|
"name": "string",
|
||||||
|
"description": "string",
|
||||||
"communityId": "string",
|
"communityId": "string",
|
||||||
"creationDate": "number"
|
"permissions": "string[]",
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
## GET /api/v1/role/{id}/permissions
|
|
||||||
|
|
||||||
_Requires an authorization header_
|
|
||||||
|
|
||||||
Returns a role with id = {id} and permissions
|
|
||||||
|
|
||||||
### Response:
|
|
||||||
|
|
||||||
```json
|
|
||||||
{
|
|
||||||
"id": "string",
|
|
||||||
"name": "string",
|
|
||||||
"communityId": "string",
|
|
||||||
"permissions": "string[]".
|
|
||||||
"creationDate": "number"
|
"creationDate": "number"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
@ -55,7 +39,10 @@ Creates a new role and returns it
|
||||||
{
|
{
|
||||||
"id": "string",
|
"id": "string",
|
||||||
"name": "string",
|
"name": "string",
|
||||||
"communityId": "string"
|
"description": "string",
|
||||||
|
"communityId": "string",
|
||||||
|
"permissions": "string[]",
|
||||||
|
"creationDate": "number"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
@ -68,6 +55,7 @@ _Requires an authorization header_
|
||||||
```json
|
```json
|
||||||
{
|
{
|
||||||
"name": "string?",
|
"name": "string?",
|
||||||
|
"description": "string?",
|
||||||
"permissions": "string[]?"
|
"permissions": "string[]?"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
@ -80,8 +68,10 @@ Updates a role with id = {id}
|
||||||
{
|
{
|
||||||
"id": "string",
|
"id": "string",
|
||||||
"name": "string",
|
"name": "string",
|
||||||
|
"description": "string",
|
||||||
"communityId": "string",
|
"communityId": "string",
|
||||||
"permissions": "string[]"
|
"permissions": "string[]",
|
||||||
|
"creationDate": "number"
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue