All URIs are relative to https://your-domain.atlassian.com
Method | HTTP request | Description |
---|---|---|
getAllApplicationRoles | GET /rest/api/3/applicationrole | Get all application roles |
getApplicationRole | GET /rest/api/3/applicationrole/{key} | Get application role |
List<ApplicationRole> getAllApplicationRoles()
Get all application roles
Returns all application roles. In Jira, application roles are managed using the Application access configuration page. Permissions required: Administer Jira global permission.
// Import classes:
//import com.xminds.jira.rest.client.ApiClient;
//import com.xminds.jira.rest.client.ApiException;
//import com.xminds.jira.rest.client.Configuration;
//import com.xminds.jira.rest.client.auth.*;
//import com.xminds.jira.rest.client.api.ApplicationRolesApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basicAuth
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("YOUR USERNAME");
basicAuth.setPassword("YOUR PASSWORD");
ApplicationRolesApi apiInstance = new ApplicationRolesApi();
try {
List<ApplicationRole> result = apiInstance.getAllApplicationRoles();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling ApplicationRolesApi#getAllApplicationRoles");
e.printStackTrace();
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
ApplicationRole getApplicationRole(key)
Get application role
Returns an application role. Permissions required: Administer Jira global permission.
// Import classes:
//import com.xminds.jira.rest.client.ApiClient;
//import com.xminds.jira.rest.client.ApiException;
//import com.xminds.jira.rest.client.Configuration;
//import com.xminds.jira.rest.client.auth.*;
//import com.xminds.jira.rest.client.api.ApplicationRolesApi;
ApiClient defaultClient = Configuration.getDefaultApiClient();
// Configure HTTP basic authorization: basicAuth
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("YOUR USERNAME");
basicAuth.setPassword("YOUR PASSWORD");
ApplicationRolesApi apiInstance = new ApplicationRolesApi();
String key = "key_example"; // String | The key of the application role. Use the [Get all application roles](#api-rest-api-3-applicationrole-get) operation to get the key for each application role.
try {
ApplicationRole result = apiInstance.getApplicationRole(key);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling ApplicationRolesApi#getApplicationRole");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
key | String | The key of the application role. Use the Get all application roles operation to get the key for each application role. |
- Content-Type: Not defined
- Accept: application/json