Skip to content

Platform Overview ​

ApeAdmin is a decoupled admin framework: the backend is built on FastAPI with SQLAlchemy 2.0 async sessions, and the frontend uses Vue 3, TypeScript, Vite and Element Plus. Business capabilities are extended via plugins; the core only handles common authentication, permissions, menus, logging, data access and AI capabilities.

What It Solves ​

  • Unified users, roles, menus and API permissions to support admin business scenarios.
  • Plugin packages isolate business code with runtime enable/disable and resource cleanup.
  • MCP exposes authorizable admin capabilities to AI agents.
  • Unified error responses, request tracing and operation logs reduce troubleshooting cost.

Runtime Boundary ​

text
Browser
  ├─ Vue Admin Panel (/)
  └─ Apehub_web Website (/apehub-web)
          │
          └─ FastAPI (/api/v1)
               ├─ Core APIs: auth / user / role / menu / dept / plugin
               ├─ MCP: tools / resources / prompts / audit-logs
               └─ Plugin APIs: mounted by the plugin itself

Apehub_web is a regular ApeAdmin plugin: it provides the website, marketplace, developer center and site admin APIs, but does not change the core routing rules. When enabled it mounts /api/v1/apehub-web and /apehub-web; when disabled the plugin manager removes its runtime resources and hides its menus.

Directory Map ​

DirectoryResponsibility
backend/src/apiCore HTTP routes
backend/src/coreConfig, security, dependency injection, middleware, seed data
backend/src/dbAsync engine, sessions and database initialization
backend/src/modelsCore ORM models
backend/src/crudGeneric CRUD and RBAC data operations
backend/src/pluginsPlugin interface, discovery, install, hot toggling and resource tracking
backend/src/mcpMCP tools, resources, prompts and auditing
backend/src/aiMulti-model chat and tool-calling loops
frontend/src/routerStatic routes, dynamic menu routes and permission guards
frontend/src/viewsVue pages; paths must match the menu component

Key Principles ​

  1. Core capabilities live in backend/src; business capabilities live in plugin directories.
  2. Plugin menus, APIs, tables and static assets must use their own namespaces.
  3. Page permissions only improve the frontend experience; backend APIs must re-check permissions.
  4. Production uses migration scripts; init_db() is for first-time development startup only.

ApeHub Plugin Ecosystem