Menu

Explorer & Settings

Tempo Explorer Submit Project
Back to all projects

GrandBazar

by Rivega42 · Updated 2 months ago

AI-powered Virtual Assistants Platform with marketplace integrations (Ozon, Wildberries, Jumia) and Agentic Commerce Protocol support

In the AI payments ecosystem

GrandBazar is an early-stage TypeScript project in the AI payments / x402 ecosystem, focused on acp, agentic-commerce, ai, marketplace. It currently has 0 GitHub stars and 0 forks, and sits alongside related tools like claw-market, npm:acp-handler, ClawRouter, internet-court-skill, bitrouter, os-moda.

README.md View on GitHub →

GrandBazar 🛍️

AI-powered Virtual Assistants Platform with Trading Hub

GrandBazar — платформа для создания и монетизации персонализированных AI-помощников с интеграциями для рынков РФ/СНГ, Африки и других регионов.

✨ Киллер-фича: Trading Hub — Автоматический торг на базе AI. Аукционы, тендеры, авто-торг. AI ведёт переговоры, находит лучшие цены и заключает сделки 24/7.


🚀 Quick Start

Prerequisites

  • Node.js ≥ 22 (see .nvmrc)
  • pnpm ≥ 9 (corepack enable && corepack prepare pnpm@9.15.4 --activate)
  • Docker & Docker Compose (for local infrastructure)

Setup

# 1. Clone the repository
git clone https://github.com/Rivega42/GrandBazar.git
cd GrandBazar

# 2. Install dependencies
pnpm install

# 3. Copy environment variables
cp .env.example .env

# 4. Start local infrastructure (PostgreSQL, Redis, RabbitMQ)
pnpm docker:up

# 5. Generate Prisma client & run migrations
pnpm db:generate
pnpm db:migrate

# 6. Seed the database (optional)
pnpm db:seed

# 7. Start all services in dev mode
pnpm dev

Available Scripts

Command Description
pnpm dev Start all services in development mode
pnpm build Build all packages and services
pnpm lint Run ESLint across all packages
pnpm typecheck TypeScript type checking
pnpm test Run all tests
pnpm format Format code with Prettier
pnpm docker:up Start local infrastructure
pnpm docker:down Stop local infrastructure
pnpm docker:clean Stop and remove all volumes
pnpm db:generate Generate Prisma client
pnpm db:migrate Run database migrations
pnpm db:seed Seed database with sample data
pnpm db:studio Open Prisma Studio GUI

🏗️ Architecture

┌─────────────────────────────────────────────────────────────────────┐
│                            Clients                                   │
│              (Web App 3000, Admin 3001, Telegram Bot, Mobile)       │
└──────────────────────────────┬──────────────────────────────────────┘
                               │
                ┌──────────────▼──────────────┐
                │   API Gateway (:4000)       │
                │   Rate Limiting, Auth, CORS │
                └──┬────────────────┬─────────┘
                   │                │
        ┌──────────▼────────┐  ┌───▼──────────────────────┐
        │  Core Services    │  │  Trading Hub (:4012)     │
        │  ────────────     │  │  • Auctions              │
        │  • Auth (4001)    │  │  • Tenders               │
        │  • Orchest. (4002)│  │  • Auto-trade (AI)       │
        │  • Billing (4003) │  │  • Escrow (4019)         │
        │  • Telegram (4004)│  │  • Reputation (4020)     │
        │  • Assistant (4005)   │  • Negotiations         │
        │  • Marketplace (4006) └────────────────────────┘
        │  • Analytics (4007)
        │  • Family (4008)
        │  • Admin (4009)
        │  • Recommend. (4010)
        │  • ACP Gateway (4011)
        │  • ML (4013)
        │  • WebSocket (4014)
        │  • Notifications (4015)
        │  • Memory (4016)
        │  • Proactive (4017)
        │  • Multimodal (4018)
        │  • Integrations (4021)
        │
        └────────────┬────────────────────┘
                     │
        ┌────────────▼─────────────────┐
        │  Shared Infrastructure        │
        │  ─────────────────────────    │
        │  • PostgreSQL 16 (:5432)      │
        │  • Redis 7 (:6379)            │
        │  • RabbitMQ 3 (:5672)         │
        └───────────────────────────────┘

Monorepo Structure

GrandBazar/
├── packages/ (9 пакетов)
│   ├── shared/          # Shared types, utils, constants
│   ├── database/        # Prisma ORM, schema, migrations
│   ├── ui/              # React UI components
│   ├── skills/          # 12 встроенных навыков
│   ├── acp/             # Advanced Control Panel
│   ├── cache/           # Redis wrapper
│   ├── events/          # Event bus
│   ├── monitoring/      # OpenTelemetry
│   └── websocket-client/# WS client library
│
├── services/ (22 микросервиса)
│   ├── api-gateway/        # Entry point (:4000)
│   ├── auth/               # Auth & OAuth2 (:4001)
│   ├── agent-orchestrator/ # Agent management (:4002)
│   ├── billing/            # Payments (:4003)
│   ├── telegram-bot/       # Telegram integration (:4004)
│   ├── assistant-runtime/  # OpenClaw runtime (:4005)
│   ├── marketplace/        # Skills marketplace (:4006)
│   ├── analytics/          # Telemetry (:4007)
│   ├── family/             # Family scenarios (:4008)
│   ├── admin/              # Admin backend (:4009)
│   ├── recommendations/    # ML recommendations (:4010)
│   ├── acp-gateway/        # Advanced control (:4011)
│   ├── trading/            # Trading Hub (:4012) [NEW]
│   ├── ml/                 # ML service (:4013)
│   ├── websocket/          # Real-time (:4014)
│   ├── notifications/      # Email, SMS, push (:4015)
│   ├── memory/             # Agent memory (:4016)
│   ├── proactive/          # Proactive triggers (:4017)
│   ├── multimodal/         # Vision, video (:4018)
│   ├── escrow/             # Escrow payments (:4019)
│   ├── reputation/         # Ratings (:4020)
│   └── integrations/       # 3rd party APIs (:4021)
│
├── apps/
│   ├── web/             # Next.js frontend (3000)
│   └── admin/           # Admin panel (3001)
│
├── infrastructure/
│   ├── docker/          # Docker Compose (dev, prod, ci)
│   ├── nginx/           # Reverse proxy config
│   ├── k8s/             # Kubernetes (future)
│   └── terraform/       # IaC (future)
│
├── docs/                # 25+ документов
├── __tests__/           # E2E, integration tests
└── .github/workflows/   # CI/CD pipelines

