POST https://www.googleapis.com/identitytoolkit/v3/relyingparty/createAuthUri?fields=authUri&key={YOUR_API_KEY} Content-Type: application/json X-JavaScript-User-Agent: Google APIs Explorer {
"continueUri": "http://auth.sumneresc.org/login/gitkit.php",
"providerId": "google.com"
}
------------------------output----------------------------
400 Bad Request
- Show headers - {
"error": {
"errors": [
{
"domain": "global",
"reason": "invalid",
"message": "CONFIGURATION_NOT_FOUND"
}
],
"code": 400,
"message": "CONFIGURATION_NOT_FOUND"
}
}
If I run this code in my browser using Postman I get the following
https://www.googleapis.com/identitytoolkit/v3/relyingparty/createAuthUri?key=api_key&continueUri=http://auth.sumneresc.org/login/gitkit.php&providerId=google.com
--------output-----------------
{
"error": {
"errors": [
{
"domain": "usageLimits",
"reason": "accessNotConfigured",
"message": "Access Not Configured. The API is not enabled for your project, or there is a per-IP or per-Referer restriction configured on your API key and the request does not match these restrictions. Please use the Google Developers Console to update your configuration.",
"extendedHelp": "https://console.developers.google.com"
}
],
"code": 403,
"message": "Access Not Configured. The API is not enabled for your project, or there is a per-IP or per-Referer restriction configured on your API key and the request does not match these restrictions. Please use the Google Developers Console to update your configuration."
}
}
curl -d "{'providerId': 'google.com', 'continueUri':'http://auth.sumneresc.org/login/gitkit.php'}" -H "Content-Type: application/json" "https://www.googleapis.com/identitytoolkit/v3/relyingparty/createAuthUri?key=api-key-removed"
{
"error": {
"errors": [
{
"domain": "usageLimits",
"reason": "accessNotConfigured",
"message": "Access Not Configured. The API is not enabled for your project, or there is a per-IP or per-Referer restriction configured on your API key and the request does not match these restrictions. Please use the Google Developers Console to update your configuration.",
"extendedHelp": "https://console.developers.google.com"
}
],
"code": 403,
"message": "Access Not Configured. The API is not enabled for your project, or there is a per-IP or per-Referer restriction configured on your API key and the request does not match these restrictions. Please use the Google Developers Console to update your configuration."
}
}
administrator@LinuxVM:~$
$ curl -d "{'providerId': 'google.com', 'continueUri':'http://auth.sumneresc.org/login/gitkit.php'}" -H "Content-Type: application/json" --referer http://auth.sumneresc.org "https://www.googleapis.com/identitytoolkit/v3/relyingparty/createAuthUri?key=api-key-removed"
400 OK
"domain": "global","reason": "invalid","message": "CONFIGURATION_NOT_FOUND"}],"code": 400,"message": "CONFIGURATION_NOT_FOUND"}}
I'm confused as it is 400 OK and not a bad request etc.Would appreciate your help.Thanks,Sam