2

I'd like to consume the Notion API from a mobile app that I am developing. When trying to set up the redirect URI, it doesn't seem possible to use a redirect URI that does not use the https scheme. Every time that I type in a custom scheme, it gets prefixed with https://. My desired implementation is to open the mobile web browser to perform the Notion authentication and OAuth authorization, and then have Notion redirect back to my application. I would like to use a custom scheme like myapp://notion/oauth. Is there a way to register a non-HTTPS redirect URI?

Michael Collins
  • 289
  • 2
  • 13

1 Answers1

0

Notion is an HTTP API, so for it to redirect to another service it would have to also use HTTP.

You can, however, register URL handlers for your app so the HTTP redirect process will open your app with the appropriate page.

Nick McCurdy
  • 17,658
  • 5
  • 50
  • 82
  • I know it’s an HTTP API. Mobile apps can create and use custom protocol schemes so that the OAuth protocol redirects to my app instead of a web server. This is common when using mobile apps as OAuth clients. The Notion website is not allowing anything but an HTTPS protocol to be used. – Michael Collins Aug 01 '22 at 05:29
  • Yes but my point is that even without a custom protocol scheme, you still should be able to registry HTTP handlers for your app. – Nick McCurdy Aug 01 '22 at 07:00
  • The only way to do that is through domain association, which I do not want to do. Again, I’m trying to use the external mobile browser and not an embedded web view for security reasons. Your idea of HTTP handlers will not work in this case. – Michael Collins Aug 01 '22 at 14:19