Skip to end of metadata
Go to start of metadata

Additional CLI documentation

Icon

Documentation Links for all CLI products including version archives and SNAPSHOTS

Icon

The information in this section is automatically generated, so if you have edit suggestions, add a comment. Otherwise, your edits will be replaced on the next update.

3.8.0

Action

Category

Description

Required parameters

Optional parameters

Output formats

addAttachment

Attachments

Add an attachment to an issue.

issue, file

findReplace, findReplaceRegex, name, encoding

 

addComment

Comments

Add a comment to an issue.

issue

comment, group, role, , findReplace, findReplaceRegex, file, encoding,

 

addComponent

Components

Add component to a project.

project, component

description, lead, defaultAssignee, replace, api

 

addGroup

Groups

Add a new group.

group

preserveCase

 

addLabels

Labels

Add labels to an issue. Requires labels are available for edit on the issue screen.

issue, labels

 

 

addProjectRoleActors

Projects

Add users or groups to a project role.

project, role, userId or group

 

 

addUserToGroupWithFile

Users

Add users to groups from comma separated file.

file

autoGroup, preserveCase, encoding

 

addUserToGroup

Users

Add user to a group.

userId, group

autoGroup, preserveCase

 

addUserWithFile

Users

Add users from comma separated file.

file

preserveCase, encoding

 

addUser

Users

Add a new user.

userId, userEmail

userFullName, userPassword, preserveCase

 

addVersion

Versions

Add a new version to a project.

project, version

description, after, date, dateFormat, replace

 

addVote

Vote

Add vote for issue.

issue

 

 

addWatchers

Watches

Add watchers to an issue. A comma separated list of user ids can be specified.

issue

userId, lookup, continue

 

addWork

Work

Add work log entry.

issue, timeSpent

comment, date, dateFormat, estimate, role, group, autoAdjust

 

archiveVersion

Versions

Archive a version for a project. This hides the version from the UI.

project, version

 

 

assignIssue

Issues

Assign an isssue to a userId. Use @default for userId to set the assignee to the project default. Use blank to set the assignee to null.

issue, userId

 

 

cloneIssue

Issues

Create a new issue by copying an existing issue. Advanced options require the Clone Plus Plugin be installed.

issue

type, summary, resolution, labels, comment, group, role, priority, reporter, assignee, description, components, affectsVersions, fixVersions, environment, security, field, value, values, field2, values2, asVersion, asComponent, asCascadeSelect, lookup, date, dateFormat, custom, autoVersion, autoComponent, , findReplace, findReplaceRegex, file, encoding, project, copyLinks, copyAttachments, copyComments, copyWatchers, copySubtasks, copySubtaskEstimates, useParentVersions, fieldExcludes, propertyPrefix, jsp

 

cloneIssues

Issues

Clone issues returned from a JQL search. Advanced options require the Clone Plus Plugin be installed.

search

project, type, continue, copyLinks, copyAttachments, copyComments, copyWatchers, copySubtasks, copySubtaskEstimates, useParentVersions, autoVersion, autoComponent, fieldExcludes, propertyPrefix, jsp

 

cloneProject

Projects

Create a new project as a clone of a base project. Optionally copy versions, components, role actors, and issues to new project. Issue cloning requires JIRA Clone Plus Plugin. Provide a search parameter to subset the issues to be cloned.

project, toProject

name, description, url, permissionScheme, notificationScheme, issueSecurityScheme, search, type, continue, copyVersions, copyComponents, copyRoleActors, cloneIssues, copyLinks, copyAttachments, copyComments, copyWatchers, copySubtasks, copySubtaskEstimates, useParentVersions, fieldExcludes, propertyPrefix, jsp

 

copyComponent

Components

Copy a component from one project to the same project or another project.

project, component

toProject, toComponent, name, description, lead, defaultAssignee, replace, api

 

copyComponents

Components

Copy all or some components from one project to another.

project, toProject

components, replace, api

 

copyFieldValue

Fields

Copy field value from an issue to a custom field of another issue. Warning: only works for fields that can be updated from their text representation.

issue, field, toIssue or field2

asVersion, asComponent, asCascadeSelect, append, appendText, encoding, dateFormat

 

copyProjectRoleActors

Projects

Copy all role actors from a project to another project.

project, toProject

continue

 

copyVersion

Versions

Copy a version from one project to the same project or another project.

project, version

toProject, name, description, after, date, dateFormat, replace

 

copyVersions

Versions

Copy all versions from one project to another project.

project, toProject

continue, replace

 

createBoard

Agile

Beta. Create an Agile board. Type is any support type like scrum, kanban, or diy. Project is a comma separated list of projects identified by key, name, or id.

name, type, project

 

 

createFilter

Filter

Beta. Create a filter.

name, search

description, favorite

 

createIssue

Issues

Create a new issue or subtask for a project.

project, type, summary

parent, priority, reporter, assignee, description, components, affectsVersions, fixVersions, environment, security, field, value, values, field2, values2, asVersion, asComponent, asCascadeSelect, lookup, date, dateFormat, custom, autoVersion, autoComponent, comment, group, role, labels, findReplace, findReplaceRegex, file, encoding,

 

