I came across this old StackOverflow answer and I’m wondering how well it holds up. https://stackoverflow.com/questions/26055501/how-to-restrict-access-to-certain-routes-in-phoenix
This linked post is quite old.
You can build your own authentication, which is not so difficult, and explained in many Phoenix books.
Or You can use authentication libraries, like Pow, or others…