<p>The reason why you are not finding many detailed resources about blockchain is because it is a new innovation and not widely understood. Most resources are scattered across blogs and code repositories. A few developer and programming guides are listed lower down.</p>

<p>The most valuable and primary resource is the <a href="https://github.com/bitcoin/bitcoin" rel="nofollow noreferrer">Bitcoin Core client</a> implementation - also called the <em>Satoshi reference client</em>.</p>

<p>It is possible to design and build a blockchain client from first principles. The design will require several components, and here are the basics:</p>

<ul>
<li><strong>P2P networking</strong> - manage connections &amp; send/receive messages and data</li>
<li>a <strong>Messaging protocol</strong> - message and data format</li>
<li><strong>Database</strong> - store &amp; retrieve block headers, blocks, transactions and previous spends (UTXOs)</li>
<li>client <strong>Behavior logic</strong> - handle messages, protocol rules, coinbase rules, etc</li>
<li><strong>Consensus logic</strong> - gather, process and apply peer consensus about the validity of transactions, blocks and the unfolding chain</li>
<li><strong>Coin generation</strong> code - mining and proof-of-work (if any)</li>
<li>general household code - logging, error handling, state maintenance, etc</li>
</ul>

<p>That may seem daunting at first glance, but it is a worthwhile and achievable project.</p>

<p>Notice, that cryptography is not listed. This is because a private blockchain does not require secrets or obfuscation. However, if it is of interest, one can implement Bitcoin's Eliptic Curve library and address schema.</p>

<p>Before creating a blockchain client and protocol from first principles, it will be necessary to do some research about how the Bitcoin protocol works. <a href="https://github.com/bitcoinbook/bitcoinbook" rel="nofollow noreferrer">Mastering Bitcoin</a> by Andreas Antonopoulos provides good insight. Other resources of interest:</p>

<ul>
<li><a href="https://bitcoin.org/en/developer-documentation" rel="nofollow noreferrer">https://bitcoin.org/en/developer-documentation</a></li>
<li><a href="https://bitcoin.stackexchange.com/questions/18461/bitcoin-programming-book">This question</a> has useful discussion and several pointers to learning resources.</li>
</ul>

<p>Study how the reference client behaves, and read the reference client code, especially the file <a href="https://github.com/bitcoin/bitcoin/blob/0.13/src/main.cpp" rel="nofollow noreferrer">main.cpp</a> - <em>(linked to Core v0.13, since that file's code has been rationalized into separate files from v0.14 onwards)</em></p>

<p>Also, there are several open source libraries that allow you to run barebones blockchain nodes and exchange protocol messages. Some libraries are better than others:</p>

<ul>
<li><a href="https://github.com/anax32/pychain" rel="nofollow noreferrer">pychain</a> - basic blockchain prototype</li>
<li><a href="https://github.com/xran-deex/PyCoin" rel="nofollow noreferrer">PyCoin</a> - a Python Bitcoin clone</li>
<li><a href="https://zensystem.io/" rel="nofollow noreferrer">Zen System</a> - encrypt <em>everything</em> blockchain featuring communications, transactions and a DAO.</li>
</ul>

CC BY-SA 3.0
2017-06-25T17:36:07.157Z
Thank you so much for your answer! Actually the question would be: How can I create a private blockchain with my own transactions?
Ignacio Martin Gallardo Urbini
CC BY-SA 3.0
2017-11-23T07:41:47.343Z
Is there any way to create the private blockchain in Java language?
Mohit Tyagi
CC BY-SA 4.0
2019-03-13T00:25:26.610Z
Obviously, just do it in Java...
Ignacio Martin Gallardo Urbini
CC BY-SA 3.0
2017-06-24T05:47:48.977Z
2017-06-27T15:59:36.670Z
2017-06-27T15:59:36.670Z
venzen
<p>I am trying to create my own blockchain with my own transactions but there is not much information on how this works in detail. 
Basically I want to create a transaction with my own structure using blockchain. It is possible?</p>

CC BY-SA 3.0
2017-06-24T04:59:15.500Z
BTW, what programming language do you intend to use?
venzen
CC BY-SA 3.0
2017-06-25T17:00:44.273Z
I do not care much about the programming language ... I just need to do it somehow!
Thanks for your help!
Ignacio Martin Gallardo Urbini
<altcoin-development>
Where can I learn how to create my own blockchain with a new transaction scheme?
Ignacio Martin Gallardo Urbini
# Where can I learn how to create my own blockchain with a new transaction scheme?

(Asked by: username_0 on 2017-06-23)

I am trying to create my own blockchain with my own transactions but there is not much information on how this works in detail.
Basically I want to create a transaction with my own structure using blockchain. It is possible?

**Tags:** altcoin-development

> **Comments:**
> **username_1**: BTW, what programming language do you intend to use?  
> **username_0**: I do not care much about the programming language ... I just need to do it somehow! Thanks for your help!  

---

## 1 answers

### Answer by username_1 on 2017-06-24. Score: 4 | Accepted answer

The reason why you are not finding many detailed resources about blockchain is because it is a new innovation and not widely understood. Most resources are scattered across blogs and code repositories. A few developer and programming guides are listed lower down.

The most valuable and primary resource is the [Bitcoin Core client](https://github.com/bitcoin/bitcoin) implementation - also called the *Satoshi reference client*.

It is possible to design and build a blockchain client from first principles. The design will require several components, and here are the basics:

* **P2P networking** - manage connections & send/receive messages and data
* a **Messaging protocol** - message and data format
* **Database** - store & retrieve block headers, blocks, transactions and previous spends (UTXOs)
* client **Behavior logic** - handle messages, protocol rules, coinbase rules, etc
* **Consensus logic** - gather, process and apply peer consensus about the validity of transactions, blocks and the unfolding chain
* **Coin generation** code - mining and proof-of-work (if any)
* general household code - logging, error handling, state maintenance, etc

That may seem daunting at first glance, but it is a worthwhile and achievable project.

Notice, that cryptography is not listed. This is because a private blockchain does not require secrets or obfuscation. However, if it is of interest, one can implement Bitcoin's Eliptic Curve library and address schema.

Before creating a blockchain client and protocol from first principles, it will be necessary to do some research about how the Bitcoin protocol works. [Mastering Bitcoin](https://github.com/bitcoinbook/bitcoinbook) by Andreas Antonopoulos provides good insight. Other resources of interest:

* <https://bitcoin.org/en/developer-documentation>
* [This question](https://bitcoin.stackexchange.com/questions/18461/bitcoin-programming-book) has useful discussion and several pointers to learning resources.

Study how the reference client behaves, and read the reference client code, especially the file [main.cpp](https://github.com/bitcoin/bitcoin/blob/0.13/src/main.cpp) - *(linked to Core v0.13, since that file's code has been rationalized into separate files from v0.14 onwards)*

Also, there are several open source libraries that allow you to run barebones blockchain nodes and exchange protocol messages. Some libraries are better than others:

* [pychain](https://github.com/anax32/pychain) - basic blockchain prototype
* [PyCoin](https://github.com/xran-deex/PyCoin) - a Python Bitcoin clone
* [Zen System](https://zensystem.io/) - encrypt *everything* blockchain featuring communications, transactions and a DAO.

> **Comments:**
> **username_0**: Thank you so much for your answer! Actually the question would be: How can I create a private blockchain with my own transactions?  
> **username_2**: Is there any way to create the private blockchain in Java language?  
> **username_0**: Obviously, just do it in Java...  

---

