Tutorial
Introduction
mijin is an versatille platform that is developed and designed for any kind of audience to freely use a 'blockchain' as a private P2P network.
In order to start to the tutorial, make sure the P2P network of mijin has been already built-on since this tutorial will be based on a prepared environment.
General Information on 'mijin'
First of all, please take a look at the following figure:

The dotted lines are either blocks or transactions. The figure shows that mijin has been installed to all four servers and noted as node 1,2,3 and 4. Blocks and transaction are synchronised by communicating each other through Port:7895.
No authoritative roles exist in each node for mijin's blockchain unlike the other blockchains do. Authoritative role can be; #1 client; #2 non-verification peer; #4 verification peer; and #8 audit. Each node shares blocks and transactions and verifies oneself, shares, and eventually it connects to a blockchain by oneself.
In other words, it is possible to place a role to each node as it is shown in the figure below. node:4 receives a transaction from a general user, and node:2 receives a transaction from a corporate.

For example, it is also possible to build an application as it is shown in the figure below based on the roles described above.

Interaction of mijin
The data interaction for mijin is performed via API. The communication method is 'POST/GET'.
Like ordinary websites, POST/GET will be runned from the HTML form under the host which mijin has been already installed.
About POST/GET
POST/GET are used as the following:
- POST ... sending transaction
- GET ... receiving various types of information
GET method will be runned like ordinary websites by using addresses and public keys as a parameter.
However, POST method differs from ordinary websites.
The data which are entered in the form are sent to the host via POST method as it is for an ordinary website. Though, in terms of mijin, POST is runned with a JSON object as described below. It is runned with a combination of; creating a data that has been serialised by each parameter; and the digital signatures that are created by the private key which belongs to the transaction creator.
POST method is possible to transact the followings, however, in order to POST on a node, it is necessary to use the POST method after converting it into a JSON object as it is described in above.
Possible Transaction through POST method
- remittance (including mosaic)
- creating a multisig account
- creating a multisig transaction
- signing a multisig transaction
- creating a namespace
- creating mosaics
It can be described as a figure below:

So, where should the digital signatured JSON object be created?
The API Path: /transaction/prepare-announce which will be needed to create a JSON object from each parameter is already settled in mijin. However, the private key information will be broadcasted on the communication when each parameters are granted and giving a call to this API towards the node.

Use under the local environment of the servers that mijin has been already installed, and in case of other environment, make sure to; use the JavaScript on the client side; create a JSON object; and POST the created JSON object towards the node when using. This enables to send transactions to a node without broadcasting the private key on the communication.

About Tutorial
In this tutorial a symplified app. which was created based on the jQuery will be used.
The specs of this app. are as listed as below:
- Convert the information which was entered in the entry form into a JSON object which comes with a digital signature
- Send a transaction to a node
- Output the results into the Response Column
The instruction on how to use the application and other related information will be described at the bottom.
Let's get started on the tutorial now.