-
-
Save richieforeman/5bc9bfb03df34ca93cf3 to your computer and use it in GitHub Desktop.
Google Identity Toolkit test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import httplib2 | |
import json | |
http = httplib2.Http() | |
data = json.dumps({"identifier": "gmail.com", | |
"continueUrl": "http://localhost/cb"}) | |
resp, content = http.request("https://www.googleapis.com/identitytoolkit/v1/relyingparty/createAuthUrl?key=AIzaSyBBPyJTesgJeCeXqTzOG7TxwAj1zkbVWOI", | |
method="POST", | |
body=data) | |
print content | |
#### | |
{ | |
"error": { | |
"errors": [ | |
{ | |
"domain": "global", | |
"reason": "invalid", | |
"message": "Invalid identifier." | |
} | |
], | |
"code": 400, | |
"message": "Invalid identifier." | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment