Can a ticket workflow change the status of all assets assigned to it?

We are working on a better way to track when we put back up classroom equipment into the field temporarily. 

Our current process idea is to create a form for use in tracking the setup and tear down of equipment. We would also like to be able to track which equipment is currently deployed in any ticket. I would like to avoid having to use both steps of creating the ticket with the form and updating the assets being checked out. This would be fairly easy if we were able to change either the status or a custom attribute on an asset during ticket creation if those assets were included on the form. Is there an option to do this? 

Tags assets forms
Asked by Patrick Lisk on Fri 5/18/18 3:01 PM
Sign In to leave feedback or contribute an answer

Answers (3)

This answer has been marked as the accepted answer
Mark Sayers Fri 5/18/18 3:17 PM

Hello Patrick,

That is a great question, unfortunately workflows do not have any functionality built into them currently to allow the assets included on the ticket to be updated.

With that being said, you could theoretically build out web service steps into your workflow which call the API to get the details of that ticket, use it's ID to get the assets associated with the ticket, then go and update all associated asset to whichever status you'd want them to have.

Our API documentation is located at https://api.teamdynamix.com/TDWebApi/ if you'd like to take a look into exploring that option.

Sincerely,
Mark Sayers
TD Support

No feedback

Jackson Potter Wed 5/23/18 3:31 PM

I'm interested in any solutions for this as well.

I've tried to make it work with web service steps in a workflow, but the issue is that the only endpoint for updating assets ( https://api.teamdynamix.com/TDWebApi/Home/section/Assets#POSTapi/{appId}/assets/{id} ) requires the entire asset object to be included in the call, instead of just the modified values. If you don't, then all the unincluded values get cleared out. Having a standard JSON body isn't viable, and it's impossible to build the whole unique JSON object in the workflow for each asset.

1 of 1 users found this helpful.
Hi Jackson,

Did you get this working? I think you have to post the entire asset. So that is at least a two part process.
One web service step to get the asset in it's entirty and save its response code.
A second web service step to post to the asset, with updates, using the response code saved in the first web service step.

The web service step says this about the response code.
When a web service call successfully executes, you can store the resulting HTTP response code or response body in the workflow's context so that it can be referenced in another web service call.

These fields indicate the names under which these values will be stored, at which point they can be referenced by a web service method parameter when "From the workflow" is selected as that parameter's source.

I'm just starting this, and found your ticket. Hope you got somewere with this. Good luck!
- Torstein Early Thu 5/19/22 6:35 PM

Greg Benn Tue 11/15/22 3:56 PM

There is the PATCH endpoint for Asset now. This might help.

No feedback