Skip to main content

I'm trying to get my asset management in order and something my company (Nucor) as a whole could benefit from possibly as a workflow or having a toggle to have the Last Login By on the asset page to update the Used By field. Currently we have to hand jam every user into the individual asset and with most of our divisions having 1000+ users per site it can really be a pain.

Does anyone know of a resource or agent we could utilize to use the JSON and Web request in workflow if that would be a possible resolution. I believe if we can just transfer the info we need from the asset to the user we could avoid even using the probe.

I hope i was able to explain that well enough if anyone has any possible solutions i am all ears!

Any progress on this? Had the same question.


Ignore that, I figured it out! ^


Ignore that, I figured it out! ^

Would you mind sharing your solution/approach that you used for this issue. Thanks


Sure thing! I initially used the Fresh service Discovery agent thinking it would auto assign the used by field based on the “Last Logged In” field but turns out you need the probe as well. Since we don’t have an on Prem AD we couldn’t even set up the probe. 

The work around I used was creating a workflow that gets the Last Logged user and puts it into the Used By field of the asset.

In order to do this you have to make a Custom Object and create records of all the requesters you expect to be assigned to assets. I just exported all of our requesters, set them up how I needed, and imported them into my custom object. For the custom object you need the Name of the user that the FS agent pulls and the requesters email. For example: Name: “FirstLast” or “BillyBob” is what the agent will pull for the users name and then that requesters email to match the user flast@example.com or bbob@example.com.

How it should look in the custom object for all users

Then in my workflow I set my trigger to be when the asset is updated, it reads from my custom object, GETs that requester in FS by the email in the custom object record, parses that data, and PUTs the requester in the Used by field.

                                 Here is the endpoint I used for my Get web request

                     When you parse that data make sure you enter a 0 here for requester id

                         Here is the endpoint and body I used for my Put web request

user_id is the “Used By” field

This is how ours works, still trying to find a better way to update my custom object when we have new requesters so I don’t have to manually add them into my custom object (if anyone has some insight on that I would really appreciate it). But every time the FS agent pulls a new requester name on a device it will update to that user (we have an issue with people signing in to different computers lol). 

If you run into any issues just let me know and I hope this helps!


You're on the right track! Using a workflow with JSON and Web Requests could definitely help automate updating the "Used By" field based on "Last Login By." You might not need a probe at all if the data exists in your system. Look into setting up a custom workflow that pulls the login data via API and maps it to the asset's "Used By" field. It could save tons of manual work across divisions.


Sure thing! I initially used the Fresh service Discovery agent thinking it would auto assign the used by field based on the “Last Logged In” field but turns out you need the probe as well. Since we don’t have an on Prem AD we couldn’t even set up the probe. 

The work around I used was creating a workflow that gets the Last Logged user and puts it into the Used By field of the asset.

In order to do this you have to make a Custom Object and create records of all the requesters you expect to be assigned to assets. I just exported all of our requesters, set them up how I needed, and imported them into my custom object. For the custom object you need the Name of the user that the FS agent pulls and the requesters email. For example: Name: “FirstLast” or “BillyBob” is what the agent will pull for the users name and then that requesters email to match the user flast@example.com or bbob@example.com.

How it should look in the custom object for all users

Then in my workflow I set my trigger to be when the asset is updated, it reads from my custom object, GETs that requester in FS by the email in the custom object record, parses that data, and PUTs the requester in the Used by field.

                                 Here is the endpoint I used for my Get web request

                     When you parse that data make sure you enter a 0 here for requester id

                         Here is the endpoint and body I used for my Put web request

user_id is the “Used By” field

This is how ours works, still trying to find a better way to update my custom object when we have new requesters so I don’t have to manually add them into my custom object (if anyone has some insight on that I would really appreciate it). But every time the FS agent pulls a new requester name on a device it will update to that user (we have an issue with people signing in to different computers lol). 

If you run into any issues just let me know and I hope this helps!

Hello, 


First of all, thank you for sharing your experience.
We are also in the process of integrating freshservice and are asking ourselves the same questions.

You say : “The work around I used was creating a workflow that gets the Last Logged user and puts it into the Used By field of the asset.”
When we go through a web request, we don't have this field available in the results.

How did you manage to get the “last loggin by” or “last used by” field?

Thanks again for your contribution !


That’s the issue I also had. Since the “Last Logged In” isn’t really a field we can use I had to create a custom object. This is where the reader comes into play because you have to format the name the Freshservice Agent pulls for that “Last Logged In” field to look exactly like it and add the corresponding requesters email.

 

This way when it reads the requester Name it will pull them by the corresponding Email and then place them in the “Used By” field. I wish it was as simple as pulling the name from “Last Logged In” and updating the “Used By” but that’s how I worked around it. The custom object basically makes up for the missing “Last Logged In” field.

If you could show me your flow or how you have it set up I can also help that way if this doesn’t clear it up.

Also make sure you only change this in your Parse.

 


Using the call below I’m pulling the first.last of the users that last logged in to the machine.  Then I’m taking that first.last and adding our domain (first.last@contoso.com) then using that output and searching against the requestors in freshservice. Then I pull the users “id” from the requestor info and assigning that to the asset. 

 

I use this API call to get the Last Logged in by fields. 

 


Reply