Python API Wrapper for the CallHub API
Project description
CallHub Python Wrapper
CallHub API Client Wrapper for Python
Creates a clean(er) python interface to several important functions of the CallHub API.
Features
- Built-in (optional) ratelimiting that respects CallHub's varying rate limits for different functions
- Better error handling for uploading contacts with fields that don't exist in CallHub
- Abstracted away some tedious parts of using CallHub's API. When uploading contacts, CallHub wants you to map CSV columns to the ids of each field in CallHub, which is difficult and easy to mess up. This wrapper handles all of that by matching on field names.
- Automatically handles paging when doing bulk fetching
- Uses async requests to improve speed for repetitive calls (implemented in get_contacts)
Currently implemented
- Bulk create contacts
- Get agent leaderboard
- Get all fields and IDs (including custom fields)
- Bulk get contacts and fields
- Create single contact
Currently on roadmap
- Create phonebook
- Add/delete/get contacts to/from DNC list
- Create/get/delete webhook
- Create/get teams
- Add/delete agent to/from team
- Create/delete agent
Usage
callhub = CallHub(api_key="123456789ABCDEF")
phonebook_id = 6545324
contacts = [{'first name': 'Sumiya', 'phone number':'5555555555', 'mobile number': '5555555555'},
{'first name': 'Joe', 'phone number':'5555555555', 'mobile number':'5555555555'}]
country_iso = "CA"
# Create multiple contacts
callhub.bulk_create(phonebook_id, contacts, country_iso)
# Create single contact
callhub.create_contact(contacts[0])
# Get all contacts (up to a user-specified limit)
callhub.get_contacts(1000000)
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
Built Distribution
Close
Hashes for callhub-python-wrapper-0.1.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | c7b870765c5f01f6e0fd93ae687e928e6f79a24df67895890ec60ef05cf850a1 |
|
MD5 | f6d05ac94587c4fe7f1773edf5448237 |
|
BLAKE2b-256 | 51c2313f92994b5d4f06faf552e18b9c6536f02757d79d726416807541b740f4 |
Close
Hashes for callhub_python_wrapper-0.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d35dee7d14d8a7467361465967862b932aa55bfdf6bbd1f33ba84b224ede8f31 |
|
MD5 | 8a6a50cd87f3dfee8de99fc7b3e83de6 |
|
BLAKE2b-256 | a08a7ef4b58d3295c0d3a62c6ca6a937aacbea57cd9b5a5fe408b597c7ad2ee5 |