Btcrpc port API
Background: the financial application of blockchain technology brings high investment value
2018 China international big data instry Expo opened in Guiyang City, Guizhou Province on the 26th. At the meeting, it was pointed out that China will vigorously develop the digital economy in the future, deeply implement the action plan for the development of big data and cloud computing, and deeply study blockchain technology and application. Especially in the field of finance, the landing application has become the focus of the scientific and financial circles
1. The value source of blockchain is that it can perfectly solve the pain points of the current financial instry:
in today's asset securitization, insurance, supply chain finance, commodity trading, asset custody and other financial scenarios, e to many participants, high cost of credit evaluation, low settlement efficiency of intermediary institutions and other reasons, Traditional financial service methods are difficult to effectively solve the long-standing core pain points in the instry, such as information asymmetry, complex and rendant processes, and high information verification cost
2. Why can blockchain solve the above pain points:
blockchain technology integrates many basic technologies, such as distributed accounting, tamper proof, built-in contract, etc., and constructs a trust building mechanism with lower cost. The financial application based on blockchain technology can realize the ability of all market participants to obtain all transaction information and asset ownership records in the market without discrimination, and effectively solve the problem of information asymmetry; Smart contract embedding reces the error rate of payment and settlement, simplifies the process and improves efficiency; At the same time, based on transparent information and brand-new trust mechanism, there is no need to spend manpower, material resources and financial resources to confirm information among participants, which will greatly rece the trust cost between institutions, and then rece the price of financial services and transaction costs
3. The application of blockchain technology in the financial field mainly includes the following aspects:
among which bitcoin is the most famous. On the basis of bitcoin, a large number of other types of decentralized digital currencies have been derived. Such as: the heyday of bits
Compared with the traditional payment system, blockchain payment can directly carry out end-to-end payment for both parties without the help of the banking system, which can greatly improve the speed and rece the cost③ digital bills
④ bank credit management: the advantage of blockchain is that it can rely on program algorithm to automatically record credit related information and store it on every computer in the blockchain network, with transparent information, tamper proof and low cost
The major financial institutions and exchanges in Europe and the United States have explored the application research of building the next generation of financial asset trading platform based on blockchain technology4. The development prospect of blockchain. The future development of blockchain technology will have the most vitality with alliance chain as the entry point, and will have a significant effect and far-reaching impact on the transformation of traditional financial instry pain points
in response to the good investment prospects of blockchain, domestic enterprises such as Alibaba, Jingdong and Netcom have entered the market. The application of financial scenarios based on blockchain technology not only brings us security and convenience, but also provides us with broader investment space. The rise and price surge of digital currency represented by bitcoin (bitcoin was about RMB 20 cents when it was first listed in 2009, and its current price is about US $7300!) It's the best proof that people with a keen sense of smell have made a lot of money from it
Abstract: This is an encrypted digital currency based on the bitcoin developed by Nakamoto Tsung, which improves and adds many new functions, such as the double-layer reward system network, also known as the main node network. It also includes anonymous payment to improve the interchangeability (bitage) and real-time payment function docking to realize real-time transaction confirmation without relying on the authority of the center (P2P mall) In 2009, Nakamoto put forward the concept of bitcoin. Since then, bitcoin has spread rapidly in mainstream applications and commercial uses, becoming the first digital currency to attract a large number of users, which is a milestone in the history of digital currency. However, from the perspective of completing the transaction, we can find an important problem, that is, it takes too long for bitcoin block to confirm the transaction. Traditional payment companies have found a solution to enable the buyer and the seller to realize zero confirmation of bitcoin transaction, but this solution usually requires a trusted third party to complete the transaction outside the agreementbitcoin provides pseudonym transaction, realizes the one-to-one transaction relationship between sender and receiver, and can always record the transactions occurred in the whole network. Bitcoin only provides low-level privacy protection, which is well known in academia. Despite this deficiency, many people still believe in the transfer history recorded by blockchain
based on Nakamoto's achievements, bitshengshi is an encrypted digital currency with the purpose of protecting privacy. We have made a series of improvements on the basis of the concept of bitcoin, resulting in a decentralized cryptocurrency with good anonymity. It supports tamper proof real-time transactions, and has a point-to-point sub network that can provide service reward system for bitsheng network
2. Master node network
the whole node is the server running on the P2P network, so that small nodes can use them to accept the dynamic changes from the whole network. These all nodes need significant traffic and other resources that consume a lot of cost. Therefore, it will be observed that the number of these nodes on the bitcoin network presents a steady downward trend over a period of time, so that the block broadcast time needs an additional 40 seconds. In order to solve this problem, many solutions have been put forward, such as the introction of Microsoft Research's new incentive plan and bitnodes incentive plan
Figure 6: Mining reward model
Take a blockchain API tool that I am currently using as an example
previously, I occasionally found bctools , which can quickly and conveniently test and verify BTC and EOS blockchain API. At the same time, these API interface test network and main network can be verified on bctools ; If you are interested, you can go http://bctools.io Use it
at present, Apis on bctools seem to have the following types:

