All URIs are relative to https://your-domain.atlassian.com
Method | HTTP request | Description |
---|---|---|
getStatus | GET /rest/api/3/status/{idOrName} | Get status |
getStatuses | GET /rest/api/3/status | Get all statuses |
StatusDetails getStatus(idOrName)
Get status
Returns a status. The status must be associated with a workflow to be returned. If a name is used on more than one status, only the status found first is returned. Therefore, identifying the status by its ID may be preferable. This operation can be accessed anonymously. Permissions required: None.
// 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.WorkflowStatusesApi;
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");
WorkflowStatusesApi apiInstance = new WorkflowStatusesApi();
String idOrName = "idOrName_example"; // String | The ID or name of the status.
try {
StatusDetails result = apiInstance.getStatus(idOrName);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling WorkflowStatusesApi#getStatus");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
idOrName | String | The ID or name of the status. |
- Content-Type: Not defined
- Accept: application/json
List<StatusDetails> getStatuses()
Get all statuses
Returns a list of all statuses associated with workflows. This operation can be accessed anonymously. Permissions required: None.
// 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.WorkflowStatusesApi;
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");
WorkflowStatusesApi apiInstance = new WorkflowStatusesApi();
try {
List<StatusDetails> result = apiInstance.getStatuses();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling WorkflowStatusesApi#getStatuses");
e.printStackTrace();
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json