From 953086743757f79feb725664bcc73a7f2c972d35 Mon Sep 17 00:00:00 2001 From: Barry <122767193+BarryTong65@users.noreply.github.com> Date: Tue, 15 Oct 2024 22:10:44 +1030 Subject: [PATCH] docs: allowance examples (#118) --- cmd/cmd_allowance.go | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/cmd/cmd_allowance.go b/cmd/cmd_allowance.go index b6d67af..1a27978 100644 --- a/cmd/cmd_allowance.go +++ b/cmd/cmd_allowance.go @@ -23,6 +23,21 @@ func cmdGrantAllowance() *cli.Command { Description: ` The command is used to grant allowance to the grantee. --grantee defines the grantee address, --expire defines the expiration time in second +Flags: +The command includes three flags that users can set when using the command to specify relevant values: +--grantee (granteeFlag) + Type: String (cli.StringFlag) + Default Value: Empty string + Usage: Specifies the address of the grantee (in hexadecimal string format). +--allowance (allowanceFlag) + Type: String + Default Value: Empty string + Usage: Specifies the amount of allowance in wei. +--expire (expireTimeFlag) + Type: Unsigned 64-bit integer (cli.Uint64Flag) + Default Value: 0 + Usage: Sets the expiration time of the allowance in UNIX timestamp (seconds). + Examples: $ gnfd-cmd fee grant --grantee 0x... --allowance 10000000000000000 --expire 3600`, Flags: []cli.Flag{