Is it possible to delete an Algolia record based on a field value versus the document delete projection in the webhook?
Use Case:
We have inventory items that we retain even when the inventory item is "sold". The stockStatus value designates if it's inStock or sold. When an item is inStock then we sync it to Algolia, however, when it later changes to sold (but not deleted), it doesn't get removed from the Algolia index. We don't want sold inventory items in our index as they are no longer relevant (they will never come back to inStock status.
Possible Work Around:
I realize I could index all items and include a field for stockStatus, however it seems like index bloat and would require further diligence to assure sold items are filtered out.
Is it possible to delete an Algolia record based on a field value versus the document delete projection in the webhook?
Use Case: We have inventory items that we retain even when the inventory item is "sold". The
stockStatus
value designates if it'sinStock
orsold
. When an item isinStock
then we sync it to Algolia, however, when it later changes tosold
(but not deleted), it doesn't get removed from the Algolia index. We don't want sold inventory items in our index as they are no longer relevant (they will never come back toinStock
status.Possible Work Around: I realize I could index all items and include a field for
stockStatus
, however it seems like index bloat and would require further diligence to assure sold items are filtered out.