Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
2e39ec0
Update docs.json, versions.json, and add cometbft directory
CryptoAssassin1 Dec 9, 2025
a09a51e
Merge pull request #140 from CryptoAssassin1/comet
CryptoAssassin1 Dec 9, 2025
5402963
file x
CryptoAssassin1 Dec 9, 2025
56f3227
file rebuild
CryptoAssassin1 Dec 9, 2025
92f9e10
file rebuild2
CryptoAssassin1 Dec 9, 2025
218f35c
file rebuild3
CryptoAssassin1 Dec 9, 2025
11e1bec
file rebuild4
CryptoAssassin1 Dec 9, 2025
6111710
fix guides
CryptoAssassin1 Dec 11, 2025
508833a
fix guides Quick-start
CryptoAssassin1 Dec 11, 2025
c148fb6
fix networks
CryptoAssassin1 Dec 11, 2025
a581c13
fix networks2
CryptoAssassin1 Dec 11, 2025
60e82e2
apps update docs.js
CryptoAssassin1 Dec 11, 2025
2557eb2
Fix Apps
CryptoAssassin1 Dec 11, 2025
06a211a
Fix Core remove readme and update docs.json
CryptoAssassin1 Dec 11, 2025
917a55c
testcores
CryptoAssassin1 Dec 11, 2025
b5f4e7e
testcores2
CryptoAssassin1 Dec 11, 2025
9d4012f
testcores3comet
CryptoAssassin1 Dec 12, 2025
d6afe20
testcores4rpc
CryptoAssassin1 Dec 12, 2025
640a6eb
testcores5rpc
CryptoAssassin1 Dec 12, 2025
d8d7cdc
coresntoolsfixed
CryptoAssassin1 Dec 12, 2025
6811f20
QAgroup
CryptoAssassin1 Dec 12, 2025
aaa440e
QAgroupspacere
CryptoAssassin1 Dec 12, 2025
8598b02
QAM
CryptoAssassin1 Dec 12, 2025
2453bde
tabspeccoref
CryptoAssassin1 Dec 12, 2025
71cd2cc
tabspeccorefi
CryptoAssassin1 Dec 12, 2025
5f80787
tabspeccorefix
CryptoAssassin1 Dec 12, 2025
445e2c7
abci++
CryptoAssassin1 Dec 12, 2025
f3c7cf3
abci++reornamef
CryptoAssassin1 Dec 12, 2025
3fc8c15
abci++reornameftri
CryptoAssassin1 Dec 12, 2025
441894d
finaltabci
CryptoAssassin1 Dec 12, 2025
56472c6
rebtriger
CryptoAssassin1 Dec 12, 2025
05fcd5c
cons1
CryptoAssassin1 Dec 12, 2025
265ac7b
cons2f
CryptoAssassin1 Dec 12, 2025
fbdf851
cons3f
CryptoAssassin1 Dec 12, 2025
f2de9a4
cons4f light client add
CryptoAssassin1 Dec 12, 2025
0afb102
cons4f light client add4
CryptoAssassin1 Dec 12, 2025
49343dc
lightc verification fixed for
CryptoAssassin1 Dec 15, 2025
8cdfcfa
lightc verification fixed for and dunused f
CryptoAssassin1 Dec 15, 2025
bb6812b
lightc verification fixed for and dunused f2
CryptoAssassin1 Dec 15, 2025
281ec49
p2pl
CryptoAssassin1 Dec 15, 2025
9b2482a
p2playera
CryptoAssassin1 Dec 15, 2025
df73208
legacy nd messages
CryptoAssassin1 Dec 15, 2025
e7f2b3a
overv added
CryptoAssassin1 Dec 15, 2025
013ecf7
legaddedp2p peers
CryptoAssassin1 Dec 15, 2025
f9618e7
refimgfix
CryptoAssassin1 Dec 15, 2025
109e0d2
refimgfix3 codebloc
CryptoAssassin1 Dec 15, 2025
ecfb319
rpc1fix
CryptoAssassin1 Dec 15, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
44 changes: 44 additions & 0 deletions cometbft/v0.38/docs/README.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
title: CometBFT Documentation
description: CometBFT is a blockchain application platform.
footer:
newsletter: false
---
{/* trigger rebuild */}

# CometBFT

Welcome to the CometBFT documentation!

CometBFT is a blockchain application platform; it provides the equivalent
of a web-server, database, and supporting libraries for blockchain applications
written in any programming language. Like a web-server serving web applications,
CometBFT serves blockchain applications.

