Documentation
Feedback
Guides
Storefront Development

Storefront Development
Storefront development

Enums

Enums define a fixed set of allowed values for a field or argument in the FastStore GraphQL schema. When a field type or query argument is an enum, only the values listed for that enum are accepted. They are used as argument values in queries (e.g., sort) and as fields returned in query responses (e.g., type in a collection).

StoreCollectionType

Product collection type, returned in the type field of the StoreCollection object. These values reflect the VTEX Catalog hierarchy: departments, categories, and subcategories make up the catalog tree, while brands, clusters, and collections are additional grouping mechanisms configured in the VTEX Admin.
To learn more about how the VTEX catalog is structured, see Categories, Brands, and Product collection guides.
ValueDescription
Department
Root level of the VTEX catalog category tree. Departments are the broadest product grouping (e.g., Electronics, Clothing). In the VTEX Admin catalog, this corresponds to a first-level category.
Category
Second level of the VTEX catalog category tree, nested inside a Department (e.g., Smartphones inside Electronics). In the VTEX Admin catalog, this corresponds to a second-level category.
SubCategory
Third level of the VTEX catalog category tree, nested inside a Category (e.g., Android Phones inside Smartphones). In the VTEX Admin catalog, this corresponds to a third-level category.
Brand
A product brand registered in the VTEX catalog. Brands are configured in the VTEX Admin under Catalog > Brands.
Cluster
A custom product grouping configured in the VTEX Admin (e.g., Best Sellers, New Arrivals). Unlike categories, clusters do not follow a fixed hierarchy and can group products from different departments or brands. Clusters are configured in the VTEX Admin under Catalog > Product Clusters.
Collection
A manually curated product group created in the VTEX Admin (e.g., Summer Sale). Collections are used to organize products for promotional or merchandising purposes and are configured under Catalog > Collections.

Usage example

The following query retrieves a collection by its slug and returns its type, which resolves to one of the StoreCollectionType values above:

_11
query {
_11
collection(slug: "electronics") {
_11
id
_11
slug
_11
type
_11
seo {
_11
title
_11
description
_11
}
_11
}
_11
}

StoreFacetType

Search facet type, returned in search results to indicate what kind of input control a facet uses. Used in StoreFacet objects to describe the filter options available on a search results page.
ValueDescription
BOOLEAN
Indicates a filter with boolean options (e.g., yes and no), for narrowing search results.
RANGE
Indicates a filter to choose between a range of values (e.g., price, size, etc) to refine search results.

StoreSort

Product search results sorting options. Passed as the sort argument in the search query to control how results are ordered.
ValueDescription
price_desc
Sort by price, from highest to lowest.
price_asc
Sort by price, from lowest to highest.
orders_desc
Sort by orders, from highest to lowest.
name_desc
Sort by name, in reverse alphabetical order.
name_asc
Sort by name, in alphabetical order.
release_desc
Sort by release date, from highest to lowest.
discount_desc
Sort by discount value, from highest to lowest.
score_desc
Sort by product score, from highest to lowest.

Usage example

The following example passes price_asc as the sort argument to return search results sorted by lowest price first:

_14
query {
_14
search(first: 10, sort: price_asc, term: "sneakers") {
_14
products {
_14
edges {
_14
node {
_14
name
_14
offers {
_14
lowPrice
_14
}
_14
}
_14
}
_14
}
_14
}
_14
}

StoreStatus

Status used to indicate a message type. Returned in cart and notification messages (e.g., StoreNotificationItem) to indicate the severity of a user-facing message.
ValueDescription
INFOIndicates non-critical notifications or informative messages related to the user's action.
WARNINGIndicates a potential issue or unexpected behavior that might require user attention but doesn't necessarily prevent them from continuing.
ERRORIndicates a critical issue that prevents the user from completing an action or indicates a problem with the system.
Contributors
1
Photo of the contributor
Was this helpful?
Yes
No
Suggest Edits (GitHub)
Contributors
1
Photo of the contributor
Was this helpful?
Suggest edits (GitHub)
On this page