NinjaOne icon

NinjaOne

Consume NinjaOne API

Actions158

Queries → Get Operating Systems

AI-generated

Overview

This node interacts with the NinjaOne API to retrieve information about operating systems via a query operation. Specifically, the "Get Operating Systems" operation under the "Queries" resource allows users to fetch paginated lists of operating system data filtered by device, timestamp, and cursor position. This is useful for IT administrators or automation workflows that need to monitor or report on the operating systems present in their managed environment.

Practical examples include:

  • Fetching all operating systems currently reported by devices.
  • Filtering operating systems by a specific device identifier.
  • Paginating through large sets of operating system records using cursors and page size limits.
  • Retrieving operating system data as of a particular monitoring timestamp.

Properties

Name Meaning
Df Device filter: Filter results by a specific device identifier (string).
Ts Monitoring timestamp filter: Filter results based on a specific monitoring timestamp (string).
Cursor Cursor name: Used for pagination to specify the starting point for the next set of results (string).
Page Size Limit number of records per page: Controls how many operating system records are returned per request (number).

Output

The node outputs JSON data representing the response from the NinjaOne API for the requested operating systems query. The structure typically includes an array of operating system records along with pagination metadata such as cursors if applicable.

If binary data were involved, it would be summarized here; however, this operation deals only with JSON data.

Dependencies

  • Requires an active connection to the NinjaOne API authenticated via an OAuth2 API key credential.
  • The node uses the NinjaOne API endpoints under /v2/queries or similar paths (inferred from context).
  • No additional external dependencies beyond the NinjaOne API and n8n's HTTP request helper.

Troubleshooting

  • Common issues:

    • Missing or invalid API credentials will cause authentication failures.
    • Providing invalid filter values (e.g., malformed timestamps or unknown device IDs) may result in empty responses or API errors.
    • Pagination parameters like cursor and page size must be used correctly to avoid missing data or infinite loops.
  • Error messages:

    • Errors from the NinjaOne API will be returned in the JSON output under an error field if "Continue On Fail" is enabled.
    • If binary data is expected but missing (not relevant here), the node throws an error indicating missing binary data.
    • Network or authentication errors will throw exceptions stopping execution unless "Continue On Fail" is enabled.

Links and References


Note: The summary is based solely on static analysis of the provided source code and property definitions without runtime behavior inference.

Discussion