-- Plugin registry table
CREATE TABLE plugin_registry (
  id TEXT PRIMARY KEY,
  name TEXT NOT NULL,
  version TEXT NOT NULL,
  enabled BOOLEAN NOT NULL DEFAULT TRUE,
  config_json TEXT,
  manifest_json TEXT,
  installed_at TEXT NOT NULL,
  updated_at TEXT NOT NULL
);

-- Index for quick lookups
CREATE INDEX idx_plugin_registry_enabled ON plugin_registry (enabled);

CREATE INDEX idx_plugin_registry_name ON plugin_registry (name);
