I am trying to include categories of the product when I fetch one, currently I do it like this:
const { product } = await medusa.store.product.retrieve(id, {
region_id: activeRegion?.id,
fields: `*variants.calculated_price,+variants.inventory_quantity`,
});
it works nicely
but when I add categories
like so:
const { product } = await medusa.store.product.retrieve(id, {
region_id: activeRegion?.id,
fields: `*variants.calculated_price,+variants.inventory_quantity,categories`,
});
I am getting error, Error: Product with id: prod_01JVS2GB9RKGXXFG1RC3HR2AKF was not found.
Why?? The ID is the damned same it shouldn't fail to fetch it so what is the issue here?
I tried setting it as both +categories and *categories but nothing same issue