Skip to content

danubetech/uni-registrar-driver-did-btc1

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Universal Registrar Driver: did:btc1

This is a Universal Registrar driver for did:btc1 identifiers.

(work in progress)

Specifications

Build and Run (Docker)

docker compose build
docker compose up

Example Requests

curl -X POST "http://localhost:9080/1.0/create?method=btc1" \
     -H "Content-Type: application/json" \
     -d '{
       "didDocument": {
         "@context": ["https://www.w3.org/ns/did/v1"]
       },
       "options": {
         "clientSecretMode": true,
         "network": "mutinynet"
       },
       "secret": { }
     }'
curl -X POST "http://localhost:9080/1.0/create?method=btc1" \
     -H "Content-Type: application/json" \
     -d '{
       "didDocument" : {
         "@context": ["https://www.w3.org/ns/did/v1"],
         "verificationMethod" : [ {
           "type" : "Multikey",
           "id" : "#initialKey",
           "publicKeyMultibase" : "zQ3shrogQZQDjQe6boF6Sas9occwW7rZVVLR3qQ85qt7JHXq4"
         } ],
         "assertionMethod" : [ "#initialKey" ],
         "capabilityDelegation" : [ "#initialKey" ],
         "capabilityInvocation" : [ "#initialKey" ],
         "authentication" : [ "#initialKey" ]
       },
       "options" : {
         "clientSecretMode" : true,
         "network" : "mutinynet"
       },
       "secret" : { }
     }'

Driver Environment Variables

The driver recognizes the following environment variables:

uniregistrar_driver_did_btc1_bitcoinConnections

  • Specifies how the driver interacts with the Bitcoin blockchain.
  • Possible values:
    • bitcoind: Connects to a bitcoind instance via JSON-RPC
    • btcd: Connects to a btcd instance via JSON-RPC
    • bitcoinj: Connects to Bitcoin using a local bitcoinj client
    • blockcypherapi: Connects to BlockCypher's API
    • esploraelectrsrest: Connects to Esplora/Electrs REST API
  • Default value: bitcoind

uniregistrar_driver_did_btc1_bitcoinConnectionsUrls

  • Specifies the JSON-RPC URLs of the Bitcoin connections.

uniregistrar_driver_did_btc1_bitcoinConnectionsCerts

  • Specifies the server TLS certificates of the Bitcoin connections.
  • Default value: ``

Driver Input Options

{
    "network": "mutinynet"
}
  • network: The name of the network where a DID should be registered. Values depend on bitcoinConnections environment variable, but are typically: bitcoin, testnet3, signet, mutinynet.

About

A Universal Registrar driver for did:btc1 identifiers.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published