Initial commit: LeadFlow lead generation platform
Full-stack Next.js 16 app with three scraping pipelines: - AirScale CSV → Anymailfinder Bulk Decision Maker search - LinkedIn Sales Navigator → Vayne → Anymailfinder email enrichment - Apify Google SERP → domain extraction → Anymailfinder bulk enrichment Includes Docker multi-stage build + docker-compose for Coolify deployment. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
40
prisma/migrations/20260317100747_init/migration.sql
Normal file
40
prisma/migrations/20260317100747_init/migration.sql
Normal file
@@ -0,0 +1,40 @@
|
||||
-- CreateTable
|
||||
CREATE TABLE "ApiCredential" (
|
||||
"id" TEXT NOT NULL PRIMARY KEY,
|
||||
"service" TEXT NOT NULL,
|
||||
"value" TEXT NOT NULL,
|
||||
"createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" DATETIME NOT NULL
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "Job" (
|
||||
"id" TEXT NOT NULL PRIMARY KEY,
|
||||
"type" TEXT NOT NULL,
|
||||
"status" TEXT NOT NULL DEFAULT 'pending',
|
||||
"config" TEXT NOT NULL DEFAULT '{}',
|
||||
"totalLeads" INTEGER NOT NULL DEFAULT 0,
|
||||
"emailsFound" INTEGER NOT NULL DEFAULT 0,
|
||||
"error" TEXT,
|
||||
"createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" DATETIME NOT NULL
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "LeadResult" (
|
||||
"id" TEXT NOT NULL PRIMARY KEY,
|
||||
"jobId" TEXT NOT NULL,
|
||||
"companyName" TEXT,
|
||||
"domain" TEXT,
|
||||
"contactName" TEXT,
|
||||
"contactTitle" TEXT,
|
||||
"email" TEXT,
|
||||
"confidence" REAL,
|
||||
"linkedinUrl" TEXT,
|
||||
"source" TEXT,
|
||||
"createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
CONSTRAINT "LeadResult_jobId_fkey" FOREIGN KEY ("jobId") REFERENCES "Job" ("id") ON DELETE CASCADE ON UPDATE CASCADE
|
||||
);
|
||||
|
||||
-- CreateIndex
|
||||
CREATE UNIQUE INDEX "ApiCredential_service_key" ON "ApiCredential"("service");
|
||||
3
prisma/migrations/migration_lock.toml
Normal file
3
prisma/migrations/migration_lock.toml
Normal file
@@ -0,0 +1,3 @@
|
||||
# Please do not edit this file manually
|
||||
# It should be added in your version-control system (e.g., Git)
|
||||
provider = "sqlite"
|
||||
43
prisma/schema.prisma
Normal file
43
prisma/schema.prisma
Normal file
@@ -0,0 +1,43 @@
|
||||
generator client {
|
||||
provider = "prisma-client-js"
|
||||
}
|
||||
|
||||
datasource db {
|
||||
provider = "sqlite"
|
||||
}
|
||||
|
||||
model ApiCredential {
|
||||
id String @id @default(cuid())
|
||||
service String @unique
|
||||
value String
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
}
|
||||
|
||||
model Job {
|
||||
id String @id @default(cuid())
|
||||
type String
|
||||
status String @default("pending")
|
||||
config String @default("{}")
|
||||
totalLeads Int @default(0)
|
||||
emailsFound Int @default(0)
|
||||
error String?
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
results LeadResult[]
|
||||
}
|
||||
|
||||
model LeadResult {
|
||||
id String @id @default(cuid())
|
||||
jobId String
|
||||
job Job @relation(fields: [jobId], references: [id], onDelete: Cascade)
|
||||
companyName String?
|
||||
domain String?
|
||||
contactName String?
|
||||
contactTitle String?
|
||||
email String?
|
||||
confidence Float?
|
||||
linkedinUrl String?
|
||||
source String?
|
||||
createdAt DateTime @default(now())
|
||||
}
|
||||
Reference in New Issue
Block a user