Not authorized to use the ReportService.Search method to query the ProductView table.

70 views
Skip to first unread message

Tom Eriksson

unread,
Nov 1, 2022, 10:58:18 AM11/1/22
to Google Content API for Shopping
Hey! I am creating a POC app script for querying data from merchant center. I read in the api docs that it is possible to query the ProductsView table as well as the MerchantPerformanceView table. The MerchantPerformanceView query works just fine, but when I query the sample query from the docs (see below) I get an unauthorised response: "GoogleJsonResponseException: API call to content.reports.search failed with error: [Not authorized to use the ReportService.Search method to query the ProductView table.]"

Since only specified merchants have access to this part of the API I requested and got a confirmation email back stating that I now have access. But I still can't manage to get it to work. Has anyone else stumbled into this problem before?

SELECT
  product_view.id,
  product_view.offer_id,
  product_view.title,
  product_view.brand,
  product_view.currency_code,
  product_view.price_micros,
  product_view.language_code,
  product_view.condition,
  product_view.channel,
  product_view.availability,
  product_view.shipping_label,
  product_view.gtin,
  product_view.item_group_id,
  product_view.creation_time,
  product_view.expiration_date,
  product_view.aggregated_destination_status,
  product_view.item_issues
FROM ProductView
WHERE product_view.aggregated_destination_status = 'NOT_ELIGIBLE_OR_DISAPPROVED'

Shopping API Forum Advisor

unread,
Nov 2, 2022, 2:03:44 AM11/2/22
to google-content-...@googlegroups.com

Hi Tom,

 

This is Ciara from the Content API support team. Thank you for reaching out.

 

For us to investigate further, kindly provide us with the following details:

  • Merchant Center ID
  • email address used for the request
  • Date when you received the confirmation for access on the said service.

Kindly provide it via the Reply privately to author option. If this option is not available, please send this requested information through our email <shopping-a...@google.com> instead for private purposes.

 

Looking forward to your response.

 

Regards,

Google Logo
Ciara
Content API for Shopping Team
 


ref:_00D1U1174p._5004Q2fqUs7:ref

James Pell

unread,
Jan 9, 2023, 5:01:40 AMJan 9
to Google Content API for Shopping
Hi,

I am also getting this error message when attempting the following query on the reports/search REST endpoint.

Query:
SELECT product_view.id, product_view.title FROM ProductView

Error:
Project not authorized to use the ReportService.Search method to query the ProductView table. The oauth2 token being used to produce the error is an offline oauth2 token.

This request runs successfully when using it with the API explorer on the reference page:
I believe that the API explorer uses an online oauth2 token.

I have checked that the Content API for Shopping is enabled for the Google Cloud Platform Project that I am using for the request.

Both oauth2 tokens being used have the required auth scope.

Additionally I can run other reports for different tables e.g. PriceCompetitivenessProductView without producing this error, therefor I believe this could be a bug.

Shopping API Forum Advisor

unread,
Jan 9, 2023, 12:32:04 PMJan 9
to james...@gear4music.com, google-content-...@googlegroups.com
Hi James,

Please share the following details using 'Reply privately to author' option:
  1. Merchant Center id
  2. Screenshots of API explorer request and response
  3. Date and timestamp of the API request using API explorer
  4. User email address used for API explorer
  5. API request and error response (include HTTP request)
  6. Date and timestamp of the API request
  7. API request and response for accounts.authinfo (not in API explorer) when you see error for reports
If you are not seeing the 'Reply privately to author' option, send the details to email shopping-api-support@google.com using the same subject.

Thanks,

Google Logo
Lakshmi
Content API for Shopping Team
 


ref:_00D1U1174p._5004Q2fqUs7:ref

Péter Gerő

unread,
Jan 19, 2023, 4:40:39 PMJan 19
to Google Content API for Shopping
Hi,

I've got the same issues mentioned above. I'm using the most recent PHP client library, and the calls return with the same error (  Not authorized to use the ReportService.Search method to query the ProductView table. ) but the API explorer returns the correct response. Same email / user account is used in both cases.
Are there any updates regarding this issue?

Thanks,
Peter

Shopping API Forum Advisor

unread,
Jan 20, 2023, 1:50:25 AMJan 20
to gerop...@gmail.com, google-content-...@googlegroups.com

Hi Peter,

 

I understand that you encountered the same error. For us to investigate further, kindly provide us with the following details:

  • Merchant Center ID
  • Email address used for the request
  • API request and error response (include HTTP request)
  • Date and timestamp of the API request

     

    Kindly provide it via the Reply privately to author option. If this option is not available, please send this requested information through our email <shopping-a...@google.com> instead for private purposes.

     

    Looking forward to your response.

     

    Regards,

    Google Logo
    Ciara
    Content API for Shopping Team
     


    ref:_00D1U1174p._5004Q2fqUs7:ref

    James Pell

    unread,
    Jan 23, 2023, 10:37:14 AMJan 23
    to Google Content API for Shopping
    Hi,

    I've just sent through an email with the requested info.

    Thanks

    Shopping API Forum Advisor

    unread,
    Jan 23, 2023, 8:18:07 PMJan 23
    to james...@gear4music.com, google-content-...@googlegroups.com

    Hi James,

     

    Confirming that we have received your information privately.

     

    Regards,

    Google Logo
    Ciara
    Content API for Shopping Team
     


    ref:_00D1U1174p._5004Q2fqUs7:ref

    Shopping API Forum Advisor

    unread,
    Jan 26, 2023, 11:16:58 AMJan 26
    to google-content-...@googlegroups.com, james...@gear4music.com
    Hi,

    I got the following update:
     we used to allow querying ProductView table only for allowlisted Google Cloud projects. The team is planning to make it available for everyone. In the API explorer it will work as it is allowlisted for all the merchants.

    Please keep an eye on our blog for future announcements:
    https://ads-developers.googleblog.com/search/label/content_api

    Thanks,
    Google Logo
    Lakshmi
    Content API for Shopping Team
     
    ​​​​​​​

    ref:_00D1U1174p._5004Q2fqUs7:ref

    James Pell

    unread,
    Feb 8, 2023, 11:18:33 AMFeb 8
    to Google Content API for Shopping
    Hi,

    Is there any way to add a Google Cloud Project to the allowlist?

    Thanks

    Shopping API Forum Advisor

    unread,
    Feb 8, 2023, 4:21:21 PMFeb 8
    to james...@gear4music.com, google-content-...@googlegroups.com

    Hello James,

    I’m afraid that there’s currently no direct way for you to add a specific Google cloud project to be allowlisted to ProductView.  However, you can fill up and submit this interest form to request access / allowlisted with the said view.

    Also, as mentioned by my colleague in her previous email and would like to note that the team is already planning to make the said view available publicly. However, there’s currently no timeline when this will be implemented. In the meantime, try to utilize the given form above or keep an eye to our developer blog for any updates on this.

    Regards,

    Google Logo
    James Howell
    Content API for Shopping Team
     


    ref:_00D1U1174p._5004Q2fqUs7:ref
    Reply all
    Reply to author
    Forward
    Message has been deleted
    0 new messages