Skip to content

Commit da4f797

Browse files
committed
Updated documentation
Signed-off-by: artem.ivanov <[email protected]>
1 parent 30132d8 commit da4f797

File tree

7 files changed

+264
-145
lines changed

7 files changed

+264
-145
lines changed

cli/src/commands/ledger.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ pub mod nym_command {
4444
.add_optional_param("verkey", "Verification key of new identity")
4545
.add_optional_param("role", "Role of identity. One of: STEWARD, TRUSTEE, TRUST_ANCHOR, TGB or empty in case of blacklisting NYM")
4646
.add_optional_param("fees_inputs","The list of source inputs")
47-
.add_optional_param("fees_outputs","The list of outputs")
47+
.add_optional_param("fees_outputs","The list of outputs in the following format: (recipient, amount, Optional<extra>)")
4848
.add_example("ledger nym did=VsKV7grR1BUE29mG2Fm2kX")
4949
.add_example("ledger nym did=VsKV7grR1BUE29mG2Fm2kX verkey=GjZWsBLgZCR18aL468JAT7w9CZRiBnpxUPPgyQxh4voa")
5050
.add_example("ledger nym did=VsKV7grR1BUE29mG2Fm2kX role=TRUSTEE")
@@ -156,7 +156,7 @@ pub mod attrib_command {
156156
.add_optional_param("raw", "JSON representation of attribute data")
157157
.add_optional_param("enc", "Encrypted attribute data")
158158
.add_optional_param("fees_inputs","The list of source inputs")
159-
.add_optional_param("fees_outputs","The list of outputs")
159+
.add_optional_param("fees_outputs","The list of outputs in the following format: (recipient, amount, Optional<extra>)")
160160
.add_example(r#"ledger attrib did=VsKV7grR1BUE29mG2Fm2kX raw={"endpoint":{"ha":"127.0.0.1:5555"}}"#)
161161
.add_example(r#"ledger attrib did=VsKV7grR1BUE29mG2Fm2kX hash=83d907821df1c87db829e96569a11f6fc2e7880acba5e43d07ab786959e13bd3"#)
162162
.add_example(r#"ledger attrib did=VsKV7grR1BUE29mG2Fm2kX enc=aa3f41f619aa7e5e6b6d0d"#)
@@ -269,7 +269,7 @@ pub mod schema_command {
269269
.add_required_param("version", "Schema version")
270270
.add_required_param("attr_names", "Schema attributes split by comma")
271271
.add_optional_param("fees_inputs","The list of source inputs")
272-
.add_optional_param("fees_outputs","The list of outputs")
272+
.add_optional_param("fees_outputs","The list of outputs in the following format: (recipient, amount, Optional<extra>)")
273273
.add_example("ledger schema name=gvt version=1.0 attr_names=name,age")
274274
.add_example("ledger schema name=gvt version=1.0 attr_names=name,age fees_inputs=txo:sov:111_rBuQo2A1sc9jrJg fees_outputs=(pay:sov:FYmoFw55GeQH7SRFa37dkx1d2dZ3zUF8ckg7wmL7ofN4,100)")
275275
.finalize()
@@ -431,7 +431,7 @@ pub mod cred_def_command {
431431
.add_required_param("primary", "Primary key in json format")
432432
.add_optional_param("revocation", "Revocation key in json format")
433433
.add_optional_param("fees_inputs","The list of source inputs")
434-
.add_optional_param("fees_outputs","The list of outputs")
434+
.add_optional_param("fees_outputs","The list of outputs in the following format: (recipient, amount, Optional<extra>)")
435435
.add_example(r#"ledger cred-def schema_id=1 signature_type=CL primary={"n":"1","s":"2","rms":"3","r":{"age":"4","name":"5"},"rctxt":"6","z":"7"}"#)
436436
.finalize()
437437
);
@@ -901,7 +901,7 @@ pub mod payment_command {
901901

902902
command!(CommandMetadata::build("payment", "Send request for doing payment.")
903903
.add_required_param("inputs","The list of payment sources")
904-
.add_required_param("outputs","The list of outputs")
904+
.add_required_param("outputs","The list of outputs in the following format: (recipient, amount, Optional<extra>)")
905905
.add_example("ledger payment inputs=txo:sov:111_rBuQo2A1sc9jrJg outputs=(pay:sov:FYmoFw55GeQH7SRFa37dkx1d2dZ3zUF8ckg7wmL7ofN4,100,extradata)")
906906
.add_example("ledger payment inputs=txo:sov:111_rBuQo2A1sc9jrJg,txo:sov:222_aEwACvA1sc9jrJg outputs=(pay:sov:FYmoFw55GeQH7SRFa37dkx1d2dZ3zUF8ckg7wmL7ofN4,100,extradata),(pay:sov:ABABefwrhscbaAShva7dkx1d2dZ3zUF8ckg7wmL7ofN4,5)")
907907
.finalize()
@@ -1005,7 +1005,7 @@ pub mod mint_prepare_command {
10051005
use super::*;
10061006

10071007
command!(CommandMetadata::build("mint-prepare", "Prepare MINT transaction.")
1008-
.add_required_param("outputs","The list of outputs")
1008+
.add_required_param("outputs","The list of outputs in the following format: (recipient, amount, Optional<extra>)")
10091009
.add_example("ledger mint-prepare outputs=(pay:sov:FYmoFw55GeQH7SRFa37dkx1d2dZ3zUF8ckg7wmL7ofN4,100,extradata)")
10101010
.add_example("ledger mint-prepare outputs=(pay:sov:FYmoFw55GeQH7SRFa37dkx1d2dZ3zUF8ckg7wmL7ofN4,100,extradata),(pay:sov:ABABaaVwSascbaAShva7dkx1d2dZ3zUF8ckg7wmL7ofN4,5)")
10111011
.finalize()

doc/design/001-cli/README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ indy> ledger <subcommand>
235235
#### NYM transaction
236236
Send NYM transaction
237237
```
238-
ledger nym did=<did-value> [verkey=<verkey-value>] [role=<role-value>] [fees_inputs=<utxo-1,..,utxo-n>] [fees_outputs=(<pay-addr-1>,<amount>,<extra>),..,(<pay-addr-n>,<amount>,<extra>)]
238+
ledger nym did=<did-value> [verkey=<verkey-value>] [role=<role-value>] [fees_inputs=<source-1,..,source-n>] [fees_outputs=(<recipient-1>,<amount>,<extra>),..,(<recipient-n>,<amount>,<extra>)]
239239
```
240240
241241
#### GET_NYM transaction
@@ -247,7 +247,7 @@ ledger get-nym did=<did-value>
247247
#### ATTRIB transaction
248248
Send ATTRIB transaction
249249
```
250-
ledger attrib did=<did-value> [hash=<hash-value>] [raw=<raw-value>] [enc=<enc-value>] [fees_inputs=<utxo-1,..,utxo-n>] [fees_outputs=(<pay-addr-1>,<amount>,<extra>),..,(<pay-addr-n>,<amount>,<extra>)]
250+
ledger attrib did=<did-value> [hash=<hash-value>] [raw=<raw-value>] [enc=<enc-value>] [fees_inputs=<source-1,..,source-n>] [fees_outputs=(<recipient-1>,<amount>,<extra>),..,(<recipient-n>,<amount>,<extra>)]
251251
```
252252
253253
#### GET_ATTRIB transaction
@@ -259,7 +259,7 @@ ledger get-attrib did=<did-value> [raw=<raw-value>] [hash=<hash-value>] [enc=<en
259259
#### SCHEMA transaction
260260
Send SCHEMA transaction
261261
```
262-
ledger schema name=<name-value> version=<version-value> attr_names=<attr_names-value> [fees_inputs=<utxo-1,..,utxo-n>] [fees_outputs=(<pay-addr-1>,<amount>,<extra>),..,(<pay-addr-n>,<amount>,<extra>)]
262+
ledger schema name=<name-value> version=<version-value> attr_names=<attr_names-value> [fees_inputs=<source-1,..,source-n>] [fees_outputs=(<recipient-1>,<amount>,<extra>),..,(<recipient-n>,<amount>,<extra>)]
263263
```
264264
265265
#### GET_SCHEMA transaction
@@ -270,7 +270,7 @@ ledger get-schema did=<did-value> name=<name-value> version=<version-value>
270270
#### CRED_DEF transaction
271271
Send CRED_DEF transaction
272272
```
273-
ledger cred-def schema_id=<schema_id-value> signature_type=<signature_type-value> [tag=<tag>] primary=<primary-value> [revocation=<revocation-value>] [fees_inputs=<utxo-1,..,utxo-n>] [fees_outputs=(<pay-addr-1>,<amount>,<extra>),..,(<pay-addr-n>,<amount>,<extra>)]
273+
ledger cred-def schema_id=<schema_id-value> signature_type=<signature_type-value> [tag=<tag>] primary=<primary-value> [revocation=<revocation-value>] [fees_inputs=<source-1,..,source-n>] [fees_outputs=(<recipient-1>,<amount>,<extra>),..,(<recipient-n>,<amount>,<extra>)]
274274
```
275275
276276
#### GET_CRED_DEF transaction
@@ -315,16 +315,16 @@ Send custom transaction with user defined json body and optional signature
315315
ledger custom [txn=]<txn-json-value> [sign=<true|false>]
316316
```
317317
318-
#### GET_UTXO transaction
319-
Send GET_UTXO transaction
318+
#### GET_SOURCES transaction
319+
Send GET_SOURCES transaction
320320
```
321-
ledger get-utxo payment_address=<payment_address>
321+
ledger get-sources payment_address=<payment_address>
322322
```
323323
324324
#### PAYMENT transaction
325325
Send PAYMENT transaction
326326
```
327-
ledger payment inputs=<utxo-1>,..,<utxo-n> outputs=(<pay-addr-1>,<amount>,<extra>),..,(<pay-addr-n>,<amount>,<extra>)
327+
ledger payment inputs=<source-1>,..,<source-n> outputs=(<recipient-1>,<amount>,<extra>),..,(<recipient-n>,<amount>,<extra>)
328328
```
329329
330330
#### GET_FEES transaction

0 commit comments

Comments
 (0)