Skip to content

Commit

Permalink
Merge pull request #421 from 1200wd/add-blockbook-docu
Browse files Browse the repository at this point in the history
Add Blockbook manual to docu
  • Loading branch information
mccwdev authored Nov 15, 2024
2 parents f8e7d2b + 3a134d5 commit 685f097
Show file tree
Hide file tree
Showing 6 changed files with 55 additions and 8 deletions.
6 changes: 4 additions & 2 deletions docs/_static/manuals.faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,10 @@ Most likely cause is a problem with a specific service provider.
Please set log level to 'debug' and check the logs in bitcoinlib.log to see if you can pin down the specific error.
You could then disable the provider and post the `issue <https://github.com/1200wd/bitcoinlib/issues>`_.

To avoid these kinds of errors it is advised to run your local `Bcoin node <manuals.setup-bcoin.html>`_.
With a local Bcoin node you do not depend on external Service providers which increases reliability, security, speed
To avoid these kinds of errors it is advised to run your local `Bcoin node <manuals.setup-bcoin.html>`_ or
`Blockbook server <manuals.setup-blockbook.html>`_.

With a local Bcoin node or Blockbook server you do not depend on external Service providers which increases reliability, security, speed
and privacy.

Can I use Bitcoinlib with another database besides SQLite?
Expand Down
4 changes: 2 additions & 2 deletions docs/_static/manuals.security.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ Frequently Asked Questions

Ten tips for more privacy and security when using Bitcoin and Bitcoinlib:

1. Run your own `Bitcoin <https://bitcoinlib.readthedocs.io/en/latest/source/_static/manuals.setup-bitcoind-connection.html>`_
or `Bcoin <manuals.setup-bcoin.html>`_ node, so you are not depending on external Blockchain API service providers anymore.
1. Run your own `Bitcoin core <https://bitcoinlib.readthedocs.io/en/latest/source/_static/manuals.setup-bitcoind-connection.html>`_,
`Bcoin node <manuals.setup-bcoin.html>`_ node or `Blockbook server <manuals.setup-blockbook.html>`_, so you are not depending on external Blockchain API service providers anymore.
This not only increases your privacy, but also makes your application much faster and more reliable. And as extra bonus
you support the Bitcoin network.
2. Use multi-signature wallets. So you are able to store your private keys in separate (offline) locations.
Expand Down
7 changes: 4 additions & 3 deletions docs/_static/manuals.setup-bcoin.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@ How to connect Bitcoinlib to a Bcoin node

Bcoin is a full bitcoin node implementation, which can be used to parse the blockchain, send transactions and run a
wallet. With a Bcoin node you can retrieve transaction and utxo information for specific addresses, this is not easily
possible with a `Bitcoind <manuals.setup-bitcoind-connection.html>`_ node. So if you want to use Bitcoinlib with a
wallet and not be dependent on external providers the best option is to run a local Bcoin node.
possible with a `Bitcoind <manuals.setup-bitcoind-connection.html>`_ node. So if you want to use Bitcoinlib's
wallet functionality for instance and not be dependant on external providers the best option is to run a local
Bcoin node or `Blockbook <manuals.setup-blockbook.html>`_ server.


Install Bcoin node
Expand All @@ -25,7 +26,7 @@ Use Bcoin node with Bitcoinlib

To use Bcoin with bitcoinlib add the credentials to the providers.json configuration file in the .bitcoinlib directory.

.. code-block:: text
.. code-block:: json
"bcoin": {
"provider": "bcoin",
Expand Down
2 changes: 1 addition & 1 deletion docs/_static/manuals.setup-bitcoind-connection.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ a lot of resources.
With a standard Bitcoin node you can only retrieve block and transaction information. You can not
query the node for information about specific addresses. So it is not suitable to run in combination with a Bitcoinlib
wallet. If you would like to use Bitcoinlib wallets and not be dependent on external providers you should use a
`Bcoin node <manuals.setup-bcoin.html>`_ instead.
`Bcoin node <manuals.setup-bcoin.html>`_ or `Blockbook server <manuals.setup-blockbook.html>`_ instead.


Bitcoin node settings
Expand Down
43 changes: 43 additions & 0 deletions docs/_static/manuals.setup-blockbook.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
How to connect Bitcoinlib to a Blockbook server
===============================================

Trezor's Blockbook is a back-end service for Trezor Suite and can also be used as back-end service provider for
Bitcoinlib. Blockbook indexes addresses, transactions, unspent outputs and balances and can be used for fast
blockchain queries. Blockbook also support Litecoin, Dash, Dogecoin and various testnets.

If you want to use Bitcoinlib as a wallet, run many blockchain queries or write an application which is dependant on
frequent requests to blockchain service providers you should use a Blockbook service or install a
`Bcoin <manuals.setup-bcoin.html>`_ node.


Install Blockbook server
------------------------

You can find some instructions on how to install a Blockbook server on
https://coineva.com/blockbook-setup-as-bitcoinlib-backend.html.

You will need a powerful server with enough memory and diskspace. Blockbook runs a full Bitcoin core node on the
background, and maintains a large RocksDB database to store additional blockchain data. But once installed and
synchronised it runs fast and smooth.


Use Blockbook with Bitcoinlib
-----------------------------

To use Blockbook with bitcoinlib add the credentials to the providers.json configuration file in the .bitcoinlib directory.

.. code-block:: json
"blockbook": {
"provider": "blockbook",
"network": "bitcoin",
"client_class": "BlockbookClient",
"provider_coin_id": "",
"url": "https://<servername>:9130/",
"api_key": "",
"priority": 20,
"denominator": 100000000,
"network_overrides": null
}
You can increase the priority so the Service object always connects to the Blockbook service first.
1 change: 1 addition & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -228,6 +228,7 @@ For more examples see https://github.com/1200wd/bitcoinlib/tree/master/examples
source/_static/manuals.command-line-wallet
Bitcoind Node <source/_static/manuals.setup-bitcoind-connection>
Bcoin Node <source/_static/manuals.setup-bcoin>
Blockbook <source/_static/manuals.setup-blockbook>
Add Service Provider <source/_static/manuals.add-provider>
Databases <source/_static/manuals.databases>
Encrypted Database <source/_static/manuals.sqlcipher>
Expand Down

0 comments on commit 685f097

Please sign in to comment.