curl --request POST \
--url https://search.glood.ai/api/storefront/v1/headless/config \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'x-shop: <x-shop>' \
--data '
{
"locale": "en-US",
"market": 123,
"publication_ids": [
"30085840999"
],
"theme": 123,
"target_page": "search",
"target_id": 123,
"skip_cache": false,
"visitor_id": "<string>",
"client_id": "<string>",
"customer_id": "<string>"
}
'import requests
url = "https://search.glood.ai/api/storefront/v1/headless/config"
payload = {
"locale": "en-US",
"market": 123,
"publication_ids": ["30085840999"],
"theme": 123,
"target_page": "search",
"target_id": 123,
"skip_cache": False,
"visitor_id": "<string>",
"client_id": "<string>",
"customer_id": "<string>"
}
headers = {
"x-shop": "<x-shop>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'x-shop': '<x-shop>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
locale: 'en-US',
market: 123,
publication_ids: ['30085840999'],
theme: 123,
target_page: 'search',
target_id: 123,
skip_cache: false,
visitor_id: '<string>',
client_id: '<string>',
customer_id: '<string>'
})
};
fetch('https://search.glood.ai/api/storefront/v1/headless/config', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://search.glood.ai/api/storefront/v1/headless/config",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'locale' => 'en-US',
'market' => 123,
'publication_ids' => [
'30085840999'
],
'theme' => 123,
'target_page' => 'search',
'target_id' => 123,
'skip_cache' => false,
'visitor_id' => '<string>',
'client_id' => '<string>',
'customer_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"x-shop: <x-shop>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://search.glood.ai/api/storefront/v1/headless/config"
payload := strings.NewReader("{\n \"locale\": \"en-US\",\n \"market\": 123,\n \"publication_ids\": [\n \"30085840999\"\n ],\n \"theme\": 123,\n \"target_page\": \"search\",\n \"target_id\": 123,\n \"skip_cache\": false,\n \"visitor_id\": \"<string>\",\n \"client_id\": \"<string>\",\n \"customer_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-shop", "<x-shop>")
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://search.glood.ai/api/storefront/v1/headless/config")
.header("x-shop", "<x-shop>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"locale\": \"en-US\",\n \"market\": 123,\n \"publication_ids\": [\n \"30085840999\"\n ],\n \"theme\": 123,\n \"target_page\": \"search\",\n \"target_id\": 123,\n \"skip_cache\": false,\n \"visitor_id\": \"<string>\",\n \"client_id\": \"<string>\",\n \"customer_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://search.glood.ai/api/storefront/v1/headless/config")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-shop"] = '<x-shop>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"locale\": \"en-US\",\n \"market\": 123,\n \"publication_ids\": [\n \"30085840999\"\n ],\n \"theme\": 123,\n \"target_page\": \"search\",\n \"target_id\": 123,\n \"skip_cache\": false,\n \"visitor_id\": \"<string>\",\n \"client_id\": \"<string>\",\n \"customer_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"config": {
"instant_search_enabled": true,
"search_result_page_enabled": true,
"image_search_enabled": true,
"personalization_enabled": false,
"personalization_config": null,
"auto_spell_correct_enabled": true,
"instant_search_objects": ["product", "collection", "page", "auto_suggestion"],
"exclude_out_of_stock": false,
"move_out_of_stock_at_end": true,
"site_wide_search": {},
"search_result_count": 10,
"default_ordering": "relevance",
"minimum_type_ahead_input_count": 2,
"default_search_result_page_size": 20,
"search_page_autocomplete_enabled": true,
"search_page_handle": "search",
"image_search_pages": null,
"settings": {}
},
"filters": [
{
"id": 1,
"key": "color",
"title": "Color",
"type": "color",
"attribute_type": "option",
"position": 1,
"expanded": true,
"visible": true,
"operator": "or",
"settings": { "multi_select": true, "show_count": true, "collapsible": true, "searchable": false, "show_more": true, "max_display": 10 },
"min": null, "max": null, "step": null, "unit": null, "suffix": null,
"values": [
{ "value": "red", "label": "Red", "count": null, "position": 1, "hex": "#ff0000", "image": null, "order": null }
]
}
],
"filter_tree": {
"id": 1,
"target_page": "search",
"target_ids": [],
"is_default": true,
"title": "Search filters",
"settings": {},
"data": [],
"translations": {}
},
"shop": { "currency_format": "${{amount}}", "primary_locale": "en", "currency": "USD" },
"analytics": { "enabled": true, "tracking_id": null },
"translations": {},
"token": "shpat_xxx",
"metadata": { "region": "toronto", "locale": "en-US", "market": null }
}
{
"error": [
{
"message": "\"target_page\" must be one of [search, collection]",
"path": ["target_page"],
"type": "any.only",
"context": { "label": "target_page", "key": "target_page" }
}
],
"ok": false
}
Search Config
Config for all three search features (instant, results page, image) plus filter definitions, filter tree, shop, analytics, translations and the Shopify storefront token. No Liquid templates and no widget css/js. Auth: Authorization: Bearer <gl_sf_...> + x-shop.
curl --request POST \
--url https://search.glood.ai/api/storefront/v1/headless/config \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'x-shop: <x-shop>' \
--data '
{
"locale": "en-US",
"market": 123,
"publication_ids": [
"30085840999"
],
"theme": 123,
"target_page": "search",
"target_id": 123,
"skip_cache": false,
"visitor_id": "<string>",
"client_id": "<string>",
"customer_id": "<string>"
}
'import requests
url = "https://search.glood.ai/api/storefront/v1/headless/config"
payload = {
"locale": "en-US",
"market": 123,
"publication_ids": ["30085840999"],
"theme": 123,
"target_page": "search",
"target_id": 123,
"skip_cache": False,
"visitor_id": "<string>",
"client_id": "<string>",
"customer_id": "<string>"
}
headers = {
"x-shop": "<x-shop>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'x-shop': '<x-shop>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
locale: 'en-US',
market: 123,
publication_ids: ['30085840999'],
theme: 123,
target_page: 'search',
target_id: 123,
skip_cache: false,
visitor_id: '<string>',
client_id: '<string>',
customer_id: '<string>'
})
};
fetch('https://search.glood.ai/api/storefront/v1/headless/config', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://search.glood.ai/api/storefront/v1/headless/config",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'locale' => 'en-US',
'market' => 123,
'publication_ids' => [
'30085840999'
],
'theme' => 123,
'target_page' => 'search',
'target_id' => 123,
'skip_cache' => false,
'visitor_id' => '<string>',
'client_id' => '<string>',
'customer_id' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"x-shop: <x-shop>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://search.glood.ai/api/storefront/v1/headless/config"
payload := strings.NewReader("{\n \"locale\": \"en-US\",\n \"market\": 123,\n \"publication_ids\": [\n \"30085840999\"\n ],\n \"theme\": 123,\n \"target_page\": \"search\",\n \"target_id\": 123,\n \"skip_cache\": false,\n \"visitor_id\": \"<string>\",\n \"client_id\": \"<string>\",\n \"customer_id\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-shop", "<x-shop>")
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://search.glood.ai/api/storefront/v1/headless/config")
.header("x-shop", "<x-shop>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"locale\": \"en-US\",\n \"market\": 123,\n \"publication_ids\": [\n \"30085840999\"\n ],\n \"theme\": 123,\n \"target_page\": \"search\",\n \"target_id\": 123,\n \"skip_cache\": false,\n \"visitor_id\": \"<string>\",\n \"client_id\": \"<string>\",\n \"customer_id\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://search.glood.ai/api/storefront/v1/headless/config")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-shop"] = '<x-shop>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"locale\": \"en-US\",\n \"market\": 123,\n \"publication_ids\": [\n \"30085840999\"\n ],\n \"theme\": 123,\n \"target_page\": \"search\",\n \"target_id\": 123,\n \"skip_cache\": false,\n \"visitor_id\": \"<string>\",\n \"client_id\": \"<string>\",\n \"customer_id\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"config": {
"instant_search_enabled": true,
"search_result_page_enabled": true,
"image_search_enabled": true,
"personalization_enabled": false,
"personalization_config": null,
"auto_spell_correct_enabled": true,
"instant_search_objects": ["product", "collection", "page", "auto_suggestion"],
"exclude_out_of_stock": false,
"move_out_of_stock_at_end": true,
"site_wide_search": {},
"search_result_count": 10,
"default_ordering": "relevance",
"minimum_type_ahead_input_count": 2,
"default_search_result_page_size": 20,
"search_page_autocomplete_enabled": true,
"search_page_handle": "search",
"image_search_pages": null,
"settings": {}
},
"filters": [
{
"id": 1,
"key": "color",
"title": "Color",
"type": "color",
"attribute_type": "option",
"position": 1,
"expanded": true,
"visible": true,
"operator": "or",
"settings": { "multi_select": true, "show_count": true, "collapsible": true, "searchable": false, "show_more": true, "max_display": 10 },
"min": null, "max": null, "step": null, "unit": null, "suffix": null,
"values": [
{ "value": "red", "label": "Red", "count": null, "position": 1, "hex": "#ff0000", "image": null, "order": null }
]
}
],
"filter_tree": {
"id": 1,
"target_page": "search",
"target_ids": [],
"is_default": true,
"title": "Search filters",
"settings": {},
"data": [],
"translations": {}
},
"shop": { "currency_format": "${{amount}}", "primary_locale": "en", "currency": "USD" },
"analytics": { "enabled": true, "tracking_id": null },
"translations": {},
"token": "shpat_xxx",
"metadata": { "region": "toronto", "locale": "en-US", "market": null }
}
{
"error": [
{
"message": "\"target_page\" must be one of [search, collection]",
"path": ["target_page"],
"type": "any.only",
"context": { "label": "target_page", "key": "target_page" }
}
],
"ok": false
}
{
"config": {
"instant_search_enabled": true,
"search_result_page_enabled": true,
"image_search_enabled": true,
"personalization_enabled": false,
"personalization_config": null,
"auto_spell_correct_enabled": true,
"instant_search_objects": ["product", "collection", "page", "auto_suggestion"],
"exclude_out_of_stock": false,
"move_out_of_stock_at_end": true,
"site_wide_search": {},
"search_result_count": 10,
"default_ordering": "relevance",
"minimum_type_ahead_input_count": 2,
"default_search_result_page_size": 20,
"search_page_autocomplete_enabled": true,
"search_page_handle": "search",
"image_search_pages": null,
"settings": {}
},
"filters": [
{
"id": 1,
"key": "color",
"title": "Color",
"type": "color",
"attribute_type": "option",
"position": 1,
"expanded": true,
"visible": true,
"operator": "or",
"settings": { "multi_select": true, "show_count": true, "collapsible": true, "searchable": false, "show_more": true, "max_display": 10 },
"min": null, "max": null, "step": null, "unit": null, "suffix": null,
"values": [
{ "value": "red", "label": "Red", "count": null, "position": 1, "hex": "#ff0000", "image": null, "order": null }
]
}
],
"filter_tree": {
"id": 1,
"target_page": "search",
"target_ids": [],
"is_default": true,
"title": "Search filters",
"settings": {},
"data": [],
"translations": {}
},
"shop": { "currency_format": "${{amount}}", "primary_locale": "en", "currency": "USD" },
"analytics": { "enabled": true, "tracking_id": null },
"translations": {},
"token": "shpat_xxx",
"metadata": { "region": "toronto", "locale": "en-US", "market": null }
}
{
"error": [
{
"message": "\"target_page\" must be one of [search, collection]",
"path": ["target_page"],
"type": "any.only",
"context": { "label": "target_page", "key": "target_page" }
}
],
"ok": false
}
Authorizations
Headers
Body
Request body
Config request. Union of the legacy instant-config and search-config inputs.
Optional. Numeric Shopify publication (sales channel) ids. When present, only products published on at least one of these channels are returned and the default "published to the Online Store" gate is replaced by this filter; market and B2B filters still apply. A single id may be sent without the array wrapper. Each id must be one the merchant enabled under Settings → Sales channels; unknown ids return 400. The id is the numeric tail of gid://shopify/Publication/.
50^[0-9]+$["30085840999"]
Response
Search configuration
Config for all three features plus filter definitions, tree, shop, analytics, translations and token.
Was this page helpful?