Skip to content

Commit

Permalink
Bringing docs to parity
Browse files Browse the repository at this point in the history
  • Loading branch information
tjayrush committed Oct 18, 2022
1 parent 659b1b0 commit 37f8ffe
Show file tree
Hide file tree
Showing 9 changed files with 108 additions and 80 deletions.
56 changes: 40 additions & 16 deletions content/api/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ info:
license:
name: GPL 3.0
url: http://www.gnu.org/licenses/
version: 0.40.1-beta
version: 0.41.0-beta
description: >
A REST layer over the TrueBlocks application. With `chifra serve`, you can
Expand Down Expand Up @@ -597,14 +597,6 @@ paths:
explode: true
schema:
type: boolean
- name: collections
description: display collections data
required: false
style: form
in: query
explode: true
schema:
type: boolean
- name: tags
description: export the list of tags and subtags only
required: false
Expand Down Expand Up @@ -658,7 +650,7 @@ paths:
"symbol": "LBA",
"source": "On chain",
"decimals": 18,
"description": "Decentralized lending infrastructure facilitating open access to credit networks on Ethereum.",
"petname": "actively-happy-mite",
},
]
"400":
Expand Down Expand Up @@ -830,6 +822,19 @@ paths:
explode: true
schema:
type: boolean
- name: flow
description: >
for the uniq and apps options only, export only from or to (including trace from or to)
required: false
style: form
in: query
explode: true
schema:
type: string
enum:
- from
- to
- reward
- name: logs
description: display only the logs found in the block(s)
required: false
Expand Down Expand Up @@ -958,6 +963,18 @@ paths:
explode: true
schema:
type: boolean
- name: flow
description: >
for the uniq option only, export only from or to (including trace from or to)
required: false
style: form
in: query
explode: true
schema:
type: string
enum:
- from
- to
- name: reconcile
description: reconcile the transaction as per the provided address
required: false
Expand Down Expand Up @@ -1310,7 +1327,7 @@ paths:
description: Retrieve token balance(s) for one or more addresses at given block(s).
operationId: chainstate-tokens
parameters:
- name: addrs2
- name: addrs
description: >
two or more addresses (0x...), the first is an ERC20 token, balances for the rest are reported
required: true
Expand Down Expand Up @@ -1420,7 +1437,6 @@ paths:
enum:
- index
- monitors
- collections
- names
- abis
- caches
Expand Down Expand Up @@ -2012,10 +2028,10 @@ components:
format: uint64
example: 18
description: "number of decimals retrieved from an ERC20 smart contract, defaults to 18"
description:
petname:
type: string
example: "any test"
description: "user supplied description for the address"
example: "ideally-known-locust"
description: "the petname such as described here http://www.erights.org/elib/capability/pnml.html"
deleted:
type: boolean
description: "`true` if deleted, `false` otherwise"
Expand Down Expand Up @@ -2240,6 +2256,10 @@ components:
format: blknum
example: 354
description: "the zero-indexed position of this log relative to the block"
transactionHash:
type: string
format: hash
description: "the hash of the transction"
timestamp:
type: number
format: timestamp
Expand Down Expand Up @@ -2282,6 +2302,10 @@ components:
format: blknum
example: 10021
description: "the number of the block"
timestamp:
type: number
format: timestamp
description: "the timestamp of the block"
transactionHash:
type: string
format: hash
Expand Down Expand Up @@ -2487,7 +2511,7 @@ components:
type: string
format: address
example: "0xa1e4...63b4"
description: "description: the address of the token contract being queried"
description: "the address of the token contract being queried"
name:
type: string
example: "The DAO Original"
Expand Down
32 changes: 16 additions & 16 deletions content/data-model/accounts.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: "Accounts"
description: ""
lead: ""
date: 2022-05-02T07:09:41
date: 2022-10-16T07:34:11
lastmod:
- :git
- lastmod
Expand Down Expand Up @@ -156,21 +156,21 @@ The following commands produce and manage names:

Name data is made of the following data fields:

