Elastic Path Commerce Development

Search for Items

Search for Items

This topic provides instructions to perform offer search and keyword search.
Tip:

Reduce the number of calls required for searching by using ?followlocation. For more information on this feature, see FollowLocation.

The examples in this section follows the standard search work flow, which does not use ?followlocation.

Offer Search Work Flow

  1. GET searches.
  2. GET offersearchform.

    For example, https://www.onlinestore.com/searches/<scope>/offer/form.

  3. Populate the form and link to offersearchaction.
  4. GET the search results link returned by Cortex.
  5. To view the item details, GET a search result element.

Keyword Search Work Flow

  1. GET searches.
  2. GET keywordsearchform.

    For example, https://www.onlinestore.com/searches/<scope>/keywords/form.

  3. Populate the form and link to itemkeywordsearchaction.
  4. GET the search results link returned by Cortex .
  5. To view the item details GET a search result element.

search_workflow

Note: Use the "rel":"next" and s"rel":"previous" links to navigate through the search results.