Re: Not able to catch error when guzzle fails

2021-02-02 Thread Google Ads API Forum Advisor Prod
Hi,

Thank you for reaching out. You could refer to this code snippet on how to 
handle the GoogleAdsException and ApiException. For the exceptions related to 
the Guzzle library, please refer to their documentation or reach out to the 
library owner to get further assistance.

Thanks and regards,
Xiaoming, Google Ads API Team

Xiaoming
Google Ads API Team
ref:_00D1U1174p._5004Q2BcdBa:ref

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/6f0jr0QNX2WY00hNAyMFi9SNmXb03BDYhOEQ%40sfdc.net.


Re: Not able to catch error when guzzle fails

2021-02-01 Thread cv
Hello Xiaoming,

Yes, that I am able to know but in this case I wanted to catch those errors 
so that my cronjobs or data fetch part not interrupted and gone through 
other accounts and capture those errors for error log i managed.

Thanks,
 

On Tuesday, 2 February 2021 at 02:09:34 UTC+5:30 adsapiforumadvisor wrote:

> Hi,
>
> Thank you for reaching out. “Account has been deleted” indicates that the 
> account that you used to generate the refresh token has been deleted. You 
> could recreate the OAuth2 credentials using a valid Google Ads account and 
> try the API call again.
>
> Thanks and regards,
> Xiaoming, Google Ads API Team
>  
> [image: Google Logo] 
> Xiaoming 
> Google Ads API Team 
>   
>
> ref:_00D1U1174p._5004Q2BcdBa:ref
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/6e855120-eb15-4841-9135-b61f6280af96n%40googlegroups.com.


RE: Not able to catch error when guzzle fails

2021-02-01 Thread Google Ads API Forum Advisor Prod
Hi,

Thank you for reaching out. “Account has been deleted” indicates that the 
account that you used to generate the refresh token has been deleted. You could 
recreate the OAuth2 credentials using a valid Google Ads account and try the 
API call again.

Thanks and regards,
Xiaoming, Google Ads API Team

Xiaoming
Google Ads API Team
ref:_00D1U1174p._5004Q2BcdBa:ref

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/JTuBZ0QNVAPJ00oZEL4SjrRc2tQRXSw03ykQ%40sfdc.net.


Not able to catch error when guzzle fails

2021-02-01 Thread cv
 

Hi,


When there error like this or guzzle fails, try catch is not able to 
capture errors.

I am using PHP client library in google ads v6.

Type:GuzzleHttp\Exception\ClientException

Message: Client error: `POST https://oauth2.googleapis.com/token` 
resulted in a `400 Bad Request` response:

{

  "error": "invalid_grant",

  "error_description": "Account has been deleted"

}


Filename:
/google-ads-php/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php

Line Number: 113


Thanks,


-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/b6ac892b-9057-493b-a837-fa4a6d2629e8n%40googlegroups.com.