andrewstuart / go-robinhood

A golang library for interacting with the Robinhood private API
Apache License 2.0
68 stars 34 forks source link

How do I use this library / login? #30

Open iseahound opened 2 years ago

iseahound commented 2 years ago

After multiple attempts, I finally figured out that I somehow had the v1 installation instead of the v2 installation, and that the default v2 astuart.co/go-robinhood/v2 isn't up to date with the GitHub.

What is a context in Robinhood.dial?

 not enough arguments in call to robinhood.Dial
        have (*robinhood.OAuth)
        want (context.Context, oauth2.TokenSource)

An updated working example would be appreciated!

manugarg commented 2 years ago

You can use context.Background() as the first argument to robinhood.Dial.