createProject

Projects

Create a new project with key provided by project parameter.

project, lead

name, description, url, defaultAssignee, lookup, permissionScheme, notificationScheme, issueSecurityScheme, workflowScheme, issueTypeScheme, issueTypeScreenScheme, fieldConfigurationScheme, category

 

deleteBoard

Agile

Beta. Delete an Agile board.

id or board

 

 

deleteComponent

Components

Delete component from a project.

project, component

api

 

deleteFilter

Filter

Beta. Delete a filter by id or filter name (if it is a favorite filter).

id or filter

 

 

deleteIssue

Issues

Delete an issue.

issue

 

 

deleteLink

Links

Remove link to another issue.

issue, toIssue, link

 

 

deleteProject

Projects

Delete a project.

project

 

 

deleteVersion

Versions

Delete a version from a project. Update affects and fix versions for issues by removing version reference or swapping it with versions specified.

project, version

affectsVersions, fixVersions, autoVersion, api

 

exportData

Export

Experimental - export project or issue participant data in a CLI compatible format.

project or search

file, exportType, dateFormat, encoding, search, limit

 

exportSite

Export

Create a site export into a file in the JIRA home/export directory.

file

 

 

getAttachmentList

Lists

List all attachments for an issue.

issue

file, dateFormat, encoding, append, outputFormat

1 - default
999 - all

getAttachment

Attachments

Get lastest attachment by name or id for an issue.

issue, file

name, encoding

 

getAvailableSteps

Steps

Get available workflow steps for issue.

issue

file, encoding

 

getBoardList

Lists

Beta. List Agile boards with optional filtering by regex on name.

 

regex, file, encoding

 

getClientInfo

Info

Get information about the this client tool.

 

 

 

getCommentList

Lists

List of comment information (id, dates, ...) for an issue.

issue

file, dateFormat, encoding, append

1 - default
999 - all

getComments

Comments

Get a formatted string of all comment text for an issue.

issue

file, dateFormat, encoding

 

getComponentList

Lists

List components defined for a projects.

project

file, encoding, append, outputFormat

1 - default
999 - all

getComponent

Components

Get information for a component of a project.

project, component

file, encoding, api

 

getCustomFieldList

Lists

Get information on all custom fields.

 

 

 

getFieldList

Lists

Get information on all fields.

 

regex

 

getFieldValue

Fields

Get field value for an issue.

issue, field

file, dateFormat, asVersion, encoding

 

getFilter

Filter

Beta. Get information about a filter by id or filter name (if it is a favorite filter).

id or filter

 

 

getIssueHistoryList

Lists

Get issue change history.

issue

file, dateFormat, encoding

 

getIssueList

Lists

List issues for a filter or a search.

filter or search or project

file, dateFormat, limit, outputFormat, encoding, append

1 - default
2 or 4 - custom fields
3 or 4 - security level
5 - 4 plus time values
101 - issue keys only
998 - all except custom
999 - all

getIssueTypeList

Lists

List issue types valid for a project.

project

file, encoding, append

 

getIssue

Issues

Get information about an existing issue.

issue

file, dateFormat, asVersion, encoding

1 - default
999 - all

getLinkList

Lists

List issue links for an issue.

issue

file, encoding, append

 

getLinkTypeList

Lists

Get a list of all issue link types.

 

file, encoding

 

getProjectCategoryList

Lists

List defined project categories.

 

file, encoding

 

getProjectList

Lists

List defined projects with optional filtering by lead and regex on project key.

 

lead, regex, outputFormat, file, encoding

1 - default
2 - schemes

getProjectRoleActorList

Lists

Get users and groups for a project's role.

project, role

 

 

getProjectRoleList

Lists

Get project roles.

 

regex

 

getProject

Projects

Get project information.

project

file, encoding

 

getSecurityLevelList

Lists

List security levels defined for a projects.

project

file, encoding, append, outputFormat

1 - default
999 - all

getServerInfo

Info

Get information about the JIRA server.

 

 

 

getStatusList

Lists

List statuses.

 

file, encoding, append

 

getUserList

Lists

List users from a group or a search by name fragment (userId, display name, and email).

group or name

count, file, encoding, append, outputFormat

1 - basic
2 - extended

getUser

Users

Get user information. JIRA 4.2 or higher.

userId

file, endcoding

 

getVersionList

Lists

List versions defined for a projects.

project

regex, file, encoding, append, outputFormat

1 - default
2 - description
999 - all

getVersion

Versions

Get information for a project version (since JIRA 4.2).

project, version

dateFormat, file, encoding

 

getVoterList

Lists

Get list of users that have voted for an issue.

issue

append

1 - simple
2 - CSV

getWatcherList

Lists

Get list of users that are watching an issue.

issue

append

1 - simple
2 - CSV

getWorkList

Lists

Get list of a work log entry.

issue

dateFormat, file, encoding, append, outputFormat

999 - all

linkIssue

Issues

Link an issue to another issue.

issue, toIssue, link

comment, group, role,

 

login

Misc

Login to remote server. Returns login token.

password

user

 

logout

Misc

