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

Perform an Applinks REST request as administrator?

Adrien Ragot 2
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.
October 5, 2015

I'm developing a Confluence & JIRA plugin, with REST resources on both sides. I use Applinks to authenticate requests. There is a REST resource in Confluence that should only be accessed from my JIRA plugin.

ApplicationLink appLink = filter(applinks.getApplicationLinks());
ApplicationLinkRequestFactory requestFactory = appLink.createAuthenticatedRequestFactory();
ApplicationLinkRequest request = requestFactory.createRequest(Request.MethodType.PUT, url);
request.execute();

This code executes the request as the logged-in JIRA user (e.g. if the user is 'user1' in JIRA, then it will authenticate the request as 'user1' in Confluence). It's not desirable, because I don't want 'user1' to be able to perform this call from the browser.

Simliarly:

  • createAuthenticatedRequestFactory() executes as the current user,
  • createImpersonatingAuthenticatedRequestFactory() also,
  • createNonImpersonatingAuthenticatedRequestFactory() executes as anonymous.

Isn't there any Applinks request which can perform a REST call as an administrator?

2 answers

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

1 vote
Answer accepted
Volodymyr Krupach
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.
October 5, 2015
Adrien Ragot 2
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.
October 5, 2015

Excellent! And sorry that I'm new to JIRA, but how to I get the list of administrators? Just give me the general direction and I'll search. Thank you!

Volodymyr Krupach
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.
October 5, 2015

I guess you can list JIRA admin group.

0 votes
Pradeep Pandit March 10, 2017

Hello,

I am trying to update applinks after refresh from production to QA and or development. Just wondering what is the best way to do it. I have seen some database queries in documentation. But it would be nice if there is a way to automate the update process.

Any help is appreciated...

TAGS
AUG Leaders

Atlassian Community Events