Client API wrapper for PredictIt
Project description
PredictIt API Client
PredictIt API Client for Python. Python 3+ required.
Installation
pip install predictit-client
Usage
from predictit_client import Client
Get all markets
market_id = 2721
client = Client()
markets = client.get_all_markets() # -> List[Market]
Get single market
market_id = 2721
client = Client()
market = client.get_market_with_id(market_id) # -> Optional[Market]
Market Fields
market_id: int
name: str
short_name: str
image_url: str
url: str
contracts: List[Contract]
time_stamp: str
status: str
Contract Fields
contract_id: int
date_end: str
image_url: str
name: str
short_name: str
status: str
last_trade_price: float
best_buy_yes_cost: float
best_buy_no_cost: float
best_sell_yes_cost: float
best_sell_no_cost: float
display_order: int
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
predictit-client-0.2.tar.gz
(3.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file predictit-client-0.2.tar.gz.
File metadata
- Download URL: predictit-client-0.2.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f68fbc688a5053876514c2a39d39060db515b3b2ac9d28e0adc1699fe6b6f38c
|
|
| MD5 |
94ba89b98022ecc45cb0a84152d4f4fe
|
|
| BLAKE2b-256 |
a7c679212dd0d14509ba8781a4e1f3adf475305eba97cd8c32f3baa3030b18e7
|
File details
Details for the file predictit_client-0.2-py3-none-any.whl.
File metadata
- Download URL: predictit_client-0.2-py3-none-any.whl
- Upload date:
- Size: 5.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8dda14aec3610b3006875065affc12b125da72e7d515537f7ccdc2737791e7b1
|
|
| MD5 |
e10ed57f6b367bd688237a0c1a870fc4
|
|
| BLAKE2b-256 |
68e9e07ca0adcfeefffc3e54d91e3cb08619a34882cccb41104ae9d2ea5c7bbc
|