Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Retrieve object ID for an asset in automation

Enrique Sánchez July 3, 2025

I am working with a company managed project in Jira Service Management (Cloud, premium).

In a global automation rule, I want to follow this process:

https://support.atlassian.com/jira/kb/assets-automation-trigger-rule-based-on-attribute-update-for-jsm-cloud/

But it seems I can't use the {{object.id}} smart field as it throws an error.

Unable to render smart values when executing this rule:
Failed to get value for object.id: {{object.id}}

{{object}} returns the key of the asset (for example "DM-23") and the same goes for {{object.key}} or {{object.objectKey}}. Others like {{object.objectId}} throw the same error above.

The API call works OK if I enter the id manually, for example v1/object/23/history, but the issue is that I can't retrieve the triggering object ID to be able to use v1/object/{{object.id}}/history.

jira-isssue-01.png

Any ideas?

Thank you.

1 answer

1 accepted

0 votes
Answer accepted
Trudy Claspill
Community Champion
July 3, 2025

Hello @Enrique Sánchez 

Welcome to the Atlassian community.

Names used in smart values can be case sensitive. For me, this works for getting the object ID following the Object trigger:

{{object.ID}}

Enrique Sánchez July 3, 2025

Hi @Trudy Claspill

{{object.ID}} is not working either

Like John Funk likes this
Trudy Claspill
Community Champion
July 3, 2025

Can you provide a new screen image of the updated rule and the output in the Audit Log?

Like John Funk likes this
Enrique Sánchez July 3, 2025

Sure, here it is.

jira-isssue-02.png

Like John Funk likes this
Trudy Claspill
Community Champion
July 3, 2025

Both lower case id and upper case ID work for me.

Screenshot 2025-07-03 at 3.23.18 PM.png

In the past I have seen rules exhibit strange behavior if they are edited too many times. Can you try creating the rule from scratch?

Like Bill Sheboy likes this
Enrique Sánchez July 4, 2025

Oh, that seemed to be the issue. When I created a new rule from scratch, the object.id started working.

I will leave here how the full rule ended up. I also needed to retrieve some object attributes so I added a second web request.

jira-solution-01.pngThank you!

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events