Skip to main content
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Google third party authentication

Jump to solution
abhiGhag
Community Member

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:

Spoiler

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?

Labels (1)
0 Likes
1 Solution
abhiGhag
Community Member
Author

I solved this by changing Login Attribute to email in Admin -> Authentication -> Google.

View solution in original post

0 Likes
1 Reply
abhiGhag
Community Member
Author

I solved this by changing Login Attribute to email in Admin -> Authentication -> Google.

0 Likes