Skip to content

Latest commit

 

History

History
113 lines (84 loc) · 1.38 KB

README.md

File metadata and controls

113 lines (84 loc) · 1.38 KB

Moderator

Resource endpoint: /groups/<int:group_id>/moderators/

List all moderators of the current group

GET /

Request Body

None

Response

[
    {
        "id": <int>,
        "name": <string>,
        "email": <email>,
        "joined_at": <datetime>,
        @optional "avatar_url": <url>,
    },
    {
        "id": <int>,
        "name": <string>,
        "email": <email>,
        "joined_at": <datetime>,
        @optional "avatar_url": <url>,
    }
]

Add a new moderator to the current group

POST /

Request Body

{
    "emails": [<email>, <email>, ...]
}

Response

[
    {
        "id": <int>,
        "email": <email>,
        "name": <string>,
        "joined_at": <datetime>,
        @optional "avatar_url": <url>,
    },
    {
        "id": <int>,
        "email": <email>,
        "name": <string>,
        "joined_at": <datetime>,
        @optional "avatar_url": <url>,
    }
]

Get a specific moderator of the current group

GET /<int:moderator_id>/

Request Body

None

Response

Add
{
    "id": <int>,
    "email": <email>,
    "name": <string>,
    "joined_at": <datetime>,
    @optional "avatar_url": <url>,
}

Delete a specific moderator

DELETE /<int:moderator_id>/

Request Body

None

Response

None