Skip to main content

A powerful Python library for scraping real-time market data, indicators, and ideas from TradingView.

Project description

TV Scraper

Python 3.11+ MIT License

A high-performance Python library for extracting real-time financial data, technical indicators, and social insights from TradingView.


✨ Features

📡 Real-Time Streaming

  • 🕯️ Candle + Indicators: Stream live OHLCV candles with built-in or custom Pine indicators via CandleStreamer.
  • ⚡ Real-time Pricing: Persistent WebSocket connection for millisecond-accurate price updates via stream_realtime_price in CandleStreamer.
  • 📊 Analyst Forecasts: Capture analyst price targets, EPS, and revenue estimates for stocks via ForecastStreamer.

📉 Financial & Technical Data

  • 🧩 Technical Analysis: Access RSI, MACD, EMAs, and 100+ other indicators via Technicals.
  • 🏛️ Fundamentals: Comprehensive financial statements, ratios, and balance sheets via Fundamentals.
  • ⛓️ Options Data: Retrieve full option chains, Greeks, IV, and theoretical prices via Options.
  • 📅 Events Calendar: Track Earnings, Dividends, IPOs, and Economic events via Calendar.

🔍 Discovery & Screening

  • 🔎 Screener: Run advanced market scans with custom filters across 50+ countries via Screener.
  • 🏁 Market Movers: Track top gainers, losers, and most active stocks via Market Movers.
  • 🌍 Global Markets: Discover symbols across exchanges and asset classes via Markets.

🤝 Social & Community

  • 💡 Trading Ideas: Scrape community-driven trading setups and technical ideas via Ideas.
  • 🧠 Heads-up (Minds): Access real-time discussions and community posts via Minds.
  • 📰 News Feed: Integrated news stream with granular filters by symbol or region via News.

🚀 Quick Start

from tv_scraper import CandleStreamer

# Initialize the streamer
streamer = CandleStreamer()

# 1. Fetch historical/real-time candles and indicators
result = streamer.get_candles(
    exchange="BINANCE",
    symbol="BTCUSDT",
    timeframe="1m",
    numb_candles=5,
    indicators=[("STD;RSI", "14")]
)

if result["status"] == "success":
    print("Candles:", result["data"]["ohlcv"])

# 2. Or, stream real-time price and indicators continuously
price_stream = streamer.stream_realtime_price(
    exchange="BINANCE",
    symbol="BTCUSDT",
    indicators=[("STD;RSI", "14")]
)

for tick in price_stream:
    print(f"Price: {tick['price']}, RSI: {tick['indicators'].get('STD;RSI', {}).get('0')}")

📚 Documentation

For complete documentation, installation guides, and API references, visit:

📖 Full Documentation

Key Resource Links


🛠️ Development & Contributing

We welcome contributions! Please see our Contributing Guide for details.


📄 License

Licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tv_scraper-1.5.1.tar.gz (829.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tv_scraper-1.5.1-py3-none-any.whl (66.5 kB view details)

Uploaded Python 3

File details

Details for the file tv_scraper-1.5.1.tar.gz.

File metadata

  • Download URL: tv_scraper-1.5.1.tar.gz
  • Upload date:
  • Size: 829.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for tv_scraper-1.5.1.tar.gz
Algorithm Hash digest
SHA256 33b861a273a3d131cce16d7117d76045976431eff9308a96c3562a37c8a2bf64
MD5 e33eb403fd69f7253afeba8e7276b619
BLAKE2b-256 9748554fbd8b83e7714292f662f51f2b0d457a4f324e570219aded9b69ba20e5

See more details on using hashes here.

Provenance

The following attestation bundles were made for tv_scraper-1.5.1.tar.gz:

Publisher: publish.yml on smitkunpara/tv-scraper

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file tv_scraper-1.5.1-py3-none-any.whl.

File metadata

  • Download URL: tv_scraper-1.5.1-py3-none-any.whl
  • Upload date:
  • Size: 66.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for tv_scraper-1.5.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fcc0805f5496fd2c26ed289f9057f32c7360166d968b4f2e40a6403193207f59
MD5 7c9c5913fdacf24841a57bc273afa7e0
BLAKE2b-256 88ee3e6b6eb8ce3bc0943880880de36b856ed9e60a65f7246c1f4af316848160

See more details on using hashes here.

Provenance

The following attestation bundles were made for tv_scraper-1.5.1-py3-none-any.whl:

Publisher: publish.yml on smitkunpara/tv-scraper

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page