Blog
Languageenid

Straight Deal - Car Selling Workflow

Backend Infrastructure by Odama

Production
Straight Deal Cover
Straight Deal 0Straight Deal 1Straight Deal 2Straight Deal 3Straight Deal 4Straight Deal 5Straight Deal 6Straight Deal 7
1,400+
Registered Users
72
API Endpoints
Live
Production Status

Project Access

Visit Website
GitHub Repository

*Code details are confidential and not publicly shared due to client and security restrictions.

About The Platform

Straight Deal is a production-grade car-selling platform built to make vehicle transactions fast, secure, and transparent. As the Full Backend Engineer for this project, I worked directly with the client to translate complex business requirements into a robust infrastructure. The platform handles everything from vehicle data submission and automated valuation to a two-way negotiation flow between users and administrators.

Engineering Excellence: Backend Architecture

Express.js Backend

Monolith architecture with a clean Layered Structure (Controller - Service - Repository). Robustly handles 72 API endpoints with full TypeScript type safety.

Automated Cron Jobs

Scheduled workers manage automated follow-up emails, track offer expirations, and trigger system-wide notifications for both users and admins.

Bidding Workflow

User Submits Car Detail
Admin Reviews & Sends Offer
Accept -> Deal Closed
Decline -> User Counter-Offer
Admin Final Decision (Accept/Reject)

Features

Bidding & Negotiation

A sophisticated two-way negotiation flow between users and admins with price locking.

Automated Follow-up

7-stage automated pipeline managing emails, calls, and texts based on user activity.

Identity Verification

Integration with Persona for automated KYC and ID verification of car owners.

Advanced Car Valuation

Calculates prices based on VIN, mileage, accident history, and 20+ condition markers.

Multi-View Media System

Structured car image upload pipeline for front, rear, and interior condition verification.

Admin Internal Notes

Collaborative notes system for administrators to track submission progress and internal flags.

Role-Based Access (RBAC)

Strict permission isolation between Users, Admins, and Visitors.

OTP & Secure Auth

Hybrid authentication system with Google OAuth2 and secure Twilio SMS OTP.

Challenges

The primary challenge was managing shifting requirements in a live production environment. Working directly with a client without a technical PM meant I had to handle technical translations and implement rapid schema changes while maintaining data integrity for 1,400+ users. I solved this by implementing a rigorous Prisma migration strategy and a layered backend architecture that allowed for modular changes without breaking existing flows. Additionally, optimizing database connections for serverless deployment on Vercel required careful connection pooling management to handle concurrent traffic spikes during bidding sessions.

Technology Stack

Backend
  • Express.js
  • TypeScript
  • Prisma ORM
  • Layered Architecture
Auth & Comms
  • JWT / Google OAuth2
  • Twilio SMS (OTP)
  • SendGrid Email
  • Persona (KYC)
Infrastructure
  • Supabase (PostgreSQL)
  • Vercel Serverless
  • Cron Jobs
  • Nginx & Docker

Key Stack

Express.js, TypeScript, Prisma ORM, Supabase PostgreSQL, JWT, Google OAuth2, Twilio, SendGrid, Vercel, Docker.