Skip to content
Panel(opens in a new tab)

Quickstart: Connect an Agent

In this quickstart, you connect an MCP client to the vviinn MCP server, run a first product search on your site’s catalog, and narrow the results with a facet. It takes about 10 minutes.

You need:

  • a site in Panel with an imported product feed (see Connect Your Product Feed)
  • a Text Search campaign on that site, which text_search uses by default (see Campaigns)
  • your site’s read-only token (see Authentication)
  • an MCP client or agent framework that supports the Streamable HTTP transport
  1. Add the server to your client. Give it the endpoint https://api.vviinn.com/mcp, the Streamable HTTP transport, and an Authorization header with your read-only token. Many clients take a JSON entry like the one below. The key names differ between clients, so check your client’s documentation.

    {
    "mcpServers": {
    "vviinn": {
    "type": "http",
    "url": "https://api.vviinn.com/mcp",
    "headers": { "Authorization": "Bearer YOUR_READ_ONLY_TOKEN" }
    }
    }
    }

    The client connects and calls tools/list. The list includes text_search, visual_search, similar_products, and cross_selling, with their input and output schemas.

  2. Run a first search. Ask your agent to search the catalog, or send a tools/call request for text_search yourself:

    {
    "jsonrpc": "2.0",
    "id": 2,
    "method": "tools/call",
    "params": {
    "name": "text_search",
    "arguments": { "query": "waterproof hiking boots", "limit": 5 }
    }
    }

    The result has results, the ranked products as McpItem objects, and dynamic_filters, the facets the result set offers. Pick one facet value, for example a brand from the brand facet.

  3. Refine the search with a session and a facet. Generate a UUID as the session ID. Send the same query again with the session ID and the picked value in dynamic_filters:

    {
    "jsonrpc": "2.0",
    "id": 3,
    "method": "tools/call",
    "params": {
    "name": "text_search",
    "arguments": {
    "query": "waterproof hiking boots",
    "limit": 5,
    "session_id": "6f1c2a7e-3b9d-4c51-9a0e-2d8f4b7c1e55",
    "dynamic_filters": [{ "column": "brand", "values": ["Acme"] }]
    }
    }
    }

    The results now contain only products with that value. The ranked candidate set is the same as in step 2, so the results stay comparable. Send the same session ID on every further refinement of this query.

  • The first search returns products from your catalog in results.
  • The refined search returns only products that match the facet value you picked.
  • An HTTP 401 means the token is missing or wrong. Copy it again from Panel and check the Bearer prefix.