Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
12 contributors

Users who have contributed to this file

@jeffdare @Lokesh-K-Haralakatta @durera @sathipal @leo-davison @timjacobi @uwefassnacht @nkolban @hrhrprasath @harrisondkurtz @boneskull @abhisheksoni27
56 lines (38 sloc) 1.59 KB

IBM Watson IoT Platform Javascript SDK

Build Status Coverage Status GitHub issues GitHub

Installation

npm install @wiotp/sdk --save

Note: This package is still in development and is not yet available from NPM, if you want to get started straight away you will need to download the source from this repository.

Usage

Application

import {ApplicationClient, ApplicationConfig} from '@wiotp/sdk';

let appConfig = ApplicationConfig.parseEnvVars();
let appClient = new ApplicationClient(appConfig);
appClient.connect();
// Do stuff
appClient.disconnect();

Device

import {DeviceClient, DeviceConfig} from '@wiotp/sdk';

let deviceConfig = DeviceConfig.parseEnvVars();
let deviceClient = new DeviceClient(deviceConfig);
deviceClient.connect();
// Do stuff
deviceClient.disconnect();

Gateway

import {GatewayClient, GatewayConfig} from '@wiotp/sdk';

let gwConfig = GatewayConfig.parseEnvVars();
let gwClient = new GatewayClient(appConfig);
gwClient.connect();
// Do stuff
gwClient.disconnect();
You can’t perform that action at this time.