Filtering & Search

KicksDB uses Meilisearch for powerful filtering and full-text search across all product endpoints.

Basic Filtering

Single Field Filter

# Filter by brand
GET /v3/stockx/products?filters=brand%3D%22Nike%22

# URL decoded: filters=brand="Nike"

Multiple Conditions (AND)

# Filter by brand AND product type
GET /v3/stockx/products?filters=brand%3D%22Nike%22%20AND%20product_type%3D%22sneakers%22

# URL decoded: filters=brand="Nike" AND product_type="sneakers"

OR Conditions

# Filter by Nike OR Jordan
GET /v3/stockx/products?filters=brand%3D%22Nike%22%20OR%20brand%3D%22Jordan%22

# URL decoded: filters=brand="Nike" OR brand="Jordan"

Comparison Operators

OperatorDescriptionExample
=Equal tobrand="Nike"
!=Not equal togender!="kids"
>Greater thanrank>1000
<Less thanrank<100
>=Greater or equalrank>=50
<=Less or equalrank<=500

Nested Object Filtering

For Shopify products, you can filter by size-specific prices:

# Find products under $100 for size 9.5
GET /v3/shopify/products?filters=prices%5B%229.5%22%5D%3C100

# URL decoded: filters=prices["9.5"]<100

Full-Text Search + Filters

Combine the query parameter with filters:

# Search "dunk" within Nike sneakers
GET /v3/stockx/products?query=dunk&filters=brand%3D%22Nike%22%20AND%20product_type%3D%22sneakers%22

Index Schemas

Each platform has different filterable and searchable fields. Indexes are refreshed every 12 hours.

stockx

FieldTypeSearchableFilterableSortable
slugstring-
brandstring-
genderstring--
product_typestring--
categorystring--
skustring-
ranknumber--
release_datedate-
colorwaystring--
barcodesarray--

goat

FieldTypeSearchableFilterableSortable
brandstring-
slugstring-
skustring-
colorwaystring--
release_datestring-
ranknumber--
product_typestring--
modelstring-
seasonstring--

shopify

FieldTypeSearchableFilterableSortable
titlestring--
slugstring-
brandstring-
product_typestring--
skustring-
shop_namestring--
pricesobject--
barcodesarray--

JavaScript Example

const API_KEY = process.env.KICKSDB_API_KEY;

// Build filter string
const filters = [
  'brand="Nike"',
  'product_type="sneakers"',
  'gender="men"'
].join(' AND ');

// URL encode the filters
const encodedFilters = encodeURIComponent(filters);

// Search with filters
const response = await fetch(
  `https://api.kicks.dev/v3/stockx/products?query=dunk&filters=${encodedFilters}`,
  { headers: { 'Authorization': `Bearer ${API_KEY}` } }
);

const { data } = await response.json();
console.log(`Found ${data.length} products`);