Get information from the user email endpoint (JWT)

Hey guys o/

I have a small question regarding JWT and Forge. We are currently developing an app, but with Atlassian Connect. During the development process we found out that we need JWT to fetch information from the endpoint

/wiki/rest/api/user/email

which probably means, that we need a server backend. We now also asked ourselves if we could easily access that endpoint with Forge if our app has been approved to do so? Does anybody know how Forge handles JWT endpoints?

Thanks in advance!

PS: Sorry if I used the JWT term incorrectly. I’m not sure yet how that is exactly working ;( I should probably read up about it a little bit more in the near future.

1 Like

You also need to request the ACCESS_EMAIL_ADDRESSES scope as described in this post.

2 Likes

Hi @martin.gypser,

Currently it’s not possible to invoke the /wiki/rest/api/user/email endpoint from a Forge app. This is because Forge and Connect use differently underlying authentication mechanisms (Connect uses JWT and Forge uses OAuth 2.0) and some REST resources in our products don’t support both auth methods. The email endpoint currently only supports JWT.

We are actively working to get 100% OAuth 2.0 coverage across all Atlassian product REST APIs, and we are also investigating how to make sure GDPR-related functionality like this works suitable for Forge apps. So hopefully I will have a different answer for you in the future!

Cheers,
Joe.

1 Like

Thanks for the responses @dzagorovsky and @HeyJoe, really appreciated :slight_smile:

Sounds very interesting of having another option to access that endpoint besides of using JWT in the future. Looking forward to that. I don`t know if I may already ask that one, but do you have a rough estimation when this will be available in the future? Thank you in advance! :slight_smile:

Hey @martin.gypser,

I don’t have a timeline on the availability of this functionality yet, sorry to say. You may wish to keep an eye on the public Atlassian developer platform roadmap to see what is actively being worked on, and what is coming up next: https://trello.com/b/8XBuIeIu/atlassian-platform-for-developers-roadmap

Cheers,
Joe.

1 Like