Learn business growth with Google Analytics 4 › Forums › Google Analytics 4 › Retrieving a List of Accounts in Google Analytics 4 Admin › Reply To: Retrieving a List of Accounts in Google Analytics 4 Admin
-
The issue you’re experiencing might be linked to the permissions of the account used to create and authenticate your PHP client. Whether you’re using OAuth 2.0 or a Service Account for authentication, the account needs to have sufficient rights across all the accounts you’re trying to access. If the account only has access to one of your GA4 accounts, it would explain why you’re only seeing one result. To fix this issue, review the account’s permissions on all your GA4 and old Google Analytics accounts, ensuring it has enough access. If your account has appropriate permissions yet you’re still facing the issue, there may be a problem with the Google Analytics Admin API, specifically with the “listAccountSummaries()” and “listAccounts()” methods. You might want to refer to the API documentation or reach out to Google’s support for a possible solution or workaround.