Create

POST
/api/v1/teams

Request Parameters

Name Type Description Required
name string Name for the team. Must be unique within Rev account. Yes
description string Team description.
userIds string User GUIDs to add to the team.
groupIds string Group GUIDs to add to the team.

Example Request

{
  "Name": "Marketing",
  "Description": "Videos for the marketing team",
  "UserIds": [
    "fe73fec5-35c4-4f55-abdc-0192f326f9a0"
  ],
  "GroupIds": [
    "13a24fc2-4fc5-4ba9-88af-f58624ad10e0"
  ]
}

Example Response

[
  {
    "teamId": "9f793be4-1b39-49ea-8406-6ea12ae3c7gd"
  }
]

Response Codes

Code Description
200 ok
401 Unauthorized error
500 Internal server error

Edit

PUT
/api/v1/teams/{teamId}

Request Parameters

Name Type Description Required
id path GUID for the team Yes
name string Name for the team. Must be unique within Rev account. Yes
description string Description for the team
userIds string GUID for the users
groupIds string GUID for the groups

Example Request

{
  "name": "Marketing",
  "description": "Videos for the marketing team",
  "userIds": [
    "fe73fec5-35c4-4f55-abdc-0192f326f9a0"
  ],
  "groupIds": [
    "13a24fc2-4fc5-4ba9-88af-f58624ad10e0"
  ]
}

Response Codes

Code Description
200 ok
401 Unauthorized error
500 Internal server error

Delete

DELETE
/api/v1/teams/{id}

Request Parameters

Name Type Description Required
id path GUID for the teams. Yes

Response Codes

Code Description
200 ok
401 Unauthorized error
500 Internal server error

List All

NOTE: As of Rev v7.22, which users are Team admins are now indicated. Admins will be returned as an object that contains two properties; ID and type. Type can be either a user or a group.

GET
/api/v1/teams?size={page size}&page={0}

Request Parameters

Name Type Description Required
size path Number of teams per page. Defaults to 10.
page path Zero based index of the page. This means page number will start from 0 and first set of 10 teams and page 1 will contain next set of 10 teams.

Example Response

[
    {
        "id": "04cf14cb-9bd9-48f8-b8cc-cc7c96d7612b",
        "name": "Team1",
        "description": null,
        "users": [
            "3e37cd8d-4965-469b-b68f-9dbe4edcaa7e"
        ],
        "groups": [
            "16848c74-bcb1-47c7-88f7-8ea970a71152"
        ],
        "admins": [
            {
                "id": "16848c74-bcb1-47c7-88f7-8ea970a71152",
                "type": "Group"
            },
            {
                "id": "3e37cd8d-4965-469b-b68f-9dbe4edcaa7e",
                "type": "User"
            }
        ]
    },
    {
        "id": "1c7f51e8-969c-498e-8f45-2259c5253044",
        "name": "Team2",
        "description": "Team2",
        "users": [
            "7c443706-7318-4452-be66-ce9bf5f5b969",
            "546fa644-370b-4ea3-9b65-8af9a8c9cc46"
        ],
        "groups": [],
        "admins": []
    }
]

Response Codes

Code Description
200 ok
401 Unauthorized error
500 Internal server error

 

Example – curl

REQUEST: Get Teams

curl -X GET 

'https://REVURL-eu.demo.vbrick.com/api/v1/teams?size=1000' 

-H 'Authorization: VBrick yqKjMfp2g7fEdy_i8G1FO4JNx2gO9CjXMzBvQXcNVzvZ1kCTsVQR_VoYUQipUdYn0rGiIrFPffxfPIwbAJWlxKJHLa9rS3yiWGTCJ_UCqRysuSGjVbqh8wmKsApBxN9zr4e1lhZqTOM-pJ-dVFcetA2' 

-H 'Cache-Control: no-cache' 

-H 'Postman-Token: 82bb6c97-a5d1-4c66-a6db-27172c09f9cf'

List For One User

This will only return teams for the user making the API request.

NOTE: As of Rev v7.15, this API is available.

GET
/api/v1/search/teams

Request Parameters

Name Type Description Required
none

Example Response

[
{
  "teamId": "13a24fc2-4fc5-4ba9-88af-f58624ad10e",
  "name": "Marketing"
},
{
  "teamId": "369fsfff-cba8-4e89-8b7f-b69863cc02a",
  "name": "Human Resources"
} ]

Response Codes

Code Description
200 ok
401 Unauthorized error
500 Internal server error