Skip to content

DISC-008Find

Search endpoint usable by GET

Checks that your site search works as a plain GET URL and returns product links in the HTML response.

What we check

During the crawl we look for a GET search form with a recognisable query field (a role="search" form, a type="search" input, or an input named q, s, query, search, keyword, term, suche, szukaj, recherche or zoeken), or else a search link with a q= parameter. We keep it only if searching for a known product's name returns a page linking to that product. This check then searches for a sampled product's name and reads the raw HTML of the results.

Why it matters

An AI agent looking for a product usually cannot type into a search box and wait for scripts. If search works as a URL such as /search?q=linen+shirt and the results contain product links in the HTML, the agent can find products directly.

How we check

PASS: the results page returns HTTP 200 and its raw HTML contains the product name (or its first word) and a link whose path contains /product/, /products/, /p/, /item/ or /dp/. FAIL: no usable GET search was found (search may be POST-only or JavaScript-only), or the search returned no product link in raw HTML. SKIPPED: the crawl found no product URL to test with, no product name was available, or the search request was refused or answered by bot management.

How to fix it

  1. Make search available as a GET URL, such as /search?q=term, returning server-rendered results.
  2. Use a form with method="get" and a named query input (q, search, query or similar).
  3. Return matching products as plain <a href> links in the initial HTML, not only via JavaScript.
  4. If a pattern failed, check the parameter name matches what the form submits.
  5. Shopify's /search?q= and WordPress/WooCommerce's ?s= search normally return HTML results; if an app or plugin replaced search with a JavaScript-only one, check the plain URL still works.

What good looks like

<form role="search" method="get" action="/search">
  <input type="search" name="q">
  <button>Search</button>
</form>

GET /search?q=Linen%20Shirt  ->  200

<ul class="results">
  <li><a href="/products/linen-shirt">Linen Shirt</a> €49.00</li>
  <li><a href="/products/linen-shirt-long">Linen Shirt, long sleeve</a> €55.00</li>
</ul>

Sources