Logout of remote server.

 

 

 

progressIssue

Issues

Progress issue through workflow.

issue, step

type, summary, resolution, labels, priority, reporter, assignee, description, components, affectsVersions, fixVersions, environment, security, field, value, values, field2, values2, asVersion, asComponent, asCascadeSelect, lookup, date, dateFormat, custom, autoVersion, autoComponent, comment, group, role, , findReplace, findReplaceRegex, file, encoding,

 

releaseVersion

Versions

Release a version for a project. Resets release date if provided. Defaults to current if release date is not set.

project, version

date, dateFormat

 

removeAttachment

Attachments

Remove an attachment from an issue. A single attachment is removed by id or all attachments matching the file name.

issue, name or id

 

 

removeGroup

Groups

Remove a group.

group

defaultGroup

 

removeLabels

Labels

Remove labels from an issue. Requires labels are available for edit on the issue screen.

issue, labels

 

 

removeProjectRoleActors

Projects

Remove users or groups from a project role.

project, role, userId or group

 

 

removeUserFromGroupWithFile

Users

Remove users from groups from comma separated file.

file

encoding

 

removeUserFromGroup

Users

Remove user from a group.

userId, group

 

 

removeUserProperty

Users

Remove a user's property.

userId, name

lookup

 

removeUserWithFile

Users

Remove users from comma separate file.

file

encoding

 

removeUser

Users

Remove a user.

userId

 

 

removeVote

Vote

Remove vote from issue.

issue

 

 

removeWatchers

Watches

Remove watchers from an issue. A comma separated list of user ids can be specified.

issue

userId, lookup, continue

 

removeWork

Work

Remove work log entry.

id

 

 

renderRequest

Render

Render url based request. The response data modified by findReplace processing is returned.

request

requestParameters, requestType, issue, project, , findReplace, findReplaceRegex, file, encoding,

 

restoreExport

Export

Restore export from file in the JIRA home/import directory.

file

 

 

runFromAttachmentList

Run

Run actions for a list of attachments for an issue. Available replacement variables are attachment, attachmentId.

issue

common, continue, simulate, limit, regex, findReplace, findReplaceRegex, file, encoding,

 

runFromCsv

Run

Run actions generated from a CSV file.

file

common, propertyFile, continue, quiet, simulate, encoding, findReplace, findReplaceRegex

 

runFromIssueList

Run

Run actions for each issue from an issue list based on a filter or a search. Available replacement variables are project, issue, issueId.

filter or search or project

common, continue, simulate, limit, findReplace, findReplaceRegex, file, encoding,

 

runFromList

Run

Run actions for each entry in a list. When file is provided, each action in the file augmented by the common parameter will be run for each entry. Otherwise, just the action specified by the common parameter will be run. Available replacement variable is entry.

list

file, common, continue, quiet, simulate, encoding, findReplace, findReplaceRegex

 

runFromProjectList

Run

Run actions for each project with optional filtering by lead and regex on project key. Available replacement variables are project, projectId.

 

lead, regex, common, continue, simulate, limit, findReplace, findReplaceRegex, file, encoding,

 

runFromSql

Run

Run actions generated by SQL provided by the sql parameter, a file, or standard input

sql or file or standard input

common, driver, database, host, port, url, dbUser, dbPassword, propertyFile, continue, simulate, encoding, findReplace, findReplaceRegex

 

runFromVersionList

Run

Run actions for each version in a project. Available replacement variables are project, projectId, version, versionId.

project

regex, common, continue, simulate, limit, findReplace, findReplaceRegex, file, encoding,

 

run

Run

Run actions from a file or standard input.

file or standard input

common, continue, simulate, encoding, findReplace, findReplaceRegex

 

setFieldValue

Fields

Set custom field value for an issue.

issue, field, file or value or values

field2, values2, asVersion, asComponent, asCascadeSelect, append, appendText, subtract, encoding, dateFormat

 

setShareScope

Filter

Beta. Set current users default share scope for filters. Valid values are GLOBAL and PRIVATE.

value

 

 

unarchiveVersion

Versions

Unarchive a version for a project. This makes the version visible again in the UI.

project, version

 

 

unreleaseVersion

Versions

Unrelease a version for a project, optionally reset release date.

project, version

date, dateFormat

 

updateComponent

Components

Update component for a project.

project, component

name, description, lead, defaultAssignee, api

 

updateFilter

Filter

Beta. Update a filter by id or filter name (if it is a favorite filter).

id of filter

name, search, description, favorite

 

updateIssue

Issues

Update an existing issue.

issue

type, summary, resolution, labels, priority, reporter, assignee, description, components, affectsVersions, fixVersions, environment, security, field, value, values, field2, values2, asVersion, asComponent, asCascadeSelect, lookup, date, dateFormat, custom, autoVersion, autoComponent, , append, appendText, comment, group, role, , findReplace, findReplaceRegex, file, encoding,

 

updateProject

Projects

Update project information. Scheme updates require compatible schemes.

project

name, description, lead, url, defaultAssignee, permissionScheme, notificationScheme, issueSecurityScheme, workflowScheme, issueTypeScheme, issueTypeScreenScheme, fieldConfigurationScheme, category

 

