It's all about the answers!

Ask a question

How to execute a python script when a work item moves to a certain state

Ramona Pillay (11) | asked Mar 03 '20, 9:43 a.m.

 I have written a python script that calls rest api and gets data. It then stores this data in an xml file and attaches it to a work item. 

I want to be able to execute this python script when a work item is moves to a certain state. For example, creating a work item is in state 'new', so once the work item moves to 'in progress' i want this python script to be executed.
Has anyone done something similar or can point me in the right direction to achieve this.

One answer

permanent link
Ralph Schoon (63.2k33646) | answered Mar 04 '20, 3:43 a.m.

 You will have to write your own JAVA advisor or follow up action as a server extension. From that extension you would have to call your Python Script.

See especially the Extensions Workshop for reference. There are examples for work item save server extensions on the blog above.

Ramona Pillay commented Mar 04 '20, 5:33 a.m.

Thanks Ralph. I will give it a try.


Your answer

Register or to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.