Cannot delete record from algolia using rules

Hi Sebastian,

I have successfully configured two Algolia rules for two different schemas.

Now, I would like to delete the record in my Algolia index whenever I DELETED or UNPUBLISHED a page in Squidex. How can I do this?

I’ve tried specifying the following under Schemas:

event.type == 'Published' || event.type == 'Updated' || event.type == 'Unpublished' || event.type == 'Deleted'

And the following under “Deletion”:

The above configuration gives me the following error:

{"message":"null value not allowed outside of body near line:1 column:46","status":400}

Error: {"message":"null value not allowed outside of body near line:1 column:46","status":400}

Elapsed 00:00:00.0590000.

Thanks!

This should actually be correct. I have no idea what the exception means.

This is the code. Could be a bug or so, I need to investigate that.

It was a small bug. I have fixed, but not deployed it yet.

Cool that you found the bug :+1:
Please do let me know when it’s deployed so that I can configure my rules again and try it out.
Thanks!

1 Like