| Field | Description | Type |
| ----------- | ----------------------------------------------------------------------------------- | ------- |
| tags | colon separated list of tags | string |
| address | the address associated with this name | address |
| name | the name associated with this address (retrieved from on-chain data if available) | string |
| symbol | the symbol for this address (retrieved from on-chain data if available) | string |
| source | user supplied source of where this name was found (or on-chain if name is on-chain) | string |
| decimals | number of decimals retrieved from an ERC20 smart contract, defaults to 18 | uint64 |
| description | user supplied description for the address | string |
| deleted | `true` if deleted, `false` otherwise | bool |
| isCustom | `true` if the address is a custom address, `false` otherwise | bool |
| isPrefund | `true` if the address was one of the prefund addresses, `false` otherwise | bool |
| isContract | `true` if the address is a smart contract, `false` otherwise | bool |
| isErc20 | `true` if the address is an ERC20, `false` otherwise | bool |
| isErc721 | `true` if the address is an ERC720, `false` otherwise | bool |
| Field | Description | Type |
| ---------- | ----------------------------------------------------------------------------------- | ------- |
| tags | colon separated list of tags | string |
| address | the address associated with this name | address |
| name | the name associated with this address (retrieved from on-chain data if available) | string |
| symbol | the symbol for this address (retrieved from on-chain data if available) | string |
| source | user supplied source of where this name was found (or on-chain if name is on-chain) | string |
| decimals | number of decimals retrieved from an ERC20 smart contract, defaults to 18 | uint64 |
| petname | the petname such as described here http://www.erights.org/elib/capability/pnml.html | string |
| deleted | `true` if deleted, `false` otherwise | bool |
| isCustom | `true` if the address is a custom address, `false` otherwise | bool |
| isPrefund | `true` if the address was one of the prefund addresses, `false` otherwise | bool |
| isContract | `true` if the address is a smart contract, `false` otherwise | bool |
| isErc20 | `true` if the address is an ERC20, `false` otherwise | bool |
| isErc721 | `true` if the address is an ERC720, `false` otherwise | bool |


## ListStats
Expand Down
4 changes: 3 additions & 1 deletion content/data-model/chaindata.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: "Chain data"
description: ""
lead: ""
date: 2022-05-02T07:09:41
date: 2022-10-12T06:16:36
lastmod:
- :git
- lastmod
Expand Down Expand Up @@ -130,6 +130,7 @@ Log data is made of the following data fields:
| blockNumber | the number of the block | blknum |
| transactionIndex | the zero-indexed position of the transaction in the block | blknum |
| logIndex | the zero-indexed position of this log relative to the block | blknum |
| transactionHash | the hash of the transction | hash |
| timestamp | the timestamp of the block this log appears in | timestamp |
| address | the smart contract that emitted this log | address |
| topics | The first topic hashes event signature of the log, up to 3 additional index parameters may appear | CTopicArray |
Expand All @@ -156,6 +157,7 @@ Trace data is made of the following data fields:
| ---------------- | --------------------------------------------------------- | ------------ |
| blockHash | The hash of the block containing this trace | hash |
| blockNumber | the number of the block | blknum |
| timestamp | the timestamp of the block | timestamp |
| transactionHash | the transaction's hash containing this trace | hash |
| transactionIndex | the zero-indexed position of the transaction in the block | blknum |
| traceAddress | a particular trace's address in the trace tree | CStringArray |
Expand Down
4 changes: 2 additions & 2 deletions content/data-model/chainstate.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: "Chain state"
description: ""
lead: ""
date: 2022-02-10T20:02:12
date: 2022-10-16T07:55:33
lastmod:
- :git
- lastmod
Expand Down Expand Up @@ -77,7 +77,7 @@ Token data is made of the following data fields:
| ---------- | ------------------------------------------------------------ | ------- |
| holder | the address for which we are reporting the token balance | address |
| balance | the balance at the address at the given block height | wei |
| address | description: the address of the token contract being queried | address |
| address | the address of the token contract being queried | address |
| name | the name of the token contract, if available | string |
| symbol | the symbol for this token contract | string |
| decimals | the number of decimals for the token contract | uint64 |
Expand Down
37 changes: 18 additions & 19 deletions content/docs/chifra/accounts.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: "Accounts"
description: ""
lead: ""
date: 2022-08-31T06:48:48
date: 2022-10-08T19:54:08
lastmod:
- :git
- lastmod
Expand Down Expand Up @@ -40,7 +40,7 @@ Arguments:
Flags:
-U, --count display only the count of records for each monitor
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
Expand Down Expand Up @@ -90,13 +90,13 @@ Flags:
--emitter strings for log export only, export only logs if emitted by one of these address(es)
--topic strings for log export only, export only logs with this topic(s)
--asset strings for the statements option only, export only reconciliations for this asset
--flow string for the statements option only, export only statements with incoming value or outgoing value
-f, --flow string for the statements option only, export only statements with incoming value or outgoing value
One of [ in | out | zero ]
-y, --factory scan for contract creations from the given address(es) and report address of those contracts
-u, --unripe export transactions labeled upripe (i.e. less than 28 blocks old)
-F, --first_block uint first block to process (inclusive)
-L, --last_block uint last block to process (inclusive)
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
Expand Down Expand Up @@ -137,7 +137,7 @@ Flags:
--remove remove a previously deleted monitor
--watch continually scan for new blocks and extract data for monitored addresses
-s, --sleep float seconds to sleep between monitor passes (default 14)
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
Expand All @@ -154,7 +154,7 @@ Notes:

