Discourse Connect Flow

Hi Ankit,
The flow is actually reverse of what you described. When you setup Discourse Connect on your site:

  1. Clicking the login button will take you to discourse_connect_url with 2 get params sso and sig.
  2. The user will enter their credentials on the discourse_connect_url and will be authenticated by your site, if the auth is successful, then you need to decode the sso and follow the further steps as described in Discourse Connect topic.