Retrieve Rules

curl -X GET -H "Content-Type: application/json" \
-u"[your token]:" \
"https://ac.cnstrc.com/refined_filters/group_id/dog%20food?key=[your index key]&section=[section]"
curl -X GET -H "Content-Type: application/json" \
-u"[your token]:" \
"https://ac.cnstrc.com/refined_filters/group_id?key=[your index key]&section=Products"
info

The above command returns a 204 Success response on success.

HTTP Requests#

GET https://ac.cnstrc.com/refined_filters/[filter_name]/[filter_value]?key=[your index key]&section=[section]

GET https://ac.cnstrc.com/refined_filters/[filter_name]?key=[your index key]&section=[section]

Response format#

{
"refined_filters": [
{
"allow_automatic_rules": false,
"blacklist_rules": [
{
"active": true,
"automatically_generated": false,
"created_at": "2020-04-07T13:45:42",
"end_time": null,
"rule": { "filters": { "type": ["toys"] } },
"rule_type": "BLACKLIST",
"start_time": null,
"updated_at": null
}
],
"boost_rules": [
{
"active": true,
"automatically_generated": false,
"created_at": "2020-04-07T13:45:42",
"end_time": null,
"rule": { "filters": { "boost": 1.0, "color": ["red"] } },
"rule_type": "BOOST",
"start_time": null,
"updated_at": null
}
],
"filter_name": "group_id",
"filter_value": "dog food",
"slot_rules": [
{
"active": true,
"automatically_generated": false,
"created_at": "2020-04-07T13:45:42",
"end_time": "2020-04-17T13:45:42",
"rule": { "item_id": "fiddos_food_item", "position": 1 },
"rule_type": "SLOT",
"start_time": "2020-04-07T13:45:42",
"updated_at": null
}
],
"whitelist_rule": {
"active": true,
"automatically_generated": false,
"created_at": "2020-04-07T13:45:42",
"end_time": null,
"rule": { "filters": { "brand": ["fiddos food"] } },
"rule_type": "WHITELIST",
"start_time": null,
"updated_at": null
}
}
],
"total_count": 1
}

URL Parameters#

ParameterDescription
filter_nameThe name of the facet you'd like to retrieve searchandizing rules for.
filter_valueThe value of the facet you'd like to retrieve searchandizing rules for.

Query Parameters#

ParameterRequired?Description
keyYesThe index you'd like to to retrieve results from.
sectionYesThe index section you'd like to retrieve results from (typically Products).
num_results_per_pageNoThe number of rules to return. Defaults to 100.
pageNoThe page of results to return. Defaults to 1.