Skip to main content

Python library for Factom DIDs

Project description

Build Status Coverage Status License: MIT Code style: black

py-factom-did

py-factom-did is a Python library, allowing the creation and update of Decentralized Identifiers (DIDs) and the exporting of public metadata for them, which can be recorded on the Factom blockchain. The library enables:

  • creating a new DID
  • adding management key(s) for the DID
  • adding DID key(s) for the DID
  • adding service(s) for the DID
  • exporting public metadata to be recorded on Factom
  • encrypting the newly created keys
  • updating an existing DID: adding/revoking management keys, DID keys and services and producing a signed DID update entry

You can find an example of the library workflow in the examples/ directory. In order to run the example, please note that it is necessary to:

  • have local instances of factomd and factom-walletd running
  • create an environment variable called EC_ADDR, which contains a funded EC address to pay the fees for recording the DID on-chain

Installation

pip install py-factom-did

Build

  • Clone the repo

  • Create the virtual environment and install the dependencies:

pipenv install

or

pipenv install --pre -d

to install both the default and development dependencies

  • Activate the virtual environment:
pipenv shell
  • Execute the tests:
pytest
  • Execute the example:
python -m examples.example

Documentation

API documentation of the library is available here

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

py-factom-did-0.4.0.tar.gz (13.0 kB view details)

Uploaded Source

Built Distribution

py_factom_did-0.4.0-py3-none-any.whl (16.8 kB view details)

Uploaded Python 3

File details

Details for the file py-factom-did-0.4.0.tar.gz.

File metadata

  • Download URL: py-factom-did-0.4.0.tar.gz
  • Upload date:
  • Size: 13.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.4

File hashes

Hashes for py-factom-did-0.4.0.tar.gz
Algorithm Hash digest
SHA256 8acb1f4afd56253d69e083dc0516dfb41a0cb9615725e890554e431c6ac9081c
MD5 fe630394ec6863a6df9c8fd352939756
BLAKE2b-256 c308147b70e1f1d1a6f1c7f0b12947bc957cd045c0bc116e665a9b712abed3ae

See more details on using hashes here.

File details

Details for the file py_factom_did-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: py_factom_did-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 16.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.4

File hashes

Hashes for py_factom_did-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5ff4b5b97e3f64ae323b1360d559d61dfcaafffabf5372a1e21da6d7b6779025
MD5 547f6eef52d3605170439a89b1e177e7
BLAKE2b-256 bc404174a8a47f1d79aef4ba41b14bb6d56674db746a826235af10aebf6cb7a1

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page