Accumulate
Search…
⌃K

CLI reference

All the commands available via the Command Line Tool are documented below

Lite Token Account/Lite Identity Creation

This command will generate a new account URL for you.
Syntax
./accumulate account generate
Command
./accumulate account generate
The above command will return an output similar to the following:
lite identity : 0143b52490530b90eef9b1a2405e322c6badc1e90e200c56
lite token account : acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME
public key : 03c633851507f63ef8517dc934075f2abe2f8c3b3053b5a49a477e8513e01955
key type : ed25519

Account List

This command will get the list of accounts.
Command
./accumulate account list
The above command will return an output similar to the following:
key name : 001846c0a1590675fd0ad816ab4873387ef127cd9b307c24
lite account : acc://001846c0a1590675fd0ad816ab4873387ef127cd9b307c24/ACME
public key : 3615e429b89fa3d6b636412d7a17b13cc321c14b2f2e5bf520868c9617401845
key type : legacyED25519
key name : 003df7b8b865b3eda520dbb224eaf7536ee98cc25874ce54
lite account : acc://003df7b8b865b3eda520dbb224eaf7536ee98cc25874ce54/ACME
public key : 45090e7cfa0edd52db7181fa0a30f1da8d2c0b1bdc6b4847de75fe922ad9e755
key type : ed25519

Faucet Transaction

