get_logs
Retrieve recent system logs from VergeOS virtualization platforms to monitor operations, troubleshoot issues, and track cluster activities.
Instructions
Get recent system logs
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Number of log entries to retrieve (default 50) |
Implementation Reference
- src/index.js:217-219 (handler)Core handler function in VergeOSAPI class that fetches the most recent system logs from the /api/v4/logs endpoint, applying the specified limit and sorting by newest first.async getLogs(limit = 50) { return this.request(`/api/v4/logs?limit=${limit}&sort=-created`); }
- src/index.js:502-513 (registration)Tool registration definition in the TOOLS array, including name, description, and input schema. Used by listTools handler.{ name: "get_logs", description: "Get recent system logs", inputSchema: { type: "object", properties: { limit: { type: "number", description: "Number of log entries to retrieve (default 50)", }, }, },
- src/index.js:606-608 (handler)Dispatch handler in the CallToolRequestSchema handler that invokes the get_logs tool logic via api.getLogs.case "get_logs": result = await api.getLogs(args?.limit || 50); break;