Python code works with encryption password required

4 posts / 0 new
Last post
VincentChan
Python code works with encryption password required

Hi,

I am trying to make the Python code from
https://github.com/ig-python/ig-markets-api-python-library work. However, it returned Exception: HTTP status code 400 {"errorCode":"error.public-api.failure.encryptio
n.required"}. From IG Labs, it advises:

A login has been attempted to the login V1 service by a client from the IG Singapore company. They need to use the v2 version as they need to send their passwords encrypyted.

Is there anyone who ever made it work or have sample code for sharing. Thanks a lot

D:\Python\ig-markets-api-python-library-master>python .\sample\stream_ig.py
Traceback (most recent call last):
File ".\sample\stream_ig.py", line 91, in
main()
File ".\sample\stream_ig.py", line 41, in main
ig_session = ig_stream_service.create_session()
File "D:\Python\Python37-32\lib\site-packages\trading_ig-0.0.6-py3.7.egg\tradi
ng_ig\stream.py", line 22, in create_session
File "D:\Python\Python37-32\lib\site-packages\trading_ig-0.0.6-py3.7.egg\tradi
ng_ig\rest.py", line 1069, in create_session
File "D:\Python\Python37-32\lib\site-packages\trading_ig-0.0.6-py3.7.egg\tradi
ng_ig\rest.py", line 221, in _req
File "D:\Python\Python37-32\lib\site-packages\trading_ig-0.0.6-py3.7.egg\tradi
ng_ig\rest.py", line 134, in req
File "D:\Python\Python37-32\lib\site-packages\trading_ig-0.0.6-py3.7.egg\tradi
ng_ig\rest.py", line 84, in _create_first
Exception: HTTP status code 400 {"errorCode":"error.public-api.failure.encryptio
n.required"}

Malcolmcroucher123
Working

Hi,

I have got it streaming off http://push.lightstreamer.com however it logs on to a demo account and does not ask for an api key ? ( I dont think it is correct )

I am also struggling to change the product from itemname 1 to a IG defined product.

Let me know how you getting on.

Best,

MC

Malcolmcroucher123
try this
Malcolmcroucher123
Singapore
Log in or register to post comments