PyGIndex - Python library/framework
Project description
PyGIndex
Python library/framework to access and trade on IG Index
Examples
Get session details
from pygindex.client import IGClient
c = IGClient()
s = c.get_session_details()
print(s)
Will produce
{'clientId': 'XXXXXXXXX',
'accountId': 'XXXXX',
'timezoneOffset': 1,
'locale': 'en_GB',
'currency': 'GBP',
'lightstreamerEndpoint': 'https://apd.marketdatasystems.com'}
Get account details
from pygindex.client import IGClient
c = IGClient()
s = c.get_accounts()
print(s)
Will produce
{
"accounts": [
{
"accountAlias": null,
"accountId": "XXXXX",
"accountName": "CFD",
"accountType": "CFD",
"balance": {
"available": 0.0,
"balance": 0.0,
"deposit": 0.0,
"profitLoss": 0.0
},
"canTransferFrom": true,
"canTransferTo": true,
"currency": "GBP",
"preferred": false,
"status": "ENABLED"
},
{
"accountAlias": null,
"accountId": "XXXXX",
"accountName": "Spread bet",
"accountType": "SPREADBET",
"balance": {
"available": 0.0,
"balance": 0.0,
"deposit": 0.0,
"profitLoss": 0.0
},
"canTransferFrom": true,
"canTransferTo": true,
"currency": "GBP",
"preferred": true,
"status": "ENABLED"
}
]
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pygindex-0.0.3.tar.gz
(18.7 kB
view hashes)
Built Distribution
Close
Hashes for pygindex-0.0.3-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 904de7be782fed1c193b0a5a0b42afdddbf012a106b719fc0b9be615298fb278 |
|
MD5 | c13a33a12edf0c7f79b43ba3d209cdac |
|
BLAKE2b-256 | 0c09ee456fd43a7a1fd7702a0f0b9a06687e519b88617a3e147d8703b4bb0698 |