This Python API client provides access to masmovil core API domains
Project description
:warning: WORK IN PROGRESS :warning:
This Python API client provides access to masmovil core API domains.
Resources
- Feasibility
- Coverage - find an address
- Streets:
- search: returns a list of street by text
- get_building_info_by_street: returns a list of building info by street id
- Buildings:
- search: returns a list of buildings by text
- multi_search: returns a list of buildings by request body
- get: returns a building by id with a list of units
- Units:
- get: returns a unit by id with a list of coverages
- get_coverage: returns coverage info for a unit id and territory_owner
- Streets:
- Coverage - find an address
Installation
$ pip install masstack-python-client
Configuration Environment
You need define the Masstack CLIENT_EMAIL, PRIVATE_KEY_ID TOKEN_URI, MASSTACK_DOMAIN and PRIVATE_KEY in BASE64 as environment variables to request access toekn. You need define:
MASSTACK_CLIENT_EMAIL=<YOUR CLIENT EMAIL>
MASSTACK_PRIVATE_KEY_ID=<YOUR PRIVATE KEY ID>
MASSTACK_TOKEN_URI=<MASSTACK TOKEN URI>
MASSTACK_PRIVATE_KEY_BASE64=<YOUR PRIVATE KEY in BASE64>
MASSTACK_DOMAIN=<MASSTACK DOMAIN>
If this envvars are not defined, a exception will be raised with the name of the envvar not defined.
Optional TOKEN_STORE_PATH environment variable to store token, if is not defined by defect is /tmp/masstack.token
MASSTACK_TOKEN_STORE_PATH=<YOUR PATH>
To all resources need define ORG_ID
MASSTACK_ORG_ID=<MASSTACK ORG ID>
For coverage resources need define COVERAGE_SEGMENT and COVERAGE_CHANNEL
MASSTACK_COVERAGE_SEGMENT=<SF SEGMENT>
MASSTACK_COVERAGE_CHANNEL=<SF CHANNEL>
Development
Setup environment
- Install
pyenv
curl https://pyenv.run | bash
- Build the Python version
pyenv install 3.11.9
- Create a virtualenv
pyenv virtualenv 3.11.9 masstack-python-client
- Activate virtualenv
pyenv activate masstack-python-client
- Install dependencies
pyenv exec pip install -r requirements-dev.txt
- Install pre-commit hooks
pyenv exec pre-commit install
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file masstack_python_client-0.0.2.tar.gz.
File metadata
- Download URL: masstack_python_client-0.0.2.tar.gz
- Upload date:
- Size: 25.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0dfb88f8a8e8bf0ec739adddbec0e12fb9324ff0ad911d4c1b623f5288e125f6
|
|
| MD5 |
cacbf76db4b18298e0491cb0f4375588
|
|
| BLAKE2b-256 |
4ff1b680e9dae183b1de2cdd0b1cbed15ed200395a8436e48fb984edeccc3ccd
|
File details
Details for the file masstack_python_client-0.0.2-py3-none-any.whl.
File metadata
- Download URL: masstack_python_client-0.0.2-py3-none-any.whl
- Upload date:
- Size: 25.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
84c9156a8005cc95ea97e3120ed27d513c4f436903583abd7f46283794f908f9
|
|
| MD5 |
d9ea2cb44b8eb9dc0adf6bfec1948879
|
|
| BLAKE2b-256 |
6e989553d3e8d0bd3129543e656e5531cc118c8759725d899a1bf249a1b5508f
|