Oauth2 Authorization Flow with Apollo GraphQL Explorer

Has anyone found a way to have the Apollo GraphQL Explorer follow an Oauth2 Authorization Flow for obtaining an access token to the specified GraphQL Server rather than requiring manual entry in the request headers dialog?

This is something that SwaggerUI enables on our REST APIs which makes it really easy to use as individuals do not have to know how to obtain a token or grab it from an inspection window.


Hi! There’s no built-in way to set up an Oauth2 flow with Explorer, but we’re working on a way to run pre-flight scripts for requests in it which will be going out somewhat soon. We have some customers using this early-access to refresh their Oauth tokens so users don’t have to refresh headers themselves.

We also have a way to embed the Explorer on other websites so you could write your own custom authentication flow and then just have Explorer proxy requests to your site’s HTML. There’s info on how to do that here: Embedding the Explorer - Studio - Apollo GraphQL Docs