By the end of this guide you will have a fully functional local instance of TenderCheck AI with the React frontend running on port 3000, the Express/TypeScript backend running on port 3001, and complete AI-powered tender analysis and proposal validation connected to a live Turso database and Gemini 2.5 Flash.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/elecodes/TenderCheck-AI/llms.txt
Use this file to discover all available pages before exploring further.
Prerequisites
Make sure the following are available before you begin:- Node.js LTS 22+ — nodejs.org
- Turso account + CLI — turso.tech (free tier is sufficient)
- Google AI Studio API key — aistudio.google.com
- Git
Setup Steps
Configure Backend Environment
Create a
.env file inside the backend/ directory by copying the example and filling in your credentials:| Variable | Required | Description |
|---|---|---|
PORT | Yes | Port the backend HTTP server listens on (defaults to 3001 if not set) |
NODE_ENV | Yes | Runtime mode — use development locally |
GOOGLE_GENAI_API_KEY | Yes | Primary Gemini API key from Google AI Studio |
GOOGLE_API_KEY | Yes | Standard Google AI key — required by Genkit 1.28.0+ |
TURSO_AUTH_TOKEN | Yes | Auth token from turso db tokens create |
TURSO_DB_URL | Yes | Turso connection URL, e.g. libsql://your-db.turso.io |
JWT_SECRET | Yes | Secret used to sign JWT session tokens |
ALLOWED_ORIGINS | Yes | Comma-separated list of allowed CORS origins |
LANGCHAIN_API_KEY | No | LangSmith API key for AI observability and tracing |
LANGCHAIN_PROJECT | No | LangSmith project name (defaults to TenderCheckAI) |
Initialize the Turso Database
Create a new Turso database and generate an access token using the Turso CLI:Copy the URL and token into your
backend/.env. The database schema (tables for users, tenders, and analyses) initialises automatically the first time the backend starts — no manual migration step is required.Configure Frontend Environment
Create a
.env file inside the frontend/ directory:VITE_API_BASE_URL points the React app at your local backend. VITE_GOOGLE_CLIENT_ID is required only if you want to enable Google Sign-In locally; you can leave it blank to use email/password auth only.Start the Backend
Open a terminal in the The backend starts on port 3001 using
backend/ directory and run:tsx watch for hot-reload. You should see:Start the Frontend
Open a second terminal in the Vite starts the React application on port 3000.
frontend/ directory and run:Try the Application
Open http://localhost:3000 in your browser.
- Click Register and create a new account.
- Log in with your credentials.
- On the dashboard, upload
docs/Testing_docs/Pliego_Tender_IT_Security.pdfas the tender document. - Wait for the AI to extract all requirements — this typically takes 15–30 seconds.
- Once the tender analysis is complete, upload
docs/Testing_docs/Oferta_Offer_IT_Security.pdfas the proposal. - Review the compliance validation report, click any citation badge to inspect the source text, and export a PDF report.
The repository includes two sample documents in
docs/Testing_docs/ for end-to-end testing:Pliego_Tender_IT_Security.pdf— an IT Security public tender document. Use this to test the Tender Analysis flow.Oferta_Offer_IT_Security.pdf— a vendor offer for the same contract. Use this to test the Proposal Validation flow (requires a completed tender analysis first).
Running Tests
TenderCheck AI enforces strict quality gates across unit, integration, and end-to-end layers. Unit tests (Vitest — run frombackend/ or frontend/):