0.5.5 • Published 3 years ago

ringcentral-wsg v0.5.5

Weekly downloads
1
License
MIT
Repository
github
Last release
3 years ago

Deprecated

Users should use @rc-ex/ws instead.

RingCentral WSG SDK

Code Style: Google

How does it work?

This SDK is powered by RingCentral Extensible SDK. RingCentral Extensible SDK has lots of extensions which could be combined to do various things. The following two extensions are used:

Instead of using this SDK, it is recommended to use RingCentral Extensible SDK directly.

Installation

yarn add ringcentral-wsg

Then you should be able to import the SDK like this:

import WSG from 'ringcentral-wsg';

Usage

Install RingCentral SDK v4

yarn add @ringcentral/sdk

Initialization

import {SDK} from '@ringcentral/sdk';
import WSG from 'ringcentral-wsg';

const sdk = new SDK({server, clientId, clientSecret});
await sdk.platform().login({username, extension, password});
const wsg = new WSG(sdk, {
  restOverWebSocket: true, // optional, default value: false
  debugMode: false; // optional, default value: false
  autoRecover: true; // optional, default value: true
});
await wsg.init(); // don't forget this!

Subscription

await wsg.subscribe(
  ['/restapi/v1.0/account/~/extension/~/message-store'],
  event => { console.log(event); }
);

For more detail, please check this test case.

Rest API

This WSG SDK is powered by RingCentral Extensible SDK.

You can access the extensible sdk by wsg.rc:

const extInfo = await wsg.rc.restapi().account().extension().get();

For more detail, please check this test case.

0.5.5

3 years ago

0.5.4

4 years ago

0.5.2

4 years ago

0.5.0

4 years ago

0.4.2

4 years ago

0.3.0

4 years ago

0.4.0

4 years ago

0.2.1

4 years ago

0.2.0

4 years ago

0.1.2

6 years ago

0.1.1

6 years ago

0.1.0

6 years ago