# python-opencnam
A simple python library for getting caller ID name information.

This library uses [OpenCNAM](https://www.opencnam.com “opencnam”) as a backend.
[](http://travis-ci.org/telephonyresearch/python-opencnam)
## Installation
Install from PyPi using [pip](http://www.pip-installer.org/en/latest/), a package manager for Python.
$ pip install opencnam
Don’t have pip installed? Try installing it, by running this from the command line:
$ curl https://raw.github.com/pypa/pip/master/contrib/get-pip.py | python
Or you can [download the source code](https://github.com/telephonyresearch/python-opencnam/zipball/master “OpenCNAM source code”) for OpenCNAM, and then run:
$ python setup.py install
You may need to run the above commands with sudo.
## Usage
Using python-opencnam is easy:
from opencnam import Phone
phone = Phone('+16284003994')
print phone.number, phone.cnam
The main object, Phone, defined in the opencnam module accepts a phone number as input, and (behind the scenes) queries the [opencnam](http://www.opencnam.com “opencnam”) API to set the Phone.cnam attribute.
## API Authentication
To specify your API credentials, just pass them into the Phone constructor, like so:
from opencnam import Phone
phone = Phone(‘+16284003994’, account_sid=’ACxxx’, auth_token=’AUxxx’)
## Changelog
v06: 2018-11-30
Use OpenCNAM v3.
Support only account_sid and auth_token for authentication, removing the deprecated api_user and api_key.
Support Python 2.7 and Python 3.7
v0.5: 2012-11-08
Add support for OpenCNAM V2 API.
Deprecate the api_user and api_key authentication parameters, in favor of account_sid and auth_token.
v0.4: 2012-07-10
Add 3 second timeout to CNAM lookups, so we won’t block for too long.
v0.3: 2012-07-09
Rewrite the backend to use requests instead of slumber.
Clean up documentation.
Add public tests via Travis CI.
v0.2: 2012-03-19
Support API authentication.
v0.1: 2012-02-26
Initial release!
Metadata
Release files for opencnam 0.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| opencnam-0.7.tar.gz | 17.6 kB | Without provenance | Details for opencnam-0.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| opencnam-0.7-py3-none-any.whl | Python 3 | none | any | Details for opencnam-0.7-py3-none-any.whl |
Total release size: 22.6 kB
Release files / opencnam-0.7.tar.gz
| Download URL | opencnam-0.7.tar.gz |
|---|---|
| Size | 17.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e28fd0f3e9ff5ed598c78a674e40673668b6562a7fcb6e551863384f98c9fcc3
|
|
BLAKE2b-256 checksum How to use checksums |
4fd680d834d9ab2b8196edecae8bf46148be247e1556226de574c1f57a4bfb17
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.7
|
Release files / opencnam-0.7-py3-none-any.whl
| Download URL | opencnam-0.7-py3-none-any.whl |
|---|---|
| Size | 5.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5901a6956bece4c876835c8a820a7c121e79da1f9b1a411897e5571067132205
|
|
BLAKE2b-256 checksum How to use checksums |
99dc29309a01b92dd8eb553b09bfea86ccbe335d2ef93a3fd1177ef80a6ea9a4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.7
|
Security for opencnam 0.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.