Digital Marketplace — AI skill for Claude Code
Marketplace for digital products where every listing has an assistant that has read it.
How to install Digital Marketplace
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open tientran1234/digital-marketplace and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Digital Marketplace does
Marketplace for digital products where every listing has an assistant that has read it. Stripe one-time + subscriptions with idempotent webhooks, durable review/refund workflows, RAG on pgvector with MMR, traced Claude agent, self-hosted edition via signed licenses. Next.js 15, en/vi.
Alternatives in AI
- Main — Open-source SaaS framework (React + Firebase + Stripe) with built-in Claude Code AI skills 550 ★
- AI Avatar System — 🎭 AI Avatar / digital human platform — upload a photo, clone a voice, talk to any face in real time with lip 422 ★
- Styleseed — Claude Code & Cursor design system 325 ★
README
digital-marketplace
A marketplace for digital products where every listing comes with an assistant that has actually read it. Sellers upload a document, buyers purchase it once or subscribe, and questions get answered from the document itself — with citations. Reviews and refunds are durable workflows that wait for a human. English and Vietnamese.
Built on four libraries extracted from it:
| Library | What it owns here |
|---|---|
| agent-runtime | the "ask about this product" agent: tools, quota gate, streaming, tracing with cost |
| durable-workflow | product review (waits up to 7 days for an admin) and refunds (waits for a decision, then calls the provider with retries) |
| subscription-billing | the billing design: idempotent webhooks, forward-only state machines, entitlements derived on read |
| offline-license | the self-hosted edition: admin area gated by a signed license, no phone-home |
The RAG pipeline (structure-aware chunking → embeddings → pgvector → MMR re-ranking) lives in `src/rag/` and runs on Postgres alone — no vector service.
Flows
**Buy.** `POST /api/checkout/order` persists a `PENDING` order *before* calling Stripe, so a webhook that beats the response still finds it. Stripe's `checkout.session.completed` arrives at `POST /api/webhooks/stripe`: raw body → signature → event id claimed in `WebhookEvent` (the insert is the lock) → `UPDATE … WHERE status IN (PENDING)`. A replayed delivery is a `duplicate`; two racing deliveries produce one winner. Download access is one pure function (`domain/access.ts`) used by both the button and the file route, so they can never disagree.
**Ask.** `POST /api/products/:id/ask` streams SSE. Before the model is called: plan check (`ask_ai`), then monthly quota incremented in the database. The agent
Related Skills
Refund Anything AI Prompt
AI prompt & agent skill that gets your money back — subscriptions, digital purchases, bookings. Polite letter
Vox Agent
LLM agent for customer support with inline evaluation, hallucination detection, retry/fallback logic, and RAG
Whatsapp Business Agent
Türkçe WhatsApp müşteri hizmetleri agent'ı: Claude Opus 5 + n8n + hibrit RAG (pgvector) + klasik ML yönlendirm
AI Document Assistant
Secure, multi-tenant enterprise document intelligence & RAG platform: sandboxed ingestion, hybrid pgvector/Qdr
Team Brain
AI knowledge assistant for teams: employees ask, TeamBrain answers from company documents with clickable sourc
Kms
Give your AI coding agent durable, checkable knowledge — decisions, facts, and guardrails it won't forget, con
Related Agents
Creo Stripe CLI
Stripe CLI and MCP expert for payments, subscriptions, customers, products, webhooks, and billing
Stripe Flow Reviewer
Use this agent when a PR touches payment, webhook, deposit, charge, or refund files — or any file whose name c
AI Specialist
Expert in integrating LLMs, building RAG systems (pgvector), and creating MCP servers.