Finnhub-Stock-API / Finnhub Python
Licence: apache-2.0
Finnhub Python API Client. Finnhub API provides institutional-grade financial data to investors, fintech startups and investment firms. We support real-time stock price, global fundamentals and alternative data. https://finnhub.io/docs/api
Stars: ✭ 161
Programming Languages
python
139335 projects - #7 most used programming language
Projects that are alternatives of or similar to Finnhub Python
Bmw Tensorflow Inference Api Cpu
This is a repository for an object detection inference API using the Tensorflow framework.
Stars: ✭ 158 (-1.86%)
Mutual labels: api
Powerwall2
Tesla Powerwall 2 - Local Gateway API documentation
Stars: ✭ 157 (-2.48%)
Mutual labels: api
Pop
Monorepo of the PoP project, including: a server-side component model in PHP, a GraphQL server, a GraphQL API plugin for WordPress, and a website builder
Stars: ✭ 160 (-0.62%)
Mutual labels: api
Jmapper Core
Elegance, high performance and robustness all in one java bean mapper
Stars: ✭ 159 (-1.24%)
Mutual labels: api
Brain.js
brain.js is a GPU accelerated library for Neural Networks written in JavaScript.
Stars: ✭ 12,358 (+7575.78%)
Mutual labels: api
Raml Server
run a mocked server JUST based on a RAML API's definition .. zero coding
Stars: ✭ 158 (-1.86%)
Mutual labels: api
Nanny
Nanny is a monitoring tool that monitors the absence of activity.
Stars: ✭ 157 (-2.48%)
Mutual labels: api
Pttdata
Open Source, contain more than 8 million PTT Data. 提供超過 800 萬筆 PTT 文章,每天更新
Stars: ✭ 160 (-0.62%)
Mutual labels: api
Countries
🌎 Public GraphQL API for information about countries
Stars: ✭ 156 (-3.11%)
Mutual labels: api
Sampleapis
This repository is a playground for API's. These are just a collection of items that you can utilize for learning purposes.
Stars: ✭ 157 (-2.48%)
Mutual labels: api
finnhub-python
- API documentation: https://finnhub.io/docs/api
- API version: 1.0.0
- Package version: 2.3.0
Installation
Install package
pip install finnhub-python
Getting Started
Refer to CHANGELOG If you are coming from version 1
import finnhub
# Setup client
finnhub_client = finnhub.Client(api_key="YOUR API KEY")
# Stock candles
res = finnhub_client.stock_candles('AAPL', 'D', 1590988249, 1591852249)
print(res)
#Convert to Pandas Dataframe
import pandas as pd
print(pd.DataFrame(res))
# Aggregate Indicators
print(finnhub_client.aggregate_indicator('AAPL', 'D'))
# Basic financials
print(finnhub_client.company_basic_financials('AAPL', 'margin'))
# Earnings surprises
print(finnhub_client.company_earnings('TSLA', limit=5))
# EPS estimates
print(finnhub_client.company_eps_estimates('AMZN', freq='quarterly'))
# Company Executives
print(finnhub_client.company_executive('AAPL'))
# Company News
# Need to use _from instead of from to avoid conflict
print(finnhub_client.company_news('AAPL', _from="2020-06-01", to="2020-06-10"))
# Company Peers
print(finnhub_client.company_peers('AAPL'))
# Company Profile
print(finnhub_client.company_profile(symbol='AAPL'))
print(finnhub_client.company_profile(isin='US0378331005'))
print(finnhub_client.company_profile(cusip='037833100'))
# Company Profile 2
print(finnhub_client.company_profile2(symbol='AAPL'))
# Revenue Estimates
print(finnhub_client.company_revenue_estimates('TSLA', freq='quarterly'))
# List country
print(finnhub_client.country())
# Crypto Exchange
print(finnhub_client.crypto_exchanges())
# Crypto symbols
print(finnhub_client.crypto_symbols('BINANCE'))
# Economic data
print(finnhub_client.economic_data('MA-USA-656880'))
# Filings
print(finnhub_client.filings(symbol='AAPL', _from="2020-01-01", to="2020-06-11"))
# Financials
print(finnhub_client.financials('AAPL', 'bs', 'annual'))
# Financials as reported
print(finnhub_client.financials_reported(symbol='AAPL', freq='annual'))
# Forex exchanges
print(finnhub_client.forex_exchanges())
# Forex all pairs
print(finnhub_client.forex_rates(base='USD'))
# Forex symbols
print(finnhub_client.forex_symbols('OANDA'))
# Fund Ownership
print(finnhub_client.fund_ownership('AMZN', limit=5))
# General news
print(finnhub_client.general_news('forex', min_id=0))
# Investors ownership
print(finnhub_client.ownership('AAPL', limit=5))
# IPO calendar
print(finnhub_client.ipo_calendar(_from="2020-05-01", to="2020-06-01"))
# Major developments
print(finnhub_client.press_releases('AAPL', _from="2020-01-01", to="2020-12-31"))
# News sentiment
print(finnhub_client.news_sentiment('AAPL'))
# Pattern recognition
print(finnhub_client.pattern_recognition('AAPL', 'D'))
# Price target
print(finnhub_client.price_target('AAPL'))
# Quote
print(finnhub_client.quote('AAPL'))
# Recommendation trends
print(finnhub_client.recommendation_trends('AAPL'))
# Stock dividends
print(finnhub_client.stock_dividends('KO', _from='2019-01-01', to='2020-01-01'))
# Stock symbols
print(finnhub_client.stock_symbols('US')[0:5])
# Transcripts
print(finnhub_client.transcripts('AAPL_162777'))
# Transcripts list
print(finnhub_client.transcripts_list('AAPL'))
# Earnings Calendar
print(finnhub_client.earnings_calendar(_from="2020-06-10", to="2020-06-30", symbol="", international=False))
# Covid-19
print(finnhub_client.covid19())
# Upgrade downgrade
print(finnhub_client.upgrade_downgrade(symbol='AAPL', _from='2020-01-01', to='2020-06-30'))
# Economic code
print(finnhub_client.economic_code()[0:5])
# Support resistance
print(finnhub_client.support_resistance('AAPL', 'D'))
# Technical Indicator
print(finnhub_client.technical_indicator(symbol="AAPL", resolution='D', _from=1583098857, to=1584308457, indicator='rsi', indicator_fields={"timeperiod": 3}))
# Stock splits
print(finnhub_client.stock_splits('AAPL', _from='2000-01-01', to='2020-01-01'))
# Forex candles
print(finnhub_client.forex_candles('OANDA:EUR_USD', 'D', 1590988249, 1591852249))
# Crypto Candles
print(finnhub_client.crypto_candles('BINANCE:BTCUSDT', 'D', 1590988249, 1591852249))
# Tick Data
print(finnhub_client.stock_tick('AAPL', '2020-03-25', 500, 0))
# Indices Constituents
print(finnhub_client.indices_const(symbol = "^GSPC"))
# Indices Historical Constituents
print(finnhub_client.indices_hist_const(symbol = "^GSPC"))
# ETFs Profile
print(finnhub_client.etfs_profile('SPY'))
# ETFs Holdings
print(finnhub_client.etfs_holdings('SPY'))
# ETFs Industry Exposure
print(finnhub_client.etfs_ind_exp('SPY'))
# ETFs Country Exposure
print(finnhub_client.etfs_country_exp('SPY'))
# International Filings
print(finnhub_client.international_filings('RY.TO'))
print(finnhub_client.international_filings(country='GB'))
# SEC Sentiment Analysis
print(finnhub_client.sec_sentiment_analysis('0000320193-20-000052'))
# SEC similarity index
print(finnhub_client.sec_similarity_index('AAPL'))
# Bid Ask
print(finnhub_client.last_bid_ask('AAPL'))
# FDA Calendar
print(finnhub_client.fda_calendar())
# Symbol lookup
print(finnhub_client.symbol_lookup('apple'))
License
Apache License
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].