KeychainMDIP / kc

Reference implementation of the Multi Dimensional Identity Protocol (MDIP)
MIT License
9 stars 4 forks source link

Structure CLI help output. #33

Closed alexfornuto closed 8 months ago

alexfornuto commented 8 months ago

I suggest a structured output with defined sections based on topic and alphabetized sub-sections, something like:

Usage: keychain-cli [options] [command]

Keychain CLI tool

Options:
  -V, --version                               output the version number
  -h, --help                                  display help for command

Commands:
    Wallet:
        backup-wallet                               Backup wallet to encrypted DID
        create-wallet                               Create new wallet (or show existing wallet)
        import-wallet <recovery-phrase>             Create new wallet from a recovery phrase
        recover-wallet <did>                        Recover wallet from encrypted DID
        show-mnemonic                               Show recovery phrase for wallet
        show-wallet                                 Show wallet
    Identities:
        backup-id                                   Backup the current ID to its registry
        create-id <name> [registry]                 Create a new decentralized ID
        list-ids                                    List IDs and show current ID
        recover-id <did>                            Recovers the ID from the DID
        remove-id <name>                            Deletes named ID
        resolve-id                                  Resolves the current ID
        use-id <name>                               Set the current ID

...
Flaxscrip commented 8 months ago

@alexfornuto - This might be one to put in the Spring release. Could you help by providing a full list? Perhaps the structure should also be reflected in the User Manual. Both changes would be valuable for Spring release (ie: easy of understanding the protocol for early reviewers).

macterra commented 8 months ago

fyi the help output is automatically generated. We can re-order the commands. I'm not sure we can add arbitrary categories.

macterra commented 8 months ago
Usage: keychain-cli [options] [command]

Keychain CLI tool

Options:
  -V, --version                               output the version number
  -h, --help                                  display help for command

Commands:
  accept-credential <did> [name]              Save verifiable credential for current ID
  add-name <name> <did>                       Adds a name for a DID
  attest-credential <file> [registry] [name]  Sign and encrypt a bound credential file
  backup-id                                   Backup the current ID to its registry
  backup-wallet                               Backup wallet to encrypted DID
  bind-credential <file> <did>                Create bound credential for a user
  create-challenge [file] [name]              Create challenge (optionally from a file)
  create-challenge-cc <did> [name]            Create challenge from a credential DID
  create-credential <file> [name]             Create credential from schema file
  create-id <name> [registry]                 Create a new decentralized ID
  create-response <challenge>                 Create a Verifiable Presentation from a challenge
  create-wallet                               Create new wallet (or show existing wallet)
  decrypt-did <did>                           Decrypt an encrypted message DID
  decrypt-json <did>                          Decrypt an encrypted JSON DID
  encrypt-file <file> <did>                   Encrypt a file for a DID
  encrypt-msg <msg> <did>                     Encrypt a message for a DID
  export-did <did>                            Export DID to file
  help [command]                              display help for command
  import-did <file>                           Import DID from file
  import-wallet <recovery-phrase>             Create new wallet from a recovery phrase
  list-ids                                    List IDs and show current ID
  list-names                                  Lists names of DIDs
  publish-credential <did>                    Publish the existence of a credential to the current user manifest
  recover-id <did>                            Recovers the ID from the DID
  recover-wallet <did>                        Recover wallet from encrypted DID
  remove-id <name>                            Deletes named ID
  remove-name <name>                          Removes a name for a DID
  resolve-did <did>                           Return document associated with DID
  resolve-id                                  Resolves the current ID
  reveal-credential <did>                     Reveal a credential to the current user manifest
  revoke-credential <did>                     Revokes a verifiable credential
  rotate-keys                                 Rotates keys for current user
  show-mnemonic                               Show recovery phrase for wallet
  show-wallet                                 Show wallet
  sign-file <file>                            Sign a JSON file
  unpublish-credential <did>                  Remove a credential from the current user manifest
  use-id <name>                               Set the current ID
  verify-file <file>                          Verify the signature in a JSON file
  verify-response <did>                       Decrypt and validate a Verifiable Presentation