npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

tvdatafeedclient-js

v3.0.2

Published

What could Be! Lightweight TradingView Websocket SDK for retrieving candle data

Readme

TradingView Data Feed JS

A lighweight websocket client for accessing tradingView candlestick data via Node.js. Inspired by tvdatafeed for python - But made for JavaScript Devs, crypto traders and bot builders. This is just what could be.


What This Project Solves

I build a lot of bots and tools that rely on TradingView data, and honestly, it's always been a pain. Every time I needed that data, I had to switch over to Python just to use tvdatafeed. It felt like a long detour for something that should've been simple — especially since most of my projects are in JavaScript or Node.js.

There wasn’t a solid npm package (at least not that I could find) that gave me what I needed. That always forced me to either rewrite parts of my project in Python or come up with ugly workarounds.

The day I finally used this package to fetch TradingView data directly from Node.js, it just clicked. I felt at peace. No hacks, no switching languages — just clean JavaScript doing what I needed it to do.


Features

  • Retrieve historical candles (open, high, low, close and volume)
  • Binance, Bybit, Mexc and others
  • No TradingView Account Needed
  • Clean Promise-based API

Features in Pipline

  • Add TradingView account to unlock private access and remove unauthorized user limits
  • cache user JWT to avoid repeated script login.
  • Convert package to type script || Achieved
  • live data access
  • more

Installation

npm install tvdatafeedclient-js

js const { TvDataFeed } = require("tvdatafeedclient-js")

js import { TvDataFeed } from "tvdatafeedclient-js";


Contribution

This package is open to contributions and suggestions.

Check out the Features in Pipeline section — there are lots of ways this project can be improved for better usability and more powerful data access. If you’re interested in fixing bugs, adding new features, or just making things cleaner, you’re more than welcome to jump in.

Before contributing, please keep the following in mind:

  • Keep your pull requests focused — smaller PRs are easier to review and merge.

  • Always test your changes before opening a PR.

  • Don’t push directly to main.

  • If you’re introducing a new feature or a breaking change, open an issue first so we can discuss it.

Let’s build something better together.


Change Log

2.0.0 - 2025-08-21

  • Migrated project to TypeScript.
  • Changed module format from commonJS to ES Modules.
  • Breaking Change: You now need to destructure imports: js const { TradingViewClient } = require("tvdatafeedclient-js")

js import { TradingViewClient } from "tvdatafeedclient-js";

  • Project is properly typed and better DX.

3.0.0 - 2025-09-05

Changed

  • Rename class export to TvDataFeed
  • Make connect method Optional
  • getCandle() method now call connect before fetching candle.
  • Added disconnect() public method
  • Breaking Change: You now need to destructure imports: js const { TvDataFeed } = require("tvdatafeedclient-js")

js import { TvDataFeed } from "tvdatafeedclient-js";

  • More improvements

3.0.2 - 2025-12-05

Changed

  • Added Error Message
  • Return Error object wgen symbol does not exist or match the exchange
  • getCandle() method now call connect before fetching candle.
  • Other Bug fix

Stack

Node.js V22^