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

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,557,403
Community Members
 
Community Events
184
Community Groups

Automation - Build Authorization Header Value from Previous Web Response

Edited

Hello

I have a web response that validates correctly

jira-screeshot-1.png

The payload returned is:

{
  "access_token": "<snip>",
  "refresh_token": "<snip>",
  "scope": "useraccount",
  "token_type": "Bearer",
  "expires_in": 1799
}


I do have "Delay execution of subsequent rule actions until we've received a response for this web request" checked

I have another send web request that needs to use the access_token in its Authorization header value like so:

jira-screenshot-2.png

The full value is Bearer {{webResponse.body.access_token}}

Thus far I have not been able to successfully build this string :( and validating the second request returns authorization failed. I have tested copy/pasting the access_token into the header and it does work 

UPDATE ***

I believe the token is being passed at this point (after testing) however now it seems like the Web request URL isn't accepting the custom field value

https://some/api/endpoint?number={{issue.customfield_123456.value}}

Any help is appreciated 

1 answer

1 accepted

1 vote
Answer accepted

Looks like I've been able to answer this myself

The custom field value is text so it looks like in both cases all I had to do was remove the .value 

{{issue.customfield_123456}} worked.

Can I know from where this value is retrieved  : {{issue.customfield_123456}}  ?

Isn't adding Bearer followed by {{webResponse.body.access_token}} working still ?

Because I need same value to insert in my headers section for another webrequest to trigger, please help. Even adding {{webResponse}} in audit log also not helping/displaying any value.

It's working, smart values are working.  What I was missing is didn't change any value on the field value of Jira story as we created automation rule for webhook for story point estimate. 

As soon as I change value on the field "story point estimate" from existing value to the other, then my automation rule invoked webhook with authorization.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events