Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Adding value in request response to now

Hi everyone,

I'm trying to add the value from the rest response over the current date;

To access the variable i am using;

{{webhookResponse.body.table.body.rows.valueColumns.value.get(0)}}

This gives me a decimal number like 87.5 which represent hours.

I need to add this value on current date with plusHours method. I tried many methods but i couldn't make it;

{{now.plusHours( {{webhookResponse.body.table.body.rows.valueColumns.value.get(0)}} )}}
{{now.plusHours({{asNumber}}{{webhookResponse.body.table.body.rows.valueColumns.value.get(0)}})}}

{{#webhookResponse.body.table.body.rows.valueColumns}}{{now.plusHours({{value.get(0)}})}}{{/webhookResponse.body.table.body.rows.valueColumns}}

None of these methods work.

On cloud i am using Create Variable action to assign this value on a variable but on datacenter Create Variable action not available. So I am trying to use access directly to variable. 


I'm open to all advice, thanks !

1 answer

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
Feb 28, 2023

Hi @Ömer 

Once inside a set of curly-brackets you do not need to repeat them.  Please try this:

{{now.plusHours(webhookResponse.body.table.body.rows.valueColumns.value.get(0).asNumber)}}

Kind regards,
Bill

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events