How to configure access to a hosted Streamlit application behind Ghosts authentication and paywall tiers


I’m looking for help / guidance on how I would be able to integrate my Ghost site’s user authentication and paywall tiers to control access to the UI of a Streamlit application that is host via some cloud hosting service (e.g. hosted via Render).

Basically, I would like to sell a digital product that is only accessible for users who are a.) registered with my Ghost site and b.) on a specific paid tier.

My background is in data science/ML, not in web development so apologies if this is an obvious ask.

My rough ideas for a solution would be:

  • Host Streamlit application via something like Render
  • Setup a Page on my Ghost site that is accessible only by paid tier membership
  • Embed the Streamlit application UI as an iframe on that page
  • Concern: this means my web app needs to be public… How do I overcome this?

I’m sure there are better ways to do this, but this is what seems the easiest for me. Please feel free to suggest better alternative methods as well that would be more secure.

Thanks so much,