Examples

Action usage examples

Examples give users ideas on actual usage. We use automation to generate, test, and run these actions, so names and combinations may be odd or repetitive (wink). In many cases, other actions or environmental setup is required for the action to run, so you will need to adjust the action parameters and setup appropriate for your environment. 

Command line environments can be different, especially between Windows and non-Windows systems. Our Tips page talks about command line escaping differences and there are differences with respect to environment variable references ($ for non-Windows and %...% for Windows). These differences can impact examples, so recognize and adjust for your platform. In particular, all examples here are run with the standard bash shell on Linux.



addAccount

--action addAccount --account "zcliaccounts" --lead "automation" --status "OPEN" --continue
--action addAccount --account "zcliaccounts" --name "zcliaccounts name" --lead "automation" --customer "My customer" --contact "contact@examplegear.com" --category "accounts category" --status "OPEN"
--action addAccount --account "zcliaccounts2" --name "zcliaccounts2 name" --lead "automation" --status "OPEN" --replace

addAccountLink

--action addAccountLink --account "zcliaccountlinks" --project "zcliaccountlinks" --continue
--action addAccountLink --account "zcliaccountlinks" --project "zcliaccountlinks" --options "default"

addCategory

--action addCategory --category "accounts category" --replace
--action addCategory --category "zclicategories" --continue
--action addCategory --category "zclicategories" --name "zclicategories name" --type "Internal"
--action addCategory --category "zclicategories2" --replace

addCustomer

--action addCustomer --customer "My customer" --replace
--action addCustomer --customer "zclicustomers" --continue
--action addCustomer --customer "zclicustomers" --name "zclicustomers name"
--action addCustomer --customer "zclicustomers2" --replace

addMembers

--action addMembers --team "CLI team" --members "automation" --continue

addTeam

--action addTeam --name "CLI team" --description "team description" --lead "automation" --mission "Test CLI"

addWorklog

--action addWorklog --issue "ZCLIWORKLOGS-1" --timeSpent "1h 10m" --comment "required" --estimate "1d"
--action addWorklog --issue "ZCLIWORKLOGS-1" --timeSpent "1h" --comment "Worklog for a specific day" --date "2018-03-01" --dateFormat "yyyy-MM-dd"
--action addWorklog --issue "ZCLIWORKLOGS-1" --timeSpent "1h" --comment "required" --account "zcliworklogs"
--action addWorklog --issue "ZCLIWORKLOGS-1" --timeSpent "1h" --comment "required" --account "zcliworklogs" --userId "developer"
--action addWorklog --issue "ZCLIWORKLOGS-1" --timeSpent "1h" --comment "to be deleted"

getAccount

--action getAccount --account "zcliaccountlinks"

getAccountLinkList

--action getAccountLinkList --account "zcliaccountlinks"

getAccountList

--action getAccountList

getCategoryList

--action getCategoryList

getClientInfo

--action getClientInfo
--action getClientInfo --outputFormat 2

getCustomerList

--action getCustomerList

getMember

--action getMember --team "CLI team" --name "automation"

getProgramList

--action getProgramList

getRoleList

--action getRoleList

getTeam

--action getTeam --team "180"
--action getTeam --team "CLI team"

getTeamList

--action getTeamList

getWorkAttributeList

--action getWorkAttributeList
--action getWorkAttributeList --regex "Account"

getWorklogList

--action getWorklogList --account "zcliworklogs" --dateFormat "yyyy-MM-dd HH:mm:ss"
--action getWorklogList --issue "ZCLIWORKLOGS-1" --dateFormat "yyyy-MM-dd HH:mm:ss"
--action getWorklogList --project "zcliworklogs" --dateFormat "yyyy-MM-dd HH:mm:ss"
--action getWorklogList --project "zcliworklogs" --dateFormat "yyyy-MM-dd HH:mm:ss" --fromDate "2017-11-01"
--action getWorklogList --project "zcliworklogs" --dateFormat "yyyy-MM-dd HH:mm:ss" --fromDate "2017-11-01" --toDate "2017-11-21"
--action getWorklogList --project "zcliworklogs" --regex "to be deleted.*"

runFromAccountList

--action runFromAccountList --common "-a getAccount --account @account@"

runFromTeamList

--action runFromTeamList --regex "CLI team.*" --common "-a getTeam --team @teamId@"

runFromWorklogList

--action runFromWorklogList --project "zcliworklogs" --regex "to be deleted.*" --common "-a getWorklog --id @worklogId@"
--action runFromWorklogList --project "zcliworklogs" --regex "to be deleted.*" --common "-a removeWorklog --id @worklogId@"

updateAccount

--action updateAccount --id "5" --account "zcliaccounts2changed" --name "zcliaccounts2 name changed" --status "OPEN"

updateCategory

--action updateCategory --id "359" --category "zclicategories2 changed" --name "zclicategories2 name changed"

updateCustomer

--action updateCustomer --id "359" --customer "zclicustomers2 changed" --name "zclicustomers2 name changed"

updateWorklog

--action updateWorklog --id "43147" --timeSpent "2h" --comment "to be deleted updated" --account "zcliworklogs" --estimate "3d"
--action updateWorklog --id "43148" --timeSpent "2h" --comment "to be deleted updated" --account "zcliworklogs" --estimate "3d"



Find answers from the community.


Ask a question to the community.


Log a request with our support team.


Confluence®, Jira®, Atlassian Bamboo®, Bitbucket®, Fisheye®, and Atlassian Crucible® are registered trademarks of Atlassian®
Copyright © 2005 - 2024 Appfire | All rights reserved. Appfire™, the 'Apps for makers™' slogan and Bob Swift Atlassian Apps™ are all trademarks of Appfire Technologies, LLC.