{
  "markdown": "# Packrift MCP Server\n\nProduction MCP (Model Context Protocol) server for Packrift exact-spec packaging procurement. Hero use case: find the right packaging supply for a given item, SKU, or reorder need, then confirm live price, inventory, shipping, and cart handoff.\n\n- **Stack**: Cloudflare Workers, TypeScript (strict), Hono, Zod, Streamable HTTP transport\n- **Backing**: Shopify Admin GraphQL API (`2025-04`), store `packrift.myshopify.com`\n- **Endpoint**: `POST /mcp`, `GET /mcp` (SSE), `GET /` and `GET /start` (MCP start page), `GET /.well-known/mcp/server-card.json`\n- **Install guide**: see [`llms-install.md`](llms-install.md) for remote MCP client configuration.\n- **Discovery gate**: product lookup, reorder, quote, and cart handoff flows are constrained to AI-approved Packrift catalog records where SKU selection is involved.\n\n## Remote MCP client setup\n\nThe public Packrift endpoint is hosted at:\n\n```text\nhttps://mcp.packrift.com/mcp\n```\n\nFast start page for developers, agents, and directory reviewers:\n\n```text\nhttps://mcp.packrift.com/start\n```\n\nDirectory and partner handoffs can use tracked start links without changing the MCP endpoint. Use a lowercase source slug with letters, numbers, and underscores:\n\n```text\nhttps://mcp.packrift.com/r/start/{source}\n```\n\nThe start page also renders source-specific copy controls when it receives a source:\n\n```text\nhttps://mcp.packrift.com/start?utm_source={source}\n```\n\nThose handoffs record aggregate install-intent telemetry: `/r/config/{source}` fetches show up as `mcp_tracked_config_fetches`, `/r/install/{source}/{target}` opens show up as `mcp_install_intent`, and copy controls record `mcp_install_copy` by source and target so partner and directory handoffs can be evaluated before downstream cart events appear.\n\nCustom partner, campaign, directory, and agent-workflow slugs are allowed without code changes as long as they match `^[a-z0-9_]{2,64}$`. Examples: `mcpservers_org`, `agency_partner`, `browser_agent_demo`, `newsletter_mcp`.\n\nWhen a directory or agent host wants a source-attributed config file instead of an HTML start page, use:\n\n```text\nhttps://mcp.packrift.com/r/config/{source}\n```\n\nTracked config fetches are exposed by source in `https://mcp.packrift.com/ai/mcp-usage-snapshot.json`.\n\nFor a target-specific tracked install action, use:\n\n```text\nhttps://mcp.packrift.com/r/install/{source}/{target}\n```\n\nCommon targets include `generic_streamable_http`, `stdio_mcp_remote`, `claude_code`, `codex`, `claude_desktop`, `cursor_windsurf_vscode`, and `cline`.\n\nMCP clients that support remote HTTP or Streamable HTTP servers can add Packrift with:\n\n```json\n{\n  \"mcpServers\": {\n    \"packrift\": {\n      \"type\": \"http\",\n      \"url\": \"https://mcp.packrift.com/mcp\"\n    }\n  }\n}\n```\n\nCline users should use the tracked Cline target, which returns Cline-native `streamableHttp` config:\n\n```text\nhttps://mcp.packrift.com/r/install/cline_mcp_marketplace/cline?format=json\n```\n\nHosts that only accept local stdio MCP commands can use the tracked `stdio_mcp_remote` target. It runs `npx mcp-remote` as a thin bridge and still forwards every call to the hosted Packrift endpoint:\n\n```text\nhttps://mcp.packrift.com/r/install/{source}/stdio_mcp_remote?format=json\n```\n\n## Hosted connector and directory listings\n\nUse the hosted endpoint above when possible. It requires no buyer-side API key and exposes the current 15-tool Packrift exact-spec commerce surface.\n\n- Glama hosted connector: https://glama.ai/mcp/connectors/io.github.Packrift/packrift-mcp\n- MCP Marketplace listing: https://mcp-marketplace.io/server/io-github-packrift-packrift-mcp\n- Official MCP Registry search: https://registry.modelcontextprotocol.io/v0/servers?search=Packrift\n- Claude connector submission packet: https://mcp.packrift.com/ai/claude-connector-submission.json\n- Agent capture outreach packet: https://mcp.packrift.com/ai/agent-capture-outreach.json\n- Source repository: https://github.com/Packrift/packrift-mcp\n- Direct Streamable HTTP endpoint: https://mcp.packrift.com/mcp\n\n### Glama source listing release notes\n\nThe hosted Glama connector should remain the primary Glama traffic target. The\nseparate Glama source server listing can use this repository for release and\nquality checks, but it should still point users at the hosted no-auth MCP\nendpoint above.\n\n- `Dockerfile` starts the Packrift MCP server on `PORT=8787`.\n- `glama.json` is the source-listing maintainer claim file.\n- `smithery.yaml` gives Glama/Smithery-compatible container metadata with an\n  empty config schema, so source-listing release checks do not infer a required\n  buyer token.\n- Running the container without `SHOPIFY_PACKRIFT_TOKEN` still exposes MCP\n  discovery: `tools/list` returns the current 15-tool surface and\n  `resources/list` returns the public AI/MCP resources.\n- `SHOPIFY_PACKRIFT_TOKEN` is not required for MCP discovery, directory\n  scanning, or hosted connector use. It is required only for self-hosted live\n  Shopify-backed catalog, pricing, inventory, shipping, and cart tool calls.\n- The source listing should not create a separate Packrift CLI or buyer\n  surface; it should release/sync the existing repository and keep the canonical\n  runtime at `https://mcp.packrift.com/mcp`.\n\n## Container Image\n\nThe public hosted endpoint above is the primary integration path and the\ncanonical `server.json` manifest is remote-only. A container image is still\npublished for local development and environments that explicitly require a\nself-hosted package-style install surface:\n\n```sh\ndocker pull ghcr.io/packrift/packrift-mcp:latest\ndocker run --rm -p 8787:8787 \\\n  -e SHOPIFY_PACKRIFT_TOKEN=<shopify_admin_api_token> \\\n  ghcr.io/packrift/packrift-mcp:latest\n```\n\nYou can also build the image from this repository:\n\n```sh\ndocker build -t packrift-mcp .\ndocker run --rm -p 8787:8787 \\\n  -e SHOPIFY_PACKRIFT_TOKEN=<shopify_admin_api_token> \\\n  packrift-mcp\n```\n\nOptional environment variables:\n\n- `PORT` defaults to `8787`\n- `SHOPIFY_STORE_DOMAIN` defaults to `packrift.myshopify.com`\n- `SHOPIFY_API_VERSION` defaults to `2025-04`\n- `STOREFRONT_DOMAIN` defaults to `packrift.com`\n- `SHOPIFY_PACKRIFT_TOKEN` is optional for MCP introspection and directory scanning, but required when self-hosting live Shopify-backed catalog, pricing, inventory, shipping, and cart tools\n\nThe container uses an in-memory cache instead of Cloudflare KV. It is intended\nfor discovery and client testing; the production server remains the Cloudflare\nWorkers endpoint at `https://mcp.packrift.com/mcp`.\n\n## AI Discovery Surfaces\n\n- `llms.txt`: https://mcp.packrift.com/llms.txt\n- `llms-full.txt`: https://mcp.packrift.com/llms-full.txt\n- Agent Web Protocol manifest: https://mcp.packrift.com/.well-known/agent.json\n- Agent Web Protocol brand-domain alias: https://packrift.com/agent.json\n- CapIndex capability card: https://mcp.packrift.com/.well-known/capability-card.json\n- MCP server card: https://mcp.packrift.com/.well-known/mcp/server-card.json\n- MCP client config: https://mcp.packrift.com/ai/mcp-client-config.json\n- Root MCP JSON config: https://mcp.packrift.com/mcp.json\n- Well-known MCP JSON config: https://mcp.packrift.com/.well-known/mcp.json\n- OpenAPI discovery adapter: https://mcp.packrift.com/openapi.json\n- Well-known OpenAPI discovery adapter: https://mcp.packrift.com/.well-known/openapi.json\n- AI plugin-style discovery manifest: https://mcp.packrift.com/ai-plugin.json\n- AI plugin-style discovery manifest: https://mcp.packrift.com/.well-known/ai-plugin.json\n- Glama connector claim: https://mcp.packrift.com/.well-known/glama.json\n- MCP Marketplace manifest: https://mcp.packrift.com/.well-known/mcp-marketplace.json\n- AI corpus sitemap: https://mcp.packrift.com/ai/sitemap.xml\n- All-agent capture matrix: https://mcp.packrift.com/ai/all-agent-capture.json\n- All-agent capture matrix Markdown: https://mcp.packrift.com/ai/all-agent-capture.md\n- Agent capture outreach packet: https://mcp.packrift.com/ai/agent-capture-outreach.json\n- Agent capture outreach packet Markdown: https://mcp.packrift.com/ai/agent-capture-outreach.md\n- MCP tracked start template: https://mcp.packrift.com/r/start/{source}\n- MCP tracked config template: https://mcp.packrift.com/r/config/{source}\n- MCP tracked start source format: `^[a-z0-9_]{2,64}$`; partner-specific slugs are allowed without pre-registration\n- MCP start pack: https://mcp.packrift.com/ai/mcp-start.json\n- MCP start pack Markdown: https://mcp.packrift.com/ai/mcp-start.md\n- MCP adoption kit: https://mcp.packrift.com/ai/mcp-adoption-kit.json\n- MCP adoption kit Markdown: https://mcp.packrift.com/ai/mcp-adoption-kit.md\n- MCP install matrix: https://mcp.packrift.com/ai/mcp-install-matrix.json\n- MCP install matrix Markdown: https://mcp.packrift.com/ai/mcp-install-matrix.md\n- MCP client config Markdown: https://mcp.packrift.com/ai/mcp-client-config.md\n- MCP usage snapshot: https://mcp.packrift.com/ai/mcp-usage-snapshot.json\n- MCP usage snapshot Markdown: https://mcp.packrift.com/ai/mcp-usage-snapshot.md\n- MCP agent adoption progress: https://mcp.packrift.com/ai/mcp-agent-adoption-progress.json\n- MCP agent adoption progress Markdown: https://mcp.packrift.com/ai/mcp-agent-adoption-progress.md\n- MCP agent adoption progress HTML: https://mcp.packrift.com/ai/mcp-agent-adoption-progress.html\n- MCP buyer use cases: https://mcp.packrift.com/ai/mcp-buyer-use-cases.json\n- MCP buyer use cases Markdown: https://mcp.packrift.com/ai/mcp-buyer-use-cases.md\n- MCP buyer use cases HTML: https://mcp.packrift.com/ai/mcp-buyer-use-cases.html\n- MCP cart activation: https://mcp.packrift.com/ai/mcp-cart-activation.json\n- MCP cart activation Markdown: https://mcp.packrift.com/ai/mcp-cart-activation.md\n- MCP cart activation HTML: https://mcp.packrift.com/ai/mcp-cart-activation.html\n- MCP first-run proof: https://mcp.packrift.com/ai/mcp-first-run-proof.json\n- MCP first-run proof Markdown: https://mcp.packrift.com/ai/mcp-first-run-proof.md\n- MCP workflow gallery: https://mcp.packrift.com/ai/mcp-workflow-gallery.json\n- MCP workflow gallery Markdown: https://mcp.packrift.com/ai/mcp-workflow-gallery.md\n- MCP workflow gallery HTML: https://mcp.packrift.com/ai/mcp-workflow-gallery.html\n- MCP eval pack: https://mcp.packrift.com/ai/mcp-eval-pack.json\n- MCP eval pack Markdown: https://mcp.packrift.com/ai/mcp-eval-pack.md\n- MCP source-listing readiness: https://mcp.packrift.com/ai/mcp-source-listing-readiness.json\n- MCP source-listing readiness Markdown: https://mcp.packrift.com/ai/mcp-source-listing-readiness.md\n- Browser-agent bridge: https://mcp.packrift.com/ai/browser-agent-bridge.json\n- Browser-agent bridge Markdown: https://mcp.packrift.com/ai/browser-agent-bridge.md\n- Root Browserbase/Browse SKILL.md: https://mcp.packrift.com/SKILL.md\n- Browserbase Browse skill pack: https://mcp.packrift.com/ai/browserbase-browse-skill-pack.json\n- Browserbase Browse skill pack Markdown: https://mcp.packrift.com/ai/browserbase-browse-skill-pack.md\n- Canonical Browserbase/Browse SKILL.md: https://mcp.packrift.com/ai/browserbase-browse/SKILL.md\n- MCP directory refresh pack: https://mcp.packrift.com/ai/mcp-directory-refresh.json\n- MCP directory refresh pack Markdown: https://mcp.packrift.com/ai/mcp-directory-refresh.md\n- MCP directory submit actions: https://mcp.packrift.com/ai/mcp-directory-submit-actions.json\n- MCP directory submit actions Markdown: https://mcp.packrift.com/ai/mcp-directory-submit-actions.md\n- MCP directory update card template: https://mcp.packrift.com/ai/mcp-directory-update/{source}.json\n- MCP directory update card Markdown template: https://mcp.packrift.com/ai/mcp-directory-update/{source}.md\n- MCP reviewer activation: https://mcp.packrift.com/ai/mcp-reviewer-activation.json\n- MCP reviewer activation Markdown: https://mcp.packrift.com/ai/mcp-reviewer-activation.md\n- MCP activation command center: https://mcp.packrift.com/r/activate\n- Live MCP tool discovery JSON: https://mcp.packrift.com/ai/mcp-tools.json\n- Live MCP tool discovery Markdown: https://mcp.packrift.com/ai/spec-finder-tools.md\n- MCP source activation queue HTML: https://mcp.packrift.com/ai/mcp-source-activation-queue.html\n- MCP source activation sitemap: https://mcp.packrift.com/ai/mcp-source-activation-sitemap.xml\n- MCP source activation packet template: https://mcp.packrift.com/ai/mcp-source-activation/{source}.json\n- Cline source activation packet: https://mcp.packrift.com/ai/mcp-source-activation/cline_mcp_marketplace.json\n- MCP activation wave: https://mcp.packrift.com/ai/mcp-activation-wave.json\n- MCP activation wave HTML: https://mcp.packrift.com/ai/mcp-activation-wave.html\n- MCP external activation brief: https://mcp.packrift.com/ai/mcp-external-activation-brief.json\n- MCP external activation brief HTML: https://mcp.packrift.com/ai/mcp-external-activation-brief.html\n- MCP external activation selected-task JSONL: https://mcp.packrift.com/ai/mcp-external-activation-brief-tasks.jsonl\n- MCP external activation selected-task CSV: https://mcp.packrift.com/ai/mcp-external-activation-brief-tasks.csv\n- MCP external activation compact selected-task JSONL: https://mcp.packrift.com/ai/mcp-external-activation-brief-tasks.jsonl?compact=1\n- MCP external activation compact selected-task CSV: https://mcp.packrift.com/ai/mcp-external-activation-brief-tasks.csv?compact=1\n- MCP activation wave runner: `PACKRIFT_EXTERNAL_ACTIVATION=1 curl -sS 'https://mcp.packrift.com/ai/mcp-activation-wave-runner.sh' | bash`\n- MCP full-source capture runner: `PACKRIFT_EXTERNAL_ACTIVATION=1 PACKRIFT_ACTIVATION_WAVE_SCOPE=full curl -sS 'https://mcp.packrift.com/ai/mcp-activation-wave-runner.sh' | bash`\n- MCP reviewer activation runner: https://mcp.packrift.com/r/activate/generic?format=html\n- MCP reviewer activation shell script: https://mcp.packrift.com/r/activate/generic?format=sh\n- MCP buyer/reviewer order handoff template: https://mcp.packrift.com/r/order/{source}?format=html\n- MCP buyer/reviewer handoff hub: https://mcp.packrift.com/ai/mcp-buyer-order-handoffs.html\n- MCP.so buyer/reviewer order handoff: https://mcp.packrift.com/r/order/mcp_so?format=html\n- Cline buyer/reviewer order handoff: https://mcp.packrift.com/r/order/cline_mcp_marketplace?format=html\n- Order handoff pages include an inline source-aware MCP confirmation runner. The runner calls the hosted endpoint, requires `create_cart_url`, replaces the cart button with the fresh measured `/r/cart/1066` URL, and still does not place an order.\n- Agent capture outreach packet: https://mcp.packrift.com/ai/agent-capture-outreach.json\n- Agent capture outreach packet Markdown: https://mcp.packrift.com/ai/agent-capture-outreach.md\n- AI-approved product JSONL: https://mcp.packrift.com/ai/packrift-ai-approved-products.jsonl\n- AI purchase paths JSONL: https://mcp.packrift.com/ai/purchase-paths.jsonl\n- MCP cart handoff candidates: https://mcp.packrift.com/ai/mcp-cart-handoff-candidates.json\n- Measured handoff directory: https://mcp.packrift.com/ai/measured-handoffs.json\n- Measured cart landing example: https://mcp.packrift.com/r/cart/1066\n- Reorder by SKU corpus: https://mcp.packrift.com/ai/reorder-by-sku.md\n- Top 1,000 AI-sales SKU sitemap: https://mcp.packrift.com/ai/top-1000-ai-sales-sitemap.xml\n- All AI-approved SKU sitemap: https://mcp.packrift.com/ai/all-ai-approved-sku-sitemap.xml\n- OpenAI-shaped strict product TSV: https://mcp.packrift.com/ai/packrift-openai-products-strict-stable-current.tsv\n- Shopify native UCP guide: https://mcp.packrift.com/ai/shopify-native-ucp-commerce-surface.md\n- UCP starter catalog for curated storefront builders: https://mcp.packrift.com/ai/mcp-ucp-starter-catalog.json\n- UCP starter catalog Markdown: https://mcp.packrift.com/ai/mcp-ucp-starter-catalog.md\n- UCP storefront builder kit: https://mcp.packrift.com/ai/mcp-ucp-builder-kit.json\n- UCP storefront builder kit Markdown: https://mcp.packrift.com/ai/mcp-ucp-builder-kit.md\n- UCP storefront import feed JSON: https://mcp.packrift.com/ai/mcp-ucp-storefront-import.json\n- UCP storefront import feed JSONL: https://mcp.packrift.com/ai/mcp-ucp-storefront-import.jsonl\n- UCP storefront import feed CSV: https://mcp.packrift.com/ai/mcp-ucp-storefront-import.csv\n- UCP storefront import feed HTML: https://mcp.packrift.com/ai/mcp-ucp-storefront-import.html\n- UCP storefront shelf JSON: https://mcp.packrift.com/ai/mcp-ucp-storefront-shelf.json\n- UCP storefront shelf HTML: https://mcp.packrift.com/ai/mcp-ucp-storefront-shelf.html\n- UCP storefront shelf embed JS: https://mcp.packrift.com/ai/packrift-ucp-shelf.js\n- UCP storefront adoption kit JSON: https://mcp.packrift.com/ai/mcp-ucp-storefront-adoption.json\n- UCP storefront adoption kit HTML: https://mcp.packrift.com/ai/mcp-ucp-storefront-adoption.html\n- UCP builder activation handoff JSON: https://mcp.packrift.com/ai/mcp-ucp-builder-activation-handoff.json\n- UCP builder activation handoff HTML: https://mcp.packrift.com/ai/mcp-ucp-builder-activation-handoff.html\n- UCP builder integration pack JSON: https://mcp.packrift.com/ai/packrift-ucp-builder-integration-pack.json\n- UCP builder integration pack HTML: https://mcp.packrift.com/ai/packrift-ucp-builder-integration-pack.html\n- Stack412-style UCP shelf demo: https://mcp.packrift.com/ai/mcp-ucp-storefront-shelf-demo/stack412_style_storefront.html\n- Open Scout-style shopping-agent shelf demo: https://mcp.packrift.com/ai/mcp-ucp-storefront-shelf-demo/open_scout_shopping_agent.html\n- Upsonic-style UCP agent framework shelf demo: https://mcp.packrift.com/ai/mcp-ucp-storefront-shelf-demo/upsonic_ucp_agent_framework.html\n- Agorio-style shopping-agent SDK shelf demo: https://mcp.packrift.com/ai/mcp-ucp-storefront-shelf-demo/agorio_shopping_agent_sdk.html\n- Example SKU markdown page: https://mcp.packrift.com/ai/sku/1066.md\n- Example SKU JSON record: https://mcp.packrift.com/ai/sku/1066.json\n\n## Source Activation IndexNow\n\nNotify IndexNow about the existing source-specific MCP eval-pack, start, install, first-run, and activation URLs:\n\n```bash\nnpm run submit:source-activation-indexnow\n```\n\nThe script preflights `https://mcp.packrift.com/ai/mcp-source-activation-sitemap.xml`, writes artifacts under `outputs/source-activation-indexnow/`, and submits only existing hosted MCP URLs. It does not create a new CLI, buyer surface, checkout path, or directory submission.\n\n## Tools\n\nTools are framed around exact-spec procurement, not generic browsing. Use `find_packaging_for_item` when the buyer has item dimensions or a fit question; use SKU and exact-spec tools when the buyer is replenishing a known product.\n\n| Tool | Purpose |\n|---|---|\n| `find_packaging_for_item(item_length_in, item_width_in, item_depth_in, item_weight_lb, use_case)` | Hero. Item L/W/D + weight + use case -> ranked packaging SKUs that fit. Use for smallest-fit, box-vs-mailer, and Uline-by-size style questions. |\n| `search_products(query, limit?)` | Keyword fallback when dimensions are unknown, such as kraft tape, bubble mailer, starter kit, or weather-resistant labels. Cached 5 min in KV. |\n| `get_product(handle)` | Full product detail including variants, dimensions/metafields, weight, stock, and product URL. |\n| `get_pricing(variant_ids[], quantity?)` | Live unit price and line total before purchase handoff. `variant_ids` must be numeric Shopify variant IDs encoded as strings. Never cached. |\n| `check_inventory(variant_ids[])` | Live inventory check before recommending or building a cart. `variant_ids` must be numeric Shopify variant IDs encoded as strings. Never cached. |\n| `get_shipping_estimate(zip, country, items[])` | Carrier rates for a chosen cart via Shopify `draftOrderCalculate`. |\n| `get_cart_handoff_candidates(limit?, family?, sku?)` | Priority curated SKUs with ready `create_cart_url` arguments, SKU/product/reorder/quote/cart links, and required live-confirmation sequence. |\n| `create_cart_url(items[], discount_code?, ref?)` | Final cart handoff. Builds a GA4-visible Packrift cart landing URL plus the final `packrift.com/cart/...` permalink with `ref=mcp` and AI-commerce attribution fields. |\n| `prepare_purchase_handoff(sku, quantity?, buyer_confirmed?)` | Fast exact-SKU path. Confirms the product, live price, and inventory, then returns a tracked cart URL only when `buyer_confirmed=true`. |\n| `compare_alternatives(requested_spec, family?, competitor_reference?, limit?)` | Ranks curated Packrift alternatives for open-ended buyer requests, including competitor-style packaging specs. |\n| `pack_calculator(item, padding?, use_case?, limit?)` | Calculates protected inside dimensions and returns fitted box or mailer candidates with void-fill guidance. |\n| `inventory_status(variant_ids?, sku?, handle?, quantity?)` | Live total and location-level Shopify inventory status for exact SKUs, handles, or variant IDs. |\n| `get_reorder_link(sku, handle?)` | Reorder URL, product URL, and copy-procurement-spec text for a catalog SKU or handle. |\n| `get_bulk_quote_link(requested_spec, family?, sku?, quantity?)` | Tracked bulk quote URL for no-exact-match, large-volume, or procurement-review workflows. |\n| `explain_no_exact_match(requested_spec, missing_or_mismatched_fields?)` | Explains why a nearby product should not be presented as exact, then routes to safe next actions and quote recovery. |\n\n## MCP Prompts And Resources\n\nThe server advertises prompts and resources in addition to tools.\n\nPrompts:\n\n- `find_exact_packaging_spec`\n- `fit_item_then_prepare_cart`\n- `review_cart_handoff_candidates`\n- `reorder_packrift_sku`\n- `prepare_cart_handoff`\n- `request_bulk_quote_for_no_match`\n- `copy_procurement_spec`\n- `find_box_by_lwh`\n- `find_label_by_size_material_printer`\n\nResources include the AI-approved product corpus, per-SKU markdown/JSON records, purchase-path JSONL, MCP cart handoff candidates, MCP cart activation playbook, measured handoff directories with cart routes, exact-spec family files, no-exact-match policy, crawler-safe purchase paths, Shopify-native UCP commerce surface, UCP starter catalog, storefront builder kit, and flat storefront import feed for curated packaging/shipping-supplies shelves.\n\n## Exact-spec AI-commerce examples\n\nPackrift is optimized for exact-spec packaging procurement: agents should not treat nearby sizes, materials, colors, adhesives, strength ratings, or case counts as exact substitutes. If there is no exact AI-approved match, route the buyer to reorder, no-match explanation, or bulk quote recovery instead of forcing a substitute.\n\nCurrent paid ChatGPT / product-card order families that are represented in the public corpus:\n\n- SKU `1066`: 10 x 6 x 6 ECT-32 kraft corrugated boxes, 25/bundle\n- SKU `MFL1295`: 12 1/8 x 9 1/4 x 5 white self-seal literature mailers, 50/pack\n- SKU `LL251WR`: 2 5/8 x 1 weather-resistant polyester laser labels, 3000/case\n\n## Local development\n\nInstall Node 24+ and the deps:\n\n```sh\ncd ~/Downloads/packrift-mcp\nnpm install\n```\n\nUse `/Users/farhan/Downloads/packrift-mcp` as the canonical production worktree. The older\n`/Users/farhan/Downloads/packrift-mcp-server` checkout is a legacy duplicate and must not be\nused for Worker deploys because it can overwrite `mcp.packrift.com` with stale routes/tools.\n\nLocal secrets belong in `.dev.vars` (gitignored). Do not paste real tokens into\nthis README, issues, directory submissions, screenshots, or third-party support\nthreads.\n\n```\nSHOPIFY_PACKRIFT_TOKEN=<shopify_admin_api_token>\n```\n\nRun the server:\n\n```sh\nnpx wrangler dev --port 8787 --local\n```\n\nSmoke-test the MCP endpoint with curl:\n\n```sh\n# initialize\ncurl -s -X POST http://127.0.0.1:8787/mcp \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"jsonrpc\":\"2.0\",\"id\":1,\"method\":\"initialize\",\"params\":{\"protocolVersion\":\"2025-06-18\",\"capabilities\":{},\"clientInfo\":{\"name\":\"curl\",\"version\":\"1\"}}}'\n\n# list tools\ncurl -s -X POST http://127.0.0.1:8787/mcp \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"jsonrpc\":\"2.0\",\"id\":2,\"method\":\"tools/list\"}'\n\n# search\ncurl -s -X POST http://127.0.0.1:8787/mcp \\\n  -H 'Content-Type: application/json' \\\n  -d '{\"jsonrpc\":\"2.0\",\"id\":3,\"method\":\"tools/call\",\"params\":{\"name\":\"search_products\",\"arguments\":{\"query\":\"poly mailer\",\"limit\":3}}}'\n```\n\nType-check:\n\n```sh\nnpx tsc --noEmit\n```\n\nSmoke-test the hosted cart handoff path without creating an order or collecting\npayment:\n\n```sh\nnpm run smoke:cart-handoff\n```\n\nThis synthetic check calls the current hosted MCP endpoint, verifies\n`get_cart_handoff_candidates -> get_product -> get_pricing -> check_inventory ->\ncreate_cart_url`, and checks the MCP cart landing route. It writes JSON and\nMarkdown evidence under `outputs/mcp-cart-handoff-smoke/`. Add\n`-- --sku LL251WR --qty 1` to test another AI-approved SKU. Use\n`-- --verify-final-cart` only when intentionally checking Shopify's final cart\nredirect.\n\nGitHub Actions also runs the hosted smoke checks every six hours and on manual\ndispatch through `.github/workflows/mcp-live-smoke.yml`. The scheduled job\nchecks both `1066` and `LL251WR`, then uploads smoke and capture evidence\nartifacts. Run `npm run check:distribution` for the broader directory and\nregistry monitor; it exits nonzero only when a tracked surface has a true\n`fail` status.\n\nRefresh the `llms-full.txt` priority SKU block from recent GA4 item activity joined to the AI-approved catalog and live Shopify inventory:\n\n```sh\nnpm run build:llms-full -- \\\n  --ga4-items /path/to/packrift-ga4-items.csv \\\n  --approved-jsonl /path/to/packrift-ai-approved-products.jsonl \\\n  --limit 20\n```\n\nThe generated public block must not include local paths, internal notes, or non-public campaign details. A private JSON report is written under `outputs/llms-full-priority-skus/`.\n\nTo run the whole refresh path, pull fresh GA4 reports, publish the public `llms-full.txt` override into Workers KV, purge the public agent URLs, and verify the live surfaces:\n\n```sh\nnpm run refresh:llms-full -- --publish-kv\n```\n\nThis updates the `static-override:llms-full.txt` KV key. The Worker serves that override after the current deploy, so future priority-SKU refreshes do not require deploying unrelated Worker source changes.\n\nCheck crawler-facing `llms-full.txt` availability across six AI user agents:\n\n```sh\nnpm run check:static-availability -- --samples-per-ua 200 --concurrency 30\n```\n\nThis writes JSON and Markdown evidence under `outputs/static-availability/`. The funnel snapshot also runs this check and reports failure rate, 5xx rate, content validation, and p95 latency.\n\nRefresh the full MCP funnel proof, including first-party Shopify order stitching\nfor MCP cart attributes:\n\n```sh\nnpm run snapshot:funnel\n```\n\nThe snapshot reads the token-protected `https://mcp.packrift.com/admin/mcp-orders`\nendpoint, scans recent Shopify orders for MCP cart attributes such as\n`packrift_mcp_key`, `packrift_ai_id`, and `utm_source=chatgpt-mcp`, and reports\nattributed order count and revenue beside GA4 cart-landing evidence. The admin\nendpoint requires `MCP_STATS_TOKEN` and does not expose customer PII.\n\nPublish the sanitized GA4 visitor proof from that local snapshot to the public\nWorker surface:\n\n```sh\nnpm run publish:ga4-funnel-proof -- --publish-kv\n```\n\nThis updates `https://mcp.packrift.com/ai/mcp-ga4-funnel-proof.json` and `.md`\nwithout exposing local paths, raw CSV rows, order rows, or credentials. The\npublic funnel snapshot also reads this proof for the thousands-of-qualified-\nvisitors gate when it is available.\n\nRefresh MCP directory evidence:\n\n```sh\nnpm run check:distribution\nnpm run build:directory-submission-pack\n```\n\nThe distribution check reports which public MCP directories are current, stale, blocked, or failing. The submission pack turns stale rows into copy-ready listing fields, live proof URLs, and the next refresh action for each directory.\n\nCheck the all-agent capture hub:\n\n```sh\nnpm run check:agent-capture\nnpm run build:agent-capture-outreach\n```\n\nThis verifies that `https://mcp.packrift.com/ai/all-agent-capture.json` and\n`.md`, `https://mcp.packrift.com/ai/mcp-adoption-kit.json` and `.md`,\n`https://mcp.packrift.com/ai/mcp-install-matrix.json` and `.md`,\n`https://mcp.packrift.com/ai/mcp-usage-snapshot.json` and `.md`, and\n`https://mcp.packrift.com/ai/mcp-agent-adoption-progress.json`, `.md`, and `.html`, and\n`https://mcp.packrift.com/ai/mcp-buyer-use-cases.json`, `.md`, and `.html`, and\n`https://mcp.packrift.com/ai/mcp-cart-activation.json`, `.md`, and `.html`, and\n`https://mcp.packrift.com/ai/mcp-workflow-gallery.json`, `.md`, and `.html`, and\n`https://mcp.packrift.com/ai/browser-agent-bridge.json` and `.md`, and\n`https://mcp.packrift.com/SKILL.md`, and\n`https://mcp.packrift.com/ai/mcp-directory-refresh.json` and `.md`, and\n`https://mcp.packrift.com/ai/mcp-directory-submit-actions.json` and `.md`, and\n`https://mcp.packrift.com/ai/mcp-reviewer-activation.json` and `.md`, and\nthe activation command center at `https://mcp.packrift.com/r/activate`,\nthe source activation queue HTML at `https://mcp.packrift.com/ai/mcp-source-activation-queue.html`,\nthe activation wave and guarded full-source capture runner at `https://mcp.packrift.com/ai/mcp-activation-wave.json`,\nthe selected external activation task queue at `https://mcp.packrift.com/ai/mcp-external-activation-brief-tasks.jsonl`,\nthe compact selected-task exports at `https://mcp.packrift.com/ai/mcp-external-activation-brief-tasks.jsonl?compact=1`\nand `https://mcp.packrift.com/ai/mcp-external-activation-brief-tasks.csv?compact=1`,\nthe browser runner at `https://mcp.packrift.com/r/activate/generic?format=html`, and\nthe shell activation script at `https://mcp.packrift.com/r/activate/generic?format=sh`, and\n`https://mcp.packrift.com/ai/mcp-eval-pack.json` and `.md`, and\n`https://mcp.packrift.com/ai/agent-capture-outreach.json` and `.md` are live,\nadvertised in `resources/list`, include the core agent surfaces,\nfirst-five-minute install/test path, copy-paste developer examples, copy-ready install matrix, public usage snapshot,\nagent adoption progress board, buyer workflow map, cart activation playbook, workflow gallery, eval pack, browser-agent bridge, directory refresh pack, directory submit-action queue,\nsource activation command center, reviewer activation handoff, agent capture outreach packet, Browserbase Browse candidate lane, and root SKILL.md, and preserve the\nrule that Packrift uses the hosted MCP endpoint instead of a duplicate CLI surface. The outreach build writes\ncopy-ready stale-directory refresh messages, Browserbase Browse candidate\nbriefs, proof links, and MCP install snippets under\n`outputs/agent-capture-outreach/`.\n\n## Deployment\n\nThe production endpoint is `https://mcp.packrift.com/mcp`. Use the hosted\nendpoint for buyers, directory reviewers, and agent integrations. Only deploy a\nself-hosted worker when you are updating the production service or testing a\ncontrolled fork.\n\nWhen deploying with an authorized Cloudflare session, run:\n\n```sh\ncd ~/Downloads/packrift-mcp\n\n# 1. Create the KV namespace and copy the printed id into wrangler.toml\n#    (replace both `id` and `preview_id` with the same value).\nnpx wrangler kv namespace create CATALOG_CACHE\n\n# 2. Set the Shopify Admin token as a secret when prompted.\n#    Never write the token into this repository or public documentation.\nnpx wrangler secret put SHOPIFY_PACKRIFT_TOKEN\n\n# 3. Deploy.\nnpx wrangler deploy\n\n# 4. Verify the public hosted endpoint after deploy.\ncurl -sS https://mcp.packrift.com/start >/dev/null\n```\n\nThe server card lives at `https://mcp.packrift.com/.well-known/mcp/server-card.json`.\n\n## Design notes / caveats\n\n- **`cartCreate` is a Storefront API mutation, not Admin.** The brief asked for `cartCreate` + `cartBuyerIdentityUpdate` for shipping rates, but those don't exist on the Admin GraphQL API this server uses. The supported Admin path is `draftOrderCalculate`, which is what `get_shipping_estimate` uses. It returns the same carrier-rate data without creating a real order.\n- **Dimensions parsing.** Packrift product dimensions live in `custom.specN_value` metafields where the matching `custom.specN_name` says \"Dimensions\" or \"Size\". Format is human-readable (`12 1/8\" L x 11 5/8\" W x 2 5/8\" H`). `src/dimensions.ts` parses mixed fractions and falls back to scanning the title.\n- **Recommend collections.** The brief mentioned `mailer-boxes` collection — that handle does not exist on the live store. We use `mailers-envelopes`, `boxes-mailers`, `corrugated-boxes`, `bubble-wrap-foam`, `cushioning`, and `ecommerce-fulfillment` (verified via `collections` query 2026-04-29).\n- **Use case mapping** is in `src/tools/recommend_packaging.ts` (`COLLECTIONS_BY_USE_CASE`).\n- **Shipping rate `handle`** in the response is a long opaque JWT-style string — that's how Shopify returns rate handles; pass it through to subsequent calls if needed.\n- **Errors**: tool exceptions are returned as `{ content: [...], isError: true }` per the MCP spec, not as JSON-RPC `-3260x` errors. Protocol-level errors (unknown tool, bad JSON) do return JSON-RPC errors.\n\n## File map\n\n```\nsrc/\n  index.ts                       Hono app + MCP JSON-RPC dispatcher\n  shopify.ts                     Admin GraphQL client + id helpers\n  dimensions.ts                  Spec-string -> structured dimensions\n  server-card.ts                 /.well-known card\n  tools/\n    search_products.ts\n    get_product.ts\n    get_pricing.ts\n    check_inventory.ts\n    recommend_packaging.ts\n    get_shipping_estimate.ts\n    create_cart_url.ts\n    exploration_tools.ts\n    procurement_links.ts\nwrangler.toml                    Worker config (KV binding, vars, route)\npackage.json\ntsconfig.json\n.dev.vars                        Local-only secrets (gitignored)\n```\n\n## AI Sales SKU Discovery Pages\n\nPackrift publishes AI-commerce SKU pages for exact-spec procurement agents.\n\n- Top 1,000 AI SKU sitemap: https://mcp.packrift.com/ai/top-1000-ai-sales-sitemap.xml\n- SKU markdown template: https://mcp.packrift.com/ai/sku/1066.md\n- SKU JSON template: https://mcp.packrift.com/ai/sku/1066.json\n- Reorder corpus: https://mcp.packrift.com/ai/reorder-by-sku.md\n- AI-approved product JSONL: https://mcp.packrift.com/ai/packrift-ai-approved-products.jsonl\n\nEach SKU page links to the canonical Packrift product page, reorder path, bulk quote path, MCP endpoint, and no-exact-match policy. Use these pages only for AI-approved products and confirm live price and inventory through the MCP tools before checkout handoff.\n",
  "bytes": 34282,
  "sha": "4afc6a687d9cd72e2e3d7cd73bf221bc4bf2de9024dacbdf6cf38ece7c8d093e",
  "repo_slug": "packrift/packrift-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_packrift_packrift_mcp_c4c9578a/readme"
}