Search Documentation

Search for a documentation page...

Search API

Full-text product search across your store.

Search Products

GET /api/v1/search

Typo-tolerant, full-text search across product names, summaries, descriptions (including rich-text content), and SEO fields. Results are ranked by relevance, with title matches weighted highest. Queries are matched using both substring matching and trigram similarity, so minor misspellings (e.g. "choclate" for "chocolate") and diacritics (e.g. "lodz" for "Łódź") still return relevant results.

Query Parameters

ParameterTypeDefaultDescription
querystringRequired. Search term (1-200 characters)
limitnumber10Results per page (1-100)
offsetnumber0Results to skip

Response

{
"items": [
{
"type": "product",
"id": "0191abc0-1234-7def-8000-000000000001",
"name": "Classic Tee",
"slug": "classic-tee",
"summary": "A comfortable everyday tee",
"image": "https://cdn.example.com/tee.jpg",
"relevance": 0.875
}
],
"pagination": {
"total": 3,
"offset": 0,
"limit": 10,
"hasMore": false
}
}
FieldTypeDescription
typestringAlways "product"
idstringProduct UUID
namestringProduct name
slugstringURL-safe slug
summarystring | nullShort product summary
imagestring | nullURL of the first product image, or null
relevancenumberRelevance score (0-1), higher is better
curl -H "Authorization: Bearer your_api_key" \
"https://your-store.yns.store/api/v1/search?query=tee&limit=5"