Autonomous Certified Mail & Legal Fax Cancellation Infrastructure
DisputeDrop is an automated cancellation and legal notice engine designed to terminate recurring gym memberships, telecom plans, and enterprise subscriptions without human retention friction.
DisputeDrop bypasses dark-pattern retention traps, fake phone queues, and mandatory in-person visits by auto-compiling jurisdiction-specific legal revocation instruments, embedding user canvas signatures, and executing physical USPS Certified Mail and legal facsimile dispatch with live delivery tracking.
- Statutory PDF Notice Engine: Headless Puppeteer engine builds verified legal notice documents embedded with user canvas signatures.
- Multi-Channel Fulfillment: Real-time integration with Lob API (US Certified Physical Mail) and Phaxio API (facsimile transmission).
- Payment Verification: Webhook-first Stripe checkout lifecycle for flat-rate $6.99 pay-per-dispute execution.
- Reliable Queues: BullMQ & Redis async queue with automated exponential backoff retries.
-
Clone the Repository:
git clone https://github.com/mmesomasaint/disputedrop-engine.git cd disputedrop-engine -
Install Dependencies:
npm install
-
Setup Local Environment:
cp .env.example .env
-
Start Storage, PostgreSQL & Redis:
docker-compose up postgres redis -d
-
Run Migrations & Seed Vendors:
npx prisma migrate dev npm run prisma:seed
-
Start Dev Server:
npm run dev
The API will be available at
http://localhost:8000. You can verify it is running by checking the health endpoint:curl http://localhost:8000/health
- Retrieve Supported Merchants
curl -X GET "http://localhost:8000/api/v1/merchants" - Provide Stripe Sandbox Key
- Log into your Stripe Dashboard.
- Toggle
Test modeat the top right. - Copy your test secret key (begins with
sk_test_51...). - Paste it into your
.envfile:STRIPE_SECRET_KEY="sk_test_51..."
- Initiate Cancellation Intent ($6.99)
Returns:
curl -X POST http://localhost:8000/api/v1/cancellations \ -H "Content-Type: application/json" \ -d @payload.json{ "status": "success", "data": { "cancellationId": "a1b2c3d4-e5f6-7a8b-9c0d-1234567890ab", "clientSecret": "pi_xxx_secret_xxx", "amountCents": 699 } }
curl -X GET "http://localhost:8000/api/v1/cancellations/<CANCELLATION_UUID>"
# e.g.
curl -X GET "http://localhost:8000/api/v1/cancellations/a1b2c3d4-e5f6-7a8b-9c0d-1234567890ab"
# 1. Run ALL tests (Unit + Integration)
npm run test
# 2. Run ONLY Unit Tests (Fast, does not require DB or Redis)
npm run test:unit
# 3. Run ONLY Integration Tests (Requires Postgres & Redis active)
npm run test:integration
# 4. Run tests with detailed code coverage report
npm run test:coverage