https://github.com/asepscareer/ycnbc
Get Real Time News and Market Data From CNBC Using ycnbc !!!
https://github.com/asepscareer/ycnbc
cnbc-api cnbc-market financial-data financial-markets lxml market-data markets news newsapi pandas python scraping-python stock-market
Last synced: 6 months ago
JSON representation
Get Real Time News and Market Data From CNBC Using ycnbc !!!
- Host: GitHub
- URL: https://github.com/asepscareer/ycnbc
- Owner: asepscareer
- License: apache-2.0
- Created: 2022-03-11T17:47:42.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2024-08-27T08:23:03.000Z (about 1 year ago)
- Last Synced: 2025-04-12T18:04:41.015Z (6 months ago)
- Topics: cnbc-api, cnbc-market, financial-data, financial-markets, lxml, market-data, markets, news, newsapi, pandas, python, scraping-python, stock-market
- Language: Python
- Homepage: https://pypi.org/project/ycnbc/
- Size: 45.9 KB
- Stars: 19
- Watchers: 1
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.rst
- Funding: .github/FUNDING.yml
- License: LICENSE.txt
Awesome Lists containing this project
README
# Download news data from CNBC! CNBC's API
#### \*\*\* IMPORTANT LEGAL DISCLAIMER \*\*\*
---
ycnbc is **not** affiliated, endorsed, or vetted by CNBC, It's an open source tool that uses Web Scraping and is intended for research and educational purposes.
---
**ycnbc** offers a threaded and Pythonic way to news and market data from [CNBC](https://www.cnbc.com).
[Changelog »](https://github.com/asepscareer/ycnbc/blob/master/CHANGELOG.rst)
---
## Quick Start
---
### Requirements- Python >=3.5+
- requests>=2.23.0
- lxml>=4.5.1---
### Installation```
$ pip install ycnbc --upgrade --no-cache-dir
```---
### Usage for Markets
```python
import ycnbcmarkets = ycnbc.Markets()
quote_summary = markets.quote_summary('AAPL')
pre_markets = markets.pre_markets()
us_markets = markets.us_markets()
europe_markets = markets.europe_markets()
asia_markets = markets.asia_markets()
currencies = markets.currencies()
cryptocurrencies = markets.cryptocurrencies()
futures_and_commodities = markets.futures_and_commodities()
bonds = markets.bonds()
funds_and_etfs = markets.funds_and_etfs()
```### Usage for news
```python
import ycnbcnews = ycnbc.News()
# Get trending news
trending_ = news.trending()# Get latest news
latest_ = news.latest()# Get news by category
economy_ = news.economy()
jobs_ = news.jobs()
white_house_ = news.white_house()
hospitals_ = news.hospitals()
transportation_ = news.transportation()
media_ = news.media()
internet_ = news.internet()
congress_ = news.congress()
policy_ = news.policy()
finance_ = news.finance()
life_ = news.life()
defense_ = news.defense()
europe_politics_ = news.europe_politics()
china_politics_ = news.china_politics()
asia_politics_ = news.asia_politics()
world_politics_ = news.world_politics()
equity_opportunity_ = news.equity_opportunity()
politics_ = news.politics()
wealth_ = news.wealth()
world_economy_ = news.world_economy()
central_banks_ = news.central_banks()
real_estate_ = news.real_estate()
health_science_ = news.health_science()
small_business_ = news.small_business()
lifehealth_insurance_ = news.lifehealth_insurance()
business_ = news.business()
energy_ = news.energy()
industrials_ = news.industrials()
retail_ = news.retail()
cybersecurity_ = news.cybersecurity()
mobile_ = news.mobile()
technology_ = news.technology()
cnbc_disruptors_ = news.cnbc_disruptors()
tech_guide_ = news.tech_guide()
social_media_ = news.social_media()
climate_ = news.climate()
```Note:
- URL pages containing news content that have the `PRO` tag still cannot be retrieved using this library.
---
### Legal Stuff
**ycnbc** is distributed under the **Apache Software License**. See
the [LICENSE.txt](./LICENSE.txt) file in the release for details.---
### P.S.
Please drop me a note with any feedback you have.
**Asep Saputra**