Click or drag to resize

Nexpaq.APIs Namespace

The Nexpaq.APIs namespace provides the main services (APIs) in the platform core to be consumed by app core and js clients
Classes
  ClassDescription
Public classCloudAPI
API for making http requests to the cloud.
Public classDriverAPI
DriverAPI is responsible for performing operations related to drivers, like installing, deleting, and loading drivers.
Public classGatewayAPI
GatewayAPI is the api responsible for performing operations on gateway, like chargng phone, stop charging phone, and requesting battery status.
Public classMainAPI
Nexpaq API, that provides access to nexpaq cloud and other functions
Public classManifestAPI
ManifestAPI is the service responsible for performing manifests operations like adding/downloading manifests, and check if installed.
Public classModuleAPI
ModuleAPI is responsible for performing module related operations like sending commands to modules and initializing modules.
Public classProductAPI
ProductAPI contains the shared functionalities used by GatewayAPI and ModuleAPI like erasing firmware, installing firmware, etc.
Public classRepositoryAPI
RepositoryAPI is responsible for performing http operations related to repository.
Examples
How to use APIs methods in javascript
Moduware.v0.API.Cloud.{method}({arguments});
Moduware.v0.API.Driver.{method}({arguments});
Moduware.v0.API.Gateway.{method}({arguments});
Moduware.v0.API.MainApi.{method}({arguments});
Moduware.v0.API.Manifest.{method}({arguments});
Moduware.v0.API.Module.{method}({arguments});
Moduware.v0.API.Product.{method}({arguments});
Moduware.v0.API.Repository.{method}({arguments});
Examples
How to use APIs Events in javascript
Moduware.v0.Cloud.addEventListener('eventName', (event) => {
});

Moduware.v0.Driver.addEventListener('eventName', (event) => {
});

Moduware.v0.Gateway.addEventListener('eventName', (event) => {
});

Moduware.v0.MainApi.addEventListener('eventName', (event) => {
});

Moduware.v0.Manifest.addEventListener('eventName', (event) => {
});

Moduware.v0.Module.addEventListener('eventName', (event) => {
});

Moduware.v0.Product.addEventListener('eventName', (event) => {
});

Moduware.v0.Repository.addEventListener('eventName', (event) => {
});