jmfernandes / robin_stocks

This is a library to use with Robinhood Financial App. It currently supports trading crypto-currencies, options, and stocks. In addition, it can be used to get real time ticker information, assess the performance of your portfolio, and can also get tax documents, total dividends paid, and more. More info at
http://www.robin-stocks.com
MIT License
1.73k stars 465 forks source link

Unable to add stocks to Watchlist #140

Open tima7891 opened 4 years ago

tima7891 commented 4 years ago

i'm getting this error message when trying to post stocks into watchlist

r.post_symbols_to_watchlist('KO',name='divid') {'detail': 'Not found.'}

AND FROM

Def request_post res = SESSION.post(url, data=payload, timeout=timeout) print(res)

<Response [404]>

Jroc561 commented 4 years ago

Ive added a ton to the watchlist, I never put anything into the name parameter. Just kept it simple like:

r.post_symbols_to_watchlist('MTCH')

and its worked everytime.

tima7891 commented 4 years ago

But what if I want to post into a specific watchlist? post_symbols_to_watchlist has an option to pick which watchlist you want to post

zhanghy88 commented 4 years ago

r.post_symbols_to_watchlist('MTCH') it doesn't work for me. no response after running this script.

sachinparyani commented 4 years ago

Doesn't work for me either!

mmojz642 commented 4 years ago

I started working with robin_stocks today (8/31/2020) and hit this issue also. A few examples below. I also saw checking for the URL doesn't return the same URL being used in the function definitions. Not sure if this is relevant, maybe not...

r.urls.watchlists('Algo') 'https://api.robinhood.com/midlands/lists/items/'

VS

url = 'https://api.robinhood.com/watchlists/'+name+'/bulk_add/'

Examples:

r.post_symbols_to_watchlist('NWL') [] r.post_symbols_to_watchlist('NWL', 'Algo') {'detail': 'Not found.'}

A related (I'm assuming) issue appears with deleting watchlists too (note: I removed the ID in the URL error message):

r.delete_symbols_from_watchlist('MPC','Algo') Error in request_delete: 404 Client Error: Not Found for url: https://api.robinhood.com/watchlists/Algo/[*ID*]/ [None]

Thanks for all the work on this! I initially wanted to leverage a watchlist for managing a universe of trading stocks, but can manage a list elsewhere also.