List all of the teamSpace elements in JSON format
This method returns a JSON array representation of the elements of the teamSpace type. You can specify how the response JSON is formatted with the "format" parameter.
Request
GET http://{hostname}:{port}
/teams/?{parameters}
Accept: application/json
Parameter | Type | Required | Description |
---|---|---|---|
format | string | false | One of the format options; this parameter determines what information is included in the JSON response. If not specified, or if an unrecognized value is specified, the default format of "list" will be used. |
Parameter | Type | Required | Description |
---|---|---|---|
Accept | application/json |
true |
For the format parameter, use one of the following format options:
list
- Primary properties, user role, and group role
detail
- Identical to 'list' format
name
- Name and ID only
Example
curl -k -u jsmith:passwd
"http://myserver.example.com:8080/teams/"
-H "Accept: application/json"
Example response
[
{
"id": "e25dce9b-f73e-4068-b79d-918e7b7b077c",
"name": "Other team",
"description": "",
"enabled": true,
"userRoleForTeam": [],
"groupRoleForTeam": []
},
{
"id": "00000000-0000-0000-0000-000000000206",
"name": "Team for Sample Release",
"description": "Sample team.",
"enabled": true,
"userRoleForTeam": [
{
"id": "00000000-0000-0000-0000-000000001306",
"user": {
"id": "00000000-0000-0000-0000-000000000002",
"name": "admin",
"displayName": "admin"
},
"role": {
"id": "00000000-0000-0000-0000-000000000003",
"name": "Admin"
},
"version": 0
},
{
"id": "00000000-0000-0000-0000-000000001307",
"user": {
"id": "00000000-0000-0000-0000-000000000003",
"name": "releaser",
"displayName": "releaser"
},
"role": {
"id": "00000000-0000-0000-0000-000000000004",
"name": "Release Manager"
},
"version": 0
},
{
"id": "00000000-0000-0000-0000-000000001308",
"user": {
"id": "00000000-0000-0000-0000-000000000004",
"name": "user",
"displayName": "user"
},
"role": {
"id": "00000000-0000-0000-0000-000000000005",
"name": "Observer"
},
"version": 0
}
],
"groupRoleForTeam": []
}
]