updateUserProperty

Users

Add or update a user's property.

userId, name, value

lookup

 

updateUser

Users

Update user information.

userId

userFullName, userEmail, activate, deactivate

 

updateVersion

Versions

Update version for a project.

project, version

name, description, after, date, dateFormat, autoVersion, api

 

updateWork

Work

Update work log entry.

id, issue

timeSpent, comment, date, dateFormat, estimate, role, group, autoAdjust

 

Parameters

Tips

Icon
  • Use single dash for single letter parameters - example: -v
  • Use double dash for multi-letter parameters - example: --help
  • When parameters are specified, most need a value - example: --action addPage
  • Some parameters are flags (boolean) and must not be followed by a value - example: --verbose
  • Parameter names are case sensitive, but, action values are not - example: --userid is invalid but --action addpage is equivalent to --action addPage
  • Some parameters become required once a specific action is chosen. This is indicated in the help text for each action.
  • Some parameters have both short (one letter) and long (more than one letter) parameter names - example: -a or --action are the same
  • Some parameters have default values, if so, they are indicated below - example: (default: automation)
  • Some parameters are required - indicated by (...) in the help text - example: (-a|--action) <action>
  • Some parameters are optional - indicated by [...] in the help text - example: [(-f|--file) <file>]
  • Values that have more than one word must be enclosed by double quotes - example: --title "this is my title"
  • Quoting rules can vary by environment (sad), here are the techniques that may work in your environment:
    • Embedded double quotes within a double quoted string can be escaped with a \ - example: –common "-a addComment --comment \"This is an example of a double quoted string inside a double quote\" "
    • Non-Windows environments: embedded double quotes within a double quoted string can be escaped by doubling the double quote - example: –common "-a addComment --comment ""This is an example of a double quoted string inside a double quote"" "
    • A single quote can used in place of a double quote - example: –common '-a addComment --comment "This is an example of a double quoted string inside a double quote" '
  • Some parameters allow entry of a comma separated list of values, values containing a comma must be enclosed in single quotes - example: --custom "'first:a,b,c', second:x". Embedded single quotes within a quoted string must be doubled
  • Some text fields support the automatic conversion of " \n " (blanks are significant) to be replaced with a new line character - example: --description "A multi-line text field: \n # line 1 \n # line 2"

Special parameter

Icon

Some special characters are difficult to deal with or make action text very complicated. This is because they have special meaning in either the OS command line handling, the tool's command line parsing, or the tool's use of separators (like comma or colon separated lists). As a convenience to avoid some of these nasty situations, a special parameter was implemented to allow alternate characters to be used instead of (or in addition to) the problematic characters within parameter values. The choice of what special characters to use depends on the content so that you do not have conflicts with intended content. The special parameter works by the user providing a order specific alternate character. The alternative character is replaced with the real character after all other parsing occurs. It is implemented for many action parameters that are problematic in this area. Not all situations are covered, but, that will improve as other use cases are identified.

PositionCharacterCharacter nameSuggested alternateUsage
1,comma Some parameters use comma separated lists.
2:colon#Some parameters use colon separated values.
3@at sign  
4'single quote Used in separated lists to cover cases where content contains separator.
5"double quote~Parameters containing blanks.

A blank in any position is ignored (no alternate provided).

Example: –special " #  ~" provides alternates for colon and double quote. 
         --common "--findReplace ~something to find containing a : (colon)#replacement~"  

 

Parameter

Short

Value

Description

action

a

 

activate

 

Activate user. Since JIRA 5.1

affectsVersions

 

Affects versions - comma separated names or ids.

after

 

Version name or id to add a version after. Defaults to after last version. Use -1 to make it the first version.

api

 

API version. Some requests produce different results based on the api version used. (default: latest)

append

 

Append values to existing values for version fields, components field, and custom fields supporting multiple values. For some actions using file, append will append output to the existing file.

appendText

 

Append text to existing value text for description, environment, and single and multi-value custom fields.

asCascadeSelect

 

Interpret values parameter as a cascade select value ids.

asComponent

 

Interpret values parameter as component values and convert each to the component id.

asVersion

 

Interpret values parameter as version values and convert each to the version id.

assignee

 

Issue assignee user id.

autoAdjust

 

Auto adjust remaining estimate when adding work entry.

autoComponent

 

Automatically add components used in components parameter.

autoGroup

 

Groups are automatically added when referenced in add user functions.

autoVersion

 

Automatically add versions used in affectsVersions and fixVersions parameters.

board

 

Agile board name.

category

 

Project category. Administrator access required to see or use project categories.

cloneIssues

 

Clone issues when cloning a project.

columns

 

Column selection and ordering when action generates CSV output. A comma separated list of column numbers (1-based) or column names (case insensitive). Only columns provided by the selected outputFormat are available for selection. Invalid columns will be ignored.

comment

 

Comment for an issue.

common

 

Common parameter string added to all run actions.

component

 

Project component name or id.

components

 

Project components - comma separated names or ids.

connectionTimeout

 

Allow overriding environment settings for connect and read timeouts on URL connections. In milliseconds, 0 means infinite.

continue

 

Continue processing even after errors are encountered.

copyAttachments

 

Copy attachments when cloning an issue.

copyComments

 

Copy comments when cloning an issue.

copyComponents

 

Copy components when cloning a project.

copyLinks

 

Copy issue links when cloning an issue.

copyRoleActors

 

Copy project role actors when cloning a project.

copySubtaskEstimates

 

Copy subtask estimates when cloning an issue.

copySubtasks

 

Copy subtasks when cloning an issue.

copyVersions

 

Copy versions when cloning a project.

copyWatchers

 

Copy Watchers when cloning an issue.

count

 

Deprecated. Use limit instead. (default: 2147483647)

custom

 

Custom fields - comma separated key:value pairs. Key can be field name or id. Single quote the key:value pair if it contains a comma (,) or line breaks.

database

 

Database name is required for SQL actions.

date

 

Date for version or due date for issue.

dateFormat

 

Format string for date in Java SimpleDateFormat, default is client date format.

dbPassword

 

Database user password. Defaults to password.

dbUser

 

Database user name. Defaults to user.

deactivate

 

Deactivate user. Since JIRA 5.1

debug

 

Requests detail debug output. Optional for all actions.

defaultAssignee

 

Project or compnent default assignee for issues. For projects, default is unassigned with options: PROJECT_LEAD or UNASSIGNED (blank). For components, default is PROJECT_DEFAULT with options: PROJECT_LEAD, PROJECT_DEFAULT, COMPONENT_LEAD or UNASSIGNED (blank).

defaultGroup

 

Default group to move users on removeGroup action.

deleteFilter

 

Attempt to delete the filter associated with the board. Filter must be a findable as a favorite filter.

description

 

Description.

driver

 

JDBC driver class or predefined value: postgresql, mysql, mssql, oracle, or db2400. Required for SQL actions.

encoding

 

Character encoding (character set) for text based file content - must be an encoding supported by your JAVA platform.

environment

 

Issue environment.

estimate

 

Estimate of time remaining for an issue. Example: 3h 30m.

exportType

 

PROJECT to export project information, PARTICIPANTS to export issue participants. Use comman separated list if more than one are needed.

favorite

 

Mark a filter as a favorite when creating or updating a filter.

field

 

Field name or id. For some actions, this parameter must be a custom field.

field2

 

Field name or id for a custom field.

fieldConfigurationScheme

 

Field configuration scheme name or id. Use blank for default scheme.

fieldExcludes

 

Fields to exclude from cloning - comma separated list of fields.

file

f

Path to file based content or result output. Use - for standard input.

filter

 

Filter id or favorite filter name.

findReplace

 

Find and replace text. Comma separated list of colon separated pairs. Single quote values containing a delimiter. Embedded quotes must be doubled.

findReplaceRegex

 

Find and replace text with a regular expression. Comma separated list of colon separated pairs. Single quote values containing a delimiter. Embedded quotes must be doubled.

fixVersions

 

Fix versions - comma separated names or ids.

group

 

Group name.

help

 

Prints this help message.

host

 

Database host server for SQL actions. Not used if url is provided. (default: localhost)

id

 

Numeric id of an item.

issue

 

Issue key or id.

issueSecurityScheme

 

Issue security scheme name or id

issueTypeScheme

 

Issue type scheme name or id. Use blank for default scheme.

issueTypeScreenScheme

 

Issue type screen scheme name or id. Use blank for default scheme. JIRA 5.1 and later only.

jsp

 

Custom JSP name for clone actions.

labels

 

Labels or tags. A blank separated list.

lead

 

Project lead user id.

limit

 

Maximum number of entries to return. (default: 2147483647)

link

 

Link description.There are release level API differences on whether the link should be specified as the link type name (like 'relates') or the directed name (like 'relates to'). On later releases (JIRA 5.0+), link type name is the best choice. The link id can also be used for both linkIssue and deleteLink.

list

 

Comma separated list of entries. Single quote values containing a delimiter. Embedded quotes must be doubled.

login

 

Login token from previous login request.

loginFromStandardInput

l

Get login token from standard input. Only works for actions based solely on SOAP based server requests. Actions using REST based server requests require passwords on each action.

lookup

 

Lookup userId via search and validate. An error is reported if search does not return a single user.

name

 

Name.

notificationScheme

 

Notification scheme name or id.

outputFormat

 

Specify output format for an action. (default: 1)

parent

 

Parent issue key or id.

password

p

User password for remote access.

permissionScheme

 

Permission scheme name or id. (default: Default Permission Scheme)

port

 

Database host port for SQL actions. Optional, defaults to database default. Not used if url is provided.

preserveCase

 

Some actions (example addUser, addGroup) automatically lowercase names usually because the construct is case insensitive. Use this switch to override the default behavior and preserve the case.

priority

 

Issue priority - name or id.

project

 

Project name, key, or id.

propertyFile

 

Property file with mapping information.

propertyPrefix

 

Prefix used for accessing properties for custom clone actions.

quiet

 

Limit some output messages. Optional for all actions.

regex

 

