Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
MODEL_NAMENoOverride default model. Required when using Ollama.
OPENAI_VISIONNoSet 'true' to pass screenshots to OpenAI-compatible vision models.
GEMINI_API_KEYNoGoogle Gemini API key
MERCH_LOG_FILENoPath to NDJSON log file.
MODEL_PROVIDERNoForce 'anthropic', 'gemini', 'openai', or 'ollama'. Auto-detected if omitted.
OPENAI_API_KEYNoOpenAI or OpenAI-compatible API key
OPENAI_BASE_URLNoBase URL for OpenAI-compatible endpoint.https://api.openai.com/v1
TOOL_TIMEOUT_MSNoAI tool timeout in ms.120000
ANTHROPIC_API_KEYNoAnthropic Claude API key
FIRECRAWL_API_KEYNoEnables Firecrawl as a fallback scraper in acquire.
LIGHTPANDA_CDP_URLNoConnect to an external Lightpanda/Chrome CDP endpoint.
MERCH_CONNECTOR_DATA_DIRNoCustom path for site memory files.~/.merch-connector/data/

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{}
logging
{}
prompts
{}
resources
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
acquireA

Acquire a complete structured payload from a storefront page in a single crawl. Returns products, facets, sort options, desktop + mobile screenshots, performance metrics, aggregated trust signals, analytics tracking summary, data quality fill rates, navigation structure, and automatically sampled PDP details — all in one call. Use this as the primary entry point for any storefront audit. The payload is designed for offline analysis: call acquire once, then analyze against the returned data with no further live site calls. Always scrapes with Puppeteer first (free, bundled, captures analytics and network events). Falls back to Firecrawl automatically only when Puppeteer is blocked (0 products + FCP=0) and FIRECRAWL_API_KEY is set — Firecrawl costs money per call and is reserved for WAF-protected sites. A warnings[] array flags data quality issues automatically (LOW_CARD_CONFIDENCE, MOBILE_RENDER_FAILED, FCP_ZERO, ECOMMERCE_TRACKING_GAP, etc.).

scrape_pageA

[DEPRECATED — use acquire instead] Extract raw structured data from any storefront URL without running AI analysis. Returns product catalog (title, price, stock, CTA, description, B2B/B2C signals), facets/filters, page metadata, performance timing, data layer contents, and interactable elements. Also intercepts XHR/fetch network responses to fingerprint the commerce platform (Algolia, Elasticsearch, SFCC, Shopify, etc.), extract structured product and facet data directly from APIs when confidence is high, and parse dataLayer/digitalData ecommerce events (GA4, GTM, Adobe, Segment). Results are cached for 10 minutes — calling audit_storefront or ask_page on the same URL afterward will reuse this data. Session cookies are managed automatically.

interact_with_pageA

Execute one or more search/click actions on a storefront page in sequence, then return the resulting page data. Accepts a single action or an array for multi-step flows (e.g. search → filter → click). Session cookies are carried over automatically.

compare_storefrontsA

Scrape two storefront URLs and return a structured side-by-side diff: product count delta, facet gaps (what site B has that A doesn't and vice versa), trust signal coverage (ratings, reviews, badges), sort option gaps, B2B mode, and performance delta. Reuses cached page data if either URL was scraped in the last 10 minutes.

ask_pageA

Ask any natural language question about a storefront page. The AI sees the full product data, facets, performance metrics, and a screenshot. If scrape_page was called on this URL within the last 10 minutes, the cached data is reused — no re-scrape. Use this for ad-hoc questions like "which products are on sale?", "can users filter by size?", "what's the average price?", or "is this page fast enough?". Tip: for slow or local AI models, call scrape_page first, then ask_page — the scrape will be reused.

clear_sessionA

Clear the stored session for a domain — wipes both cookies and cached page data. Use this to start fresh (e.g., test logged-out vs logged-in experience, or force a fresh scrape).

site_memoryA

Read, write, or list persistent memory about websites. Memory auto-accumulates on every scrape (structure, performance, facets). Use this to add custom notes ("this site needs 5s wait for lazy load", "products use .wat-product-tile selector", "requires login cookies for pricing"). Memory persists across sessions and server restarts.

merch_roundtableA

[EXPERIMENTAL] Run a multi-perspective merchandising analysis using three expert personas (Floor Walker, Auditor, Scout) that independently evaluate the page, then debate their findings to produce a consensus. The Floor Walker reacts as a real shopper, the Auditor evaluates against a structured framework, and the Scout analyzes competitive positioning. A moderator then synthesizes all three views into prioritized recommendations with endorsements from each persona. Reuses cached page data if scrape_page was called on the same URL within the last 10 minutes.

save_evalA

Save the current roundtable or audit persona results for a URL to the eval store. Reads persona results from the session cache — call merch_roundtable or audit_storefront first on the same URL. Returns an eval ID, a convergence score (0–100 measuring how much the three personas agreed on their top concerns), and the storage path. Evals persist across sessions in ~/.merch-connector/evals/ (up to 100 compact records + 10 full runs per domain). Use list_evals to review history and track whether findings are consistent across runs.

list_evalsA

List saved eval runs from the eval store. If a URL or domain is provided, returns the eval history for that domain (newest first) with convergence scores, top concerns, and moderator summaries. If no URL is provided, returns a summary of all domains with saved evals. Use this to track trends, compare runs before/after changes, or retrieve a full run ID for deeper inspection.

get_logsA

Retrieve recent server log entries from the in-memory buffer (last 500 entries). Returns entries newest-first. Filter by level or tool name. Useful for reviewing roundtable notification streams, debugging tool calls, and capturing logs that are hard to copy from the MCP Inspector UI.

scrape_pdpA

Scrape a product detail page (PDP) and return PDP-specific signals: title, description fill rate, image count, review presence and count, review schema (ld+json), spec table, cross-sell modules, CTA text, primary and original prices, badge texts, and performance timing. Use this instead of scrape_page when the target is a single product page.

get_category_sampleA

Sample a set of PDPs from a category page. Scrapes the category page (or uses cached data), picks product URLs based on a sampling strategy, then calls scrape_pdp on each in parallel. Useful for PDP spot-checks without manual URL selection. Strategies: "spread" (low/mid/high price tiers), "random" (random selection), "top" (first N products).

analyze_productsA

Run full persona analysis on pre-scraped product data without making any live site requests. Accepts products[], facets[], and page metadata as JSON, computes a page fingerprint, then runs the selected persona (or full roundtable if persona is "auto" or unset). Use this to re-analyze acquire payloads offline, or to analyze data from external sources (CSV exports, internal APIs, DTC Research server handoffs). Requires an AI provider (ANTHROPIC_API_KEY, GEMINI_API_KEY, or Ollama) to be configured.

Prompts

Interactive templates invoked by user choice

NameDescription
floor-walkerEvaluate a storefront page from a real shopper's perspective — frustrations, confusion, and missed moments.
auditorRun a structured B2C merchandising audit using the Trust / Guidance / Persuasion / Friction framework.
auditor-b2bEvaluate a page for B2B procurement buyers: steps-to-PO, spec completeness, pricing transparency.
scoutAnalyze the page from a VP of Merchandising lens — competitive positioning and strategic gaps.
conversion-architectEvaluate the page through a pure CRO lens — mapping the funnel and identifying revenue-bleeding friction.
merch-roundtableRun a full multi-persona roundtable (Floor Walker + Auditor + Scout + Moderator) for a storefront URL.

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/grahamton/merchGent'

If you have feedback or need assistance with the MCP directory API, please join our Discord server