Skip to content

Latest commit

 

History

History
119 lines (87 loc) · 3.95 KB

WorkflowStatusCategoriesApi.md

File metadata and controls

119 lines (87 loc) · 3.95 KB

WorkflowStatusCategoriesApi

All URIs are relative to https://your-domain.atlassian.com

Method HTTP request Description
getStatusCategories GET /rest/api/3/statuscategory Get all status categories
getStatusCategory GET /rest/api/3/statuscategory/{idOrKey} Get status category

getStatusCategories

List<StatusCategory> getStatusCategories()

Get all status categories

Returns a list of all status categories. Permissions required: Permission to access Jira.

Example

// 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.WorkflowStatusCategoriesApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure OAuth2 access token for authorization: OAuth2
OAuth OAuth2 = (OAuth) defaultClient.getAuthentication("OAuth2");
OAuth2.setAccessToken("YOUR ACCESS TOKEN");
// Configure HTTP basic authorization: basicAuth
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("YOUR USERNAME");
basicAuth.setPassword("YOUR PASSWORD");

WorkflowStatusCategoriesApi apiInstance = new WorkflowStatusCategoriesApi();
try {
    List<StatusCategory> result = apiInstance.getStatusCategories();
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling WorkflowStatusCategoriesApi#getStatusCategories");
    e.printStackTrace();
}

Parameters

This endpoint does not need any parameter.

Return type

List<StatusCategory>

Authorization

OAuth2basicAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

getStatusCategory

StatusCategory getStatusCategory(idOrKey)

Get status category

Returns a status category. Status categories provided a mechanism for categorizing statuses. Permissions required: Permission to access Jira.

Example

// 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.WorkflowStatusCategoriesApi;

ApiClient defaultClient = Configuration.getDefaultApiClient();

// Configure OAuth2 access token for authorization: OAuth2
OAuth OAuth2 = (OAuth) defaultClient.getAuthentication("OAuth2");
OAuth2.setAccessToken("YOUR ACCESS TOKEN");
// Configure HTTP basic authorization: basicAuth
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("YOUR USERNAME");
basicAuth.setPassword("YOUR PASSWORD");

WorkflowStatusCategoriesApi apiInstance = new WorkflowStatusCategoriesApi();
String idOrKey = "idOrKey_example"; // String | The ID or key of the status category.
try {
    StatusCategory result = apiInstance.getStatusCategory(idOrKey);
    System.out.println(result);
} catch (ApiException e) {
    System.err.println("Exception when calling WorkflowStatusCategoriesApi#getStatusCategory");
    e.printStackTrace();
}

Parameters

Name Type Description Notes
idOrKey String The ID or key of the status category.

Return type

StatusCategory

Authorization

OAuth2basicAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json