Hi,
While testing the Deals endpoint I found out that the category filter is not working as expected.
Example below for “Beauty & Personal Care” category, which id is 11055981.
const options = {
method: ‘GET’,
url: ‘https://real-time-amazon-data.p.rapidapi.com/deals-v2’,
params: {
country: ‘US’,
categories: ‘11055981’
},
headers: {
‘X-RapidAPI-Key’:
‘X-RapidAPI-Host’: ‘real-time-amazon-data.p.rapidapi.com’
}
};
First returned deal should not be in that category.
{
deal_id: ‘a2d2a9a1’,
deal_type: ‘BEST_DEAL’,
deal_title: ‘SAMSUNG 49-Inch Odyssey G9 Series DQHD 1000R Curved Gaming Monitor, 1ms(GtG), VESA DisplayHDR 1000, 240Hz, AMD FreeSync Premium Pro, Height Adjustable Stand, LS49CG954ENXZA, 2024’,
deal_photo: ‘https://m.media-amazon.com/images/I/71lXYTc4nLL.jpg’,
deal_state: ‘AVAILABLE’,
deal_url: ‘https://www.amazon.com/SAMSUNG-DisplayHDR-FreeSync-Adjustable-LS49CG954ENXZA/dp/B0CP6HW894’,
canonical_deal_url: ‘https://www.amazon.com/deal/a2d2a9a1’,
deal_starts_at: ‘2024-05-13T07:05:00.000Z’,
deal_ends_at: ‘2024-05-20T06:59:59.000Z’,
deal_price: { amount: ‘799.99’, currency: ‘USD’ },
list_price: { amount: ‘1299.99’, currency: ‘USD’ },
savings_percentage: 38,
savings_amount: { amount: ‘500.0’, currency: ‘USD’ },
deal_badge: ‘38% off’,
type: ‘SINGLE_ITEM’,
product_asin: ‘B0CP6HW894’
}
Can you please check if there is anything wrong?
Or I’m not using this endpoint correctly?
Thanks.
הצטרף לדיון - הוסף תגובה למטה:
Happy to help and glad it works for you now.
Feel free to reach out if anything comes up.
You are right sorry about this. I was using the same category id than for US.
Hey,
First, are you using the Deals V2 endpoint? The Deals endpoint was deprecated today, it will still return results but the filters are not working anymore.
I just tried to filter for Automotive both in GB (domain: amazon.co.uk. category id: 248878031) and CA (domain: amazon.ca. category_id: 6948390011) and it works for me on the Deals V2 endpoint.
Do you perhaps have an example of a category that the endpoint fails to filter on?
Hi,
Sorry to re-open this but I have the same issue on other countries, I only tested Canada (CA) and Great Britain (GB) for now.
Sure, sorry for the inconvenience and thanks for letting me know.
Please feel free to reach out in case you have any question or if anything comes up.
It seems better indeed, thanks a lot for your quick help.
Hi,
Thank you for your message.
There was indeed an issue with the categories filter that is now fixed. Does it work for you now?
Thank you,
Adam @ OpenWeb Ninja