Posts tagged with authentication

I'm encountering an issue with the Google Ads API where I'm receiving the following error message:

Credentials failed to obtain metadata

This error occurs when making requests to the Google Ads API using the GoogleAdsService/Search method. Here's an example of the request and response details:

Request

MethodName: google.ads.googleads.v16.services.GoogleAdsService/Search Endpoint: googleads.googleapis.com:443 Headers: {developer-token=REDACTED, login-customer-id=9854212609, x-goog-api-client=gl-java/17.0.10__Oracle-Corporation gccl/31.0.0 gapic/31.0.0 gax/2.47.0 grpc/1.62.2} Body: customer_id: "9854212609" query: "SELECT campaign.id, campaign.name FROM campaign" 

Response

Headers: null Body: null Failure message: null Status: Status{code=UNAVAILABLE, description=Credentials failed to obtain metadata, cause=com.google.auth.oauth2.GoogleAuthException: com.google.api.client.http.HttpResponseException: 401 Unauthorized POST https://oauth2.googleapis.com/token 

...

Here are the details of my configuration:

  • I'm using Spring Boot for my application.
  • I have a google-ads.properties file where I've configured the necessary credentials such as clientId, clientSecret, refreshToken, developerToken, and loginCustomerId.
  • I've implemented the Google Ads client using the GoogleAdsClient class provided by the Google Ads Java library.
  • I've verified that the credentials are correct and have the necessary permissions to access the Google Ads API.

Despite these configurations, I'm still encountering the error mentioned above. I'm not sure what could be causing the issue. Any insights or suggestions on how to troubleshoot and resolve this would be greatly appreciated.

Thank you in advance for your help!

based on the provided error message and the details of the configuration, I expected the Google Ads API requests to authenticate successfully and return the requested data. However, the actual result was a failure with the message "Credentials failed to obtain metadata," indicating an authentication issue.

We are using Facebook Login and public_profile advanced access for an iOS app. All reviews are done and on the dashboard there is nothing to submit for a review, all green lights(Business Review is done). When we try to login via an account which has a role on the meta developer "published"(live in old terminology) app, we are seeing the warning below.


Submit for Login Review Some of the permission below have not been approved for use by Facebook.

Submit for review now or learn more

If you are not using Limited Login, you will need to hand all Graph API calls using Graph API, IOS. The access token will not be valid. To learn more about changes to the Facebook SDK for iOS and how you can continue using the Facebook Login SDK, visit the blog.


Issue is that, when you click on Submit for a Review on the warning, it takes you to App Review tab on the meta developers dashboard which does not have anything to submit for a review and everything looks ok.

Anyone has ever seen this? How did you solve the issue? Thanks for the help!

We have doubled checked that app is only using login and public_profile. We are on the newest SDK due to Privacy Manifest requirements of the iOS that is why we are using Limited Login on iOS as well. Normally we should not see this warning but it keeps showing up. I could not find much at the internet regarding the note about "Graph API". Not sure if we somehow call Graph API still but since SDK is updated, this should not happened. How can we check this and make sure that we are not using Limited Login properly or still using Graph API somewhere?

I have been trying to build an app (react for front end with typescript) that requires social media integration from various platforms, one of which is Facebook. So, I tried to follow the Meta docs and tried to implement the Facebook Login through their SDK code. The login alone was not very difficult to code, however when I refresh the page or switch to a different page and then return back to the one with the Facebook Login button, I am automatically logged out, and need to log back in every time.

I have looked through so many resources and forums trying to understand how to properly implement the Facebook login where a user can safely log in and would stay logged in throughout page refreshes until they directly click on a logout button. I feel like the Meta docs are pretty good, but the code and instructions they provide are in "pieces", if that makes sense. So, are there any full-length, detailed tutorials or guides available that I can follow along to implement this feature?