Search code examples
amazon-selling-partner-api

Amazon Selling partner API - client error in BRAND_ANALYTIC_REPEAT_PURCHASE_REPORT


when try to fetch BRAND_ANALYTIC_REPEAT_PURCHASE_REPORT it shows "errorDetails" : "A client error occurred. Please double check that your parameters are valid and fulfill the requirements of the report type." in sp spi documentation they mentioned that the report options as follows. WEEK, MONTH, QUARTER Example: "reportOptions":{"reportPeriod": "WEEK"} , report type, marketplace, endpoints are correct , and the credentials are also correct. the credentials required for BRAND_ANALYTIC_MARKET_BASKET_REPORT are same and while fetching this its successfully getting.

i tried with different week dates in different year, and also tried with MONTH and QUARTER with different dates.


Solution

  • I received this error when the start and end did not respect the Amazon Selling Partner requirements for the report period:

    The dataStartTime and dataEndTime values must correspond to valid first and last days in the specified reportPeriod. For example, dataStartTime must be a Sunday and dataEndTime must be the following Saturday when reportPeriod=WEEK.

    Similarly, for MONTH we would need 2023-01-01 and 2023-01-31 (start and end of the month) or 2023-01-01 and 2023-12-31 for YEAR.

    Amazon SP-API Analytics Reports