The Test Faucet can be used to add test ACME tokens to a Lite Token Account. The Sponsor of the transaction is the Test Faucet address that holds Test ACME. (acc://7117c50f04f1254d56b704dc05298912deeb25dbc1d26ef6/ACME):
Syntax
accumulate faucet [url] Get tokens from faucet to address
Command
./accumulate faucet acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME
The above command will return an output similar to the following:
Transaction Hash : a0018d18c558c36f3f639fa1a64e2e9c47cc705fdf0d3f65a8ec8f0e0bd0f328
Signature 0 Hash : 78d521b36691c46216a66d6648dd620a9f6ec312a24b3b0f29a9889887f4953d
Simple Hash : ab039db9714e8a30b0443054dea78a36e754ead8ca50a6ab6e50adc62ef3d801
Error code : ok
Result :
The Transaction Hash is a hash of the transaction without signatures and the Signature Hash is the Transaction Hash with the Signature appended to it and hashed.

TX Get Transaction Hash (TXID)

To query a transaction by the transaction ID a tx get command is required
Syntax
accumulate tx get [txid] Get token transaction by txid
Command
accumulate tx get a0018d18c558c36f3f639fa1a64e2e9c47cc705fdf0d3f65a8ec8f0e0bd0f328
The above command will return an output similar to the following:
(type): Acme Faucet
Transaction Type: acme Faucet
Url: acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME
- Synthetic Transaction 0 : 8eb0088ec37e2fca37fd915aa2348e03b30c77e2b2abdcbc4ee7b94e6c532f2f

TX Get Signature Hash

To query the transaction hash from the Faucet account transaction:
Syntax
accumulate tx get [txid] Get token transaction by txid
Command
./accumulate tx get 78d521b36691c46216a66d6648dd620a9f6ec312a24b3b0f29a9889887f4953d
The above command will return an output similar to the following:
(type): Acme Faucet
Transaction Type: acme Faucet
Url: acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME
- Synthetic Transaction 0 : 8eb0088ec37e2fca37fd915aa2348e03b30c77e2b2abdcbc4ee7b
94e6c532f2f

Synthetic TX Get

To query the synthetic transaction from the Faucet Account transaction
Syntax
accumulate tx get [txid] Get token transaction by txid
Command
./accumulate tx get 8eb0088ec37e2fca37fd915aa2348e03b30c77e2b2abdcbc4ee7b94e6c532f2f
The above command will return an output similar to the following:
Receive 2000000.00000000 ACME to acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME (cause: A0018D18C558C36F3F639FA1A64E2E9C47CC705FDF0D3F65A8EC8F0E0BD0F328)
---
- Transaction : 8eb0088ec37e2fca37fd915aa2348e03b30c77e2b2abdcbc4ee7b94e6c532f2f
- Signer Url : acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME
- Signatures :
- Signer : acc://bvn-BVN0/validators/1 (keyPage)
- : synthetic
- : 739d02db90d8f4a979241d37aab8de104f7d967cfc29611e8664afb70006aa4e0b6d728c9d01a8481704e7a3a0b17ce15de6c7744d82508e9102ac3572cbdf0e (sig)
- : b4449beb71f752736e8223fae4a407037e3016e7e91d5b2dc60e87f5b2978cc4 (key hash)
- : receipt
- Signatures :
- Signer : acc://dn/validators/1 (unknownSigner)
- : receipt

Get Token Balance

The get token command will query the balance to check the token balance of a Lite Token Account. The Token URL in the output specifies the type of Token.
Syntax
accumulate get [url] Get data by Accumulate URL
Command
./accumulate get acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME
The above command will return an output similar to the following:
Account Url : acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME
Token Url : acc://ACME
Balance : 2000000.00000000 ACME

Key

A named key can be generated using the key generating function. This will also output the public key's name and key type. Unless specified otherwise, this will create an ed25519 key. If you are creating an ADI DO NOT use a key other than an ed25519 key. Support for this will be added in the future.
Syntax
./accumulate key generate [key name]
Command
./accumulate key generate keytest
The above command will return an output similar to the following:
name : keytest
lite account : acc://601b40a84a69f216173a457c44de5b942bf5aec62a7003ce/ACME
public key : 1ac021a5d6a1e457102019d5fd00cc04d3e9783a745905761d3fab96e9598c57
key type : ed25519

Bitcoin

This command will sign an Accumulate transaction using the Bitcoin signature algorithm
Syntax
./accumulate key generate --sigtype btc [keyname]
Command
./accumulate key generate --sigtype btc testbtc
The above command will return an output similar to the following:
name : testbtc
lite account : acc://321ec96337292b2a34b6b5c8c62f54f1d198465b0a00f35a/ACME
public key : 0396adeb7869b780606a8fe1218ebfb9c71e7e91ca72b1d95210717c3ed5f4dfd8
key type : btc

Bitcoin Legacy

This command will sign an Accumulate transaction using the Bitcoin signature algorithm
Syntax
./accumulate key generate --sigtype btclegacy [keyname]
Command
./accumulate key generate --sigtype btclegacy testbtclegacy
The above command will return an output similar to the following:
name : testbtclegacy
lite account : acc://95b9e649f8853e40c59aea635ef883100f014b85d57b75a6/ACME
public key : 040ea7496cd6f50c77230d89b9c9ca60bca1d078b06e0efba9c5f3068f8668d229a38fdb71105cb4beffe66958c9b46bec940296346c494a65263f1330c4340755
key type : btclegacy

Ethereum

This command will sign an Accumulate transaction using the Ethereum signature algorithm
Syntax
/accumulate key generate --sigtype eth [keyname]
Command
./accumulate key generate --sigtype eth testeth
The above command will return an output similar to the following:
name : testeth
lite account : acc://388acd64ebbabbf89f0c2b250fb181ef5dff5122b1448c87/ACME
public key : 041901c4486b91f82d16281d84031bd25baf2d61703a3c4caade2f5a844a6f73f2f1e2f80f995fa9db6ed794234eb5efdd44efad81a4b2bf6e14319bd74b55d588
key type : eth

Factom (RCD1)

This command will sign an Accumulate transaction using the Factom signature algorithm
Syntax
./accumulate key generate --sigtype RCD1 [keyname]
Command
./accumulate key generate --sigtype RCD1 testRCD1
The above command will return an output similar to the following:
name : testRCD1
lite account : acc://6a3956d856638d58757e0a47f24fa112876e664ffa322fa2/ACME
public key : 9f3d2d2604d8e50453f59d379c25c0fc5220d512a786f3c419947e6050e758a6
key type : rcd1

Key Import Mnemonic

This command imports the key using the mnemonic phrase
Syntax
accumulate key import mnemonic [mnemonic phrase...] Import the mnemonic phrase used to generate keys in the wallet
Command
./accumulate key import mnemonic decide trap aisle raise above wool excite funny tuna body choice stereo
The above command will return an output similar to the following:
mnemonic import successful

Key Import Factoid

This command imports the key using the mnemonic
Syntax
accumulate key import factoid [factoid private address] Import a factoid private address
Command
./accumulate key import factoid Fs23yok1z8ZsHtoMsWc1oMy76sKRgHF3jN6HLjoMQ9iMxYrnnkiL
The above command will return an output similar to the following:
name : FA2MSMBiyHmBLP1LDYAVWGRkkLpr64mMMi7N11hKchT6bAi926XW
lite account : acc://32c484ebfd344810353cb273d538166f3b4a9391486343d5/ACME
public key : aba7ecaa24874d13f272b87b7924bc4613a82904a98ef399f4b6d9a29e46a381
key type : rcd1

Key Import Lite

Syntax
accumulate key import lite [private key hex] Import a key as an anonymous address
Command
./accumulate key import lite ****************************
The above command will return an output similar to the following:
name : 4111d56848824a2d74ee93e2c42091f7019a87c7649b48fe
lite account : acc://4111d56848824a2d74ee93e2c42091f7019a87c7649b48fe/ACME
public key : 76324e43a382e6ff6a9724f8dae137b93f5d5a61a3eb9d6e5213739b656c5d44
key type : ed25519

Key Export All

Syntax
accumulate key export all
Command
./accumulate key export all
The above command will return an output similar to the following:
{
keys: [
{
name: 'f194af0eeb01ca0ffcf05918aa2328bb11c44b9d27d80ff4',
privateKey: '9272c3f03a182281efa8baf743fe4172216fd90e60c47c1cbe47bd36b51b08d90026e3420379dcc7f7eeeb1c61132ac4a1ecad95843bd255eb1b762e8c5e84b4',
publicKey: '0026e3420379dcc7f7eeeb1c61132ac4a1ecad95843bd255eb1b762e8c5e84b4',
keyInfo: [Object],
keyHash: 'f194af0eeb01ca0ffcf05918aa2328bb11c44b9d434887c9f1319c562af0d57e'
},
{
name: 'e4df9ccaab3e644788eac7361a8cc93caff5e9c2021eda10',
privateKey: '23834430ffa16cfe52ed79448259e058e21728c700695e6b4583f6843adbf614007486895d9cf3b5a9d945f615d1922bbd2e696a1b5dedcdeaa04e6aa2bdab14',
publicKey: '007486895d9cf3b5a9d945f615d1922bbd2e696a1b5dedcdeaa04e6aa2bdab14',
keyInfo: [Object],
keyHash: 'e4df9ccaab3e644788eac7361a8cc93caff5e9c2c28ac65ee5340f8f34af8787'
},
... 1158 more items
]
}

Key Export Private

Syntax
accumulate key export private [key name] export the private key by key name
Command
./accumulate key export private [key/label name]
The above command will return an output similar to the following:
./accumulate key export private dnkey
Password: ********
Name | dnkey
Private Key | 9a94cb8f45f6cbd4d421c07b491d9067dee6c9a72c73f923f90ff188c1d37030c1b5e95298e6817ac62cfbe792240025e9ce9c9644913a5e3c27c10516961721
Public Key | c1b5e95298e6817ac62cfbe792240025e9ce9c9644913a5e3c27c10516961721
Key Hash | 4b3684fb8fa25fa279d4b6fb6c4681999b92446eb5fca4a508f3a12a9c430f2e
Key Type | ed25519
Derivation | m/44'/281'/0'/0'/0'

Key Export Mnemonic

Syntax
accumulate key export mnemonic (export the mnemonic phrase if one was entered)
Command
./accumulate key export mnemonic
Password: ********
mnemonic phrase: cat laugh aunt question rib scrap picture axis cushion deposit door taste

Key Export Seed

Syntax
accumulate key export seed (export the seed generated from the mnemonic phrase)
Command
./accumulate key export seed
Password: ********
The above command will return an output similar to the following:
seed: ed542528af5bf865161314165b25bd106d98d7b57b372e7ac61bba767433bb6046c09f02c705b42153e2f95eef54b62981f2022dd8864b53b790d444cfd92756

Key Label

Syntax
accumulate key label [command]
Available Commands:
assign assign public key of existing label to a new label.
remove remove a key label
rename rename a key label to new label, note: the old key name will be replaced with the new key
name
Command (assign)
./accumulate key label assign test501 test505
Password: ********
The above command will return an output similar to the follow
Label(s) | test501
| test505
Lite Label | 612d6cd0ff886f95c9385c828cd8c3006de84d06617f20fa
Public Key | 936dc073a2694118a4e1d8b344b033d7a7fac0bdc981ef16f122e65be4967c16
Key Hash | 612d6cd0ff886f95c9385c828cd8c3006de84d06a2fd5474fed97f0d954a6215
Key Type | rcd1
Derivation | m/44'/131'/0'/0/3
Command (rename)
/accumulate key label rename test501 test599
Password: ********
The above command will return an output similar to the follow
Label(s) | test505
| test599
Lite Label | 612d6cd0ff886f95c9385c828cd8c3006de84d06617f20fa
Public Key | 936dc073a2694118a4e1d8b344b033d7a7fac0bdc981ef16f122e65be4967c16
Key Hash | 612d6cd0ff886f95c9385c828cd8c3006de84d06a2fd5474fed97f0d954a6215
Key Type | rcd1
Derivation | m/44'/131'/0'/0/3
Command (remove)
/accumulate key label remove test599
Password: ********
The above command will return an output similar to the follow
Label(s) | test505
Lite Label | 612d6cd0ff886f95c9385c828cd8c3006de84d06617f20fa
Public Key | 936dc073a2694118a4e1d8b344b033d7a7fac0bdc981ef16f122e65be4967c16
Key Hash | 612d6cd0ff886f95c9385c828cd8c3006de84d06a2fd5474fed97f0d954a6215
Key Type | rcd1
Derivation | m/44'/131'/0'/0

Wallet

Export - Export Wallet Details ./accumulate export "C:\filepath\myaccounts.json" Check the file path and open the json file to view its contents Init - Import secret factoid key from terminal input ./accumulate wallet init create ./accumulate wallet init import Enter mnemonic : Serve - run wallet service daemon
./accumulate wallet serve

Credits

To send ACME tokens to another account, you need to purchase credits with ACME and send them to a recipient.
Check this link to view the Base Fees for different transactions.
To send credits to your lite account or Key Page, run the example command in your terminal

Adding Credits to a Lite Token Account/Lite Identity.

This command adds credit to your lite token account/lite identity.
Syntax
accumulate credits [origin token account] [key page or lite identity url] [number of credits wanted] [max acme to spend] [percent slippage (optional)] [flags][BS2]
Command
./accumulate credits acc://f338762f7013acb0fd5e1480c20df47ff836862adbd6e0f1/ACME acc://f338762f7013acb0fd5e1480c20df47ff836862adbd6e0f1/ACME 10000
The above command will return an output similar to the following:
Transaction Hash : a743ab4412cc4ca8b08761e21d7bae7ddb2ed84e7e82a514a32e538eb5d79f08
Simple Hash : 7e43cfcdb1acbc1f1f43d266013b2d48463fd2e5263f3cac3b89e4b08a52d9aa
Error code : ok
Result : Oracle $0.05 / ACME
Credits 10000.00
Amount 2000.00000000 ACME
Use the TX History command to see prior transactions
This command gets the list of your transactions using a range of numbers.
Syntax
accumulate tx history [url] [starting transaction number] [ending transaction number] Get transaction history
Command
accumulate tx history acc://ec53ee9f68b7f712da6ef3a0c96583af547c8e2964684733/ACME 0 10
The above command will return an output similar to the following:
Transaction History Start: 0 Count: 1 Total: 28

Oracle

To explicitly query the oracle to see the current price of ACME and the number of credits per ACME:
Syntax
./accumulate oracle
Command
./accumulate oracle
The above command will return an output similar to the following:
USD per ACME : $0.0500
Credits per ACME : 5.00

Lite Data Accounts

Lite Data Accounts are an extension of the Factom Protocol, which will be used to transition data from Factom to Accumulate.

Lite Data Account Creation from Lite Token Account/Lite Identity

This command creates a new lite data account from a lite token account.
Syntax
account create data --lite [lite token account URL] [data (chain name)]
Command
./accumulate account create data --lite acc://f338762f7013acb0fd5e1480c20df47ff836862adbd6e0f1/ACME "Ben"
The above command will return an output similar to the following:
Account Url :acc://c26fd6ed6beafd197086c420bbc334f0cd4f05802b550e5d
Account Id :c26fd6ed6beafd197086c420bbc334f0cd4f0580a44dc689452b57b150d10e46
Entry Hash :cda19cfa7cc15bcf1ce2dea451c13a0f8a77e15fee6289c0839f4f176d357bce
Transaction Hash : 62f4c555e8d95b00a775337c54cac80ab6222d6bdf7c4f8eadc013830b9b1fc4
Signature 0 Hash : 89bfdd4619147eb32590cb83f8d05d73697f6f8a31a6961df3e0a8feaaa41b1e
Simple Hash : 05ea5c5b406964af4f4a5adc52d5c8ef6e5565ec9de21415847310e5e5980a40
Error code : ok
Result :

Lite Data Account Creation from ADI

This command creates a new lite data account from an ADI
Syntax
Account create data --lite [origin token account][signing key][extID]
Command
./accumulate account create data --lite acc://DefiDevs.acme Key2 "Marian"
The above command will return an output similar to the following:
Account Url :acc://7d27485702b1f756a7c0f6ac39931e77959f58d475ee3898
Account Id :7d27485702b1f756a7c0f6ac39931e77959f58d4598949d4fd9dfd8f98358c04
Entry Hash :071b9662b4c3512d4c0b3dbdd73fc092e155abe805aad3ec14a1183fb732b960
Transaction Hash : eac6868a7e756faca5e00e999efadec6967eab5c9b7b434b4c6160bda6e7a283
Signature 0 Hash : 31c2b9d9e9457dc484a3dc2260b20bc6d34f2876196fabc531279c6100145a1f
Simple Hash : d28c28d27ec764bcf3218c10abcdf69e23024461c102331e35cd221c0663580a
Error code : ok
Result :

Writing to a Lite Data Account

This command writes to an Accumulate lite data account
Syntax
accumulate data write-to [account url] [signing key][BS3] [lite data account] [extid_0 (optional)] ... [extid_n (optional)] [data]
Command
data write-to acc://0143b52490530b90eef9b1a2405e322c6badc1e90e200c56/ACME acc://7d27485702b1f756a7c0f6ac39931e77959f58d475ee3898 "Key6"
The above command will return an output similar to the following:
Account Url :acc://7d27485702b1f756a7c0f6ac39931e77959f58d475ee3898
Account Id :7d27485702b1f756a7c0f6ac39931e77959f58d4598949d4fd9dfd8f98358c04
Entry Hash :185f8db32271fe25f561a6fc938b2e264306ec304eda518007d1764826381969
Transaction Hash : f27277b07e66883c836a72020d50e57cc8c1e86f24307ac99e2a4c035f6f8973
Signature 0 Hash : 0b4fbe4878374e5dd7aafb10dbe23f141998dd3603ee35dd930102f80cc256cf
Simple Hash : e8b203831aa0de000a9e26e60c44d8167c272d2e53dcb99c0785dfd7bd6ede15
Error code : ok
Result :

Querying a Lite Data Account by URL

This command **** returns a lite data account by url.
Syntax
accumulate data get [DataAccountURL] Get most current data entry by URL
Command
./accumulate data get acc://7d27485702b1f756a7c0f6ac39931e77959f58d475ee3898
The above command will return an output similar to the following:
{"type":"dataEntry","mainChain":{"height":2,"count":2,"roots":["04b097c244655110e76f77dfeaf39910af96d4c651037c05cdc841872f53d11a","8e70b62e509e6f037b69f205a8355c0586ce7e26457411d781dfe8de0eecedc7"]},"data":{"entry":{"data":["48656c6c6f"]},"entryHash":"f522210a71e681a1f7f40d005322dc36fb6bcbe915889dd9f1aa78147703ee38"},"chainId":"a2bd8fbd9b14eef22f157079cb3a99067d87fd3b9923e423fdf051e55d116a01"}

Querying a Lite Data Account by URL and a Specific Entry Hash

This command returns a lite data account by using the url and entryhash.
Syntax
accumulate data get [DataAccountURL] [EntryHash] Get data entry by entryHash in hex
Command
./accumulate data get acc://7d27485702b1f756a7c0f6ac39931e77959f58d475ee3898 071b9662b4c3512d4c0b3dbdd73fc092e155abe805aad3ec14a1183fb732b960
The above command will return an output similar to the following:
{"type":"dataEntry","mainChain":{"height":2,"count":2,"roots":["04b097c244655110e76f77dfeaf39910af96d4c651037c05cdc841872f53d11a","8e70b62e509e6f037b69f205a8355c0586ce7e26457411d781dfe8de0eecedc7"]},"data":{"entry":{"data":["","4d617269616e"]},"entryHash":"071b9662b4c3512d4c0b3dbdd73fc092e155abe805aad3ec14a1183fb732b960"},"chainId":"a2bd8fbd9b14eef22f157079cb3a99067d87fd3b9923e423fdf051e55d116a01"}

Querying a Lite Data Account by URL and Index

This command returns a lite data account by using the url and index.
Syntax
accumulate data get [DataAccountURL] [start index] [count] expand(optional) Get a set of data entries starting from start and going to start+count, if "expand" is specified, data entries will also be provided
Command
./accumulate data get acc://7d27485702b1f756a7c0f6ac39931e77959f58d475ee3898 0 2
The above command will return an output similar to the following:
{"type":"dataSet","items":[{"entry":{},"entryHash":"071b9662b4c3512d4c0b3dbdd73fc092e155abe805aad3ec14a1183fb732b960"},{"entry":{},"entryHash":"f522210a71e681a1f7f40d005322dc36fb6bcbe915889dd9f1aa78147703ee38"}],"start":0,"count":2,"total":2}

ADI Creation from a Lite Token Account:

This command creates an ADI from a lite token account.
Syntax
accumulate adi create [origin-lite-account] [adi url to create] [public-key or key name] [key-book-name (optional)] [public key page 1 (optional)] Create new ADI from lite token account.
When public-key one is specified, it will be assigned to the first page. Otherwise, the origin key is used.
Command
./accumulate adi create acc://f338762f7013acb0fd5e1480c20df47ff836862adbd6e0f1/ACME acc://DefiDevs.acme Key1 acc://DefiDevs.acme/Keybook
The above command will return an output similar to the following:
Transaction Hash : 1139db355819257a618129641464b145e8a4d0fdab301507f7c0ebbcd9185105
Signature 0 Hash : cf3dbe8c63b9f31b5a506de03cf758393e1db6c71e039b7c528d7651b9128b8c
Simple Hash : a08ab66047f800ce11e0654bae6b584d085fd594c70c225a3aa87cbd9e0bc597
Error code : ok
Result :

ADI Creation from an ADI

This command creates ADI from another ADI.
Syntax
accumulate adi create [origin-adi-url] [wallet signing key name] [key index (optional)] [key height (optional)] [adi url to create] [public key or wallet key name] [key book url (optional)] [public key page 1 (optional)] Create new ADI for another ADI
Command
./accumulate adi create acc://DefiDevs.acme Key2 acc://Toyota Key2 acc://Toyota/Keybook
The above command will return an output similar to the following:
Transaction Hash : 00038a5fd818006ac01089f8aea782b846722bec150a333dfc77356a277e60bf
Signature 0 Hash : 5c64193d64950c2bee4873feb557d477ca0590fd37e4b0b4ad817a5fdd1fcdb4
Simple Hash : 032d354fc6b03036f00cb5cfdf2674705a2e5f0f2f99896b9ceea48e77feaad9
Error code : ok
Result :
ADIs can also be created using the following accounts as principals for the transaction: ADI Data Account, ADI Token Account, ADI Token Issuance, and a Sub-ADI and its Accounts.

ADI Creation from a Sub-ADI

This command creates ADI from a sub-ADI.
Syntax
accumulate adi create [origin-adi-url] [wallet signing key name] [key index (optional)] [key height (optional)] [adi url to create] [public key or wallet key name] [key book url (optional)] [public key page 1 (optional)] Create new ADI for another ADI
Command
./accumulate adi create acc://DefiDevs.acme/Robot Key2 acc://Ford.acme Key2 acc://Ford.acme/Keybook
The above command will return an output similar to the following:
Transaction Hash : e3fa9f05a4eb736dbaac58594fdcfb1478098555d7c27c315a4595a38aabdd5e
Signature 0 Hash : c00282900903ddf18f7ca2fcbe09bd2971d48d8364516e45d9f7069ecb1db7b7
Simple Hash : 23c66ccbe1bba178b553c87582595d2710e7e97d85528c96c37d5ae07ebfebe3
Error code : ok
Result :

ADI Creation from a Sub-Sub-ADI

This command creates ADI from a sub-sub-ADI.
Syntax
accumulate adi create [origin-adi-url] [wallet signing key name] [key index (optional)] [key height (optional)] [adi url to create] [public key or wallet key name] [key book url (optional)] [public key page 1 (optional)] Create new ADI for another ADI
Command
./accumulate adi create acc://DefiDevs.acme/Robot/MrRoboto Key2 acc://Ferrari Key2 acc://Ferrari/Keybook
The above command will return an output similar to the following:
Transaction Hash : a203c790287deb440c2fb1abeaab92131ea0ce4deaeb1d2c448bf2ba92b9dac6
Signature 0 Hash : e095e22c1e20d89f0b741332200d647febc86369826f3c65000e842f99cbef35
Simple Hash : f4509afb159a11ece81f89395f512e9f0bf40b16c0a007140b8606dd6ba23f93
Error code : ok
Result :

ADI Directory

This command returns the list of your ADI directory.
Syntax
accumulate adi directory [url] [from] [to] [flags]
Command
./accumulate adi directory acc://DefiDevs.acme 0 20
The above command will return an output similar to the following:
ADI Entries: start = 0, count = 20, total = 11
acc://DefiDevs.acme/Keybook (Key Book)
acc://DefiDevs.acme/Tokens (ADI Token Account)
acc://DefiDevs.acme/Data (Data Chain)
acc://DefiDevs.acme/ScratchData (Data Chain)
acc://DefiDevs.acme/Keybook2 (Key Book)
acc://DefiDevs.acme/Car (ADI)
acc://DefiDevs.acme/Robot (Sub-ADI)
acc://DefiDevs.acme/Cybertruck (Sub-ADI)
acc://DefiDevs.acme/AI (tokenIssuer)
acc://DefiDevs.acme/AITokens (ADI Token Account)

ADI List

To see a list of ADIs created and the initial Key specified for Key Page 1

ADI Get

An ADI get returns the ADI URL, as well as the Key Book, generated during the creation of the ADI.
Syntax
accumulate adi get [url] [flags]
Command
./accumulate adi get acc://DefiDevs.acme
The above command will return an output similar to the following:
ADI url : acc://DefiDevs.acme
Key Book Url : acc://DefiDevs.acme/Keybook

Key Books

The Key Books store an ADI's Hierarchical Key Management Structure using Key Pages and Keys within those pages.

Get Key Book

This command returns the list of keybook
Syntax
accumulate get [url] Get data by Accumulate URL
Command
./accumulate get acc://DefiDevs.acme/Keybook/
The above command will return an output similar to the following:
Page Count
2
get Deprecated - use `accumulate get ...` fix in CLI

Create an Additional Key Book

An ADI can have multiple Key Books. To create an additional Key Book, a Public Key Hash or Key Book URL must be specified for the purpose of signing the transaction. A new public key or key name should be added to the new book.
Syntax
accumulate book create [origin adi url] [signing key name] [key index (optional)] [key height (optional)] [new key book url] [public key 1 (optional)] ... [public key hex or name n + 1 [flags]
Command
./accumulate book create acc://DefiDevs.acme Key1 acc://DefiDevs.acme/Keybook2 Key3
The above command will return an output similar to the following:
Transaction Hash : c168ecfb3985a88f694666b0ed19f8e24b6451eb412da788f1068694a24e4a24
Signature 0 Hash : 0c023834a44520f396470c0db58404db94330aee7189a78073463d017d2736a1
Simple Hash : 48f0c4a86d6c1d45e8de4d718370aa6481da9f09c853f53135b5858de85d976c
Error code : ok
Result :

Key Pages

A Key Page has entries that define the parties required to sign a transaction. If you have the same Key in multiple Key Pages you must explicitly specify the page using [email protected]/book/(page number).

Get Key Page

This command returns the list of key pages.
Syntax
accumulate get [url] Get data by Accumulate URL
Command
./accumulate get acc://DefiDevs.acme/Keybook/1
The above command will return an output similar to the following:
Credit Balance : 0.00
Index Nonce Public Key Key Name(s)
0 1969-12-31 19:00:00 -0500 EST fa9ae1e76b6936583546d495c98f34a9f0d57b52f759b4ebf1f04e6db0111381 Key3
1 1969-12-31 19:00:00 -0500 EST c3781e20dd3dbaade511587e4b153efc86e2194111a07091a0e6159d7699c513 Key4
2 1969-12-31 19:00:00 -0500 EST 0d83eababd1ba323f69470576f8c9eb563821a07cca55f5ac30f276cf62bebc4 Key1

Adding Credits to a Key Page

An ACME token account must be referenced when adding credits to a Key Page. This can either be a Lite Token Account or an ADI Token Account.
Syntax
accumulate credits [origin token account] [key page or lite identity url] [number of credits wanted] [max acme to spend] [percent slippage (optional)] [flags]
Command
./accumulate credits acc://f338762f7013acb0fd5e1480c20df47ff836862adbd6e0f1/ACME acc://DefiDevs.acme/Keybook/1 10000
The above command will return an output similar to the following:
Transaction Hash : 7bba5f1178d71193a91641ad627d8d232b88f4f0a37cb855bef5afa1b741aa1a
Simple Hash : 00da35f2201a5a6143375d9225188ac49f1129c7c748bd7f6c0f2d218eb85b2a
Result : Oracle $0.05 / ACME
Credits 10000.00
Amount 2000.00000000 ACME

Adding Additional Key Pages to a Key Book

A new Key Page can be added to a Key Book where public keys or key names can be specified. In the example below 3 keys were added to the new Key Page (Key1, Key3, and Key4. Due to this being the 2nd Key Page, the Key Page URL would be acc:/DefiDevs.acme/Keybook/2.
Syntax
accumulate page create [origin key book url] [key name[@key book or page]] [public key 1] ... [public key hex or name n + 1] [flags]
Command
./accumulate page create acc://DefiDevs.acme/Keybook Key1 Key3 Key4
The above command will return an output similar to the following:
Signature 0 Hash : dee40ebb838385eb43c78edd325cf4ad1c54c4e68dd73e8b4454348aea8a849b
Simple Hash : cb61cd5f34b2785da2763ac8ca773c2c19a60410f734bb7cb230fd8bc4fc009f
Error code : ok
Result :

Adding a Key

Syntax
accumulate page key add [key page url] [signing key name] [key index (optional)] [key height (optional)] [new key name] [flags]
Command
./accumulate page key add acc://DefiDevs.acme/Keybook/1 Key1 Key2
The above command will return an output similar to the following:
Transaction Hash : 9fbcbe49b4dbbf861be63eeae41576f1da7b7ca3b31e1c3968adff766b0445c2
Signature 0 Hash : 99f87aa951585592d66a56e670b083c8a4f10de0fd014a72b2d05fa901546dde
Simple Hash : f4f7e5e0d8b5599aad214412939f954b4bf012b8f5ac9a56d24d54983f185d3d
Error code : ok
Result :

Query Page

A get command will query the Key Page to show the new key that has been added.
Syntax
accumulate get [url] Get data by Accumulate URL
Command
./accumulate get acc://DefiDevs.acme/Keybook/1
The above command will return an output similar to the following:
Credit Balance : 9997.00
Index Nonce Public Key Key Name(s)
0 1969-12-31 19:00:00 -0500 EST 272b7a64c2caf76ffe6cf0adf37a144aff60920bdc269803982f150802053afb Key1
1 1969-12-31 19:00:00 -0500 EST f619aa889a2532d2d331d8a1287895b87605d7a5a1c75ad671f9bb6a7628940c Key2

Removing a Key

This command removes a key from a keypage.
Syntax
accumulate page key remove [key page url] [signing key name] [key index (optional)] [key height (optional)] [old key name] [flags]
Command
./accumulate page key remove acc://DefiDevs.acme/Keybook/1 Key2 Key2
The above command will return an output similar to the following:
Transaction Hash : c237853496f3348e8dd9fc847bb692608a1d9ed95236d351908203691951b749
Signature 0 Hash : ecb1aa735f8473d8d0b0194549d9ec94be520b1ee6c24e4846b0b7b122ebf932
Simple Hash : 5355696f77cfc89d0f5b3be90dccb66e7f337af303d2c66129de8c8ba5b02aed
Error code : ok
Result :

Updating a Key of another party

This command updates a key in a key page and requires the page threshold to be met.
Syntax
accumulate page key update [key page url] [signing key name] [key index (optional)] [key height (optional)] [old key name] [new public key or name] [flags]
Command
./accumulate page key update acc://DefiDevs.acme/Keybook/1 Key1 Key1 Key2
The above command will return an output similar to the following:
Transaction Hash : f5b4ab98ff3b322bf513376acaad748d65847408c6b3e10909e32bd1c81401d9
Signature 0 Hash : d9e3c4786353b89d1fa7bca22e2e317f2e4071e195e86f6f2bfd409d0516cb63
Simple Hash : ffe7d185949a7322333a485590c8976fc1dd66855f7fc973dfae084f1afb455a
Error code : ok

Updating your own Key

This command updates your own key in a key page and doesn't require the page threshold to be met.
./accumulate page key replace directorynetwork.acme/book/1 dnkey hello
Transaction Hash : e1a36e712b0bb6c2335d0c03dbb2e8238dcbe7f25e07ede3f419d19af5adc981
Signature 0 Hash : db932235913e8f6d4d8bd5c0299f31bc4878e878878ab494f2b24279a022ffc3
Simple Hash : b32974949f5f81b2fffe6f6e04b5700db4ad5d1192970db3c5976b9a53dea884
Error code : ok
Result :
Transaction Hash : e1a36e712b0bb6c2335d0c03dbb2e8238dcbe7f25e07ede3f419d19af5adc981
Signature 0 Hash : db932235913e8f6d4d8bd5c0299f31bc4878e878878ab494f2b24279a022ffc3
Simple Hash : b32974949f5f81b2fffe6f6e04b5700db4ad5d1192970db3c5976b9a53dea884
Error code : ok
Result :

Locking/Unlocking a Key page

This command is used to lock a Key page. This prevents "update" operation to a key page.
Syntax
accumulate page lock [key page url] [key name[@key book or page]] [flags]
Command
./accumulate page lock acc://RajagopalIndia456.acme/book/3 [email protected]/book/1
Output
Transaction Hash : 4d0b16c471a19d7abcc2173ca5b268c28283a0e3c0764d776fdfbd1259aa1310
Signature 0 Hash : eb59b97b4a084f07205602a5dbe3fccf7ff7911e6f40540b627737fcc1dccd44
Simple Hash : 151016ca9c69c73cd0c36f0094350104bfabd6cda7d6edf63573c39326c1839f
Error code : ok
Result :
To verify a locked key page
To verify the locked key page, retrieve the value of key page. The following entry should be present in output.
"transactionBlacklist":["updateKeyPage"]
./accumulate.exe get acc://RajagopalIndia456.acme/book/3 -j
{"chainId":"1827174d2c721b93eb85c867fdf2dacadf75b9118cd702bcd4e831978de43f8c","chains":[{"count":41,"height":41,"name":"main","roots":["4d0b16c471a19d7abcc2173ca5b268c28283a0e3c0764d776fdfbd1259aa1310",null,null,"cc592302f8b7e438aebab91abf97e88b0a3f77e34f0a3264a7244c72bfb6b717",null,"4ba548e009f93ef4f2cffbbc2c6c251f3afbae95facbcac4547f03d41431c46f"],"type":"transaction"},{"count":41,"height":41,"name":"main-index","roots":["012802c5ae03039ea8aa01200000000000000000000000000000000000000000",null,null,"46ce7e00434dcf5b35ae6f269b144f353829224e295f0f8f3cf05d60afd715b3",null,"c65ed6c7442a1d5826ba41a4f8685ee492d36ff7321c18f481e7cebbd7caa59b"],"type":"index"},{"count":37,"height":37,"name":"signature","roots":["eb59b97b4a084f07205602a5dbe3fccf7ff7911e6f40540b627737fcc1dccd44",null,"7ba62d5dd3593010efb1a8a3d0d35c7b29f9fb814451eae2247fccca62b3bd76",null,null,"e146cca3dade29f26b8cda0bcbd9ed8f86b896bbb53cd3f0c43ca23449f619f1"],"type":"transaction"}],"data":{"acceptThreshold":1,"creditBalance":9700,"keyBook":"acc://RajagopalIndia456.acme/book","keys"[{"publicKey":"3ebc9b367208e1834afc5a9819ca6ab54d84e2a529a76267d02594f5fe118db0","publicKeyHash":"3ebc9b367208e1834afc5a9819ca6ab54d84e2a529a76267d02594f5fe118db0"},{"publicKey":"40d2648776279fcefd975ecda62d06cd7204952d8637b5dc0d6cd2115bc34df9","publicKeyHash":"40d2648776279fcefd975ecda62d06cd7204952d8637b5dc0d6cd2115bc34df9"},{"publicKey":"4af9d6740c30b7cab4c3639bf4ffa0aedbc38db41978818d8e268fc4f4c29c9c","publicKeyHash":"4af9d6740c30b7cab4c3639bf4ffa0aedbc38db41978818d8e268fc4f4c29c9c"},{"publicKey":"51bc346a606cfa7de2834f04a6c69d560e47257a78b5f12caaa338605ae8d37d","publicKeyHash":"51bc346a606cfa7de2834f04a6c69d560e47257a78b5f12caaa338605ae8d37d"}],"threshold":1,"transactionBlacklist":["updateKeyPage"],"type":"keyPage","url":"acc://RajagopalIndia456.acme/book/3","version":38},"mainChain":{"count":41,"height":41,"roots":["4d0b16c471a19d7abcc2173ca5b268c28283a0e3c0764d776fdfbd1259aa1310",null,null,"cc592302f8b7e438aebab91abf97e88b0a3f77e34f0a3264a7244c72bfb6b717",null,"4ba548e009f93ef4f2cffbbc2c6c251f3afbae95facbcac4547f03d41431c46f"]},"merkleState":{"count":41,"height":41,"roots":["4d0b16c471a19d7abcc2173ca5b268c28283a0e3c0764d776fdfbd1259aa1310",null,null,"cc592302f8b7e438aebab91abf97e88b0a3f77e34f0a3264a7244c72bfb6b717",null,"4ba548e009f93ef4f2cffbbc2c6c251f3afbae95facbcac4547f03d41431c46f"]},"type":"keyPage"}
This command is used to unlock a Key page.
Syntax
accumulate page unlock [key page url] [key name[@key book or page]] [flags]
Command
./accumulate page unlock acc://RajagopalIndia456.acme/book/3 [email protected]/book/1
Output
Transaction Hash : 40c3de4f3688b9a9aa993537196b9f6e221fadb2137305f419a4f789f75a877f
Signature 0 Hash : 5ae4def21f0387606bc6cac36f149aa85747ce916096bc74787e3c446d1dd92b
Simple Hash : 550a22a7dd0d536787581840f3710ab7a317157858c1bd7d75e01d97c1bb5946
Error code : ok
Result :

Setting a Threshold for a Key Page

By default, setting a threshold for a Key Page, the m of n will be 1 of 1. Because of this, any entry within the Key Page can update the signature threshold. In the example below, the number of Keys within acc://DefiDevs.acme/Keybook/2 is 3. Setting the threshold at two means that 2 of 3 signatures are required for the transaction to be processed.
Syntax
accumulate tx execute [origin url] [signing key name] [key index (optional)] [key height (optional)] [payload]
Command
./accumulate tx execute acc://DefiDevs.acme/Keybook/2 Key1 '{\"type\": \"updateKeyPage\", \"operation\": [{ \"type\": \"setThreshold\", \"threshold\": 2 }]}'
The above command will return an output similar to the following:
Transaction Hash : 6130d09c7b8bc2ffbdf82f13b9a0a4b5144bc2878523e899549ed732c9829f22
Signature 0 Hash : 2990a1ee1894494859162ed9d6772454a55a8737960fcaa09e7f6d150c8ef944
Simple Hash : 881275aea93bd90879f8f8d6c4d7d479ccffdc18b31f89538c752f67b77b0368
Error code : ok
Result :

Multi-Signature Transactions

A multi-signature transaction is defined by the signature threshold for a given Key Page. As a note, to sign with multiple keys at once you can add the --sign-with flag with a list of keys to a transaction.
Multi-Signature Transactions
A multi-signature transaction is defined by the signature threshold for a given Key Page. In the following examples, a new Key will be added to a Key Page using a multi-signature transaction.
Syntax
accumulate page key add [key page url] [signing key name] [key index (optional)] [key height (optional)] [new key name] [flags]
Command
./accumulate page key add acc://DefiDevs.acme/Keybook/2 Key5 Key1
The above command will return an output similar to the following:
Transaction Hash : 72fb5fcdecbf8b30182e20eaeb4d218f13163fe15b2ff6543f8be7ea2d4a78e6
Signature 0 Hash : de3f985a3569b3537c591353db6a15a385578967b7ddc28910f6779bebce4cf3
Simple Hash : 8961c92b3adeadaae13eba36e935808d723c33806bc421937159d0a9498b33c6
Error code : ok
Result :

Pending Transaction

A pending transaction can be queried to see the status.
Syntax
./accumulate tx pending [txid]
Command
./accumulate tx pending 72fb5fcdecbf8b30182e20eaeb4d218f13163fe15b2ff6543f8be7ea2d4a78e6
The above command will return an output similar to the following:
Pending Tranactions -> Start: 0 Count: 1 Total: 1

Sign Transaction Hash

The second signer signs the transaction hash of the first transaction in the multi-signature sequence. If there are additional signers, they sign the same transaction hash.
Syntax
./accumulate tx sign [key page url] [signing key name] [txid]
Command
./accumulate tx sign acc://DefiDevs.acme/Keybook/2 Key3 72fb5fcdecbf8b30182e20eaeb4d218f13163fe15b2ff6543f8be7ea2d4a78e6
The above command will return an output similar to the following:
Transaction Hash : 72fb5fcdecbf8b30182e20eaeb4d218f13163fe15b2ff6543f8be7ea2d4a78e6
Signature 0 Hash : de79633b1ceced2652f29f7fcb813190c19d175dd1846e76b3e233da66252666
Simple Hash : c87ef41af1233a666e9a833f50ee030ddcca08a1adaab76904846489220f3b8b
Error code : ok