UReact.me API lib
Project description
# UReact.me Python client
## Usage
```python
from ureactme import Client
from ureactme.models import Metric, User, Event
c = Client("put your token here")
# Get the list of Metrics sent by users:
metrics = c.get_object_list(Metric)
for m in metrics:
print m.id
# Get the list of Users, and print his ID, the data and the auto-collected data
users = c.get_object_list(User)
for u in users:
print u.id, u.data, u.auto_data
# Get the list of events of a certain type sent by the user in a given day
u = User(id="user_id_test")
for e in u.get_events('redbutton_click', '2016-05-18'):
print e.created_at, e.value, e.data
```
## Usage
```python
from ureactme import Client
from ureactme.models import Metric, User, Event
c = Client("put your token here")
# Get the list of Metrics sent by users:
metrics = c.get_object_list(Metric)
for m in metrics:
print m.id
# Get the list of Users, and print his ID, the data and the auto-collected data
users = c.get_object_list(User)
for u in users:
print u.id, u.data, u.auto_data
# Get the list of events of a certain type sent by the user in a given day
u = User(id="user_id_test")
for e in u.get_events('redbutton_click', '2016-05-18'):
print e.created_at, e.value, e.data
```
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
ureactme-0.1.2.tar.gz
(2.7 kB
view hashes)