More formally, CometBFT performs Byzantine Fault Tolerant (BFT)
State Machine Replication (SMR) for arbitrary deterministic, finite state machines.
For more background, see [What is CometBFT?](./introduction/README.md#what-is-cometbft).

To get started quickly with an example application, see the [quick start guide](guides/quick-start.md).

To learn about application development on CometBFT, see the [Application Blockchain Interface](https://github.com/cometbft/cometbft/tree/v0.38.x/spec/abci).

For more details on using CometBFT, see the respective documentation for
[CometBFT internals](core/), [benchmarking and monitoring](tools/), and [network deployments](networks/).

## Contribute

To recommend a change to the documentation, please submit a PR. Each major
release's documentation is housed on the corresponding release branch, e.g. for
the v0.34 release series, the documentation is housed on the `v0.34.x` branch.

When submitting changes that affect all releases, please start by submitting a
PR to the docs on `main` - this will be backported to the relevant release
branches. If a change is exclusively relevant to a specific release, please
target that release branch with your PR.

Changes to the documentation will be reviewed by the team and, if accepted and
merged, published to (https://docs.cometbft.com) for the respective version(s).

The build process for the documentation is housed in the [CometBFT documentation
repository](https://github.com/cometbft/cometbft-docs).
55 changes: 55 additions & 0 deletions cometbft/v0.38/docs/app-dev/Application-Architecture-Guide.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
---
order: 4
---

# Application Architecture Guide

Here we provide a brief guide on the recommended architecture of a
CometBFT blockchain application.

We distinguish here between two forms of "application". The first is the
end-user application, like a desktop-based wallet app that a user downloads,
which is where the user actually interacts with the system. The other is the
ABCI application, which is the logic that actually runs on the blockchain.
Transactions sent by an end-user application are ultimately processed by the ABCI
application after being committed by CometBFT.

The end-user application communicates with a REST API exposed by the application.
The application runs CometBFT nodes and verifies CometBFT light-client proofs
through the CometBFT RPC. The CometBFT process communicates with
a local ABCI application, where the user query or transaction is actually
processed.

The ABCI application must be a deterministic result of the CometBFT
consensus - any external influence on the application state that didn't
come through CometBFT could cause a consensus failure. Thus _nothing_
should communicate with the ABCI application except CometBFT via ABCI.

If the ABCI application is written in Go, it can be compiled into the
CometBFT binary. Otherwise, it should use a unix socket to communicate
with CometBFT. If it's necessary to use TCP, extra care must be taken
to encrypt and authenticate the connection.

All reads from the ABCI application happen through the CometBFT `/abci_query`
endpoint. All writes to the ABCI application happen through the CometBFT
`/broadcast_tx_*` endpoints.

The Light-Client Daemon is what provides light clients (end users) with
nearly all the security of a full node. It formats and broadcasts
transactions, and verifies proofs of queries and transaction results.
Note that it need not be a daemon - the Light-Client logic could instead
be implemented in the same process as the end-user application.

Note for those ABCI applications with weaker security requirements, the
functionality of the Light-Client Daemon can be moved into the ABCI
application process itself. That said, exposing the ABCI application process
to anything besides CometBFT over ABCI requires extreme caution, as
all transactions, and possibly all queries, should still pass through
CometBFT.

See the following for more extensive documentation:

- [Interchain Standard for the Light-Client REST API](https://github.com/cosmos/cosmos-sdk/pull/1617) (legacy/deprecated)
- [CometBFT RPC Docs](../rpc)
- [CometBFT in Production](../core/running-in-production.md)
- [ABCI spec](../spec/abci)
199 changes: 199 additions & 0 deletions cometbft/v0.38/docs/app-dev/Getting-Started.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,199 @@
---
order: 2
---

# Getting Started

## First CometBFT App

As a general purpose blockchain engine, CometBFT is agnostic to the
application you want to run. So, to run a complete blockchain that does
something useful, you must start two programs: one is CometBFT,
the other is your application, which can be written in any programming
language.

CometBFT handles all the p2p and consensus logic, and just forwards transactions to the
application when they need to be validated, or when they're ready to be
executed and committed.

In this guide, we show you some examples of how to run an application
using CometBFT.

### Install

The first apps we will work with are written in Go. To install them, you
need to [install Go](https://golang.org/doc/install), put
`$GOPATH/bin` in your `$PATH` and enable go modules. If you use `bash`,
follow these instructions:

```bash
echo export GOPATH=\"\$HOME/go\" >> ~/.bash_profile
echo export PATH=\"\$PATH:\$GOPATH/bin\" >> ~/.bash_profile
```

Then run

```bash
go get github.com/cometbft/cometbft
cd $GOPATH/src/github.com/cometbft/cometbft
make install_abci
```

Now you should have the `abci-cli` installed; run `abci-cli` to see the list of commands:

```
Usage:
abci-cli [command]

Available Commands:
batch run a batch of abci commands against an application
check_tx validate a transaction
commit commit the application state and return the Merkle root hash
completion Generate the autocompletion script for the specified shell
console start an interactive ABCI console for multiple commands
echo have the application echo a message
finalize_block deliver a block of transactions to the application
help Help about any command
info get some info about the application
kvstore ABCI demo example
prepare_proposal prepare proposal
process_proposal process proposal
query query the application state
test run integration tests
version print ABCI console version

Flags:
--abci string either socket or grpc (default "socket")
--address string address of application socket (default "tcp://0.0.0.0:26658")
-h, --help help for abci-cli
--log_level string set the logger level (default "debug")
-v, --verbose print the command and results as if it were a console session

Use "abci-cli [command] --help" for more information about a command.
```

You'll notice the `kvstore` command, an example application written in Go.

Now, let's run an app!

## KVStore - A First Example

The kvstore app is a [Merkle
tree](https://en.wikipedia.org/wiki/Merkle_tree) that just stores all
transactions. If the transaction contains an `=`, e.g. `key=value`, then
the `value` is stored under the `key` in the Merkle tree. Otherwise, the
full transaction bytes are stored as the key and the value.

Let's start a kvstore application.

```sh
abci-cli kvstore
```

In another terminal, we can start CometBFT. You should already have the
CometBFT binary installed. If not, follow the steps from
[here](../guides/install.md). If you have never run CometBFT
before, use:

```sh
cometbft init
cometbft node
```

If you have used CometBFT, you may want to reset the data for a new
blockchain by running `cometbft unsafe-reset-all`. Then you can run
`cometbft node` to start CometBFT, and connect to the app. For more
details, see [the guide on using CometBFT](../core/using-cometbft.md).

You should see CometBFT making blocks! We can get the status of our
CometBFT node as follows:

```sh
curl -s localhost:26657/status
```

The `-s` just silences `curl`. For nicer output, pipe the result into a
tool like [jq](https://stedolan.github.io/jq/) or `json_pp`.

Now let's send some transactions to the kvstore.

```sh
curl -s 'localhost:26657/broadcast_tx_commit?tx="abcd"'
```

Note the single quote (`'`) around the url, which ensures that the
double quotes (`"`) are not escaped by bash. This command sent a
transaction with bytes `abcd`, so `abcd` will be stored as both the key
and the value in the Merkle tree. The response should look something
like:

```json
{
"jsonrpc": "2.0",
"id": "",
"result": {
"check_tx": {},
"deliver_tx": {
"tags": [
{
"key": "YXBwLmNyZWF0b3I=",
"value": "amFl"
},
{
"key": "YXBwLmtleQ==",
"value": "YWJjZA=="
}
]
},
"hash": "9DF66553F98DE3C26E3C3317A3E4CED54F714E39",
"height": 14
}
}
```

We can confirm that our transaction worked and the value got stored by
querying the app:

```sh
curl -s 'localhost:26657/abci_query?data="abcd"'
```

The result should look like:

```json
{
"jsonrpc": "2.0",
"id": "",
"result": {
"response": {
"log": "exists",
"index": "-1",
"key": "YWJjZA==",
"value": "YWJjZA=="
}
}
}
```

Note the `value` in the result (`YWJjZA==`); this is the base64-encoding
of the ASCII of `abcd`. You can verify this in a python 2 shell by
running `"YWJjZA==".decode('base64')` or in python 3 shell by running
`import codecs; codecs.decode(b"YWJjZA==", 'base64').decode('ascii')`.
Stay tuned for a future release that [makes this output more
human-readable](https://github.com/tendermint/tendermint/issues/1794).

Now let's try setting a different key and value:

```sh
curl -s 'localhost:26657/broadcast_tx_commit?tx="name=satoshi"'
```

Now if we query for `name`, we should get `satoshi`, or `c2F0b3NoaQ==`
in base64:

```sh
curl -s 'localhost:26657/abci_query?data="name"'
```

Try some other transactions and queries to make sure everything is
working!
Loading