Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

tradingview-websocket

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tradingview-websocket

This Python package provides a simple WebSocket client for connecting to the TradingView WebSocket API. It allows users to subscribe to real-time financial data streams and retrieve historical data.

  • 0.6
  • PyPI
  • Socket score

Maintainers
1

TradingView WebSocket Client

Introduction

This Python package provides a simple WebSocket client for connecting to the TradingView WebSocket API. It allows users to subscribe to real-time financial data streams and retrieve historical data.

Installation

You can install the package via pip:

pip install tradingview_websocket

Usage

from tradingview_websocket import TradingViewWebSocket

Define symbol, timeframe, and number of candles

symbol = "USDEUR"
timeframe = "1D"
candles = 100

Initialize TradingViewWebSocket object

ws = TradingViewWebSocket(symbol, timeframe, candles)
ws.connect()

Run the WebSocket client

ws.run()

Access the result data

result_data = ws.result_data
print(result_data)

License

This project is licensed under the MIT License - see the LICENSE file for details.

Issues

If you encounter any issues or have questions regarding the package, please feel free to open an issue on GitHub.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc