This is a command line interface (CLI) for remotely accessing Atlassian products. This provides a convenient way to automate administration tasks and content for Atlassian products. Examples are build and test automation or other business processes. This is a working command line client that can be used directly with your installation. This distribution makes it convenient to have a single installation to access all your Atlassian products. For each product, it is functionally equivalent to the individual product (at the same release level) as it is derived from the built individual products. If you only have one Atlassian product, you should just use the product specific CLI download.
All CLI tools have standard interfaces and implementations. They share common components that can be used to build additional CLI-like tools.
Product dependency
All tools are dependent on the products implementing remote interfaces for the capabilities needed remotely. Atlassian product enhancements may be needed before a specific capability can be exposed in the CLI. Raise product issues or vote for existing remote API enhancement requests.
The Crowd remote interfaces are primarily for authorization. Once the remote API is expanded to provide operational actions and information, Crowd CLI will be included in the suite of CLI products.
Installation
Unzip the distribution package and put the enclosed directory in a convenient location
Ensure the Remote API capability is enabled for any product you wish to access with the client.
Usage
On a command line, cd to the directory where you installed the client
On Windows
Run the product specific (confluence, jira, bamboo, fisheye) bat file
On Linux (or Windows)
Run java -jar release/<product>-cli-1.x.x.jar
This will show help text for the command line interface client
The client defaults to use a user of automation. Either add this user with all the authorities required to do the actions you want or specify a different user parameter
It is recommended that you open each product bat file with an editor and customize it for your environment by adding server, user, and password parameters. Follow the example in the comments and make sure you do not remove the %* at the end of the line.
Each client comes with standard elp text displayed by the default command or using --help. This gives the precise definition of parameters. The product specific CLI pages have a copy of the online help. All follow standards and all have consistent parameters for cross product functions like action, server, user, password, file, ...
Tips
Use single dash for single letter parameters - example: -v
Use double dash for multi-letter parameter - 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 value.
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 (...) - example: (-a|--action) <action>
Some parameters are optional - indicated by [CODEGEIST:...] - example: [(-f|CODEGEIST:--file) <file>]
Values that have more than one word must be enclosed by double quotes - example: --title "this is my title"
Error handling
Care is taken to return the appropriate exit codes to the command processor. This makes it possible do error handling in automation scripts. Error and error logging output is directed to standard error.
Error type
Exit code
Description
SUCCESS
0
Normal exit
CLIENT_EXCEPTION
-1
The client has found a problem with the request and is reporting an error with a message.
PARAMETER_PROBLEM
-2
The client processed the command parameters and found a syntax error or missing required parameters according to the parameter definition
REMOTE_EXCEPTION
-3
The remote system has reported an error. The error message comes from the server.
I have downloaded the crucible-cli-1.0.0-distribution.zip file and installed it....
I have downloaded the crucible-cli-1.0.0-distribution.zip file and installed it. I have it working but the documentation at http://confluence.atlassian.com/display/CODEGEIST/Crucible+Command+Line+Interfaceshows[--attribute <attribute>]
Review attribute (comment, reviewitems, ...)
The Review attribute of "comment" does not work, however, "comments" does. You should correct the page listed above.
I would also like to know what other Review attribute values are available. (comments, reviewitems, ...). Please expand on the ...
What values are permitted for state in -a listReviews --state "open"
I have tried open, closed, and draft each separately and they each return all of the Closed, Draft, and Review records.
Is there a way of getting replies to comments? This CLI and the crucible plugin to export to a PDF file do not show replies.
Dale, sorry, you are on your own for Crucible for a while - I will not be able t...
Dale, sorry, you are on your own for Crucible for a while - I will not be able to get back to this support for a few months. Atlassian has been gradually making more Crucible interfaces available especially in the upcoming 1.6, but I don't know all the details.
Comments (4)
Jul 31
Paul Csapo says:
Hi Bob, is this now obsolete and replaced with this one? http://confluence.atlas...Hi Bob, is this now obsolete and replaced with this one? http://confluence.atlassian.com/display/CONFEXT/Confluence+Command+Line+Interface
Jul 31
Bob Swift says:
No, it is included in this. This is a bundle of the others.No, it is included in this. This is a bundle of the others.
Sep 19
Dale Miller says:
I have downloaded the crucible-cli-1.0.0-distribution.zip file and installed it....I have downloaded the crucible-cli-1.0.0-distribution.zip file and installed it. I have it working but the documentation at http://confluence.atlassian.com/display/CODEGEIST/Crucible+Command+Line+Interfaceshows [--attribute <attribute>]
Review attribute (comment, reviewitems, ...)
The Review attribute of "comment" does not work, however, "comments" does. You should correct the page listed above.
I would also like to know what other Review attribute values are available. (comments, reviewitems, ...). Please expand on the ...
What values are permitted for state in -a listReviews --state "open"
I have tried open, closed, and draft each separately and they each return all of the Closed, Draft, and Review records.
Is there a way of getting replies to comments? This CLI and the crucible plugin to export to a PDF file do not show replies.
Sep 20
Bob Swift says:
Dale, sorry, you are on your own for Crucible for a while - I will not be able t...Dale, sorry, you are on your own for Crucible for a while - I will not be able to get back to this support for a few months. Atlassian has been gradually making more Crucible interfaces available especially in the upcoming 1.6, but I don't know all the details.