Tech Stack

Layer Technology
Monorepo Turborepo + pnpm workspaces
Language TypeScript (strict mode)
API Services Express.js + OpenClaw SDK
Frontend Next.js 15, React 19
AI/LLM Claude (Haiku, Opus) via OpenClaw
Database PostgreSQL 16 + Prisma ORM
Cache Redis 7
Message Queue RabbitMQ 3
Real-time WebSocket.io
Logging Pino + Winston
Observability OpenTelemetry + Prometheus
CI/CD GitHub Actions
Container Registry GitHub Container Registry (ghcr.io)

📦 Packages (9)

Пакет Назначение Статус
@grandbazar/shared Types, utils, constants
@grandbazar/database Prisma, migrations, seed
@grandbazar/ui React components
@grandbazar/skills 12 встроенных навыков
@grandbazar/acp Advanced Control Panel
@grandbazar/cache Redis wrapper
@grandbazar/events Event bus (RabbitMQ)
@grandbazar/monitoring OpenTelemetry setup
@grandbazar/websocket-client WS client library

🎯 Skills (12)

Навык Порт Статус
💰 Finance в Runtime
📚 Education в Runtime
🏥 Health в Runtime
👩‍⚕️ Women's Health в Runtime
📅 Schedule в Runtime
🛒 Shopping в Runtime
✈️ Travel в Runtime
🎯 Trading в Trading Hub
🏠 Smart Home в Runtime
👨‍👩‍👧‍👦 Family Coordinator в Runtime
💪 Personal Coach в Runtime
📱 Subscription Manager в Runtime

🔧 Development

Service Ports (22 микросервисов + инфраструктура)

Frontend & Backends:

Service Port Статус
Web App 3000
Admin Panel 3001

Core Services:

Service Port Описание
API Gateway 4000 Главный entry point
Auth Service 4001 JWT, OAuth2, сессии
Agent Orchestrator 4002 Управление AI-агентами
Billing 4003 Платежи, подписки
Telegram Bot 4004 Telegram интеграция
Assistant Runtime 4005 Выполнение помощников
Marketplace 4006 Каталог навыков
Analytics 4007 Telemetry, аналитика
Family Service 4008 Семейные сценарии
Admin Panel Backend 4009 Админ API
Recommendations 4010 Персонализация
ACP Gateway 4011 Продвинутый контроль
Trading Hub 4012 Торги, аукционы
ML Service 4013 ML, классификация
WebSocket 4014 Real-time
Notifications 4015 Email, SMS, push
Memory Service 4016 Долговременная память
Proactive Service 4017 Проактивные триггеры
Multimodal Service 4018 Обработка медиа
Escrow Service 4019 Эскроу платежи
Reputation Service 4020 Рейтинги, отзывы
Integrations 4021 Zapier, webhooks

Infrastructure:

Service Port
PostgreSQL 5432
Redis 6379
RabbitMQ 5672
RabbitMQ Management 15672

Working with Packages

# Run command in specific package
pnpm --filter @grandbazar/auth dev

# Add dependency to a service
pnpm --filter @grandbazar/auth add express

# Add workspace dependency
pnpm --filter @grandbazar/auth add @grandbazar/shared --workspace

Database

# Open Prisma Studio
pnpm db:studio

# Create a new migration
pnpm --filter @grandbazar/database prisma migrate dev --name your_migration_name

# Reset database
pnpm --filter @grandbazar/database prisma:reset

🚀 Deployment

CI/CD Pipeline

  • PR: Lint → Typecheck → Test → Build
  • Merge to main: Build Docker images → Push to ghcr.io → Deploy staging
  • Tag/Manual: Build production images → Deploy production

Docker

# Build all service images
docker compose -f infrastructure/docker/docker-compose.prod.yml build

# Deploy with Docker Compose
docker compose -f infrastructure/docker/docker-compose.prod.yml up -d

🤝 Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feat/amazing-feature
  3. Follow conventional commits: feat:, fix:, docs:, chore:
  4. Ensure all checks pass: pnpm lint && pnpm typecheck && pnpm test
  5. Open a Pull Request

Code Style

  • TypeScript strict mode everywhere
  • ESLint + Prettier (auto-formatted on commit)
  • Conventional commits

📖 Documentation

Полная документация доступна в папке docs/:

🗂️ Справочники (Essential)

🚀 Strategia & Monetization

💰 Trading Hub (Киллер-фича)

👨‍👩‍👧‍👦 Product Modules

📊 Analytics & Partnerships


📝 License

Private. All rights reserved.


Built with ❤️ by Roman Gudkov

All ACP projects →