This package contains an isomorphic SDK (runs both in Node.js and in browsers) for Finnhub API client.
- LTS versions of Node.js
- Latest versions of Safari, Chrome, Edge and Firefox.
See the support policy for more details.
Install the FinnhubApi client library for JavaScript with npm
:
npm install @jeanmc/finnhub-sdk
const client = new FinnhubAPI()
client.pipeline.addPolicy({
name: 'add-api-key',
sendRequest(req, next) {
req.headers.set('X-Finnhub-Token', '')
return next(req)
},
})
To use this client library in the browser, first you need to use a bundler. For details on how to do this, please refer to the bundling documentation.