QUANTM7 Docs
Headless APIAPI Reference

Search

Fuzzy search across products, collections, blog posts, pages, and policies.

Search store

Returns search results across all content types in your store. The search is typo-tolerant and uses trigram matching, so "cotten" still finds "cotton". Results are ranked by relevance with products weighted highest.

GET /v1/search

Auth: Publishable or secret key

Query parameters

ParameterTypeDefaultDescription
qstringrequiredSearch term (minimum 2 characters)
limitinteger20Max product results (1-50). Other types are capped at 10.

Response

Results are grouped by content type. Each group is an array sorted by relevance.

{
  "data": {
    "products": [
      {
        "title": "Classic Tee",
        "handle": "classic-tee",
        "description": "A comfortable everyday tee...",
        "image_url": "https://cdn.quantm7.com/store/products/abc123.webp",
        "price": 29.99,
        "compare_at_price": 39.99,
        "vendor": "Basics Co",
        "product_type": "Apparel"
      }
    ],
    "collections": [
      {
        "title": "Summer 2026",
        "handle": "summer-2026",
        "description": "Lightweight styles for warm weather.",
        "image_url": "https://cdn.quantm7.com/store/collections/summer.webp"
      }
    ],
    "blog_posts": [
      {
        "title": "Summer Style Guide",
        "handle": "summer-style-guide",
        "description": "Five looks to take you from beach to bar.",
        "image_url": "https://cdn.quantm7.com/store/blog/summer-guide.webp"
      }
    ],
    "pages": [],
    "policies": []
  }
}

Search ranking

Results are scored using a combination of exact matches and trigram similarity:

  1. SKU match (products only) scores highest
  2. Title match scores next
  3. Vendor or product type match follows
  4. Description match scores last
  5. Fuzzy similarity catches typos and partial matches

Content types are boosted differently: products (1.0x), collections (0.5x), blog posts (0.3x), pages (0.2x), policies (0.15x).

Errors

StatusCodeMessage
400bad_requestSearch query must be at least 2 characters

Examples

Search for products:

curl "https://api.quantm7.com/v1/search?q=cotton+tee" \
  -H "Authorization: Bearer q7_pk_your_key"

Limit results:

curl "https://api.quantm7.com/v1/search?q=summer&limit=5" \
  -H "Authorization: Bearer q7_pk_your_key"

On this page