Crawling Robinhood APIΒΆ

Hats off to the team at Robinhood their REST API is well formed. pyRobinhood uses the REST API architecture online to crawl and gather data directly by route.

Just walk the API node-by-node. Crawler is provided as a layer to access raw Robinhood data. Filtering and subsetting will be done by TODO

import pyrobinhood.crawler as crawler

root = crawler.Endpoint(
    username='MYACCOUNT',
    password='MYPASSWORD',
)

# List all companies in Robinhood tracking
company_fundamentals = []
for page in root.fundamentals
    company_fundamentals.extend(page.results)


# List all stocks I hold
my_stocks = []
for page in root.account.positions:
    my_stocks.extend(page.results)