Like `chifra abis`, this tool is useful from the command line but is primarily used in support of other tools, especially `chifra export` where naming addresses becomes the single best way to turn unintelligible blockchain data into understandable information.

The various options allow you to search and filter the results. The `collections` and `tags` options are used primarily by the TrueBlocks explorer.
The various options allow you to search and filter the results. The `tags` option is used primarily by the TrueBlocks explorer.

You may use the TrueBlocks explorer to manage (add, edit, delete) address-name associations.

Expand All @@ -169,18 +169,17 @@ Arguments:
terms - a space separated list of one or more search terms (required)
Flags:
-e, --expand expand search to include all fields (search name, address, and symbol otherwise)
-m, --match_case do case-sensitive search
-l, --all include all accounts in the search
-c, --custom include your custom named accounts
-p, --prefund include prefund accounts
-n, --named include well know token and airdrop addresses in the search
-a, --addr display only addresses in the results (useful for scripting)
-s, --collections display collections data
-g, --tags export the list of tags and subtags only
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
-e, --expand expand search to include all fields (search name, address, and symbol otherwise)
-m, --match_case do case-sensitive search
-l, --all include all accounts in the search
-c, --custom include your custom named accounts
-p, --prefund include prefund accounts
-n, --named include well know token and airdrop addresses in the search
-a, --addr display only addresses in the results (useful for scripting)
-g, --tags export the list of tags and subtags only
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
Notes:
- The tool will accept up to three terms, each of which must match against any field in the database.
Expand Down Expand Up @@ -216,7 +215,7 @@ Flags:
-s, --sol extract the abi definition from the provided .sol file(s)
-f, --find strings search for function or event declarations given a four- or 32-byte code(s)
-n, --hint strings for the --find option only, provide hints to speed up the search
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
Expand Down
12 changes: 6 additions & 6 deletions content/docs/chifra/admin.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
title: "Admin"
description: ""
lead: ""
date: 2022-09-03T10:11:05
date: 2022-10-08T19:54:08
lastmod:
- :git
- lastmod
Expand Down Expand Up @@ -40,7 +40,7 @@ Usage:
Flags:
-p, --port string specify the server's port (default ":8080")
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
Expand Down Expand Up @@ -71,7 +71,7 @@ Flags:
-i, --pin pin new chunks (requires locally-running IPFS daemon or --remote)
-m, --remote pin new chunks to the gateway (requires pinning service keys)
-s, --sleep float seconds to sleep between scraper passes (default 14)
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
```
Expand All @@ -90,7 +90,7 @@ Each of the following additional configurable command line options are available
| first_snap | uint64 | 0 | the first block at which snap_to_grid is enabled |
| unripe_dist | uint64 | 28 | the distance (in blocks) from the front of the chain under which (inclusive) a block is considered unripe |
| channel_count | uint64 | 20 | number of concurrent processing channels |
| allow_missing | bool | false | do not report errors for blockchains that contain blocks with zero addresses |
| allow_missing | bool | true | do not report errors for blockchains that contain blocks with zero addresses |


These items may be set in three ways, each overridding the preceeding method:
Expand Down Expand Up @@ -146,7 +146,7 @@ Flags:
-m, --remote prior to processing, retreive the manifest from the Unchained Index smart contract
-b, --belongs strings in index mode only, checks the address(es) for inclusion in the given index chunk
-s, --sleep float for --remote pinning only, seconds to sleep between API calls
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
Expand Down Expand Up @@ -188,7 +188,7 @@ Usage:
Flags:
-a, --all in addition to Bloom filters, download full index chunks
-s, --sleep float seconds to sleep between downloads
-x, --fmt string export format, one of [none|json*|txt|csv|api]
-x, --fmt string export format, one of [none|json*|txt|csv]
-v, --verbose enable verbose (increase detail with --log_level)
-h, --help display this help screen
Expand Down
Loading

0 comments on commit 37f8ffe

Please sign in to comment.