Is it possible to use Lucene Search in Sitecore and have the results returned as JSON by the Sitecore Item Web API?
The documentation for the Sitecore Item Web API on the Sitecore Developer Network doesn't give any examples how to use Lucene Search through the Item Web API.
The end result I'm looking for is to have the search results returned as JSON based on the search parameter provided. Since the Sitecore Item Web API can be used with Sitecore Query to retrieve items it would be convenient to be able to use it for search as well.
I do not think this is possible with the default implementation of the Item Web Api.
You can however extend it. When you look into the config, there is a lot of points where you can hook up with extensions.
You should be able to add your custom processor in the itemWebApiRequest
pipeline. I would add new processor there which inherits from Sitecore.ItemWebApi.Pipelines.Request.RequestProcessor
and add logic to handle Lucene queries there.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With