Skip to main content

Documentation Index

Fetch the complete documentation index at: https://algolia.com/llms.txt

Use this file to discover all available pages before exploring further.

Required ACL: search Use cases include:
  • Searching different indices, such as products and marketing content.
  • Run multiple queries on the same index with different parameters or filters.
If you know the expected result type, use the searchForHits or searchForFacets helper to simplify the response format.

Usage

// Initialize the client
var client = new SearchClient(new SearchConfig("ALGOLIA_APPLICATION_ID", "ALGOLIA_API_KEY"));

// Call the API
var response = await client.SearchAsync<Hit>(
  new SearchMethodParams
  {
    Requests = new List<SearchQuery>
    {
      new SearchQuery(new SearchForHits { IndexName = "<YOUR_INDEX_NAME>" }),
      new SearchQuery(
        new SearchForFacets
        {
          IndexName = "<YOUR_INDEX_NAME>",
          Type = Enum.Parse<SearchTypeFacet>("Facet"),
          Facet = "theFacet",
        }
      ),
      new SearchQuery(
        new SearchForHits
        {
          IndexName = "<YOUR_INDEX_NAME>",
          Type = Enum.Parse<SearchTypeDefault>("Default"),
        }
      ),
    },
    Strategy = Enum.Parse<SearchStrategy>("StopIfEnoughMatches"),
  }
);

// print the response
Console.WriteLine(response);

See the full API reference

For more details about input parameters and response fields.
Last modified on April 30, 2026