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

stocksera

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

stocksera

Official Stocksera API

  • 0.1.21
  • PyPI
  • Socket score

Maintainers
1

Stocksera API

Downloads

This is the official API for Stocksera. Visit Stocksera at https://github.com/guanquann/Stocksera. Sign up for free Stocksera API at https://stocksera.pythonanywhere.com/accounts/developers.

Installation

The package can easily be installed in your terminal by entering

pip install stocksera

Import the package

import stocksera

# Sign up for free Stocksera API at https://stocksera.pythonanywhere.com/accounts/developers/
client = stocksera.Client(api_key="YOUR API KEY")

Get data from social media

Get total mentions/ mentions of a stock on wallstreetbets
data = client.wsb_mentions(days=1, ticker="AAPL")
ParamsRequiredDefaultDescription
daysNo1number days ago
tickerNostock symbol
Get total number of puts/calls mentions on wallstreetbets
data = client.wsb_options(days=1)
ParamsRequiredDefaultDescription
daysNo1number days ago
Get subreddit count on Reddit
data = client.subreddit(days=50, ticker="GME")
ParamsRequiredDefaultDescription
daysNo100number days ago
tickerYesGMEstock symbol
data = client.stocktwits(ticker="AAPL")
ParamsRequiredDefaultDescription
tickerNostock symbol
Get SEC fillings of a stock
data = client.sec_fillings(ticker="AAPL", date_from="2022-01-01", date_to="2022-01-31")
ParamsRequiredDefaultDescription
tickerYesAAPLstock symbol
date_fromNoYYYY-MM-DD
date_toNoYYYY-MM-DD
Get news sentiment of a stock
data = client.news_sentiment(ticker="AAPL")
ParamsRequiredDefaultDescription
tickerYesAAPLstock symbol
Get recent insider trading of all tickers/ insider trading of a stock
data = client.insider_trading(limit=500, ticker="AAPL", date_from="2022-01-01", date_to="2022-01-31")
ParamsRequiredDefaultDescription
limitNo500last n records
tickerNoAAPLstock symbol
date_fromNoYYYY-MM-DD
date_toNoYYYY-MM-DD
Get recent insider trading analysis
data = client.latest_insider_trading_summary()
Get stocks with high short volume/ short volume of a stock
data = client.short_volume(ticker="AAPL", date_from="2022-01-01", date_to="2022-01-31")
ParamsRequiredDefaultDescription
tickerNostock symbol
date_fromNoYYYY-MM-DD
date_toNoYYYY-MM-DD
Get stocks with consistently high FTD/ FTD of a stock
data = client.ftd(ticker="AAPL", date_from="2022-01-01", date_to="2022-01-31")
ParamsRequiredDefaultDescription
tickerNostock symbol
date_fromNoYYYY-MM-DD
date_toNoYYYY-MM-DD
Get number of shares available and borrow fees of a stock
data = client.borrowed_shares(ticker="AAPL")
ParamsRequiredDefaultDescription
tickerNoAAPLstock symbol

Get government trades data

Get all senate trades/ trades of a specific person/ trades of a specific ticker
data = client.senate(ticker="AAPL", name="Thomas H Tuberville", date_from="2022-01-01", date_to="2022-01-31")
ParamsRequiredDefaultDescription
tickerNostock symbol
nameNoname of person
date_fromNoYYYY-MM-DD
date_toNoYYYY-MM-DD
Get all house trades/ trades of a specific person/ trades of a specific ticker
data = client.house(ticker="AAPL", name="Nancy Pelosi", state="CA", date_from="2022-01-01", date_to="2022-01-31")
ParamsRequiredDefaultDescription
tickerNostock symbol
nameNoname of person
stateNodistrict code
date_fromNoYYYY-MM-DD
date_toNoYYYY-MM-DD

Get ETF data

Get market indices
data = client.market_summary(market_type="snp500")
ParamsRequiredDefaultDescription
market_typeYessnp500snp500/nasdaq100/dia/wsb

Get economic data

Get reverse repo
data = client.reverse_repo(days=100)
ParamsRequiredDefaultDescription
daysNo100number days ago
Get daily treasury
data = client.daily_treasury(days=100)
ParamsRequiredDefaultDescription
daysNo100number days ago
Get inflation
data = client.inflation()
Get initial jobless claims
data = client.jobless_claims(days=100)
ParamsRequiredDefaultDescription
daysNo100number days ago
Get retail sales
data = client.retail_sales(days=100)
ParamsRequiredDefaultDescription
daysNo100number days ago
Get recent market news
data = client.market_news()
Get trading halts
data = client.trading_halts()

Get other interesting data

Get Jim Cramer trades
data = client.jim_cramer(ticker="AAPL", segment="featured", call="buy")
ParamsRequiredDefaultDescription
tickerNoallstock symbol
segmentNoallfeatured/discussed/lightning/guest
callNoallbuy/positive/hold/negative/sell
Get stocks with high short interest
data = client.short_interest()
Get stocks with low float
data = client.low_float()
Get upcoming and past IPOs
data = client.ipo_calendar()
Get earnings calendar of stocks
data = client.earnings_calendar(date_from="2022-01-01", date_to="2022-01-31")
ParamsRequiredDefaultDescription
date_fromNoYYYY-MM-DD
date_toNoYYYY-MM-DD

Keywords

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