Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/theatlantic/kruxpy
Kruxpy is a library for dealing with the Krux / Salesforce DMP API
https://github.com/theatlantic/kruxpy
Last synced: 7 days ago
JSON representation
Kruxpy is a library for dealing with the Krux / Salesforce DMP API
- Host: GitHub
- URL: https://github.com/theatlantic/kruxpy
- Owner: theatlantic
- License: mit
- Created: 2018-11-06T20:01:11.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2018-11-06T20:14:00.000Z (about 6 years ago)
- Last Synced: 2024-10-10T16:23:04.120Z (about 1 month ago)
- Language: Python
- Size: 8.79 KB
- Stars: 1
- Watchers: 31
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Kruxpy
[![Build Status](https://secure.travis-ci.org/theatlantic/kruxpy.png?branch=master)](https://travis-ci.org/theatlantic/kruxpy)A python library for working with the [Salesforce DMP API](https://konsole.zendesk.com/hc/en-us/articles/216119137-Salesforce-DMP-API). You will need an API Key - which your Salesforce DMP Solutions Representative will have to provide.
## Installation
```shell
pip install kruxpy
```## Example Usage
```python
from kruxpy.client import Clientc = Client('username', 'password', 'apikey')
# This will return all 1st/3rd party segments
print(c.audiences)# returns a list of sites
print(c.sites)# get a list of segment overlaps for a given segment
print(c.get_audience_distribution('12345'))# get a list of events
print(c.events)
```## Logging
This library uses the standard [Python logging library](https://docs.python.org/3/library/logging.html). To see debut output printed to STDOUT, for instance, use:```python
import logginglog = logging.getLogger('kruxpy')
log.setLevel(logging.DEBUG)
log.addHandler(logging.StreamHandler())
```## Running Tests
To run tests:```
pip install -r dev-requirements.txt
python -m unittest
```