NinjaOne icon

NinjaOne

Consume NinjaOne API

Actions158

System → Get Users

AI-generated

Overview

This node interacts with the NinjaOne API to retrieve user information filtered by user type. Specifically, the "Get Users" operation under the "System" resource fetches a list of users based on their role within the system, such as technicians or end users. This is useful in scenarios where you need to automate workflows involving user management, reporting, or integration with other systems that require user data from NinjaOne.

For example, you might use this node to:

  • Automatically generate reports listing all technicians currently registered.
  • Sync user roles and details with an external HR or ticketing system.
  • Filter users by type to trigger specific automation workflows depending on whether they are technicians or end users.

Properties

Name Meaning
User Type Filter users by type. Options: TECHNICIAN, END USER
Include Roles Boolean flag to include detailed user role information in the response (true/false)

Output

The node outputs JSON data containing the list of users matching the specified filters. The structure typically includes user details such as names, IDs, and optionally their roles if "Include Roles" is set to true.

Example output JSON structure (simplified):

[
  {
    "json": {
      "users": [
        {
          "id": "123",
          "name": "John Doe",
          "type": "TECHNICIAN",
          "roles": ["Admin", "Support"] // Present only if Include Roles = true
        },
        ...
      ]
    }
  }
]

No binary data output is produced by this operation.

Dependencies

  • Requires an active NinjaOne API OAuth2 credential configured in n8n for authentication.
  • The node uses NinjaOne's REST API endpoints to fetch user data.
  • No additional environment variables are required beyond the API credentials.

Troubleshooting

  • Common issues:

    • Authentication failures due to invalid or expired API tokens.
    • Empty results if the user type filter does not match any users.
    • Errors if the API service is unreachable or returns unexpected responses.
  • Error messages:

    • "No binary data exists on item!" or similar will not occur here since this operation does not handle binary data.
    • API errors returned from NinjaOne will be surfaced; ensure your credentials have sufficient permissions.
  • Resolutions:

    • Verify and refresh the NinjaOne API credentials in n8n.
    • Confirm the user type filter matches existing user categories.
    • Check network connectivity and NinjaOne API status.

Links and References

Discussion