Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ DATABASE_URL=
# WEB CRAWLING (FIRECRAWL)
FIRECRAWL_API_KEY=

# WEB CRAWLING (FASTCRW) — Firecrawl-compatible web scraper (self-host or cloud)
CRW_API_KEY=
# Optional self-host base URL override (defaults to https://fastcrw.com/api)
CRW_API_URL=

# AWS
AWS_GENERAL_ACCESS_KEY=
AWS_GENERAL_SECRET_KEY=
Expand Down
2 changes: 2 additions & 0 deletions environment.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ declare global {
GOOGLE_CLIENT_SECRET: string
RESEND_API_KEY: string
FIRECRAWL_API_KEY: string
CRW_API_KEY: string
CRW_API_URL?: string
AWS_GENERAL_ACCESS_KEY: string
AWS_GENERAL_SECRET_KEY: string
AWS_REGION: string
Expand Down
9 changes: 9 additions & 0 deletions src/lib/crw.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import FirecrawlApp from '@mendable/firecrawl-js'

// fastCRW: Firecrawl-compatible web scraper (single binary; self-host or cloud).
// Reuses the Firecrawl client with a custom base URL. Defaults to the managed
// cloud; set CRW_API_URL to point at a self-hosted server.
export const crw = new FirecrawlApp({
apiKey: process.env.CRW_API_KEY,
apiUrl: process.env.CRW_API_URL ?? 'https://fastcrw.com/api',
})
2 changes: 2 additions & 0 deletions src/server/jstack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ interface Env {
GOOGLE_CLIENT_SECRET: string
RESEND_API_KEY: string
FIRECRAWL_API_KEY: string
CRW_API_KEY: string
CRW_API_URL?: string
AWS_GENERAL_ACCESS_KEY: string
AWS_GENERAL_SECRET_KEY: string
AWS_REGION: string
Expand Down