Getting Started
Just a few steps to spin up the Issuer!
1. git clone
the Demo Issuer Repository
git clone
the Demo Issuer RepositoryThe prerequisites necessary to run the Demo Issuer are:
2. Setup a Public URL
To run the demo issuer we need to set up a publicly accessible URL. For that, we use ngrok
ngrok http 8001
# Output -> https://ecd9-49-207-208-41.in.ngrok.io
3. Setup the config
Add the following variables inside the config file
demo-issuer/issuer/issuer_config.default.yaml
:
log_level
parameter controls the amount of messages that are generated when running the issuer.db_file_path
is the path to the DB file where the state of the issuer is stored (or will be stored)reset_db
will reset the DB state of issuer on boot.publishing_private_key
is the private key of the wallet that will be used to execute any on-chain transactions. Ensure that the account associated with this private has enough test MATIC tokens.
publishing_contract_address
is the address of the contract that manages the state of the identity (in our case the demo-issuer)circuits_dir
is the directory which all the required data related to zkp operations (proving/verification) is storedlocal_url
is the url the HTTP API of the demo-issuer will run locallypublic_url
is the ngrok public url obtained from the previous step
log_level: TRACE # TRACE/DEBUG/INFO
# DB
db_file_path: issuer.db
reset_db: true
# On-chain interaction
node_rpc_url: <mumbai-node-rpc>
publishing_contract_address: 0x46Fd04eEa588a3EA7e9F055dd691C688c4148ab3
publishing_private_key: <mumbai-private-key>
# Protocol specific information
circuits_dir: keys
ipfs_url: ipfs.io
# Hosting
local_url: 'localhost:8001'
public_url: https://cb4d-46-121-236-63.eu.ngrok.io
4. Start the Demo Issuer
Run the main.go
file to start the Demo Issuer
cd issuer
go run cmd/main.go
INFO[0000] boot up issuer service
INFO[0000] loading Configuration
INFO[0000] using config file: /Users/enricobottazzi/Documents/GitHub/demo-issuer/issuer/issuer_config.default.yaml
INFO[0000] issuer config: &{INFO issuer.db keys https://a0cb-88-147-75-172.eu.ngrok.io localhost:8001 {30237d5b882221685f2926361ca7e81f1235d5faef02bcfbf99f459718bfd952 32} ipfs.io}
INFO[0000] setting up logger
INFO[0000] creating DB
INFO[0000] creating identity state
INFO[0000] processing secret key
INFO[0000] creating Identity
INFO[0000] spining up API server @localhost:8001
INFO[0000] starting HTTP server (address: localhost:8001)
Last updated