Skip to content

Latest commit

 

History

History
150 lines (117 loc) · 3.28 KB

File metadata and controls

150 lines (117 loc) · 3.28 KB

ILLA Supervisor Backend Team APIs

Index

Get My Teams

Desc

Get the list of Teams I've joined, in reverse chronological order. Note that this interface is authenticated based on the user's login token, so the user won't be able to get information about Teams they haven't joined. It will show that you don't have permission.

API Endpoint

GET  /api/v1/teams/my

Request Body

none

Response

[
    {
        "id": "ILAfx4p1C7es",
        "uid": "0af23d3f-ae32-4a70-9302-2e8025c30f14",
        "name": "t2",
        "identifier": "t2",
        "icon": "https://illa-cloud-storage.illacloud.com/system-assets/images/people.png",
        "myRole": 1, // root
        "teamMemberID": "ILAfx4p1C7eG",
        "teamMemberPermission": {
            "config": 0
        },
        "permission": {
            "allowEditorInvite": true,
            "allowViewerInvite": true,
            "allowEditorManageTeamMember": true,
            "allowViewerManageTeamMember": true,
            "inviteLinkEnabled": true
        }
        }
    },
    {
        "id":"ILAfx4p1C7eR",
        "uid":"uuid",
        "name":"team_name_b",
        "identifier":"team_identifier",
        "icon":"http://teamcion.com/icon.png",
        "myRole": 4 // viewer
        "teamMemberID": "ILAfx4p1C7X3",
        "teamMemberPermission": {
            "config": 0 
        },
        "permission" { 
            "allowEditorInvite": true,
            "allowViewerInvite": true,
            "allowEditorManageTeamMember": true,
            "allowViewerManageTeamMember": true,
            "inviteLinkEnabled": true
        }
    },
    ...
]

Update Team Config

Desc

Update team config.

API Endpoint

PATCH  /api/v1/teams/:teamID/config

Request Body

{
    "name":"team_name",
    "identifier":"team_identifier",
    "icon":"http://teamcion.com/icon.png"
}

Response

none

Update Team Permission Config

Desc

Updated customizable permissions settings in the team, which now include.

  • Switch to allow editor and viewer to invite members.
  • A switch to allow the editor and viewer to manage members (including moving team members out of the team within the permission level).

In the future, this permission will be a global permission for the team, with a lower priority than the attribute system, i.e. the attribute system will override this permission if the user has customized it (not yet implemented).

API Endpoint

PATCH  /api/v1/teams/:teamID/permission

Request Body

{
    "allowEditorInvite": true,
    "allowViewerInvite": true,
    "allowEditorManageTeamMember": true,
    "allowViewerManageTeamMember": true
}

Response

none