Closed ajiybanesij closed 1 year ago
Sorry for the delayed reply.
Try calling this function before get_account()
get_account_id()
from webull import paper_webull
wb = paper_webull() wb.login('nad......, 'A....') wb.get_trade_token('A.....')
res1=wb.get_account_id() print(res1)
I tried your solution but still I have error. Output is :
Traceback (most recent call last):
File "/home/ubuntu/bot/bot0/utils/webull_papertrade.py", line 182, in
If I look with debug I take this error "AccessToken is expire". I delete did.bin but still continue.
if you output wb.login('nad......, 'A....')
print(wb.login('nad......, 'A....'))
what do you get? If you cannot login correctly, get_account_id wouldnt work as well.
print(wb.login('nad......, 'A....'))
Output: {'success': False, 'code': 'account.version.upgrade', 'msg': 'You are using an outdated version of Webull Desktop. Please update your application by visiting www.webull.com/introduce.'}
I researched this issue https://github.com/tedchou12/webull/issues/353 and I set device_name = "MacOS Chrome" in the login method still I take same error.
print(wb.login('nad......, 'A....',device_name = "MacOS Chrome"))
I was using some paper trade methods for the bot before, but now I am getting the No message available error. Has the Webull url changed?
Sample Method
wb.get_account()
Sample Output
{'timestamp': '2022-12-09T08:40:29.596+0000', 'status': 404, 'error': 'Not Found', 'message': 'No message available', 'path': '/webull-paper-center/api/paper/1/acc/'}
Sample Method:
wb.place_order(stock="AAPL", price=143, quant=1, action="BUY")
Sapmle Output: {
'timestamp': '2022-12-09T08:40:29.657+0000', 'status': 404, 'error': 'Not Found', 'message': 'No message available', 'path': '/webull-paper-center/api/paper/1/acc//orderop/place/913256135'}