MAGIQ AI
Founding-stage engineering across customer-facing React workflows, internal admin and growth dashboards, email verification tooling, and Elasticsearch contacts discovery.
Role & Team Context
Associate Software Engineer (Founding-Stage Engineering Team · Remote, Singapore) — Joined the early-stage engineering team at MagiQ AI days after core service initialization, working alongside the CTO and fellow engineers across web surfaces, product UX, search APIs, and billing workflows.
Stack
Explore MagiQ AI Deep Dives
Product & UX
Customer-facing SaaS workflows, progressive onboarding, interactive guided tours, admin/verification tooling, and async enrichment UX.
Billing & Credits
Frontend subscription & credit UX, admin support endpoints, and architecture study of Stripe webhooks, idempotency guards & dual pools.
AI Research Scraper
Hybrid static-HTTP and Playwright web extraction pipeline normalizing messy B2B company sites into structured JSON.
How Vishank's primary Next.js/React surfaces connect into Elasticsearch discovery, async enrichment, and team-owned backend services.
Web & Internal Tooling
Landing + Sanity CMS
Country-slug SEO pages, LiveWorkflowCanvas & pricing UI
Next.js 16 Admin Dashboard
Credit support, PropelAuth/PostHog & GA4 Growth Funnel
Onboarding & Discovery UX
FirstSession & GuidedTour
driver.js mock state + 5-stage MagiqJourney shell
Email Verification BFF
Single & bulk CSV verification UI + proxy routes
Search & Async State
Contacts API (ES9)
Domain/slug contacts matching + async enrichment polling
Pre-Action Usage Limits
402/403 UsageLimitModal + WPS circular SVG gauges
Core multi-service orchestration, billing-engine webhooks/pools, and backend enrichment workers are maintained by the CTO and backend team.
Verified public-safe architecture spanning MagiQ AI web, onboarding, admin, search, and team backend services.
Verified frontend-service and company-search-service flow from query filters to 10-second polling and 402/403 quota handling.
Workspace Entry
GuidedTour (driver.js)
Injects temporary dummy records on /today; purges on exit
Prospector + Contacts API
Facet filters + Elasticsearch contacts & company lookup
POST /enrich-company
Fast 10s Timeout Gate
Branches: immediate_data | cached_data | existing | new_job
10s Decision-Makers Poll
useDecisionMakersPoll tracks batch status until completed
Monotonic Usage Feedback
UsageMenu + usageVersion
Translates raw credits into live per-feature remaining counts
402 / 403 Modal Interceptor
Surfaces required credits, reset window & upgrade CTA before waste
Companion standalone Next.js apps: admin-dashboard (user/credit support & GA4 funnel) and email-verification-frontend.
How React prospecting, 10s enrichment polling, driver.js tours, and 402/403 quota dialogs coordinate.
Architecture inspected read-only in billing-engine (built by CTO Nilesh; Vishank contributed billing UI alignment, admin support endpoints & pricing PRD).
Signed Stripe Ingress
Subscription Checkout
Attaches accountUserId, tier, interval & creditsPerPeriod metadata
express.raw + Timing-Safe
Preserves req.rawBody for constructEvent & HMAC verification
4-Layer Idempotency Guard
Processed Event + Atomic Upsert
Webhook lookup + $setOnInsert dedup + deterministic boost:<id> keys
CreditHold 11000 Guard
Unique CreditHold.idempotencyKey prevents double-charge holds
Dual Pool Waterfall
$expr Atomic Deduction
Consumes expiring creditBalance FIRST, addonCreditBalance SECOND
Billing UI + Admin Endpoints
Vishank: billing history/subscription UI, adminController.ts & v3 PRD
Core billing-engine commits are team/CTO-owned; shown strictly to document verified system boundaries.
Dual credit pools and idempotency safeguards (core backend CTO-owned; UI/admin/PRD contributed by Vishank).
Hybrid static HTTP and Playwright rendering architecture per internal system specifications (external repo absent from local workspace).
Lightweight Signal Probe
HTTPX / Status Check
Probes reachability, response headers & framework hydration markers
Static vs. Dynamic Router
Routes static HTML via Scrapy; escalates SPAs to Playwright only when needed
HTML Signal Distillation
BeautifulSoup Reduction
Strips nav/footer chrome; extracts product, pricing & leadership routes
Payload Normalization
Compresses unstructured DOM slices into token-bounded inputs
Schema JSON & Pools
Structured LLM Extraction
Validates typed company profiles with retry on schema mismatch
Bounded Worker Concurrency
Isolates DNS/TLS timeouts & anti-bot walls per domain without batch stall
Repo company-info-scraper is outside this workspace; flow strictly reflects available owner-authored specifications.
Specification-sourced extraction routing for messy company websites into structured schemas.
Primary Ownership
- Internal Next.js + Radix admin dashboard (`admin-dashboard`): user/credit operations, PropelAuth/PostHog migration, and GA4 growth funnel analytics.
- Standalone Next.js email-verification frontend & BFF proxy (`email-verification-frontend`) paired with Python worker stabilization.
- Progressive onboarding (`FirstSessionModal`), interactive `driver.js` walkthroughs (`GuidedTour` with isolated mock state), and 5-stage `MagiqJourney` bar.
- Public marketing platform (`magiqai-landing_page` + Sanity `cms-studio`) and Elasticsearch Contacts Intelligence endpoints (`company-search-service`).
- Python AI research scraper architecture (`01C`) documented in owner-authored system specifications (external/confidential repo not present in this workspace).
Substantial Shared Contributions
- Customer-facing React/TypeScript prospecting workspace, Finder enrichment column drawer UI, My Pipeline, PDF export, and pre-action credit-limit UX (`UsageLimitModal`).
- Company intelligence BFF proxy routes (`company-intel-service`: HubSpot proxy, async ICP onboarding, tour persistence) and multi-service Jest unit-test suites.
- Customer billing/subscription UI alignment, admin support credit endpoints (`billing-engine`), and `PRD-Pricing-and-Billing-Plan_v3.md`.
Team-Owned Infrastructure
- Core Stripe webhook/idempotency/dual-pool `billing-engine` backend, multi-provider enrichment waterfall, FastAPI SMTP engine, and FastMCP server architected and maintained by the CTO and backend teammates.
Attribution boundaries audited directly against repository history and engineering specs.
Product Problem & Workflow
Lean B2B revenue teams spend substantial manual effort identifying target accounts, researching company context, finding decision-makers, and orchestrating personalized outreach.
MagiQ AI connects these stages in a guided workspace—Ideal Customer Profile (ICP) setup, Elasticsearch account & contact filtering, async enrichment polling, guided first-session onboarding, and subscription credit controls.
Public-Safe Scope & Architecture
To respect customer privacy and confidentiality, this case study presents sanitized architectural diagrams and verified contribution boundaries rather than internal production credentials, customer records, or private Cloud Run endpoints.
Explore the three deep dives below: Customer-Facing Product & UX (01A), Billing & Credit Architecture (01B), and AI Research Scraper (01C).