DISCOVER THE FUTURE OF AI AGENTSarrow_forward

Open Mercato

calendar_todayAdded Feb 23, 2026
categoryAgent & Tooling
codeOpen Source
TypeScriptNode.jsWorkflow AutomationNext.jsReactModel Context ProtocolAI AgentsAgent FrameworkWeb ApplicationAgent & ToolingAutomation, Workflow & RPAProtocol, API & IntegrationEnterprise Applications & Office

An AI-ready modular CRM/ERP foundation framework built on TypeScript and Next.js. It offers out-of-the-box multi-tenancy, permissions, workflows, and Headless API capabilities, supports deep customization via overlay overrides, and includes built-in AI Agent (MCP) integration tools.

Project Overview#

Open Mercato is an enterprise-grade CRM and ERP foundation framework with the core philosophy of "Start with 80% done" β€” freeing development teams from repetitive infrastructure work to focus on the remaining 20% of differentiated innovation.

Core Value Proposition#

  • Buy vs. Build Balance: Achieving the optimal balance between out-of-the-box functionality and high customizability
  • Modular & Upgrade-Compatible: Rapid customization through Overlay mechanism without breaking upgrade paths
  • AI-Ready Design: Structured design for assisted workflows, automation, and conversational interfaces

Business Domain Capabilities#

ModuleKey Capabilities
CRMInfinitely flexible customer, opportunity, and workflow modeling with custom data definitions
ERPOrder/production/service delivery management with modular trimming
CommerceCPQ process, B2B procurement portal, complete e-commerce backend
Self-serviceConfigurable forms and guided flows, fine-grained permission customer/partner portals
ProductionCoordinated production management with modular entities and automation hooks
WorkflowsCustom data lifecycle and document workflows (per tenant/team)

Platform & Architecture Capabilities#

  • 🧩 Modular Architecture: Auto-discovery of modules, pages, APIs, entities; Overlay override mechanism
  • 🧬 Custom Entities & Dynamic Forms: Runtime declaration of fields, validators, and UI controls
  • 🏒 Multi-tenant by Default: Default multi-tenancy with strict organization/tenant isolation
  • πŸ›οΈ Multi-hierarchical Organizations: Built-in organization trees, roles, and user visibility controls
  • πŸ›‘οΈ Feature-based RBAC: Role/user-level feature flags combined with organization scope for page/API gating
  • ⚑ Data Indexing & Caching: Hybrid JSONB indexing + intelligent caching
  • πŸ”” Event Subscribers: Domain event publishing and persistent subscription handling (local/Redis)
  • 🌐 Headless/API Platform: Unified extensible data model with richly-typed APIs (mobile/Web)

AI Integration Capabilities#

MCP (Model Context Protocol) Tools#

  • discover_schema - Discover data structures
  • find_api - Search available APIs
  • call_api - Invoke backend interfaces
  • context_whoami - Get current context

Supports development/production integration patterns, enabling AI Agents to understand business logic and execute operations.

Data Encryption#

  • Tenant-level DEK (Data Encryption Key)
  • AES-GCM encryption
  • Automatic encryption/decryption in ORM lifecycle

Technical Architecture#

  • Frontend: Next.js App Router + React + TypeScript (92.7%)
  • Backend ORM: MikroORM + PostgreSQL
  • Dependency Injection: Awilix (request-level DI container)
  • Caching & Events: Redis
  • Search Engine: Meilisearch (full-text/vector search)
  • Authentication: bcryptjs + JWT Session

Project Structure#

apps/
β”œβ”€β”€ mercato/     # Main Next.js application
└── docs/        # Documentation site
packages/        # @open-mercato/<pkg> naming
β”œβ”€β”€ core/        # Core packages
β”œβ”€β”€ shared/      # Shared utilities
β”œβ”€β”€ ui/          # UI components
β”œβ”€β”€ cli/         # CLI tools
β”œβ”€β”€ ai-assistant/# AI assistant
└── enterprise/  # Enterprise edition

Requirements#

  • Node.js: 24.x
  • Yarn: 4+
  • PostgreSQL: Database
  • Redis: Events & caching
  • Meilisearch: Search engine (optional)

Quick Start#

git clone https://github.com/open-mercato/open-mercato.git
cd open-mercato
git checkout develop
yarn install
cp apps/mercato/.env.example apps/mercato/.env
yarn generate
yarn initialize
yarn dev
# Visit http://localhost:3000/backend

Docker Deployment#

# Development mode (hot reload)
docker compose -f docker-compose.fullapp.dev.yml up --build

# Production mode
docker compose -f docker-compose.fullapp.yml up --build -d

API Development Style#

  • Route Convention: api/<method>/<path>.ts
  • Quick CRUD: Use makeCrudRoute to build CRUD APIs
  • Auto Documentation: Export OpenAPI specifications
  • Input Validation: Zod Schema

Related Projects

View All arrow_forward

STAY UPDATED

Get the latest AI tools and trends delivered straight to your inbox. No spam, just intelligence.

rocket_launch