Bandwidth API for v2 messaging
Project description
Bandwidth Python API
Client library for the Bandwidth App Platform
Full Reference
dev.bandwidth.com/python-bandwidth
Requirements
Installation
pip install pybandwidth_v2
Usage
Client Initialization
from pybandwidth_v2.bandwidth_client import BandwidthAccountAPI, BandwidthMessagingAPI
messaging_api = BandwidthMessagingAPI('acc-account_id', 't-token', 's-secret', 'a-application_id')
account_api = BandwidthAccountAPI('acc-account_id', 'u-username', 'p-password')
Each of these code sample assumes that you have already initialized a client
Search phone number
numbers = account_api.search_available_numbers(area_code = '910', quantity = 3)
print(numbers[0]['number'])
## +19104440230
Send Text Message
message_id = messaging_api.send_message('+1234567980',
['+1234567981'],
'SMS message')
print(message_id)
# m-messageId
Release History
0.0.2 (2019-09-12)
Initial release of SDK
Developer Info
Running tests
pip3 install nose
nosetests pybandwidth_v2
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
pybandwidth_v2-0.0.3.tar.gz
(4.2 kB
view hashes)
Built Distribution
Close
Hashes for pybandwidth_v2-0.0.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ef303cc66ce7a0ce2dcc7ad5db7bd1abef3a6e2a1026c109818305607a68d19a |
|
MD5 | b71489ff0f31784081c9c507e2012942 |
|
BLAKE2b-256 | 90621938ee826e06c92abbe6e67b8a50df00b983e73881c4709b51748382c4b7 |