SearchFacets
Returns available facet values for filtering listings, such as categories, pricing models, fulfillment option types, publishers, and customer ratings. Each facet value includes a count of matching listings.
Request Syntax
POST /2026-02-05/searchFacets HTTP/1.1
Content-type: application/json
{
"facetTypes": [ "string" ],
"filters": [
{
"filterType": "string",
"filterValues": [ "string" ]
}
],
"locale": "string",
"nextToken": "string",
"searchText": "string"
}
URI Request Parameters
The request does not use any URI parameters.
Request Body
The request accepts the following data in JSON format.
- facetTypes
-
A list of specific facet types to retrieve. If empty or null, all available facets are returned.
Type: Array of strings
Array Members: Minimum number of 0 items. Maximum number of 30 items.
Valid Values:
AVERAGE_CUSTOMER_RATING | CATEGORY | PUBLISHER | FULFILLMENT_OPTION_TYPE | PRICING_MODEL | PRICING_UNIT | DEPLOYED_ON_AWS | NUMBER_OF_PRODUCTSRequired: No
- filters
-
Filters to apply before retrieving facets. Multiple filters are combined with AND logic. Multiple values within the same filter are combined with OR logic.
Type: Array of SearchFilter objects
Array Members: Minimum number of 1 item. Maximum number of 30 items.
Required: No
- locale
-
A BCP 47 language tag or comma-separated priority list specifying the preferred locale for response content. See
Localefor supported values, constraints, fallback behavior, and the default locale. If omitted, the service returns content in the default locale.Type: String
Length Constraints: Minimum length of 1. Maximum length of 256.
Pattern:
[^;,]+(\s*,\s*[^;,]+){0,1}Required: No
- nextToken
-
If
nextTokenis returned, there are more results available. Make the call again using the returned token to retrieve the next page.Type: String
Length Constraints: Minimum length of 0. Maximum length of 8192.
Pattern:
[a-zA-Z0-9+/=]+Required: No
- searchText
-
The search query text to filter listings before retrieving facets.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 512.
Pattern:
.*[^ ]*.*Required: No
Response Syntax
HTTP/1.1 200
Content-type: application/json
{
"listingFacets": {
"string" : [
{
"count": number,
"displayName": "string",
"parent": "string",
"value": "string"
}
]
},
"nextToken": "string",
"totalResults": number
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
- listingFacets
-
A map of facet types to their corresponding facet values. Each facet value includes a display name, internal value, and count of matching listings.
Type: String to array of ListingFacet objects map
Valid Keys:
AVERAGE_CUSTOMER_RATING | CATEGORY | PUBLISHER | FULFILLMENT_OPTION_TYPE | PRICING_MODEL | PRICING_UNIT | DEPLOYED_ON_AWS | NUMBER_OF_PRODUCTSArray Members: Minimum number of 0 items. Maximum number of 100 items.
- totalResults
-
The total number of listings matching the search criteria.
Type: Long
Valid Range: Minimum value of 0.
- nextToken
-
If
nextTokenis returned, there are more results available. Make the call again using the returned token to retrieve the next page.Type: String
Length Constraints: Minimum length of 0. Maximum length of 8192.
Pattern:
[a-zA-Z0-9+/=]+
Errors
For information about the errors that are common to all actions, see Common Error Types.
- AccessDeniedException
-
You don't have sufficient access to perform this action.
HTTP Status Code: 403
- InternalServerException
-
Unexpected error during processing of the request.
HTTP Status Code: 500
- ThrottlingException
-
The request was denied due to request throttling.
HTTP Status Code: 429
- ValidationException
-
The input fails to satisfy the constraints specified by the service.
- reason
-
The reason that the input fails to satisfy the constraints specified by the service.
HTTP Status Code: 400
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: