new Issuetype()
Issuetype
Properties:
Name | Type | Description |
---|---|---|
connector |
IConnector | the jira connector instance |
- Source:
Methods
createAvatarFromTemporary(options, callbackopt) → {Promise.<any>}
Converts temporary avatar into a real avatar
Parameters:
Name | Type | Attributes | Description | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
|||||||||||||||||||||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>
createIssueType(options, callbackopt) → {Promise.<any>}
Creates an issue type from a JSON representation and adds the issue newly created issue type to the default issue type scheme.
Parameters:
Name | Type | Attributes | Description | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
||||||||||||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>
deleteIssueType(options, callbackopt) → {Promise.<any>}
Deletes the specified issue type. If the issue type has any associated issues, these issues will be migrated to the alternative issue type specified in the parameter. You can determine the alternative issue types by calling the /rest/api/2/issuetype/{id}/alternatives resource.the id of an issue type to which issues associated with the removed issue type will be migrated.
Parameters:
Name | Type | Attributes | Description | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
|||||||||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>
getAlternativeIssueTypes(options, callbackopt) → {Promise.<any>}
Returns a list of all alternative issue types for the given issue type id. The list will contain these issues types, to which issues assigned to the given issue type can be migrated. The suitable alternatives are issue types which are assigned to the same workflow, the same field configuration and the same screen scheme.
Parameters:
Name | Type | Attributes | Description | |||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
||||||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>
getIssueAllTypes(options, callbackopt) → {Promise.<any>}
Returns a list of all issue types visible to the user
Parameters:
Name | Type | Attributes | Description | ||||||
---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
|||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>
getIssueType(options, callbackopt) → {Promise.<any>}
Returns a full representation of the issue type that has the given id.
Parameters:
Name | Type | Attributes | Description | |||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
||||||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>
storeTemporaryAvatar(options, callbackopt) → {Promise.<any>}
Creates temporary avatar. Creating a temporary avatar is part of a 3-step process in uploading a new avatar for an issue type: upload, crop, confirm.
The following examples shows these three steps using curl. The cookies (session) need to be preserved between requests, hence the use of -b and -c. The id created in step 2 needs to be passed to step 3 (you can simply pass the whole response of step 2 as the request of step 3).
curl -c cookiejar.txt -X POST -u admin:admin -H "X-Atlassian-Token: no-check" \ -H "Content-Type: image/png" --data-binary @mynewavatar.png \ 'http://localhost:8090/jira/rest/api/2/issuetype/1/avatar/temporary?filename=mynewavatar.png'
curl -b cookiejar.txt -X POST -u admin:admin -H "X-Atlassian-Token: no-check" \ -H "Content-Type: application/json" --data '{"cropperWidth": "65","cropperOffsetX": "10","cropperOffsetY": "16"}' \ -o tmpid.json \ http://localhost:8090/jira/rest/api/2/issuetype/1/avatar
curl -b cookiejar.txt -X PUT -u admin:admin -H "X-Atlassian-Token: no-check" \ -H "Content-Type: application/json" --data-binary @tmpid.json \ http://localhost:8090/jira/rest/api/2/issuetype/1/avatar name of file being uploadedsize of file
Parameters:
Name | Type | Attributes | Description | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
||||||||||||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>
storeTemporaryAvatarUsingMultiPart(options, callbackopt) → {Promise.<any>}
Creates temporary avatar using multipart. The response is sent back as JSON stored in a textarea. This is because the client uses remote iframing to submit avatars using multipart. So we must send them a valid HTML page back from which the client parses the JSON from.
Creating a temporary avatar is part of a 3-step process in uploading a new avatar for an issue type: upload, crop, confirm. This endpoint allows you to use a multipart upload instead of sending the image directly as the request body.
You must use "avatar" as the name of the upload parameter:
curl -c cookiejar.txt -X POST -u admin:admin -H "X-Atlassian-Token: no-check" \ -F "avatar=@mynewavatar.png;type=image/png" \ 'http://localhost:8090/jira/rest/api/2/issuetype/1/avatar/temporary'
Parameters:
Name | Type | Attributes | Description | |||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
||||||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>
updateIssueType(options, callbackopt) → {Promise.<any>}
Updates the specified issue type from a JSON representation.
Parameters:
Name | Type | Attributes | Description | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object | An object containing options to pass to the Jira API. Properties
|
|||||||||||||||||||
callback |
<optional> |
if supplied, called with result of api call |
- Source:
Returns:
result of api call
- Type
- Promise.<any>