Creating SearchAPI searches without using Views I am using SearchAPI on a website with 20,000 entities indexed. Searching through them with SearchAPI is pretty simple. Its fast. I want to keep it as fast as possible with very low overhead, without using Views.

I've created the appropriate code needed to create a form, blocks, and a page callback via a custom module. What I would like to do is have someone use a custom search form, hit submit, and be sent to the search results page callback.

What is the best way to store and read from form values in a page callback? Is there any way to have values persist outside of $_SESSION? Or is that the best method? If I wrote a method in my search class that inspected $_POST and did proper validation on it, would it be better to use that to keep executing a search based on that?

I already have paging methods worked out in the code, but kind of scratched my head on how to execute a form, then when using a pager, keep those values for querying the next set. I think I am close, but wanted some input if there is a way I am not seeing.
Realized I never added a follow up. Search API Page does not solve all the cases, and this is possible in Drupal 8 as well.

A query string was added on form submission, redirecting to my url + query string args. These prefill form values (sanitized of course) and modify the initial Search API query. Extra work was done to store some data in session, so that the query could be repeated on detail pages for sidebar results (prev/next navigation in the same result set).

Using the normal Drupal pager worked fine as well.

As part of this work, a module was born: https://www.drupal.org/project/search_api_view_modes

Here is an example of doing it in Drupal 8: https://gist.github.com/kevinquillen/cad07541347385744b161a26690ab75d

Taking this route allows you to create and provide a very tailored, controlled experience.