Overview

Prev Next

Overview

Purpose

The Command Center provides a unified intent surface for OneCMS.

It allows users to navigate, discover, and execute actions across the entire platform from a single entry point — without needing to know where things live or how to get there.

The system treats searchable data as domain-agnostic indices, not UI elements.

ℹ️ Note
If a domain exists in the platform, it should be reachable through the Command Center without any changes to the core system.

What This Module Is

  • A platform capability, not a feature
  • Adapter-driven and registry-based
  • Decoupled — search, data, execution, and UI are separate layers
  • Designed to scale linearly with data, not with code

New capabilities are added by onboarding data through adapters. The system itself does not change.

What This Module Is Not

The Command Center is not:

  • A UI component library
  • A search engine implementation
  • A routing layer
  • A shortcut or keybinding system

It does not own the search library, render UI, manage keyboard shortcuts, or contain domain-specific business logic.

Public Surface

The public API is defined by index.ts (the barrel export):

// Core
export { commandEngine } from './core/engine';
export { indexer } from './core/indexer';
export { setupCommandCenter } from './core/composer';
export { GROUP_LABELS } from './core/constants';

// Types
export type { CommandResult } from './core/types';

// Command
export { CommandExecutor } from './command/executor';
export { commandRegistry } from './command/registry';

Everything else is private implementation detail.

Module Map

Component File Responsibility
Types core/types.ts All public types: IndexItem, CommandResult, etc.
IndexRegistry core/registry.ts Collects adapter providers, builds unified index
Indexer core/indexer.ts Holds the built index, exposes items to the engine
CommandEngine core/engine.ts Initializes fuzzy search, executes queries, returns results
Composer core/composer.ts Registers all adapters at bootstrap
Constants core/constants.ts UI group labels for result categorization
CommandExecutor command/executor.ts Dispatches navigation or action based on result type
CommandRegistry command/registry.ts Stores and executes registered action handlers
Routes Adapter adapters/routes.adapter.ts Normalizes route config into IndexItem[]
AppCMS Settings Adapter adapters/appcmsSettings.adapter.ts Normalizes AppCMS settings configs into IndexItem[] with deep links
Result Adapter adapters/result.adapter.ts Transforms search library output to CommandResult[]
Index index.ts Barrel export of all public API

Further Reading

  • Core ConceptsIndexItem, adapters, registry, engine, executor
  • Architecture — layered design and data flow
  • Adapters — adapter contract and implementation guide
  • Execution — route vs command dispatch model
  • Extending the System — how to onboard new domains