All URIs are relative to https://your-domain.atlassian.com
Method | HTTP request | Description |
---|---|---|
createIssueType | POST /rest/api/3/issuetype | Create issue type |
createIssueTypeAvatar | POST /rest/api/3/issuetype/{id}/avatar2 | Load issue type avatar |
deleteIssueType | DELETE /rest/api/3/issuetype/{id} | Delete issue type |
getAlternativeIssueTypes | GET /rest/api/3/issuetype/{id}/alternatives | Get alternative issue types |
getIssueAllTypes | GET /rest/api/3/issuetype | Get all issue types for user |
getIssueType | GET /rest/api/3/issuetype/{id} | Get issue type |
updateIssueType | PUT /rest/api/3/issuetype/{id} | Update issue type |
IssueTypeDetails createIssueType(body)
Create issue type
Creates an issue type and adds it to the default issue type scheme. 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.IssueTypesApi;
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");
IssueTypesApi apiInstance = new IssueTypesApi();
IssueTypeCreateBean body = new IssueTypeCreateBean(); // IssueTypeCreateBean |
try {
IssueTypeDetails result = apiInstance.createIssueType(body);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling IssueTypesApi#createIssueType");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
body | IssueTypeCreateBean |
- Content-Type: application/json
- Accept: application/json
Avatar createIssueTypeAvatar(body, size, id, x, y)
Load issue type avatar
Loads an avatar for the issue type. Specify the avatar's local file location in the body of the request. Also, include the following headers: * `X-Atlassian-Token: no-check` To prevent XSRF protection blocking the request, for more information see Special Headers. * `Content-Type: image/image type` Valid image types are JPEG, GIF, or PNG. For example: `curl --request POST \ --user [email protected]:<api_token> \ --header 'X-Atlassian-Token: no-check' \ --header 'Content-Type: image/< image_type>' \ --data-binary "<@/path/to/file/with/your/avatar>" \ --url 'https://your-domain.atlassian.net/rest/api/3/issuetype/{issueTypeId}'This` The avatar is cropped to a square. If no crop parameters are specified, the square originates at the top left of the image. The length of the square's sides is set to the smaller of the height or width of the image. The cropped image is then used to create avatars of 16x16, 24x24, 32x32, and 48x48 in size. After creating the avatar, use Update issue type to set it as the issue type's displayed avatar. 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.IssueTypesApi;
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");
IssueTypesApi apiInstance = new IssueTypesApi();
Object body = null; // Object |
Integer size = 56; // Integer | The length of each side of the crop region.
String id = "id_example"; // String | The ID of the issue type.
Integer x = 0; // Integer | The X coordinate of the top-left corner of the crop region.
Integer y = 0; // Integer | The Y coordinate of the top-left corner of the crop region.
try {
Avatar result = apiInstance.createIssueTypeAvatar(body, size, id, x, y);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling IssueTypesApi#createIssueTypeAvatar");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
body | Object | ||
size | Integer | The length of each side of the crop region. | |
id | String | The ID of the issue type. | |
x | Integer | The X coordinate of the top-left corner of the crop region. | [optional] [default to 0] |
y | Integer | The Y coordinate of the top-left corner of the crop region. | [optional] [default to 0] |
- Content-Type: /
- Accept: application/json
deleteIssueType(id, alternativeIssueTypeId)
Delete issue type
Deletes the issue type. If the issue type is in use, all uses are updated with the alternative issue type (`alternativeIssueTypeId`). A list of alternative issue types are obtained from the Get alternative issue types resource. 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.IssueTypesApi;
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");
IssueTypesApi apiInstance = new IssueTypesApi();
String id = "id_example"; // String | The ID of the issue type.
String alternativeIssueTypeId = "alternativeIssueTypeId_example"; // String | The ID of the replacement issue type.
try {
apiInstance.deleteIssueType(id, alternativeIssueTypeId);
} catch (ApiException e) {
System.err.println("Exception when calling IssueTypesApi#deleteIssueType");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | The ID of the issue type. | |
alternativeIssueTypeId | String | The ID of the replacement issue type. | [optional] |
null (empty response body)
- Content-Type: Not defined
- Accept: Not defined
List<IssueTypeDetails> getAlternativeIssueTypes(id)
Get alternative issue types
Returns a list of issue types that can be used to replace the issue type. The alternative issue types are those assigned to the same workflow scheme, field configuration scheme, and screen scheme. 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.IssueTypesApi;
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");
IssueTypesApi apiInstance = new IssueTypesApi();
String id = "id_example"; // String | The ID of the issue type.
try {
List<IssueTypeDetails> result = apiInstance.getAlternativeIssueTypes(id);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling IssueTypesApi#getAlternativeIssueTypes");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | The ID of the issue type. |
- Content-Type: Not defined
- Accept: application/json
List<IssueTypeDetails> getIssueAllTypes()
Get all issue types for user
Returns all issue types. This operation can be accessed anonymously. Permissions required: Issue types are only returned as follows: * if the user has the Administer Jira global permission, all issue types are returned. * if the user has the Browse projects project permission for one or more projects, the issue types associated with the projects the user has permission to browse are returned.
// 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.IssueTypesApi;
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");
IssueTypesApi apiInstance = new IssueTypesApi();
try {
List<IssueTypeDetails> result = apiInstance.getIssueAllTypes();
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling IssueTypesApi#getIssueAllTypes");
e.printStackTrace();
}
This endpoint does not need any parameter.
- Content-Type: Not defined
- Accept: application/json
IssueTypeDetails getIssueType(id)
Get issue type
Returns an issue type. This operation can be accessed anonymously. Permissions required: Browse projects project permission in a project the issue type is associated with or 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.IssueTypesApi;
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");
IssueTypesApi apiInstance = new IssueTypesApi();
String id = "id_example"; // String | The ID of the issue type.
try {
IssueTypeDetails result = apiInstance.getIssueType(id);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling IssueTypesApi#getIssueType");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
id | String | The ID of the issue type. |
- Content-Type: Not defined
- Accept: application/json
IssueTypeDetails updateIssueType(body, id)
Update issue type
Updates the issue type. 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.IssueTypesApi;
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");
IssueTypesApi apiInstance = new IssueTypesApi();
IssueTypeUpdateBean body = new IssueTypeUpdateBean(); // IssueTypeUpdateBean |
String id = "id_example"; // String | The ID of the issue type.
try {
IssueTypeDetails result = apiInstance.updateIssueType(body, id);
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling IssueTypesApi#updateIssueType");
e.printStackTrace();
}
Name | Type | Description | Notes |
---|---|---|---|
body | IssueTypeUpdateBean | ||
id | String | The ID of the issue type. |
- Content-Type: application/json
- Accept: application/json