choose your own direction
the cost of developing an interface is not so high. Except for EOS, there is not much data to be chained, which is basically completed locally. As a top blockchain technology developer in China, weisanyun is still a good technology developer.
<? php
* DATE:2014-07-29
>
& #39 39; < br/> #api No
$apicode=& #39; caipiao ' < br/> $ rettype=& #39; xml ' # Providing json and xml in two forms, select I
$ url = & #39 in use; http://192.168.1.15/data/getData.htm' ;# The requested data interface URL
$ c=& #39; dlt ' < br/> $ params =& #39;& apikey='$ apikey.'& apicode='$ apicode.'& rettype='$ rettype.'& c='$ c; < br/ >
$ content = getData($url.'?' 39. $ Parms); < / br/ > } else {
< echo & #39; #39; < br/ / /br/ / / / /br/ / / /br/ / / / / / / /br// / / / / / /br/ / / / / / / / / / / / / / / /
/curl_setopt($ch, CURLOPT_URL, $url); < br/ > / /curl_setopt($ch, CURLOPT_HEADER, 0); < br/ / / / /curl_setopt($ch, CURLOPT_RETURNTRANSFER, true) / / retrieve data
/ / / / / / capture URLs and transmit it to the browser
/ $ response = curl_exec($ch); < br />
/ /curl_close($ch); < br />
/ < return $response; <
> <
br > <
*@author datatang
@version 1.0
@create date 2014/08
*/
import java.io.BufferedReader; < br/>Import java.io.IOException; < br/>Import java.io.InputStream; < br/>Import java.io.InputStreamReader; < br/>Import java.net.HttpURLConnection; < br/>Import java.net.URL; < br/>
import org.apache.log4j.Logger; < / br/ / / / / / / / / / / / / /public static void main(String[]args) {
< String strUrl = " http://api.datatang.com/data/getData.htm"; < br/ / / / / /dtkey / / API KEY applied for via page. (must be projected)
= String strKey = " XXXXXXXXXXXXXXXXXXXX " < br/ / / / / / / /apicode/ Encoding API (required projects)
/String strApicode = " < br/ / / / //rettype / Form of return required (support XML and JSON) (need projects)
/String strRettype = " < br/ > / / / / / / / /API needs parameters (detailed reference to painting-various API parameters)
/String strparam = " ) < br/ / / / / / / /e.g.
/ /strparam = " datatype=ore&startDate=2014-06-30&endDate=2014-06-30" < br/ / / / / / / /
/ / /String url = strUrl + "? apikey=" + strKey + "" apicode=" + strApicode + "" rettype=" + strRettype
& > quot;+ strparam; < br/ > /try
< String res = readByGet(url); < br/ > > System.out.println(res); < br/ > } catch (IOException e) {
< e.printStackTrace(); < br br/ / / /br/ / / /
* br/ / / / / / /
* * param inUrl in Url request url
* @param inUrl in Url request url
/private static String readByGet(String inUrl) throws IOException {
/StringBuffer sbf = new StringBuffer();
> String strRead = zero; < br/ >
/ / / / / / / / / / / / / /String userAgent = " Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 " < br /> & + "( KHTML, like Gecko) Chrome/29.0.1547.66 Safari/537.36 " < br/ / /
/ /URL = new URL (inUrl); < br/ / / / / / / / / / / / / / / / / / / / /fort 20945; / fort 20945; / / / / / / / / / / / / / / forts 20945; ; / openConnConnConnConnection communications will be opened on a connection, in accordance with URLs types of,
> connection.setReadTimeout(30000); < br/ > > connection.setConnectTimeout(30000); < RequestProperty(" User-agent ", userAgent); < br/ / / / / / / / / / / / / / / /connection.connect(); < br/ / / / / / / / / / / / / / / / / /InputStream is = connection.getInputStream(); < br/ > / / / / / / / / / / / / /BufferedReader = new BufferedReader UTF-8 ") ";< br/ > = while ((strRead = reader.readLine())= zero) {
> sbf.append(strRead); < br/ > /sbf.append(" 92; r\ n") < br/ > }
< reader.close(); < br/ / / / / / discontinue contact
/ / connection.disconnect(); < br/ > / /return sbf.toString(); < br/ >
I hope my answer can help you. If you don't understand anything, you can ask.
