braze-client-2.3.3
توضیحات
Braze Python Client
| ویژگی | مقدار |
|---|---|
| سیستم عامل | - |
| نام فایل | braze-client-2.3.3 |
| نام | braze-client |
| نسخه کتابخانه | 2.3.3 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | - |
| ایمیل نویسنده | mail@dtatarkin.ru |
| آدرس صفحه اصلی | https://github.com/dtatarkin/braze-client |
| آدرس اینترنتی | https://pypi.org/project/braze-client/ |
| مجوز | - |
# braze-client
A Python client for the Braze REST API
[](https://travis-ci.com/dtatarkin/braze-client)
[](https://codecov.io/gh/dtatarkin/braze-client)
### How to install
Make sure you have Python 2.7+ or 3.6+ installed and run:
```
$ git clone https://github.com/dtatarkin/braze-client
$ cd braze-client
$ python setup.py install
```
### How to use
```python
from braze.client import BrazeClient
client = BrazeClient(api_key='YOUR_API_KEY', use_auth_header=True)
r = client.user_track(
attributes=[{
'external_id': '1',
'first_name': 'First name',
'last_name': 'Last name',
'email': 'email@example.com',
'status': 'Active',
# And other fields ...
}],
events=None,
purchases=None,
)
if r['success']:
# do our magic here
print('Success!')
print(r)
else:
print(r['client_error'])
print(r['errors'])
```
For more examples, check `examples.py`.
### How to test
To run the unit tests, make sure you have the [tox](https://tox.readthedocs.io/en/latest/) module installed
and run the following from the repository root directory:
`$ tox`
نیازمندی
| مقدار | نام |
|---|---|
| <3.0.0,>=2.21.0 | requests |
| <6.0.0,>=5.0.0 | tenacity |
| - | tox |
زبان مورد نیاز
| مقدار | نام |
|---|---|
| >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.* | Python |
نحوه نصب
نصب پکیج whl braze-client-2.3.3:
pip install braze-client-2.3.3.whl
نصب پکیج tar.gz braze-client-2.3.3:
pip install braze-client-2.3.3.tar.gz