I am new to Confluence and i have been assigned to develop a custom macro that fetches JIRA issues from Confluence, process a customfield on these issues and create a graph in a Confluence page. So far i have set up the JIRA and Confluence on my localsystem, linked them together and developed a macro that creates a graph(with some dummy values).
I tried to fetch the the JIRA issues using the api , but it was giving me a http400 bad request. I am not sure if its because of the authentication problem(since i was getting the same error message in postman, but worked in browser when i was logged in). Is it because of authentication problem? or my approach does not work?
By linked them together you mean an application link? You are right, it probably is an authentication problem because there's probably no information in your requests that would allow Jira to identify that the request is in fact coming from your Confluence. In the browser it works because the user is authenticated.
Since your instances are already linked you should take a look at the Application Link Java API which provides a way to make authenticated requests. There are some threads about how to use this API on the Atlassian Developer Community.
In general you should post app development related questions to the Atlassian Developer Community. :)
- Create your own custom emoji 🔥 - "Shake for Feedback" on mobile 📱 - An endless supply of GIFs via GIPHY 🤩 Is there anything quite as nice as a pleasant surprise? Comment below with what...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events