{"_id":"@agentprolabs/pet-recall-mcp","name":"@agentprolabs/pet-recall-mcp","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@agentprolabs/pet-recall-mcp","version":"0.1.0","description":"Monitor pet food and drug recalls from Canadian (CFIA) and US (FDA) government sources","type":"module","main":"dist/index.js","bin":{"pet-recall-mcp":"dist/index.js"},"scripts":{"build":"tsc","dev":"tsc --watch","lint":"eslint .","format":"prettier --write .","format:check":"prettier --check .","test":"vitest run","test:watch":"vitest","typecheck":"tsc --noEmit"},"keywords":["mcp","pet","recall","veterinary","food-safety","fda","cfia"],"author":{"name":"AgentProLabs"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/agentprolabs/pet-recall-mcp.git"},"homepage":"https://recalls.agentprolabs.com","publishConfig":{"access":"public"},"dependencies":{"@modelcontextprotocol/sdk":"^1.29.0","zod":"^4.4.3"},"devDependencies":{"@cloudflare/workers-types":"^4.20260602.1","@eslint/js":"^10.0.1","@types/node":"^25.9.1","@types/pg":"^8.20.0","eslint":"^10.4.1","pg":"^8.21.0","prettier":"^3.8.3","resend":"^6.12.4","typescript":"^6.0.3","typescript-eslint":"^8.60.0","vitest":"^4.1.7","wrangler":"^4.95.0"},"gitHead":"a7ec470333d55227473cc8c8f18022752c481237","types":"./dist/index.d.ts","_id":"@agentprolabs/pet-recall-mcp@0.1.0","bugs":{"url":"https://github.com/agentprolabs/pet-recall-mcp/issues"},"_nodeVersion":"24.13.1","_npmVersion":"11.8.0","dist":{"integrity":"sha512-JnkA0R92iJX2898NvrEu+MaMpw0xjzAUEdDrwe0FikenDrQnRqn+Z/cUpJtcslXgJ8OJ/gYluwLxW6P7dgyhpA==","shasum":"ce43fc813cf2d71f085a8198977102854d008546","tarball":"https://registry.npmjs.org/@agentprolabs/pet-recall-mcp/-/pet-recall-mcp-0.1.0.tgz","fileCount":84,"unpackedSize":105839,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQDKr018CRe5qi35OG3Hsb4AjVcc5az28PfbMa4piy5FxwIgH4ykiPeSJOXPGKKvfvkiUlW65HI5esZnflwHxJcaNxU="}]},"_npmUser":{"name":"agentprolabs","email":"agentprolabs@gmail.com"},"directories":{},"maintainers":[{"name":"agentprolabs","email":"agentprolabs@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/pet-recall-mcp_0.1.0_1780542539989_0.9023732333990113"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-04T03:08:59.864Z","0.1.0":"2026-06-04T03:09:00.143Z","modified":"2026-06-04T03:09:00.311Z"},"maintainers":[{"name":"agentprolabs","email":"agentprolabs@gmail.com"}],"description":"Monitor pet food and drug recalls from Canadian (CFIA) and US (FDA) government sources","homepage":"https://recalls.agentprolabs.com","keywords":["mcp","pet","recall","veterinary","food-safety","fda","cfia"],"repository":{"type":"git","url":"git+https://github.com/agentprolabs/pet-recall-mcp.git"},"author":{"name":"AgentProLabs"},"bugs":{"url":"https://github.com/agentprolabs/pet-recall-mcp/issues"},"license":"MIT","readme":"# Pet Recall Watcher MCP\n\nAn open-source [Model Context Protocol](https://modelcontextprotocol.io) server\nthat monitors pet food and veterinary drug recalls from the Government of Canada\n(CFIA / Health Canada) and the US FDA (openFDA), making recall data queryable by\nAI assistants like Claude.\n\nBuilt by [AgentProLabs](https://agentprolabs.com) · Open source under MIT\n\n> **Status:** v0.1. The `npx` package is pending its first npm publish; the\n> landing page is live at [recalls.agentprolabs.com](https://recalls.agentprolabs.com).\n> A hosted HTTP/SSE MCP endpoint is planned for v0.2 — for now use the stdio\n> server below.\n\n## What it does\n\nRecall communication at the vet-clinic level is a scramble of distributor emails\nand listservs, with no machine-readable feed. Pet Recall Watcher ingests the\npublic government recall datasets daily and exposes them over MCP so an AI\nassistant can answer questions on a clinic's behalf.\n\n- **Daily ingestion** of pet-relevant recalls from the Government of Canada open\n  dataset and the openFDA food + drug enforcement endpoints.\n- **Three MCP tools:**\n  - `query_active_recalls` — search/filter active recalls by species, category,\n    region, and date range.\n  - `lookup_product_status` — fuzzy-match a product name against the recall\n    database (handles partial names and minor misspellings).\n  - `subscribe_recall_alerts` — register an email for filtered recall alerts.\n- **Email notifications** via Resend when new recalls match a subscription.\n- **Landing page** with a subscribe form and a recent-recalls feed.\n\nIt runs as a local **stdio** server (via `npx`) for desktop AI clients.\n\n## Quick Start (stdio)\n\nRun directly with `npx` — no install needed:\n\n```bash\nnpx @agentprolabs/pet-recall-mcp\n```\n\n### Claude Desktop\n\nAdd to your `claude_desktop_config.json`:\n\n```json\n{\n  \"mcpServers\": {\n    \"pet-recall-watcher\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@agentprolabs/pet-recall-mcp\"]\n    }\n  }\n}\n```\n\nRestart Claude Desktop — the tools appear automatically. Then ask, e.g.,\n_\"Are there any recent dog food recalls in Canada?\"_\n\n**Requirements:** Node.js 20+. **No configuration needed** — the server is a thin\nclient over the hosted Pet Recall API, so there are no API keys or database\ncredentials to set. _(Advanced/self-host: override the API origin with the\n`PET_RECALL_API_URL` env var.)_\n\n## Tools\n\n### `query_active_recalls`\n\nReturns active pet food and drug recalls, with optional filtering. Sorted by\nrecall date (newest first), paginated.\n\n| Parameter          | Type                                                           | Default | Description                        |\n| ------------------ | -------------------------------------------------------------- | ------- | ---------------------------------- |\n| `species`          | `\"dog\"` \\| `\"cat\"` \\| `\"all\"`                                  | `\"all\"` | Filter by affected species         |\n| `product_category` | `\"food\"` \\| `\"treat\"` \\| `\"drug\"` \\| `\"supplement\"` \\| `\"all\"` | `\"all\"` | Filter by product type             |\n| `region`           | `\"canada\"` \\| `\"us\"` \\| `\"all\"`                                | `\"all\"` | Filter by recall origin            |\n| `since_date`       | ISO 8601 date string                                           | —       | Only recalls on or after this date |\n| `limit`            | number (1–100)                                                 | `20`    | Results per page                   |\n| `offset`           | number                                                         | `0`     | Pagination offset                  |\n\n**Example response:**\n\n```json\n{\n  \"recalls\": [\n    {\n      \"id\": \"1e6a57aa-80f6-400a-9896-a7f90baf4cfc\",\n      \"title\": \"Primal Patties for Dogs Beef Formula recalled due to Listeria\",\n      \"source\": \"canada_recalls\",\n      \"source_id\": \"64441\",\n      \"species\": [\"dog\"],\n      \"product_category\": \"food\",\n      \"product_names\": [\"Primal Patties for Dogs – Beef Formula\"],\n      \"brand\": null,\n      \"risk_level\": null,\n      \"reason\": \"Microbial hazard\",\n      \"region\": \"canada\",\n      \"recall_date\": \"2022-08-05\",\n      \"source_url\": \"https://recalls-rappels.canada.ca/en/alert-recall/...\",\n      \"data_freshness\": \"2026-06-02 23:17:23+00\"\n    }\n  ],\n  \"total_count\": 1,\n  \"limit\": 20,\n  \"offset\": 0\n}\n```\n\n### `lookup_product_status`\n\nCheck whether a specific product has been recalled. Uses PostgreSQL `pg_trgm`\nfuzzy matching against product names and brand — partial names and minor\nmisspellings still find results. No match is a valid, useful answer (not an\nerror).\n\n| Parameter         | Type              | Required   | Description                                     |\n| ----------------- | ----------------- | ---------- | ----------------------------------------------- |\n| `query`           | string (≥2 chars) | Yes        | Product name, brand, or UPC to look up          |\n| `match_threshold` | number (0.1–1)    | No (`0.3`) | Minimum similarity score (lower = more results) |\n\n**Example response (match found):**\n\n```json\n{\n  \"matches\": [\n    {\n      \"title\": \"FRESHPET SELECT ... REFRIGERATED DOG FOOD\",\n      \"source\": \"openfda_food\",\n      \"risk_level\": \"Class II\",\n      \"recall_date\": \"2019-07-31\",\n      \"source_url\": null,\n      \"similarity_score\": 0.72,\n      \"matched_field\": \"product_name\"\n    }\n  ],\n  \"query\": \"freshpet dog food\",\n  \"total_matches\": 1,\n  \"data_freshness\": \"2026-06-02 23:17:23+00\"\n}\n```\n\n**Example response (no match):**\n\n```json\n{\n  \"matches\": [],\n  \"query\": \"asdfghjkl\",\n  \"total_matches\": 0,\n  \"data_freshness\": null\n}\n```\n\n### `subscribe_recall_alerts`\n\nSubscribe an email to recall alerts matching optional filters. A duplicate\n(same email + filters) returns the existing subscription rather than creating a\nnew one.\n\n| Parameter          | Type                                                           | Required     | Description                                                      |\n| ------------------ | -------------------------------------------------------------- | ------------ | ---------------------------------------------------------------- |\n| `email`            | string                                                         | Yes          | Email address for alerts                                         |\n| `species`          | `\"dog\"` \\| `\"cat\"` \\| `\"all\"`                                  | No (`\"all\"`) | Only alert for this species                                      |\n| `product_category` | `\"food\"` \\| `\"treat\"` \\| `\"drug\"` \\| `\"supplement\"` \\| `\"all\"` | No (`\"all\"`) | Only alert for this category                                     |\n| `region`           | `\"canada\"` \\| `\"us\"` \\| `\"all\"`                                | No (`\"all\"`) | Only alert for this region                                       |\n| `webhook_url`      | string                                                         | No           | RESERVED for Phase 2 PMS integration — accepted but not acted on |\n\n**Example response:**\n\n```json\n{\n  \"subscription_id\": \"e5f6g7h8-...\",\n  \"email\": \"clinic@example.com\",\n  \"filters\": {\n    \"species\": \"dog\",\n    \"product_category\": \"food\",\n    \"region\": \"canada\"\n  },\n  \"status\": \"active\",\n  \"created_at\": \"2026-06-02T00:00:00Z\",\n  \"message\": \"Subscription created\"\n}\n```\n\n## Resources\n\n### `recent-recalls`\n\nURI: `recall-feed://recent`\n\nReturns the 20 most recent recalls across all sources as JSON — lets a client\nshow current recall activity without calling a tool.\n\n## Prompts\n\n### `check-product-safety`\n\nA pre-built prompt that takes a product name, runs the fuzzy lookup, and frames\nthe result for a plain-language safety summary.\n\n| Argument       | Type   | Required | Description          |\n| -------------- | ------ | -------- | -------------------- |\n| `product_name` | string | Yes      | The product to check |\n\n## Server Info\n\n| Field     | Value                                  |\n| --------- | -------------------------------------- |\n| Name      | `pet-recall-watcher`                   |\n| Version   | `0.1.0`                                |\n| Protocol  | MCP (Model Context Protocol)           |\n| Transport | stdio (local); HTTP/SSE planned (v0.2) |\n| Tools     | 3                                      |\n| Resources | 1                                      |\n| Prompts   | 1                                      |\n\n## Data sources\n\nDaily ingestion from three public, unauthenticated government datasets — CFIA\n(Canada), openFDA food, and openFDA drug enforcement. See\n[`docs/DATA-SOURCES.md`](docs/DATA-SOURCES.md) for endpoints, schema mappings,\nfreshness caveats, and the pet-relevance filtering strategy.\n\n## Development\n\n```bash\nnpm install\nnpm run typecheck   # tsc --noEmit\nnpm run lint        # eslint .\nnpm run test        # vitest run\nnpm run build       # tsc -> dist/\n```\n\nArchitecture: shared logic in `src/` (data-sources, tools, db, notifications);\nCloudflare Workers in `workers/` (mcp-server, ingestion, api, notification);\nthe Astro landing page in `landing/`. See\n[`IMPLEMENTATION_LOG.md`](IMPLEMENTATION_LOG.md) for the build playbook and\n[`docs/PHASE2-HOOKS.md`](docs/PHASE2-HOOKS.md) for deferred features.\n\n## Coming later\n\n- **Hosted HTTP/SSE MCP endpoint** at `recalls.agentprolabs.com/mcp` (v0.2).\n- **`match_recall_to_patients`** — cross-reference a recall against a clinic's\n  patient product records (Phase 2; see `docs/PHASE2-HOOKS.md`).\n\n---\n\nBuilt by [AgentProLabs](https://agentprolabs.com) ·\n[Source](https://github.com/agentprolabs/pet-recall-mcp) · Open source under MIT.\n","readmeFilename":"README.md","_rev":"1-038e34fc9376fc4072c13d838a36cbcd"}