Get market data from Yahoo Finance using Selenium
Requirements:
- Python 3.6 or Python 3.7
- Pip3
- Selenium Python
- Chromium driver binary
- Jupyter Notebook (optional)
Example:
-
USD-IDR
https://api.gabrielkheisa.xyz/stocks/usdidr/
{
"price": "15,735",
"price_change": "+40.0",
"change": "(+0.25%)",
"last_update": "As of 03:24PM GMT. Market open.",
"server_update": "04-11-2022 22:34:34 GMT+7",
"color": "#40ff00",
"symbol": "🟢"
}
Dow Jones Industrial Average SPDR ETF
https://api.gabrielkheisa.xyz/stocks/sp500/
Nasaq Composite
https://api.gabrielkheisa.xyz/stocks/ixic/
BTC-USD
https://api.gabrielkheisa.xyz/stocks/btcusd/
{
"price": "21,188.77",
"price_change": "+869.87",
"change": "(+4.28%)",
"last_update": "As of 02:52PM UTC. Market open.",
"server_update": "04-11-2022 21:54:44 GMT+7",
"color": "#40ff00",
"symbol": "🟢"
}
ETH-USD
https://api.gabrielkheisa.xyz/stocks/ethusd/
Indeks Harga Saham Gabungan
https://api.gabrielkheisa.xyz/stocks/jkse/