Skip to content

Commit

Permalink
chore: update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolasbrugneaux committed Nov 8, 2024
1 parent faf6e93 commit f4d8d95
Show file tree
Hide file tree
Showing 8 changed files with 331 additions and 33 deletions.
69 changes: 69 additions & 0 deletions docs/command-line-interface/account.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Manage your account, keys, and metadata
* [`celocli account:offchain-read ARG1`](#celocli-accountoffchain-read-arg1)
* [`celocli account:offchain-write`](#celocli-accountoffchain-write)
* [`celocli account:proof-of-possession`](#celocli-accountproof-of-possession)
* [`celocli account:recover-old`](#celocli-accountrecover-old)
* [`celocli account:register`](#celocli-accountregister)
* [`celocli account:register-data-encryption-key`](#celocli-accountregister-data-encryption-key)
* [`celocli account:register-metadata`](#celocli-accountregister-metadata)
Expand Down Expand Up @@ -780,6 +781,74 @@ EXAMPLES

_See code: [src/commands/account/proof-of-possession.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/account/proof-of-possession.ts)_

## `celocli account:recover-old`

Recovers the Valora old account and print out the key information. The old Valora app (in a beta state) generated the user address using a seed of 32 bytes, instead of 64 bytes. As the app fixed that, some old accounts were left with some funds. This command allows the user to recover those funds.

```
USAGE
$ celocli account:recover-old --mnemonicPath <value> [--gasCurrency
0x1234567890123456789012345678901234567890] [--globalHelp] [--passphrasePath
<value>] [--changeIndex <value>] [--addressIndex <value>] [--language chinese_simpli
fied|chinese_traditional|english|french|italian|japanese|korean|spanish]
[--derivationPath <value>]
FLAGS
--addressIndex=<value>
Choose the address index for the derivation path
--changeIndex=<value>
Choose the change index for the derivation path
--derivationPath=<value>
Choose a different derivation Path (Celo's default is "m/44'/52752'/0'"). Use "eth"
as an alias of the Ethereum derivation path ("m/44'/60'/0'"). Recreating the same
account requires knowledge of the mnemonic, passphrase (if any), and the derivation
path
--gasCurrency=0x1234567890123456789012345678901234567890
Use a specific gas currency for transaction fees (defaults to CELO if no gas
currency is supplied). It must be a whitelisted token.
--globalHelp
View all available global flags
--language=<option>
[default: english] Language for the mnemonic words. **WARNING**, some hardware
wallets don't support other languages
<options: chinese_simplified|chinese_traditional|english|french|italian|japanese|kor
ean|spanish>
--mnemonicPath=<value>
(required) Path to a file that contains all the mnemonic words separated by a space
(example: "word1 word2 word3 ... word24"). If the words are a language other than
English, the --language flag must be used. Only BIP39 mnemonics are supported
--passphrasePath=<value>
Path to a file that contains the BIP39 passphrase to combine with the mnemonic
specified using the mnemonicPath flag and the index specified using the addressIndex
flag. Every passphrase generates a different private key and wallet address.
DESCRIPTION
Recovers the Valora old account and print out the key information. The old Valora app
(in a beta state) generated the user address using a seed of 32 bytes, instead of 64
bytes. As the app fixed that, some old accounts were left with some funds. This
command allows the user to recover those funds.
EXAMPLES
recover-old --mnemonicPath some_folder/my_mnemonic_file
recover-old --mnemonicPath some_folder/my_mnemonic_file --passphrasePath myFolder/my_passphrase_file
recover-old --mnemonicPath some_folder/my_mnemonic_file --language spanish
recover-old --mnemonicPath some_folder/my_mnemonic_file --passphrasePath some_folder/my_passphrase_file --language japanese --addressIndex 5
recover-old --mnemonicPath some_folder/my_mnemonic_file --passphrasePath some_folder/my_passphrase_file --addressIndex 5
```

_See code: [src/commands/account/recover-old.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/account/recover-old.ts)_

## `celocli account:register`

Register an account on-chain. This allows you to lock Gold, which is a pre-requisite for registering a Validator or Group, participating in Validator elections and on-chain Governance, and earning epoch rewards.
Expand Down
85 changes: 85 additions & 0 deletions docs/command-line-interface/identity.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,93 @@

Interact with ODIS and the attestations service

* [`celocli identity:get-attestations`](#celocli-identityget-attestations)
* [`celocli identity:identifier`](#celocli-identityidentifier)
* [`celocli identity:withdraw-attestation-rewards`](#celocli-identitywithdraw-attestation-rewards)

## `celocli identity:get-attestations`

Looks up attestations associated with the provided phone number. If a pepper is not provided, it uses the --from account's balance to query the pepper.

```
USAGE
$ celocli identity:get-attestations [--gasCurrency
0x1234567890123456789012345678901234567890] [--globalHelp] [--phoneNumber <value>]
[--from 0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d] [--pepper <value>] [--identifier
<value>] [--network <value>]
FLAGS
--from=0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d Account whose balance to use
for querying ODIS for the
pepper lookup
--gasCurrency=0x1234567890123456789012345678901234567890 Use a specific gas currency
for transaction fees
(defaults to CELO if no gas
currency is supplied). It
must be a whitelisted token.
--globalHelp View all available global
flags
--identifier=<value> On-chain identifier
--network=<value> The ODIS service to hit:
mainnet, alfajores,
alfajoresstaging
--pepper=<value> ODIS phone number pepper
--phoneNumber=<value> Phone number to check
attestations for
DESCRIPTION
Looks up attestations associated with the provided phone number. If a pepper is not
provided, it uses the --from account's balance to query the pepper.
EXAMPLES
get-attestations --phoneNumber +15555555555 --from 0x47e172F6CfB6c7D01C1574fa3E2Be7CC73269D95
get-attestations --phoneNumber +15555555555 --pepper XgnKVpplZc0p1
get-attestations --identifier 0x4952c9db9c283a62721b13f56c4b5e84a438e2569af3de21cb3440efa8840872
```

_See code: [src/commands/identity/get-attestations.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/identity/get-attestations.ts)_

## `celocli identity:identifier`

Queries ODIS for the on-chain identifier and pepper corresponding to a given phone number.

```
USAGE
$ celocli identity:identifier --from 0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d
--phoneNumber +14152223333 [--gasCurrency
0x1234567890123456789012345678901234567890] [--globalHelp] [--context <value>]
FLAGS
--context=<value> mainnet (default),
alfajores, or
alfajoresstaging
--from=0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d (required) The address from
which to perform the query
--gasCurrency=0x1234567890123456789012345678901234567890 Use a specific gas currency
for transaction fees
(defaults to CELO if no gas
currency is supplied). It
must be a whitelisted token.
--globalHelp View all available global
flags
--phoneNumber=+14152223333 (required) The phone number
for which to query the
identifier. Should be in
e164 format with country
code.
DESCRIPTION
Queries ODIS for the on-chain identifier and pepper corresponding to a given phone
number.
EXAMPLES
identifier --phoneNumber +14151231234 --from 0x5409ed021d9299bf6814279a6a1411a7e866a631 --context alfajores
```

_See code: [src/commands/identity/identifier.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/identity/identifier.ts)_

## `celocli identity:withdraw-attestation-rewards`

Withdraw accumulated attestation rewards for a given currency
Expand Down
71 changes: 71 additions & 0 deletions docs/command-line-interface/reserve.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
`celocli reserve`
=================

Shows information about reserve

* [`celocli reserve:status`](#celocli-reservestatus)
* [`celocli reserve:transfergold`](#celocli-reservetransfergold)

## `celocli reserve:status`

Shows information about reserve

```
USAGE
$ celocli reserve:status [--gasCurrency
0x1234567890123456789012345678901234567890] [--globalHelp]
FLAGS
--gasCurrency=0x1234567890123456789012345678901234567890 Use a specific gas currency
for transaction fees
(defaults to CELO if no gas
currency is supplied). It
must be a whitelisted token.
--globalHelp View all available global
flags
DESCRIPTION
Shows information about reserve
EXAMPLES
status
```

_See code: [src/commands/reserve/status.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/reserve/status.ts)_

## `celocli reserve:transfergold`

Transfers reserve celo to other reserve address

```
USAGE
$ celocli reserve:transfergold --value <value> --to
0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d --from
0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d [--gasCurrency
0x1234567890123456789012345678901234567890] [--globalHelp] [--useMultiSig]
FLAGS
--from=0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d (required) Spender's address
--gasCurrency=0x1234567890123456789012345678901234567890 Use a specific gas currency
for transaction fees
(defaults to CELO if no gas
currency is supplied). It
must be a whitelisted token.
--globalHelp View all available global
flags
--to=0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d (required) Receiving address
--useMultiSig True means the request will
be sent through multisig.
--value=<value> (required) The unit amount
of CELO
DESCRIPTION
Transfers reserve celo to other reserve address
EXAMPLES
transfergold --value 9000 --to 0x91c987bf62D25945dB517BDAa840A6c661374402 --from 0x5409ed021d9299bf6814279a6a1411a7e866a631
transfergold --value 9000 --to 0x91c987bf62D25945dB517BDAa840A6c661374402 --from 0x5409ed021d9299bf6814279a6a1411a7e866a631 --useMultiSig
```

_See code: [src/commands/reserve/transfergold.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/reserve/transfergold.ts)_
37 changes: 37 additions & 0 deletions docs/command-line-interface/transfer.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Transfer CELO and Celo Dollars
* [`celocli transfer:dollars`](#celocli-transferdollars)
* [`celocli transfer:erc20`](#celocli-transfererc20)
* [`celocli transfer:euros`](#celocli-transfereuros)
* [`celocli transfer:gold`](#celocli-transfergold)
* [`celocli transfer:reals`](#celocli-transferreals)
* [`celocli transfer:stable`](#celocli-transferstable)

Expand Down Expand Up @@ -156,6 +157,42 @@ EXAMPLES

_See code: [src/commands/transfer/euros.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/transfer/euros.ts)_

## `celocli transfer:gold`

Transfer CELO to a specified address. *DEPRECATION WARNING* Use the "transfer:celo" command instead

```
USAGE
$ celocli transfer:gold --from 0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d --to
0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d --value <value> [--gasCurrency
0x1234567890123456789012345678901234567890] [--globalHelp] [--comment <value>]
FLAGS
--comment=<value> Transfer comment
--from=0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d (required) Address of the
sender
--gasCurrency=0x1234567890123456789012345678901234567890 Use a specific gas currency
for transaction fees
(defaults to CELO if no gas
currency is supplied). It
must be a whitelisted token.
--globalHelp View all available global
flags
--to=0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d (required) Address of the
receiver
--value=<value> (required) Amount to
transfer (in wei)
DESCRIPTION
Transfer CELO to a specified address. *DEPRECATION WARNING* Use the "transfer:celo"
command instead
EXAMPLES
gold --from 0xa0Af2E71cECc248f4a7fD606F203467B500Dd53B --to 0x5409ed021d9299bf6814279a6a1411a7e866a631 --value 10000000000000000000
```

_See code: [src/commands/transfer/gold.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/transfer/gold.ts)_

## `celocli transfer:reals`

Transfer Celo Brazilian Real (cREAL) to a specified address.
Expand Down
36 changes: 36 additions & 0 deletions docs/command-line-interface/validator.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ View and manage Validators
* [`celocli validator:deaffiliate`](#celocli-validatordeaffiliate)
* [`celocli validator:deregister`](#celocli-validatorderegister)
* [`celocli validator:downtime-slash`](#celocli-validatordowntime-slash)
* [`celocli validator:force-deaffiliate`](#celocli-validatorforce-deaffiliate)
* [`celocli validator:list`](#celocli-validatorlist)
* [`celocli validator:register`](#celocli-validatorregister)
* [`celocli validator:requirements`](#celocli-validatorrequirements)
Expand Down Expand Up @@ -163,6 +164,41 @@ EXAMPLES

_See code: [src/commands/validator/downtime-slash.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/validator/downtime-slash.ts)_

## `celocli validator:force-deaffiliate`

Force deaffiliate a Validator from a Validator Group, and remove it from the Group if it is also a member. Used by stake-off admins in order to remove validators from the next epoch's validator set if they are down and consistently unresponsive, in order to preserve the health of the network. This feature will be removed once slashing for downtime is implemented.

```
USAGE
$ celocli validator:force-deaffiliate --from 0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d
--validator 0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d [--gasCurrency
0x1234567890123456789012345678901234567890] [--globalHelp]
FLAGS
--from=0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d (required) Initiator
--gasCurrency=0x1234567890123456789012345678901234567890 Use a specific gas currency
for transaction fees
(defaults to CELO if no gas
currency is supplied). It
must be a whitelisted token.
--globalHelp View all available global
flags
--validator=0xc1912fEE45d61C87Cc5EA59DaE31190FFFFf232d (required) Validator's
address
DESCRIPTION
Force deaffiliate a Validator from a Validator Group, and remove it from the Group if
it is also a member. Used by stake-off admins in order to remove validators from the
next epoch's validator set if they are down and consistently unresponsive, in order to
preserve the health of the network. This feature will be removed once slashing for
downtime is implemented.
EXAMPLES
force-deaffiliate --from 0x47e172f6cfb6c7d01c1574fa3e2be7cc73269d95 --validator 0xb7ef0985bdb4f19460A29d9829aA1514B181C4CD
```

_See code: [src/commands/validator/force-deaffiliate.ts](https://github.com/celo-org/developer-tooling/tree/master/packages/cli/src/commands/validator/force-deaffiliate.ts)_

## `celocli validator:list`

List registered Validators, their name (if provided), affiliation, uptime score, and public keys used for validating.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

#### Defined in

[wallets/wallet-base/src/signing-utils.ts:232](https://github.com/celo-org/developer-tooling/blob/master/packages/sdk/wallets/wallet-base/src/signing-utils.ts#L232)
[wallets/wallet-base/src/signing-utils.ts:240](https://github.com/celo-org/developer-tooling/blob/master/packages/sdk/wallets/wallet-base/src/signing-utils.ts#L240)

___

Expand All @@ -30,7 +30,7 @@ ___

#### Defined in

[wallets/wallet-base/src/signing-utils.ts:233](https://github.com/celo-org/developer-tooling/blob/master/packages/sdk/wallets/wallet-base/src/signing-utils.ts#L233)
[wallets/wallet-base/src/signing-utils.ts:241](https://github.com/celo-org/developer-tooling/blob/master/packages/sdk/wallets/wallet-base/src/signing-utils.ts#L241)

___

Expand All @@ -40,4 +40,4 @@ ___

#### Defined in

[wallets/wallet-base/src/signing-utils.ts:231](https://github.com/celo-org/developer-tooling/blob/master/packages/sdk/wallets/wallet-base/src/signing-utils.ts#L231)
[wallets/wallet-base/src/signing-utils.ts:239](https://github.com/celo-org/developer-tooling/blob/master/packages/sdk/wallets/wallet-base/src/signing-utils.ts#L239)
Loading

0 comments on commit f4d8d95

Please sign in to comment.