Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

On this page

Use this method to retrieve the team of a specific project. The team consists of those users that have a role in that project, the same users that are displayed in the "Project Team" tab of that project dashboard.

To retrieve the data using this method, you must be authenticated with a user that has permissions to edit the custom fields of other users. See Configuring the app permissions.

Request URL

The request URL takes the following form:

GET <ROOT>/rest/stonikbyte-project-team-api/1.0/project/{projectKey}/team?includeCustomFieldValues=true

Parameters

You have to specify the following parameters:

Parameter

Description

{projectKey}

The key of the Jira project for which you want to retrieve the team.

includeCustomFieldValues

Optional. Set this on true if you want to the value of user custom fields to be included in the response data. If is not specified, this parameter is considered false.

An example of the request URL with parameters is as follows:

http:/ /MY_Jira_BASE_URL/rest/stonikbyte-project-team-api/1.0/project/DEMO/team
In this example the team of DEMO project is retrieved.

A successful response

An HTTP 200 status response indicates a successful request. The following data is returned in JSON format:

[
  {
    "key": "john.smith",
    "username": "john.smith",
    "email": "john.smith@stonikbyte.com",
    "displayName": "John Smith",
    "listProjectRoles": [
      {
        "id": 10101,
        "name": "Project Manager"
      },
      {
        "id": 10100,
        "name": "Programmer"
      }
    ]
  },
  {
    "key": "dorothy.grey",
    "username": "dorothy.grey",
    "email": "dorothy.grey@stonikbyte.com",
    "displayName": "Dorothy Grey",
    "listProjectRoles": [
      {
        "id": 10100,
        "name": "Programmer"
      }
    ]
  }
]

Error Response

If the REST call fails, the service returns one of the following HTTP statuses:

HTTP Status Code

Description

400

Returned if the project key is invalid or user does not have permissions to browse the project.

401

Returned if the calling user is not authenticated or user does not have enough permissions. Same in case of invalid app license.

  • No labels