1.0.0-beta.22 • Published 6 years ago
deriv-api v1.0.0-beta.22
deriv-api
Async Websocket API for deriv.app
Usage
There are two ways to establish a connection:
Use a previously opened connection:
import DerivAPI from 'DerivAPI'; const connection = new WebSocket('ws://...'); const api = new DerivAPI({ connection });Pass the arguments needed to create a connection:
import DerivAPI from 'DerivAPI'; const api = new DerivAPI({ endpoint: 'ws://...', appId: 1003, lang: 'EN' });
For more detailed examples see the wiki See also: DerivAPI reference
Development
npm installTo run the tests
npm testRun tests automatically on source code edits
npm run develRun linter
npm run syntaxRun all tests (lint + js tests)
npm run test_allPrettify the code (done automatically on commit)
npm run prettifyGenerate documentations
npm run docsRegenerate docs automatically on source code edit
Needs inotify to work.
npm run devel_docsServe docs on localhost and update on source code changes
npm run serve_docsGenerate html version of the docs and publish it to gh-pages
npm run gh-pagesBuild the package
npm run buildRun examples
DERIV_TOKEN=YourTokenHere npm run examples1.0.0-beta.22
6 years ago
1.0.0-beta.21-development
6 years ago
1.0.0-beta.21
6 years ago
1.0.0-beta.20
6 years ago
1.0.0-beta.19
6 years ago
1.0.0-beta.18
6 years ago
1.0.0-beta.17
6 years ago
1.0.0-beta.16
6 years ago
1.0.0-beta.15-development
6 years ago
1.0.0-beta.15
6 years ago
1.0.0-beta.14-development
6 years ago
1.0.0-beta.14
6 years ago
1.0.0-beta.13
6 years ago
1.0.0-beta.12
6 years ago
1.0.0-beta.11
6 years ago
1.0.0-beta.10
6 years ago
1.0.0-beta.9
6 years ago
1.0.0-beta.8-development
6 years ago
1.0.0-beta.8
6 years ago
1.0.0-beta.7-large
6 years ago
1.0.0-beta.7
6 years ago
1.0.0-beta.6
6 years ago
1.0.0-beta.4
6 years ago
1.0.0-beta.3
6 years ago
1.0.0-beta.2
6 years ago
1.0.0-beta.1
6 years ago
1.0.0-beta.0
6 years ago
1.0.0-beta
6 years ago