PageSourceSearch

https://store.soeju.com/cdn/shop/t/446/assets/storefront-mcp.js?v=110834943858295593661769386917

js soeju.com collected 2026-10-03 19:10:46 UTC 1,201 bytes, 2 lines download raw bytes

1class StorefrontMCP{constructor(){this.storeDomain=window.location.hostname,this.mcpEndpoint=`https://${this.storeDomain}/api/mcp`}async callTool(name,args){try{const response=await fetch(this.mcpEndpoint,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({jsonrpc:"2.0",method:"tools/call",id:Date.now(),params:{name,arguments:args}})});if(!response.ok)throw new Error(`MCP Server Error: ${response.status} ${response.statusText}`);const data=await response.json();if(data.error)throw new Error(`MCP Tool Error: ${JSON.stringify(data.error)}`);return data.result}catch(error){throw console.error("StorefrontMCP Error:",error),error}}async searchCatalog(query,context="customer browsing"){return this.callTool("search_shop_catalog",{query,context})}async getPolicies(query,context="customer inquiry"){return this.callTool("search_shop_policies_and_faqs",{query,context})}async getCart(cartId){return this.callTool("get_cart",{cart_id:cartId})}async updateCart(cartId,lines){return this.callTool("update_cart",{cart_id:cartId,lines})}}window.storefrontMCP=new StorefrontMCP;
2//# sourceMappingURL=/cdn/shop/t/446/assets/storefront-mcp.js.map?v=110834943858295593661769386917

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.