Linkparser is a Next.js product intelligence tool that searches commerce results and extracts structured product data from URLs. It combines a simple web UI with API routes that call Firecrawl, normalize product names/prices/images, and optionally cache results in Convex.
- Paste a product URL and extract a normalized product name, display name, price, and primary image.
- Search for products, filter toward likely commerce pages, and extract product data from top results.
- Normalize messy retailer titles into short display names.
- Parse common currency symbols and price formats.
- Cache repeated requests in memory and optionally in Convex.
- Keep raw extraction payloads available for debugging.
- Next.js App Router
- TypeScript
- Firecrawl search and extraction APIs
- Convex for optional persistent caching
- Zod request validation
src/app/
|-- page.tsx # Product URL extraction and search UI
`-- api/
|-- extract/route.ts # URL extraction, normalization, cache lookup/write-through
`-- search/route.ts # Commerce-oriented search and sequential product extraction
convex/
|-- schema.ts # Product cache schema
`-- products.ts # Product lookup/upsert functions
Create .env.local:
FIRECRAWL_API_KEY=
CONVEX_URL=FIRECRAWL_API_KEY is required. CONVEX_URL is optional; without it, the app still uses in-memory cache during the server process lifetime.
npm run devOpen http://localhost:3000 with your browser to see the result.
To enable persistent caching:
npm run convex:onceThen keep Convex syncing in another terminal:
npm run convex:devThe API routes are intentionally defensive around third-party extraction output. They normalize data into a stable UI shape while preserving the raw payload for inspection.
- CI installs dependencies and runs the production build on pushes and pull requests.
CONTRIBUTING.mddocuments the expected validation path for extraction, search, and cache changes.SECURITY.mdcaptures expectations around API keys, external URL handling, and raw third-party payloads.