Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Confirming there is an issue with "query" #688

Closed
guillim opened this issue Jan 28, 2021 · 4 comments
Closed

Confirming there is an issue with "query" #688

guillim opened this issue Jan 28, 2021 · 4 comments
Assignees

Comments

@guillim
Copy link

guillim commented Jan 28, 2021

Hi there,

While trying to get the "query" term into my reports using your npm package, I have some issue. I notices you already spotted it here :

But basically, any kind of Sponsored brand report will not allow the query to be in the report for some unknown reason.

Even trying the API example from official doc https://advertising.amazon.com/API/docs/en-us/reference/sponsored-brands/2/reports

will not give the as it should be

[                                                                                           
 {"keywordId":123, "query": "red iphone case", "impressions": 584920, "clicks": 2989},         
 {"keywordId":123, "query": "blue iphone 6s case", "impressions": 8348230, "clicks": 16483},   
 {"keywordId":456, "query": "chuck taylor all star", "impressions": 83910, "clicks": 2483},    
 {"keywordId":456, "query": "converse chuck taylor", "impressions": 2349190, "clicks": 1238},  
 {"keywordId":456, "query": "chuck taylor", "impressions": 291827, "clicks": 1289},            
 {"keywordId":789, "query": "rare earth magnets", "impressions": 99375092, "clicks": 912037},  
 {"keywordId":789, "query": "magnets", "impressions": 93894023, "clicks": 238482},             
 {"keywordId":789, "query": "strong magnets", "impressions": 292, "clicks": 1}                 
]

instead we have this :

[                                                                                           
 {"keywordId":123, "impressions": 584920, "clicks": 2989},         
 {"keywordId":123, "impressions": 8348230, "clicks": 16483},   
 {"keywordId":456, "impressions": 83910, "clicks": 2483},    
 {"keywordId":456, "impressions": 2349190, "clicks": 1238},  
 {"keywordId":456, "impressions": 291827, "clicks": 1289},            
 {"keywordId":789, "impressions": 99375092, "clicks": 912037},  
 {"keywordId":789, "impressions": 93894023, "clicks": 238482},             
 {"keywordId":789, "impressions": 292, "clicks": 1}                 
]
@moltar
Copy link
Contributor

moltar commented Feb 1, 2021

@guillim can you please show me what your request looks like?

@guillim
Copy link
Author

guillim commented Feb 2, 2021

Yep, it looks something like this :

import { HttpClient,
  OperationProvider,
  SponsoredBrandsReportOperation,
 } from '@scaleleap/amazon-advertising-api-sdk'

const params = {
  recordType: 'keywords',
  segment: 'query',
  reportDate: '20210126',
  metrics: ['campaignName', 'currency','portfolioName','targetingText','keywordText','matchType','impressions','clicks','cost', 'attributedSales14d','unitsSold14d','attributedConversions14d','attributedSales1d','adGroupName']
  }
const httpClient = await new HttpClient(myendpoint, auth)
const operation = new OperationProvider(httpClient)
.create(SponsoredBrandsReportOperation)
const result = await operation.requestReport(params)

@nguyentoanit
Copy link
Contributor

@moltar : I couldn't confirm this issue in sandbox API.
I also tried to create a sponsored brands (sb) keyword and get sb keywords report. But API returns an INTERNAL_ERROR (Cannot create a keyword.)

We need to try in Production API? I created a PR too (#697).

@moltar
Copy link
Contributor

moltar commented Feb 3, 2021

@guillim can you please test PR #697 against your production to see if it works.

@moltar moltar closed this as completed Jan 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants