ninja-api
TypeScript icon, indicating that this package has built-in type declarations

0.0.17 • Public • Published

Ninja RMM API

Contents

Description

Easy to use JavaScript package for fetching data from the Ninja RMM API

Usage

Install the ninja-api package with NPM:

npm install ninja-api

You can then use the API by importing the package, creating a client and calling a function:

import { NinjaClient } from "ninja-api";

const { devices } = new NinjaClient({
  prefix: "eu",
  clientId: "[YOUR_CLIENT_ID]",
  clientSecret: "[YOUR_CLIENT_SECRET]",
  sessionToken: "[YOUR_SESSION_TOKEN]"
});

devices.get(1).then(device => {
  console.log(device)
})

Types

You can use types defined in the API by importing them:

import type { DeviceDetails } from "ninja-api";

const devices: DeviceDetails[] = [];

Documentation

You can find further documentation about authentication and API routes on the official documentation

Requirements

This package has no requirements and can be run on any Node.js server or JavaScript client.

License

The ninja-api script is released under the MIT license.

Versions

Current Tags

VersionDownloads (Last 7 Days)Tag
0.0.1737latest

Version History

VersionDownloads (Last 7 Days)Published
0.0.1737
0.0.162
0.0.157
0.0.141
0.0.131
0.0.120
0.0.110
0.0.100
0.0.90
0.0.80
0.0.70
0.0.60
0.0.50
0.0.40
0.0.31
0.0.21
0.0.11

Package Sidebar

Install

npm i ninja-api

Weekly Downloads

48

Version

0.0.17

License

ISC

Unpacked Size

200 kB

Total Files

10

Last publish

Collaborators

  • niels_krijnen