matomo_get_system_info
Retrieve Matomo system information to monitor analytics configurations, user settings, and site details via the Matomo MCP Server API.
Instructions
Lấy thông tin hệ thống Matomo
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:488-502 (handler)The MCP tool handler that checks if connected to Matomo, calls the service method, and returns the formatted text response.private async handleGetSystemInfo() { if (!this.matomoService) { throw new Error('Chưa kết nối đến Matomo. Vui lòng sử dụng matomo_connect trước.'); } const info = await this.matomoService.getSystemInfo(); return { content: [ { type: 'text', text: `Thông tin hệ thống:\n${JSON.stringify(info, null, 2)}`, }, ], }; }
- src/services/matomo-api.ts:187-190 (helper)Service method implementing the core logic by calling Matomo API endpoint 'API.getSystemInfo' via the generic makeRequest helper.async getSystemInfo(): Promise<MatomoSystemInfo> { const response = await this.makeRequest('API.getSystemInfo'); return response; }
- src/index.ts:236-243 (registration)Registration of the tool in the ListTools response, including name, description, and empty input schema.{ name: 'matomo_get_system_info', description: 'Lấy thông tin hệ thống Matomo', inputSchema: { type: 'object', properties: {}, }, },
- src/types/matomo.ts:90-96 (schema)TypeScript interface defining the structure of the Matomo system info response.export interface MatomoSystemInfo { phpVersion: string; matomoVersion: string; databaseVersion: string; serverInfo: string; plugins: MatomoPlugin[]; }