document
The blocklet document command provides tools for managing the Decentralized Identifier (DID) Document associated with a blocklet. A DID Document is a JSON object containing essential metadata, such as public keys and service endpoints, that defines a blocklet's identity on the network.
This command is primarily used to ensure a blocklet's public-facing information is up-to-date with its on-chain or server-side configuration.
update#
The update command regenerates and publishes the DID Document for a specified blocklet running on your Blocklet Server. You should run this command after making configuration changes that affect the blocklet's public metadata, such as updating service endpoints or capabilities.
Usage#
blocklet document update <appId>Arguments#
Argument | Description |
|---|---|
| The DID of the blocklet whose DID Document needs updating. |
Example#
To update the DID Document for a blocklet with the DID z8iZtw..., run the following command:
blocklet document update z8iZtw...Upon successful execution, the CLI will display a confirmation message:
✔ Updating...
Update did document for z8iZtw... successfully!If the command fails because the blocklet is not found, an error will be returned:
Failed to update did document for blocklet z8iZtw..., error: Blocklet z8iZtw... not foundExecution Flow#
The update command follows a clear sequence to ensure the DID Document is correctly updated.
Managing your blocklet's DID Document is a key part of maintaining its identity and functionality. For a complete list of commands to manage your blocklets, see the blocklet command reference.