pypassbolt-api
About
Python library for Passbolt API based on httpx and PGPy.
You can also use python-gnupg if needed but it is not the default.
How to install
python -m pip install pypassbolt-api
How to use
config.json configuration file
Basically, create a config.json file containing needed configuration. You will find samples:
- For PGPy (default): config.json.PGPy.sample
- For python-gnupg: config.json.gnupg.sample
Then have a look at https://gitlab.com/AnatomicJC/py-passbolt/-/blob/main/example.py python script.
Environment variables
Mandatory:
- PASSBOLT_BASE_URL: Your passbolt URL
For PGPy:
- PASSBOLT_PRIVATE_KEY: Your passbolt private key in one-line format (See below about how to format)
- PASSBOLT_PASSPHRASE: Your passbolt passphrase
For python-gnupg:
- PASSBOLT_GPG_BINARY (Optional): path to your gpg binary, default to "gpg"
- PASSBOLT_GPG_LIBRARY: Set this to gnupg, otherwise it will be the default "PGPy"
- PASSBOLT_FINGERPRINT: The OpenPGP key fingerprint to use
How to set OpenPGP key in config.json or environment variables
Linux:
sed -z 's/\n/\\n/g' passbolt_private.txt
MacOS
Install gnu-sed with brew:
brew install gnu-sed
Use gsed instead of sed:
gsed -z 's/\n/\\n/g' passbolt_private.txt
Note: Almost all the source code has been obtained from the existing py-passbolt library, with some extra functions. py-passbolt
Metadata
Release files for pypassbolt-api 0.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pypassbolt_api-0.0.4.tar.gz | 8.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pypassbolt_api-0.0.4-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details |
Total release size: 13.9 kB
Release files / pypassbolt_api-0.0.4.tar.gz
| Download URL | pypassbolt_api-0.0.4.tar.gz |
|---|---|
| Size | 8.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ffcd718d76d258696b946954aff5427bafe8b84b7e5a8512d7959b68062bcf55
|
|
BLAKE2b-256 checksum How to use checksums |
f43982a463e051ffde750ffe208a18d21f70bc839e4e1322c788bc083eab6ea8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.8.19
|
Release files / pypassbolt_api-0.0.4-py2.py3-none-any.whl
| Download URL | pypassbolt_api-0.0.4-py2.py3-none-any.whl |
|---|---|
| Size | 5.3 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
6b3e1dd268da7a29a0eb32bc7c2821fc9f7869594a623a7d5c26c3a7b0193b9c
|
|
BLAKE2b-256 checksum How to use checksums |
155895599d43b697b4e6a14f9640763062fbe587da9eeabd49d3cda1a30265df
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.8.19
|