How to obtain a bearer token for a third party client
I want to try and write a simple mobile app. As a "hello world" it could just fetch the data model for a given workspace. This requires a bearer token - not an API key.
Is there currently a way to achieve this? A way for the app to hit the server and become authorized?
10 Replies
Api Keys are bearer token technically
you can create api keys here
/settings/developers
after toggling the Advance toggleSorry, I know API keys are accepted, but there are parts of the API that require a real bearer token - like identifying the current user
ohh, I see, what part of the API are you thinking about?
Well, current user is one lol. Basically, I want to be able to do the login flow from a mobile app and potentially show all the same info as the web app
Yes, indeed, I was thinking about REST Api which does not exposes the currentUser endpoint. But the grahqlApi does
@Félix what do you think?
What prevents you from getting a bearer token using the login flow and then use that to request currentUser?
Oh I'm just not sure how to go about it. I wasn't able to find the relevant endpoint(s)
You can look for for challenge and verify endpoints (additionally, you can check what calls are made when login with the web app in the developer console)
Ok I'll give it a shot
Unknown User•4w ago
Message Not Public
Sign In & Join Server To View