get-enterprise-stats
Retrieve statistics and analytics data from GitHub Enterprise to monitor organizational performance and track key metrics.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get-enterprise-stats"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- server/index.js:392-416 (handler)Inline handler and registration for the 'get-enterprise-stats' MCP tool. Fetches enterprise stats via AdminAPI, returns formatted JSON text or error response.
server.tool("get-enterprise-stats", {}, async () => { try { const stats = await context.admin.getStats(); return { content: [ { type: "text", text: `GitHub Enterprise 통계 정보:\n\n${JSON.stringify(stats, null, 2)}` } ] }; } catch (error) { console.error('엔터프라이즈 통계 조회 오류:', error); return { content: [ { type: "text", text: `엔터프라이즈 통계 조회 중 오류가 발생했습니다: ${error.message}` } ], isError: true }; } }); - api/admin/admin.js:67-69 (helper)The supporting getStats() method in AdminAPI class that makes the GitHub Enterprise Server API request to '/enterprise/stats/all'.
async getStats() { return this.client.get('enterprise/stats/all'); }