ninja_get_device_volumes
Retrieve disk volume details for any device, including capacity, free space, and filesystem type, to monitor storage usage.
Instructions
Get disk volume information for a device (capacity, free space, filesystem type).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Device ID |
Implementation Reference
- src/tools/index.ts:13-22 (registration)The tools array is exported/registered from index.ts - includes all deviceTools.
export const ALL_TOOLS = [ ...deviceTools, ...organizationTools, ...alertTools, ...activityTools, ...ticketingTools, ...queryTools, ...policyTools, ...userTools, ...backupTools, - src/tools/devices.ts:206-219 (handler)The full tool definition for 'ninja_get_device_volumes': name, description, inputSchema (requires id), and handler that calls GET /device/{id}/volumes.
{ tool: { name: 'ninja_get_device_volumes', description: 'Get disk volume information for a device (capacity, free space, filesystem type).', inputSchema: { type: 'object', required: ['id'], properties: { id: { type: 'number', description: 'Device ID' }, }, }, }, handler: async ({ id }, client: NinjaOneClient) => client.get(`/device/${id}/volumes`), }, - src/tools/devices.ts:210-216 (schema)Input schema for the tool: requires 'id' (number) as the only parameter.
inputSchema: { type: 'object', required: ['id'], properties: { id: { type: 'number', description: 'Device ID' }, }, }, - src/tools/types.ts:4-8 (helper)ToolDef interface definition that models the structure of a tool (tool + handler).
export interface ToolDef { tool: Tool; // eslint-disable-next-line @typescript-eslint/no-explicit-any handler: (args: any, client: NinjaOneClient) => Promise<unknown>; }