Skip to main content

Create or Update Permission Session

Before issuing the credential or requesting the presentation of a credential, if payment is required, the entity that would like to perform the action must first create a transaction to prove the payment took place, using the sessionid shared by the peer.

Anyone can use this method.

You must use the find beneficiaries method first to calculate the needed trust fees and make sure your account has enough balance (including gas fees) to execute the transaction.

Message Parameters

NameDescriptionMandatory
iduuid of the sessionId of the peer for which we want to create the permission sessionyes
agent-perm-idid of the agent permissionyes
wallet-agent-perm-idid of the wallet agent permission (can be equal to agent-perm-id)yes
issuer-perm-idid of the issuer permissionno
verifier-perm-idid of the verifier permissionno

Important: At least one of issuer-perm-id or verifier-perm-id must be provided.

TODO

@matlux

Post the Message

Usage

veranad tx perm create-or-update-perm-session [id] [agent-perm-id] [flags]

Issuance Example

plantuml

SESSION_ID=$(uuidgen)
veranad tx perm create-or-update-perm-session $SESSION_ID 45 --issuer-perm-id 30 --wallet-agent-perm-id 50 \
--from $USER_ACC --keyring-backend test --chain-id $CHAIN_ID --fees 600000uvna --node $NODE_RPC

Explanation:

  • agent-perm-id = 45 (Agent handling issuance).
  • wallet-agent-perm-id = 50 (Wallet where credential will be stored).
  • issuer-perm-id = 30 (Permission of the Issuer).

Verification Example

plantuml

SESSION_ID=$(uuidgen)
veranad tx perm create-or-update-perm-session $SESSION_ID 45 --verifier-perm-id 60 --wallet-agent-perm-id 50 \
--from $USER_ACC --keyring-backend test --chain-id $CHAIN_ID --fees 600000uvna --node $NODE_RPC

Explanation:

  • agent-perm-id = 45 (Agent handling verification).
  • wallet-agent-perm-id = 50 (Wallet where credential will be stored).
  • verifier-perm-id = 60 (Permission of the Verifier).