Package Exports
- @barchart/marketdata-api-js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@barchart/marketdata-api-js) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
@barchart/marketdata-api-js
JavaScript library for accessing streaming market data from Barchart
Include streaming market data in your applications. Asset classes include equities, futures, and forex.
All you need is a username/password from Barchart and your app can be live within a matter of minutes. To obtain your credentials, please contact solutions@barchart.com.
Supported Environments
- Browsers - Your target browser must support WebSockets (which all modern Browsers do). Also, the source code is written using ES6, so transpilation (with appropriate polyfills) is recommended before distribution.
- Node.js - Node.js does not natively support WebSockets. Instead, a third-party library called WS is responsible for maintaining the WebSocket connection to Barchart's servers.
Examples
Browser
Open the following file in your browser:
./example/browser/example.htmlOr, visit the hosted page at:
Node.js
Ensure you're running a recent version of Node.js (e.g. v10.16.0) and execute the example script as follows:
> node example/node/example.js {host} {username} {password} {comma-delimited symbol list}Documentation
Wiki
Read the Wiki for full documentation
Code
JSDoc is used to document the source code. HTML documentation can be generated (into a "docs" folder), as follows:
> gulp document