Adding SSO after many users already signed up -- how to migrate them?

Excellent! Now what is the HTTP endpoint that I call in order to get all the user info, including password hash and salt?

I imagine that there isn’t one to serve up to the public at large (why make it easier to hack people?) So what can I do? Connect to the MySQL database? Write a Discourse plugin?