Regular expression for including matching content. For example, used to subset projects or versions on getProjectList and runFromVersionList.

replace

 

Replace existing entity.

reporter

 

Issue reporter user id.

request

 

URL fragment for a request.

requestParameters

 

URL request parameters.

requestType

 

Type of a render request like GET or POST (default: GET)

resolution

 

Resolution name or id.

role

 

User role in project

search

 

Search JQL query.

security

 

Issue security level name or id.

server

s

Server URL.

service

 

Service address extension. (default: /rpc/soap/jirasoapservice-v2)

simulate

 

Simulate running actions. Log the action that would be taken.

special

 

Ordered list of alternate characters for comma (,), colon (, at (@), quote ('), and double quote (") characters used for specialized processing of some specific parameters.

sql

 

SQL select statement used to generate a run script.

step

 

Workflow step - name or id.

subtract

 

Subtract values from existing values custom fields supporting multiple values.

summary

 

Summary of issue.

timeSpent

 

Time spent on work using. Example: 3h 30m.

toComponent

 

Project component name or id for JIRA 4.4 or higher.

toIssue

 

Link destination issue key or id.

toProject

 

Project name, key, or id to copy to.

type

 

Issue type - name or id.

url

 

Action specific setting. Example: Database access url for SQL actions. Optional when host is provided.

useParentVersions

 

Copy parent versions to subtask when cloning an issue.

user

u

User name for remote access. (default: automation)

userEmail

 

User email for user management actions.

userFullName

 

User name for user management actions.

userId

 

User id for user management and other actions. For some actions, a comma separated list of ids.

userPassword

 

User password for user management actions.

value

 

Single field or property value.

values

 

Comma separated list of field values. Single quote values containing commas.

values2

 

Comma separated list of field values. Single quote values containing commas.

verbose

v

Requests verbose output to help with problem determination. Optional for all actions.

version

 

Project version name or id or plugin version.

workflowScheme

 

Workflow scheme name or id. Use blank for default scheme.

  • No labels

50 Comments

  1. For the "getAttachments" function, it seems the URL generated is not being URL escaped (based on tcpdump-ing the resulting requests), hence downloading (and I'd have guessed other functions will too) attachments with spaces in fails.  Is it possible to fix this, or am I missing something?

     

    Thanks

    1. Looking at the code the problem seems to be here: bob_swift/jira-cli/src/37ecf22c6759/src/main/java/org/swift/jira/cli/JiraClient.java#cl-2605

      However, it seems using wget/curl makes for an ok workaround. (smile)

      1. I think you are right. Please create an issue (issues tab) and it will be fixed soon.

  2. In JIRA 5, there are multiple user directories supported. The addUser command doesn't currently allow specifying a directory to use when creating a new user. Could this be added?

     

    1. No, since the API support is lacking. I know it is an important element, but I don't have a solution at this time.

  3. Hi,

    Trying to link two issues and receiving "Resource does not exists" error. After running with the -v flag, it gives a 404 Not Found error. The command being run is something like this

    jira.sh --server https://jira.notRealServer.com --user username --password password --action linkIssue --issue KEY-123 --toIssue KEY-456 --link "relates to"

    Any idea what could be causing this?

    Thanks for the help!

     

    1. See JCLI-291 and comment/add details there if that doesn't solve your issue.

      1. Seems to be working. On a side note though, JIRA in the Atlassian 2.7 snapshot is not the same as Jira 2.7 snapshot (there is no getLinkTypeList action). Is this intentional?

         

        1. No, but the ACLI version doesn't get built for every product specific fix yet. I will try to keep them more in sync soon. For now, check the dates. 

  4. Hi Bob - I'm trying to use the createIssue function, but I keep getting this message

     

    Remote error: Issue type 'whatever I enter' is not valid

     

    The project I am trying to create the issue for has several types including Detailed Design, Task, Defect, Build Request , etc...  I have tried all of the possibilities, and see the above mentioned error on each.  I was able to get it to work only with a type of 'Sub-task', which I pulled from an example on this site.  Any ideas what I am doing wrong. 

    Here is my command

     

    jira --action createIssue --parent RXPLAY-546 --type "Task" --summary "TestTask 2" --project RXPLAY

    1. Only subtask types are valid when you request to create a subtask by specifying a parent issue.

  5. Got it, thanks for the explanation.  I was confusing the parent action with trying to link the issue to another. 

    On another note, I tried to use the linkIssue action and ran into the same trouble Scott explained above.  It looks like I need to run the getLinkTypeList action to get the values I need to set the link type, however, I see 'Invalid action specified' errors when trying to run that action.  Any ideas what I am doing wrong?

    I tried this

    jira --action getLinkTypeList

    and this

    jira --action getLinkTypeList --file -

     

    Both return a 'Client error: Invalid action specified: GETLINKTYPELIST.' error..

     



    1. Dave, good. Regarding getLinkTypeList - that action is only available on 3.0 or later. Are you sure you are on that version? If not, either upgrade or consult the documentation for the release you are using - for instance 2.6.0 - Documentation

      Link actions can be a bit difficult because of the terminology and recent changes between using the link name instead of the directional name (underlying APIs used were different). 

  6. Thanks Bob.  I am, in fact, using 2.6.  I checked out the documentation, but I'm still a bit unclear of what values I should be using to specify the link type.  Is there somewhere in JIRA Admin where I can find the exact verbage I need to use? 

     

     

    1. See Issue Linking from administration. It lists the name, outward description, and inward description. The name needs to be used on later versions of JIRA.

  7. Hi Bob - I had our JIRA Admin look this  up for me.  I tried all the values, but still struggling to get it to work.  Can you take a look?

     

    First, here's the info from the Issue Linking section

     

    Duplicate             duplicates           is duplicated by Edit | Delete  = 10021

    Parent-Child       is a parent of      is a child of          Edit | Delete  = 10010

    Reference           relates to             is related to        Edit | Delete = 10030

     

    I'm trying to use the 'relates to' link type.  I have tried the following without success

     

    jira --action linkIssue --issue RXPLAY-551 --toIssue RXPLAY-549 --link "Reference"

    jira --action linkIssue --issue RXPLAY-551 --toIssue RXPLAY-549 --link "relates to"

    jira --action linkIssue --issue RXPLAY-551 --toIssue RXPLAY-549 --link "is related to"

    jira --action linkIssue --issue RXPLAY-551 --toIssue RXPLAY-549 --link "10030"

     

    All of these result in 'Remote error.  Resource does not exist.'

     

     

    1. Sorry you are having trouble. You will need to [create an issue|http://bobswift.atlassian.net/secure/CreateIssue!default.jspa] and provides details like JIRA release and output when you add --debug to your command.

      1. Thanks for your help Bob, I created an issue for this.

        1. The issue has limited visibility, but the resolution is that the link must match exactly the configured link definition and that includes blanks. Administrators should trim any leading or trailing blanks from link definition names to avoid confusion and problems like this.

  8. Hi Bob - I have encountered another issue, this time with the run action.  Was hoping you may be able to help.

     

    I am trying to run through a file that has 1 line which creates an issue using createIssue, and another which uses RunFromIssueList to link the issue that was just created to another.  When I run these statements seperately from the command line, they work fine.  However, when I put them both in a txt file and use the run command to loop through, only the createIssue statement works.  When it gets to the runFromIssueList line, it fails with the following message "Error: Unexpected argument: Reference\"". 

     

    Here's the run statement I am using

    jira --action run --file "C:/RUN/run7.txt"

     

    And, here is the contents of the Run7.txt file

    --action createIssue --type "Detailed Design" --summary "0000 | Sample RxHWT Project | Detailed Design | Tuxedo - New Service" --priority "Major" --date "12/19/12" --estimate "48h" --project "RXPLAY" --labels "DM0000 RMATEMP" --reporter aurandry--action runFromIssueList --search "issueType='Detailed Design' and labels = 'RMATEMP'" --common "--action linkIssue --issue \"@issue@\" --toIssue \"RXPRPLAY-116\" --link \"12. Reference\""

     

    Here is the output

    C:\>jira --action run --file "C:/RUN/run7.txt"

    Run: --action createIssue --type "Detailed Design" --summary "0000 | Sample RxHW
    T Project | Detailed Design | Tuxedo - New Service" --priority "Major" --date "1
    2/19/12" --estimate "48h" --project "RXPLAY" --labels "DM0000 RMATEMP" --reporte
    r aurandry
    Issue RXPLAY-668 created with id 96347. Labels added. URL: http://wagwiki.walgre
    ens.com/jira/browse/RXPLAY-668

    Run: --action runFromIssueList --search "issueType='Detailed Design' and labels
    = 'RMATEMP'" --common "--action linkIssue --issue \"RXPLAY-668\" --toIssue \"RXP
    RPLAY-116\" --link \"12. Reference\""

    Error: Unexpected argument: Reference\""

    Client error: 1 actions failed, 1 actions were successful from file: C:\RUN\run7
    .txt

     

    1. Please open issues for things like this. Also, use {noformat}. I will have a look, but I am confused by all the formatting.

       

  9. Got it, thanks.  An issue has been opened.

  10. Hi Bob!

    Is it possible to move issue from one project to another?

    1. No, there is no remote API for that. You need to use cloneIssue and then deleteIssue. Furthermore, to clone an issue to a different project requires Clone Plus Plugin for JIRA

  11. What would be the proper syntax to clear a due date?  I tried this:

    jira -a updateissue --issue <valid issue number> --date ""  

    but I just get  back:

    There are no field values changed by the parameters specified. Issue <issue number> not changed.

    I also tried sending a space, and got the same error.  

    1. See  JCLI-338 - Not able to make due date field NULL Closed

       

  12. Is it possible to use the CLI to set custom user properties? I would like to build a script which takes user's location information from our HR system and populate a custom property in JIRA "Location" from this data. I can't seem to find a method of doing this programmatically. If the CLI doesn't provide a means to do this, can you provide any guidance on what tools are available that might support this?

     

    1. See  JCLI-340 - Ability to set/update custom user properties from CLI Closed

  13. I noticed "estimate" is not listed as a parameter in the CreateIssue action.  Is there another way to add an estimate to an issue when creating it?  Would I have to use UpdateWork?

    1. Original estimate is not supported by remote APIs currently - see  JCLI-98 - Provide ability to set Original Estimate field Open . Yes, add/update work is the only way to deal with the current estimate.

  14. How do i use getIssueList action to show only the Key and Summary without having to create a custom outputFormat.

    1. It is not possible. Output format 101 is issue keys only, but that does not include Summary. The default format has both and a bunch of other fields. You might want to vote for JCLI-245.

  15. Hi Bob,

    When running specific queries I get resultsets containing over a 1000 issues. There is a 'limit' parameter which could help me. Is there also a "start" parameter? That way, I could run it from 1 through 1000 and continue from there.

    I just noticed btw that "runFromIssueList" on this page mentions "count" which says that it's deprecated.

    Regards!

    James

      1. limit is the same as count and is preferred usage. I opened JCLI-401 to rename references from count to limit. Thanks for alerting me to that. 
      2. JQL is limited to the system configured limit (normally 1000) - see answers for discussions on that.
      3. If you use a filter, then processing will automatically chunk results (500 at a time) up to the requested limit of issues. I don't recall if that is restricted by the system limit or not. Please check that out.
      4. You can define a filter using JQL, but that may be restricted by the system limit. 
      5. There is no way to start at a particular starting point.
  16. How do I get the IssueCount for a project using JIRA CLI ?

    1. getIssueList action returns the number of issues available in the list as the result string for the operation. Use --file to a null device like /dev/null (OS dependent) to throw away the list details. 

  17. Hi Bob,

    Using CLI, How do I add a group to JIRA users global permissions ?

    Thanks

    1. Not available, you will need to open an issue.

  18. Hi Bob,

     

    While doing deleteIssue i am getting below error; is there anything i am missing here?

     

    Client error: Invalid action specified: DELETEISSUE.  Use --help for more information.

     

    and following is the command i am using

     

    jira --action DELETEISSUE --issue "RNCTC-1986" --server "https://XXXXX.com" --user "XXXX" --password "XXXX" --continue

     

    Thanks

    1. deleteIssue is a valid action. I can't reproduce your problem. If you are still having problems, open an issue with the exact command and log.

  19. Hi Bob,

    Thanks for the response;

     

    I can open a issue but what kind of logs do you want me to provide; i am sorry i am a new user of this tool; i just downloaded JIRA cli 2.0 and started using it the only log i have is the one that comes on console

     

    D:\Tools\jira-cli-2.0.0-distribution\jira-cli-2.0.0>jira --action deleteIssue --project "RNC UP Testcases" --issue "RNCTC-1987" --server "https://xxx.com" --user "xxx" --password "xxx" --continue

    Client error: Invalid action specified: DELETEISSUE. Use --help for more information.

     

    Could you please guide me in this regard.; if you still want me to mention same details in Issue i can go ahead and raise bug in JIRA

     

    Thanks

    1. This documentation is for the latest release of the software. Install version 3.6 and then it will match the documentation here.


  20. Hi Bob,

     

    Now i have started using 3.6 version but i am getting following error; Does DeleteIssue needs special previleges? i am able to create the issue with same user but not able to delete the created Issue;

     

    D:\Tools\jira-cli-3.6.0-distribution\jira-cli-3.6.0>jira --action deleteIssue --project "RNC UP Testcases" --issue "RNCTC-1986" --server "https://xxxxx.com" --user "xxxx" --password "xxxx" --continue
    Ignore error trying to delete RNCTC-1986. Error: com.atlassian.jira.rpc.exception.RemotePermissionException: The project specified does not exist or you don't have permission to delete issues in it.

    1. The ability to delete an issue is a special permission in permission scheme. If you can do it from the UI, then you should be able to delete from the CLI (with the same user).

  21. Bob - is it right that unlike for Confluence, there's no support for listing or installing plugins in JCLI?

    Thanks, M.

    1. Correct, it was a unique Confluence service.

  22. Hi

    Is it possible to directly close an issue? progressIssue require that you know the status of the issue and updateIssue doesn't seem to have that possibility? Why?

    We are using JIRA for the SCRUM board but the "real" system is another and that is where the backog is so we need to sync. Since not everyone use JIRA yet (but work in the other system) I would need to close some issues directly. A workaround would be to delete those issues but closing would be nicer.

    /Linus

    1. Progress issue is the only thing that you can do to change the status of an issue. This is how JIRA workflow works. You need to know the workflow transition step that you want to use just like on the UI. Yes, you should just close them (not delete). Normally, that would be using progress issue with the close transition. If the problem is that you want to close issues that don't have a close transition, then you need to progress the issue through whatever workflow is necessary to eventually get to a status that allows the close transition. getAvailableSteps can help with that.

      A simple, alternative technique that we used extensively for automation, was to define workflow transitions (steps) from all status to closed that only automation (or administrators) would be able to see/use. Thus circumventing the normal flow. 

      1. Ok that's the way to go then. Thank you.

        You can set an issue to any state (overriding the workflow) if you update through the built in csv importer

        1. The importer is a bit of a unique situation.