Google third party authentication
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am trying to set up Google as third-party authentication, and I am running into an error on login.
To add google as an authorization provider, I followed the steps listed here: https://community.canvaslms.com/t5/Admin-Guide/How-do-I-configure-third-party-authentication-provide.... Then I used the logins API to send a POST request as follows:
POST: https://domain.instructure.com/api/v1/accounts/1/logins
user[id]:123
login[unique_id]:email@domain.com
login[authentication_provider_id]:google
This is the error I get when I try to login using google auth:
Failed to Log In
Canvas doesn't have an account for user: 114****************762
You can try to log in again.
Now, if I change my POST request to send the 114****************762 from the error message as unique_id in the logins POST request instead of my email address, google auth works perfectly fine. I can send this id in the POST, but I am not sure how to find this id for all users we want to enable Google authentication. I tried a few endpoints, including https://domain.instructure.com/api/v1/users/123, to get this id but couldn't find it.
What's the best way forward here?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I solved this by changing Login Attribute to email in Admin -> Authentication -> Google.