@roylines/tradingview

1.0.11 • Public • Published

@roylines/tradingview

ci npm version

A node module for accessing trading view technical analysis signals. This allows you to access the numbers underpinning, for example, the BTC to GBP technicals.

Install

npm install @roylines/tradingview

Quick Start

const tradingview = require('@roylines/tradingview');

const signal = await tradingview.get()
console.log('signal', signal)

API

get(opts): Promise

Retrieves a signal from tradingview

Options:

  • ticker: String, the ticker to obtain a signal for. Defaults to COINBASE:BTCGBP.
  • resolution: Integer, the resolution of the technical signal in seconds. Defaults to 1.
  • scanner: String, the scanner to use. Defaults to crypto
  • indicator: String, the indicator to retrieve. Defaults to Recommend.All.

Returns:

  • ticker: String, the ticker used.
  • resolution: Integer, the resolution used.
  • scanner: String, the scanner used.
  • indicator: String, the indicator retrieved.
  • signal: Float, the signal from trading view. This a float between -1 and 1 where -1 represents a strong sell signal, 1 represents a strong buy signal, and 0 represents a neutral view.

Example:

const tradingview = require('@roylines/tradingview')

const {signal} = await tradingview.get({ticker: "COINBASE:BTCGBP", resolution: 5});
console.log('signal received', signal)

License

MIT

/@roylines/tradingview/

    Package Sidebar

    Install

    npm i @roylines/tradingview

    Weekly Downloads

    0

    Version

    1.0.11

    License

    MIT

    Unpacked Size

    5.13 kB

    Total Files

    10

    Last publish

    Collaborators

    • roylines