-
Notifications
You must be signed in to change notification settings - Fork 42
Description
I've gone through all the setup instructions, and looked through previous Issues here but can't find any solution to getting this working. I'm wondering if there's been Google updates that have broken this? Initially I thought it might be because my Analytics property is GA4, so I created a 2nd one that's GA3/GA4, but the same issue persists.
Console errors:
Uncaught (in promise)
{error: {…}}
error:
code: 403
errors: [{…}]
message: "User does not have sufficient permissions for this profile."
Browsing to the above url (ID removed) gives the following output:
{
"error": {
"code": 401,
"message": "Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.",
"errors": [
{
"message": "Login Required.",
"domain": "global",
"reason": "required",
"location": "Authorization",
"locationType": "header"
}
],
"status": "UNAUTHENTICATED"
}
}
It's not that useful a message in the end as any malformed or even missing data seems to produce the same error. The best I can take from that is that none of login credential info is getting through. The instructions for GA_KEY_FILEPATH are a little ambiguous (is this an OS path or partial URL?) - I tried both and also using the GA_KEY_CONTENT to make sure. Same result.
Steps I've followed (and re-followed from scratch to make sure I'm not doing something stupid):
- Create new project in Cloud console.
- Enable Analytics API
- Create service account with Viewer role.
- Create key.
- Copy service account email address.
- In Analytics console, add service account email address to property with Read & Analyse access.
- Add relevant entries to local.py using property ID from property settings. I've tried with both GA_KEY_FILEPATH and GA_KEY_CONTENT.


