Merge pull request #4 from hyle-team/main

upstream update
This commit is contained in:
Ravaga 2025-03-27 14:51:57 +04:00 committed by GitHub
commit 9ab0c8041a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
229 changed files with 10090 additions and 3381 deletions

1
.gitignore vendored
View file

@ -18,3 +18,4 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*

View file

@ -10,15 +10,19 @@ sudo apt-get install -y build-essential g++ python-dev autotools-dev libicu-dev
### Download and build Boost
(Assuming you have cloned Zano into `zano` folder. If used different location for Zano, edit line 4 correspondingly)
```
curl -OL https://boostorg.jfrog.io/artifactory/main/release/1.70.0/source/boost_1_70_0.tar.bz2
echo "430ae8354789de4fd19ee52f3b1f739e1fba576f0aded0897c3c2bc00fb38778 boost_1_70_0.tar.bz2" | shasum -c && tar -xjf boost_1_70_0.tar.bz2
cd boost_1_70_0
rm boost_1_70_0.tar.bz2 && cd boost_1_70_0
patch -p0 < ../zano/utils/boost_1.70_gcc_8.patch || cd ..
./bootstrap.sh --with-libraries=system,filesystem,thread,date_time,chrono,regex,serialization,atomic,program_options,locale,timer,log
./b2
```
Make sure that you see "The Boost C++ Libraries were successfully built!" message at the end.
### Install OpenSSL
Please, make sure the paths correspond to your environment (\`/home/user/')
@ -36,18 +40,10 @@ make install
### Checkout Zano from github
Mainnet:
```
git clone --recursive https://github.com/hyle-team/zano.git
```
Testnet:
```
git clone --recursive https://github.com/hyle-team/zano.git -b cryptoassets
```
### Set environment variables
For instance, by adding the following lines to ~/.bashrc

View file

@ -6,15 +6,15 @@ sidebar_position: 2
This example illustrates and explains the usage of a technology we call **IonicSwap**, which involves exchanging one asset for another within a single transaction.
Such a transaction is created collaboratively by two users using a secure trustless mechanism (see [whitepaper](https://github.com/hyle-team/docs/blob/master/zano/Zano_WP_1.1.pdf) "Consolidated Transactions"). Initially, one user creates one part of the transaction, and then the second user adds the second part necessary for the transaction to become valid. Afterward, the transaction is sent to the network.
Such a transaction is created collaboratively by two users using a secure trustless mechanism (see section 2.4 in [whitepaper](https://hyle-team.github.io/docs/zano/Zano_tokenization_platform.pdf) "Consolidated Transactions"). Initially, one user creates one part of the transaction, and then the second user adds the second part necessary for the transaction to become valid. Afterward, the transaction is sent to the network.
Traditionally, we will use the commonly used cryptographic designations for the parties involved - **Alice** and **Bob**. Alice will act as the initiator, creating the **Ionic Swap Proposal** and sending it to Bob, who will then make a decision whether to accept it or not.
Traditionally, we will use the commonly used cryptographic designations for the parties involved - **Initiator** and **Finalizer**. Initiator will act as the initiator, creating the **Ionic Swap Proposal** and sending it to Finalizer, who will then make a decision whether to accept it or not.
Let's assume that the native token **Zano** is circulating in the network with an asset_id of "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a".
Additionally, let's assume that there is a token called **CT** with an asset_id of "e03a140b8447d2895290022b25c06bdabea514e2475ae56ce5bcbc554ab9865c".
Let's assume **Alice** has the following address and balance in her wallet:
Let's assume **Initiator** has the following address and balance in her wallet:
```
ZxD4VNFRSHwMK3DY2Ka66C4SxGiAesSfrcC7vn1u6PSpjMq5v54Pt4wiW4FfGWtrJ55WuvoXtCCYeAL6mEvYU7na1xQioGffJ
@ -23,7 +23,7 @@ balance unlocked / [balance total] ticker asset id
14.0 CT e03a140b....4ab9865c
```
And **Bob** has a wallet with the following address and balance:
And **Finalizer** has a wallet with the following address and balance:
```
ZxDAcbaxXkyWRgYbeARBpngfmFat5TjDjjQA5NAbouB9eytwGWJqA5shAVYeCAHWPo254DF2o2X1td79PNvRr2Yc1b9Ep67ff
@ -31,7 +31,7 @@ ZxDAcbaxXkyWRgYbeARBpngfmFat5TjDjjQA5NAbouB9eytwGWJqA5shAVYeCAHWPo254DF2o2X1td79
11738.97 ZANO d6329b5b....51a6498a
```
Alice is planning to offer Bob to exchange 2 coins of the CT token that she possesses (but Bob does not) for 10 native coins of ZANO (which Bob has). To do this, she generates a proposal through an API call [ionic_swap_generate_proposal](https://docs.zano.org/v2.0/reference/ionic_swap_generate_proposal) in her wallet with the following parameters:
Initiator is planning to offer Finalizer to exchange 2 coins of the CT token that she possesses (but Finalizer does not) for 10 native coins of ZANO (which Finalizer has). To do this, she generates a proposal through an API call [ionic_swap_generate_proposal](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/ionic_swap_generate_proposal) in her wallet with the following parameters:
```json json
{
@ -40,13 +40,13 @@ Alice is planning to offer Bob to exchange 2 coins of the CT token that she poss
"method": "ionic_swap_generate_proposal",
"params": {
"proposal": {
"to_bob": [
"to_finalizer": [
{
"asset_id": "e03a140b8447d2895290022b25c06bdabea514e2475ae56ce5bcbc554ab9865c",
"amount": 2000000000000
}
],
"to_alice": [
"to_initiator": [
{
"asset_id": "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a",
"amount": 10000000000000
@ -61,15 +61,15 @@ Alice is planning to offer Bob to exchange 2 coins of the CT token that she poss
}
```
As **destination_address** she set a Bob's wallet address, to make sure that he'll be able to decrypt payload data, that needed to finalise transaction and properly read it's details.
As **destination_address** she set a Finalizer's wallet address, to make sure that he'll be able to decrypt payload data, that needed to finalise transaction and properly read it's details.
In **fee_paid_by_a** she specifies how much fee of this transaction Alice willing to pay. If fee is not enough, Bob supposed to add more fee to fulfil network requirements
In **fee_paid_by_a** she specifies how much fee of this transaction Initiator willing to pay. If fee is not enough, Finalizer supposed to add more fee to fulfil network requirements
In a **to_bob** entry Alice put list of assets that she wants to transfer to Bob, in our case it's only asset "CT" with asset_id "e03a140b8447d2895290022b25c06bdabea514e2475ae56ce5bcbc554ab9865c".
In a **to_finalizer** entry Initiator put list of assets that she wants to transfer to Finalizer, in our case it's only asset "CT" with asset_id "e03a140b8447d2895290022b25c06bdabea514e2475ae56ce5bcbc554ab9865c".
In a **to_alice**entry Alic put list of assets that she expect to get in exchange, in our case it's 10 coins of Zano (native asset_id "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a")
In a **to_initiator**entry Alic put list of assets that she expect to get in exchange, in our case it's 10 coins of Zano (native asset_id "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a")
As a result of this API call Alice receive proposal in raw hex format:
As a result of this API call Initiator receive proposal in raw hex format:
```json
{
@ -81,11 +81,11 @@ As a result of this API call Alice receive proposal in raw hex format:
}
```
**hex_raw_proposal** contains proposal transaction template(half-creted transaction) and additional encrypted data, that would be needed by Bob if he'll be accepting this swap operation.
**hex_raw_proposal** contains proposal transaction template(half-creted transaction) and additional encrypted data, that would be needed by Finalizer if he'll be accepting this swap operation.
After **Alice** got this response, she sends **hex_raw_proposal** to Bob by messenger/email or any other available channel.
After **Initiator** got this response, she sends **hex_raw_proposal** to Finalizer by messenger/email or any other available channel.
After **Bob** receives the raw proposal from **Alice**, his first step is to analyze the proposal and ensure that the transaction entails the conditions that suit him. To do this, he calls the API [ionic_swap_get_proposal_info](https://docs.zano.org/v2.0/reference/ionic_swap_get_proposal_info) from his wallet and obtains the proposal details that are validated by his wallet using his keys. In our case request and response supposed to look like this:
After **Finalizer** receives the raw proposal from **Initiator**, his first step is to analyze the proposal and ensure that the transaction entails the conditions that suit him. To do this, he calls the API [ionic_swap_get_proposal_info](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/ionic_swap_get_proposal_info) from his wallet and obtains the proposal details that are validated by his wallet using his keys. In our case request and response supposed to look like this:
Request:
@ -111,13 +111,13 @@ Response:
"expiration_time": 0,
"fee_paid_by_a": 10000000000,
"mixins": 10,
"to_alice": [
"to_initiator": [
{
"amount": 10000000000000,
"asset_id": "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a"
}
],
"to_bob": [
"to_finalizer": [
{
"amount": 2000000000000,
"asset_id": "e03a140b8447d2895290022b25c06bdabea514e2475ae56ce5bcbc554ab9865c"
@ -130,9 +130,9 @@ Response:
> 🚧 IMPORTANT
>
> It is critically important for **Bob** to analyze this structure and **ensure** that the conditions described therein perfectly reflect his intentions regarding the upcoming swap transaction.
> It is critically important for **Finalizer** to analyze this structure and **ensure** that the conditions described therein perfectly reflect his intentions regarding the upcoming swap transaction.
After Bob reviewed structure of the proposal, he call API [ionic_swap_accept_proposal](https://docs.zano.org/v2.0/reference/ionic_swap_accept_proposal) and by calling this he execute the swap operation.
After Finalizer reviewed structure of the proposal, he call API [ionic_swap_accept_proposal](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/ionic_swap_accept_proposal) and by calling this he execute the swap operation.
Request:
@ -161,7 +161,7 @@ Response:
This operation is **irreversible**. Upon confirmation, the balances of both parties should be updated according to the swap structure.
After swap tx got confirmed,**Alice** balance change would look like this:
After swap tx got confirmed,**Initiator** balance change would look like this:
```
height 42712, tx c08522c94355524cc8a1fa1514419814e99989ba503382256cbffc39a733a186
@ -173,9 +173,9 @@ Refresh done, blocks received: 42775
12.0 CT e03a140b....4ab9865c
```
Pay attention to transaction c08522c94355524cc8a1fa1514419814e99989ba503382256cbffc39a733a186. For Alice's wallet, this transaction simultaneously sends the CT token and receives ZANO (the amount minus the transaction fee).
Pay attention to transaction c08522c94355524cc8a1fa1514419814e99989ba503382256cbffc39a733a186. For Initiator's wallet, this transaction simultaneously sends the CT token and receives ZANO (the amount minus the transaction fee).
For Bob balance change would look like that:
For **Finalizer** balance change would look like that:
```
height 42712, tx c08522c94355524cc8a1fa1514419814e99989ba503382256cbffc39a733a186
@ -188,4 +188,4 @@ Refresh done, blocks received: 42776
```
From Bob's wallet perspective same transaction c08522c94355524cc8a1fa1514419814e99989ba503382256cbffc39a733a186 sends 10 Zano and receives 2 CT tokens.
From Finalizer's wallet perspective same transaction c08522c94355524cc8a1fa1514419814e99989ba503382256cbffc39a733a186 sends 10 Zano and receives 2 CT tokens.

View file

@ -1,4 +1,4 @@
{
"label": "Methods",
"label": "Commands",
"position": 2
}

View file

@ -1,9 +1,9 @@
# emit-asset
# emit_asset
Mint more coins for the asset, possible only if current wallet is a maintainer for the asset
### Command
```
emmit_asset <asset_id> <amount>
emit_asset <asset_id> <amount>
```

View file

@ -0,0 +1,407 @@
---
sidebar_position: 1
---
# Exchange integration full guide
## Table of Contents
- [Exchange integration full guide](#exchange-integration-full-guide)
- [Table of Contents](#table-of-contents)
- [Introduction](#introduction)
- [Creating a Wallet](#creating-a-wallet)
- [Seed phrase backup](#seed-phrase-backup)
- [Receiving Money with Payment ID](#receiving-money-with-payment-id)
- [Processing Incoming Transactions](#processing-incoming-transactions)
- [Requesting Wallet Balance](#requesting-wallet-balance)
- [Searching for Transactions in the Wallet](#searching-for-transactions-in-the-wallet)
- [Transfer Coins](#transfer-coins)
- [Legacy methods](#legacy-methods)
## Introduction
Zano is a privacy-oriented blockchain from the CryptoNote family, which makes working with the wallet somewhat different from traditional blockchains like Bitcoin or Ethereum. In this article, we will show how to work with the wallet and how to build multi-user custody on it.
Architecturally, Zano consists of two modules - a **full node(daemon)** and a **wallet**. Both of these modules provide their own RPC API. Therefore, when you set up Zano on your server, you compile the **full node** (make target “**daemon**”, executable name **zanod**) and the console wallet (**simplewallet**), and run both, so that the wallet can connect to the full node through the RPC API via localhost (For security reasons, it is highly recommended to use ONLY your own full node).
Thus, the RPC API in Zano is divided into two parts - the DAEMON RPC API and the WALLET RPC API. This is due to the fact that, unlike EVM or Bitcoin networks, you cannot simply request the balance of a specific address from the Zano node. To get the balance of a specific address, you need to know its secret key and perform computationally complex operations. Therefore, there is a process of synchronizing the wallet with the daemon. If you have a wallet created, for example, a year or two ago and you haven't opened it for a long time or have restored it, the synchronization process may take some time. If the wallet was online a few days ago, the synchronization happens quickly - less than a minute.
Zano is a platform where anyone can deploy their own asset, which will have the same privacy features as Zano itself. Such assets are called **Confidential Assets**. Support for Confidential Assets is reflected in the API documentation and in this manual. Each asset has an identifier (**asset_id**), and only this asset_id identify this specific asset. All other attributes of the asset may match similar attributes of other assets
## Creating a Wallet
To create a new wallet, you need to run the following command (you will be prompted to enter a new password for the wallet; do not use simple passwords and make sure to remember this password):
~/zano/build # src/simplewallet --generate-new-wallet=custody_wallet.zan
Zano simplewallet v2.0.0.333
password: *******
Generated new wallet: ZxCk74TxaFsRvbHrvebi5fgBLXDWukJ3VRXk6PENQ4orUTRfh11EHjCgCBxokeg5FEPHumvqJ76ikKHnD43iGjsE1cVfgebFa
view key: f665686bbc719569e9f6c1e36058dcda011ddd55a584443b64c1e7bca5bbdd04
**********************************************************************
Your wallet has been generated.
**********************************************************************
A wallet can operate in two modes - command line interface mode, when it is started only with the **--wallet-file** parameter, or RPC server mode, when in addition it has the **--rpc-bind-port=port_number** parameter. When the wallet is in command line mode, you can do various commands to it, such as **transfer** or **deploy_new_asset**, and thus work with the wallet. You can view the list of commands by typing **help** in command line mode.
## Seed phrase backup
After you have created a new wallet, run it in command line mode to save the seed phrase:
src/simplewallet --wallet-file=custody_wallet.zan
Zano simplewallet v2.0.0.333
password: *******
Opened wallet: ZxCk74TxaFsRvbHrvebi5fgBLXDWukJ3VRXk6PENQ4orUTRfh11EHjCgCBxokeg5FEPHumvqJ76ikKHnD43iGjsE1cVfgebFa
**********************************************************************
Use "help" command to see the list of available commands.
**********************************************************************
Starting refresh...
Refresh done, blocks received: 1440
balance unlocked / [balance total] ticker asset id
0.0 ZANO d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a
[Zano wallet ZxCk74]:
After the wallet has synchronized, enter the command **show_seed**. First, the wallet will ask for its own password for security reasons (the one you specified when creating the wallet). After this, you will be prompted to enter a special password that will protect your seed phrase. ([More about Secure Seed](https://docs.zano.org/docs/use/seed-phrase/)) If you leave this password empty, an unprotected seed phrase will be generated, and anyone who gains access to the seed phrase will be able to control all assets.
[Zano wallet ZxCk74]: show_seed
Enter password to confirm operation:
*****
Please enter a password to secure this seed. Securing your seed is HIGHLY recommended. Leave password blank to stay unsecured.
Remember, restoring a wallet from Secured Seed can only be done if you know its password.
Enter seed password: **********
Confirm seed password: **********
heart eat cost little goodbye arrive commit dreamer stick reason freeze left okay cousin frustrate certainly focus town proud chin stretch difference easily content couple land
[Zano wallet ZxCk74]:
!!! Be sure to save this seed phrase in a secure place. If the seed phrase is lost, the wallet may become impossible to restore, and all assets may be lost.
## Receiving Money with Payment ID
Each wallet file in Zano is always one address and one secret key (in fact, it's a two secrete keys, but this is not important in the context of this manual). Zano does not support HD wallets for a number of technical reasons. Instead, for multi-user support, a so-called **payment_id** is used, which is a special identifier associated with the user. Each incoming transaction that contains this payment_id is considered credited to the balance of this user. Typically, a **payment_id** is an 8-byte random number generated by an exchange (or another custody service). It can be up to 128 bytes, but it is usually 8 bytes.
**IMPORTANT**: Users should never "operate" their payment_id anywhere under any circumstances. Instead, an **integrated address** is used. An **integrated address** is a special address format that encodes the user's payment_id along with the base wallet address, eliminating errors or typos. To generate an integrated address, you can use the WALLET RPC API [make_integrated_address](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/make_integrated_address/):
```json
Request:
{
"id": 0,
"jsonrpc": "2.0",
"method": "make_integrated_address",
"params": {
"payment_id": "1dfe5a88ff9effb3"
}
}
Response:
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"integrated_address": "iZ2EEMZWeKBRvbHrvebi5fgBLXDWukJ3VRXk6PENQ4orUTRfh11EHjCgCBxokeg5FEPHumvqJ76ikKHnD43iGjsECvV53PeAEkM3CLGRmST3",
"payment_id": "1dfe5a88ff9effb3"
}
}
```
An address that starts with a lowercase letter "i" is an **Integrated Address**. It is always longer than a regular address and looks something like this: "iZ2EEMZWeKBRvbHrvebi5fgBLXDWukJ3VRXk6PENQ4orUTRfh11EHjCgCBxokeg5FEPHumvqJ76ikKHnD43iGjsECvV53PeAEkM3CLGRmST3". Only such an address can be shown to the user as their own deposit address. Transactions sent to this address will always have the payment_id specified when creating the address.
## Processing Incoming Transactions
There are several ways to get information about transactions for a Zano wallet. We will review most convenient and also mention other legacy approaches at the end.
The main method for obtaining transaction history information is [get_recent_txs_and_info2](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/get_recent_txs_and_info2/). In the example below, we removed excessive and irrelevant for this article information from the response and left only those fields that are essential for processing custody.
```json
Request:
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_recent_txs_and_info2",
"params": {
"count": 100,
"exclude_mining_txs": false,
"exclude_unconfirmed": true,
"offset": 0,
"order": "FROM_END_TO_BEGIN",
"update_provision_info": true
}
}
Response:
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"pi":{
"curent_height": 100010,
},
"last_item_index": 1,
"total_transfers": 2,
"transfers": [
{
"comment": "Comment here",
"fee": 10000000000,
"height": 100000,
"payment_id": "1dfe5a88ff9effb3",
"subtransfers": [
{
"amount": 1000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"is_income": true
},
{
"amount": 1000000000000,
"asset_id": "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a",
"is_income": true
}
],
"timestamp": 1712590951,
"transfer_internal_index": 1,
"tx_hash": "bfaf3abfd644095509650e12c8f901e6731a2e3e1366d3dbeddb0c394cd11db8",
"unlock_time": 0
},
{
"comment": "Comment here",
"fee": 10000000000,
"height": 100001,
"payment_id": "1dfe5a88ff9effb3",
"subtransfers": [
{
"amount": 1000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"is_income": false
},
{
"amount": 1000000000000,
"asset_id": "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a",
"is_income": true
}
],
"timestamp": 1712590951,
"transfer_internal_index": 0,
"tx_hash": "5509650e12c8f901e6731a2bfaf3abfd64409e3e1366d3d94cd11db8beddb0c3",
"unlock_time": 0
}
]
}
}
```
You can read the transaction feed either from the oldest to the most recent (set "**order**" to "**FROM_END_TO_BEGIN**"), or vice versa - from the most recent to the oldest (set "**order**" to "**FROM_BEGIN_TO_END**"). Generally, when doing custody, you read the transaction feed from the wallet starting from the oldest transactions and read the entire history to the most recent transactions. To do this, set the "**order**" field in the request to "**FROM_END_TO_BEGIN**". If the response returns fewer elements than the "count" specified in the request (in our example, this is 100), it means that you have read the entire transaction history from end to the most recent transactions. If not, you need to continue calling [get_recent_txs_and_info2](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/get_recent_txs_and_info2/) in such a way that each subsequent call passes the "**offset**" value, which indicates how many elements have already been read from the feed (if using the **FROM_END_TO_BEGIN** mode, you can also use the value from the "**transfer_internal_index**" field in the most recent element of the "transfers" array). Keep in mind that the number of transactions you count as transfers to users may differ from the total number of transactions read due to some transactions that you may decide to ignore as non-legit.
The list of transactions is in the "transfers" array. The response header has a **pi.current_height field**, which indicates the current highest known blockchain height to the wallet. Relative to this number, you will calculate the number of confirmations for each transaction in the "**transfers**" array (specifically, subtract the "**height**" field from **pi.current_height field**).
Each element in the "transfers" array represents a description of a transaction with its details. The important fields in this structure are:
- **"height"**: block number when transaction got included
- **"payment_id"**: "1dfe5a88ff9effb3" - user-associated identification, that was encoded
in integrated address of the user. If transaction has valid
payment_id, that means incoming payments from this transaction should
go to user associated with this payment_id
Since Zano is a multi-asset platform, each transaction might contain multiple transfers (different assets). The “**subtransfers**” array lists each asset that was part of this transaction:
```json
"subtransfers": [
{
"amount": 1000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"is_income": false
},
{
"amount": 1000000000000,
"asset_id": "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a",
"is_income": true
}
]
```
IMPORTANT:
- Do not account deposits for transactions that have not reached 10 confirmations. Sometimes the network undergoes reorganisation among the last 2-3 blocks. This is normal, and within this number of confirmations, the transaction sequence may change, including the removal of transactions that previously appeared with 2-3 confirmations. Read the history only until those transactions that got 10 confirmations, when it comes to transactions that haven't mach this number of transactions - re-read **get_recent_txs_and_info2** until you see those transactions in response with 10 confirmations. Make your code fully aware of such situations and re-read history for those transactions.
- Consider only those **asset_id** that you know, and ignore any others.
- When depositing an asset, ensure the correct interpretation of the decimal point, as it may differ for each asset. You can request asset details via the DAEMON RPC API [get_asset_info](https://docs.zano.org/docs/build/rpc-api/daemon-rpc-api/get_asset_info/). Native coins have the asset_id d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a and should always be deposited for.
- A transaction may contain both incoming and outgoing subtransfers. Check the **is_income** field for each element.
- We also recommend specifying the **"exclude_unconfirmed": true** field in your request, as unconfirmed transactions are not important in the context of custody.
- Do not deposit transactions where the "**unlock_time**" field is different from 0, as such transactions may be locked for a long period.
- Over time, the payment_id may be pruned from old transactions history (over a year old), so backup the transfer history of your users to avoid future issues.
## Requesting Wallet Balance
To request the current balance of the wallet, you can use the WALLET RPC API [getbalance](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/getbalance).
```json
Request:
{
"id": 0,
"jsonrpc": "2.0",
"method": "getbalance",
"params": {
}
}
Response:
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"balances": [
{
"asset_info": {
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped USD",
"hidden_supply": false,
"meta_info": "Stable and private",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"ticker": "ZUSD",
"total_max_supply": 1000000000000000000
},
"awaiting_in": 1000000000000,
"awaiting_out": 2000000000000,
"total": 100000000000000,
"unlocked": 50000000000000
},
{
"asset_info": {
"asset_id": "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a",
"current_supply": 13000000000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped USD",
"hidden_supply": false,
"meta_info": "Stable and private",
"owner": "",
"ticker": "ZANO",
"total_max_supply": 18000000000000000000000
},
"awaiting_in": 2000000000000,
"awaiting_out": 1000000000000,
"total": 500000000000000,
"unlocked": 10000000000000
}
]
}
}
```
Response returns a list of assets that are present in the wallet, and for each asset, there are details ("**asset_info**") as well as the balances in the "**total**" and "**unlocked**" fields. The "**unlocked**" field shows how many coins are currently available for sending (this does not include incoming transactions that have not reached 10 confirmations, for example change). The "**total**" field shows all assets, including those that have not reached the required number of confirmations.
IMPORTANT: Assets not included in the public or private whitelist do not appear in the [getbalance](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/getbalance) response. There is a public whitelist maintained by the project community, as well as a private whitelist for each wallet, which is stored in the wallet's file. If you want to see the balance of an asset not present in the public whitelist, you need to call the WALLET RPC API [assets_whitelist_add](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/assets_whitelist_add):
```json
Request:
{
"id": 0,
"jsonrpc": "2.0",
"method": "assets_whitelist_add",
"params": {
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8"
}
}
Response:
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"asset_descriptor": {
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped USD",
"hidden_supply": false,
"meta_info": "Stable and private",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"ticker": "ZUSD",
"total_max_supply": 1000000000000000000
},
"status": "OK"
}
}
```
## Searching for Transactions in the Wallet
You can also search for an arbitrary transaction by its tx_id or using other available parameters in the API [search_for_transactions2](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/search_for_transactions2):
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "search_for_transactions2",
"params": {
"filter_by_height": true,
"in": true,
"max_height": 20000,
"min_height": 11000,
"out": true,
"pool": false,
"tx_id": "97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"
}
}
```
## Transfer Coins
Transferring coins is done using the WALLET RPC API [transfer](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/transfer/):
```json
Request:
{
"id": 0,
"jsonrpc": "2.0",
"method": "transfer",
"params": {
"destinations": [{
"address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp",
"amount": 10000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852"
}],
"fee": 10000000000,
"hide_receiver": true,
"mixin": 15,
"push_payer": false
}
}
Response:
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"tx_hash": "01220e8304d46b940a86e383d55ca5887b34f158a7365bbcdd17c5a305814a93",
"tx_size": 1234,
"tx_unsigned_hex": ""
}
}
```
It is good practice to check that your balance is sufficient for sending the desired asset before making a transfer; otherwise, there may be an error in sending the transaction. Sometimes, you need to wait up to 10 minutes to gather the required number of confirmations for the change (if the value in the unlocked field is still less than the value in the total field in the balances response). If you received a transaction hash in the “**tx_hash**” field, it means the transaction has been successfully created and accepted by the daemon for relay across the network. Once this transaction is included in a block and starts getting confirmations, you will see it in the results of [get_recent_txs_and_info2](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/get_recent_txs_and_info2/) (the **is_income** field will be false).
IMPORTANT: Before sending, be sure to check that the address you are sending to does not belong to your wallet, even if it is an integrated address of another user on your base wallet. You cannot send transactions between users within the same wallet. To check the base wallet address from integrated address, you need to call the WALLET RPC API [split_integrated_address](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/split_integrated_address):
```json
Request:
{
"id": 0,
"jsonrpc": "2.0",
"method": "split_integrated_address",
"params": {
"integrated_address": "iZ2EMyPD7g28hgBfboZeCENaYrHBYZ1bLFi5cgWvn4WJLaxfgs4kqG6cJi9ai2zrXWSCpsvRXit14gKjeijx6YPCLJEv6Fx4rVm1hdAGQFis"
}
}
Response:
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"payment_id": "1dfe5a88ff9effb3",
"standard_address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp"
}
}
```
You need to check the **standard_address** field and ensure it is different from your own custody wallet. If the fields match, it means an attempt is being made to perform an internal transfer within your own custody, from one user to another. Such internal transactions are typically handled offchain by well-designed services.
IMPORTANT: Avoid sending to multiple destinations in a single transaction, as there are some limitations. For example, you cannot specify multiple different integrated addresses in multiple destinations for one transaction.
## Legacy methods
[get_bulk_payments](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/get_bulk_payments)
[get_payments](https://docs.zano.org/docs/build/rpc-api/wallet-rpc-api/get_payments)

View file

@ -0,0 +1,39 @@
# Hi-Load Servers (WARP-mode)
To improve the efficiency of production servers under heavy loads—such as remote nodes for mobile wallets—we have implemented a special daemon mode called **WARP-mode**(derived from “full warm up”). This mode requires at least 64GB of physical RAM, but it can deliver up to a x20 performance boost compared to the standard mode.
To use WARP-mode, make sure your server has at least 64 GB of physical RAM.
To enable WARP-mode launch daemon with this command line option:
```bash
zanod --do-warp-mode
2025-Mar-13 13:51:18.787912 Zano v2.1.0.382[926549e]
2025-Mar-13 13:51:18.793423 Starting...
2025-Mar-13 13:51:18.794923 Module folder: C:\Users\roky\home\projects\zano_UI_x64\build\src\Release\zanod.exe
2025-Mar-13 13:51:18.806597 Pre-downloading not needed (db file size = 12569350144)
2025-Mar-13 13:51:18.808596 Initializing p2p server...
......
2025-Mar-13 13:51:19.042870 Core initialized OK
2025-Mar-13 13:51:19.044871 Initializing full warp-mode
2025-Mar-13 13:51:19.045871 Using db items cache size(L2): 38.91 M items
2025-Mar-13 13:51:19.049737 [Warp]: Setting up db cache to 38.91 M items.....
2025-Mar-13 13:51:19.051743 [Warp]: Detected only 53.99 GB RAM, might be not optimal, recommended above 64.00 GB
2025-Mar-13 13:51:19.053738 [Warp]: Launching warm up....
2025-Mar-13 13:51:19.055737 Warming up starting, total blocks...3064647
2025-Mar-13 13:51:19.059450 Warming up: 0%, 1 of 3064647
2025-Mar-13 13:51:52.573744 Warming up: 0%, 28812 of 3064647
2025-Mar-13 13:51:54.604781 Warming up: 1%, 30979 of 3064647
2025-Mar-13 13:52:19.995541 Warming up: 1%, 61177 of 3064647
.....
2025-Mar-13 13:52:19.995541 [Warp]: Warm up finished!
```
This command line option reconfigure core cache paprameters and then "warm up" all data stored in databse into cache(which might take some time - up to 10 minutes), and after that the server would start handling network reaquests(RPC and P2P).
### Technical Note
From a technical standpoint, the getblocks.bin RPC request essential for wallet synchronization and one of the most time-consuming operations must load each of roughly 4,000 blocks from the database and then deserialize them into C++ structures. The same process is repeated for every transaction within each block. To alleviate this load, Zano introduced a special caching mechanism about seven years ago. Each database table has its own cache, which by default can hold around 10,000 items. This lets the daemon quickly carry out tasks needed for fast block validation (for example, calculating various block medians or recalculating the next difficulty).
To further enhance performance in production, we decided to fully leverage this cache by setting its size larger than the entire storage. This ensures that all blocks and transactions remain “hot” loaded and deserialized at all times. Currently, with over three million blocks, a fully loaded database is about 35GB. We expect this size to grow, though wallet requests typically focus on more recent blocks. Even if, in the future, the loaded database exceeds the amount of physical RAM, WARP-mode will still be significantly more efficient because any swapping is efficiently handled at the operating system level, and there is no additional deserialization phase.

4
docs/build/libraries/_category_.json vendored Normal file
View file

@ -0,0 +1,4 @@
{
"label": "Zano Libraries",
"position": 3
}

33
docs/build/libraries/overview.md vendored Normal file
View file

@ -0,0 +1,33 @@
# List of Libraries
## Zano Web3 Library (TypeScript)
Zano Web3 TS is a TypeScript library designed to facilitate interaction with the Zano Companion extension within web browsers. It enables connection to user extensions, handles authentication, and manages wallet credentials, plus it includes a server component for RPC interactions with the Zano wallet and daemon.
Github: https://github.com/hyle-team/zano_web3
Package: https://www.npmjs.com/package/zano_web
## Native Zano Wallet for IOS/Android (C++)
This C++ library provides tools for integrating Zano's wallet into native iOS and Android applications, offering a robust solution for mobile app developers working with Zano's technology. All API implemented as a plain text calls that works with JSON format, which make this library a perfect framework agnostic tool for supporting Zano.
Github: https://github.com/hyle-team/zano_native_lib
## Flutter/Android Zano Wallet Plugin (Dart)
This Dart library is tailored for integrating Zano Wallet functionalities into mobile and web applications using the Flutter framework or native Android development with Dart, making it ideal for mobile developers.
Github: https://github.com/hyle-team/zano_plugin
## SWIFT package manager plugin for Native Wallet Library for IOS/Android (C++)
A dedicated iOS library that allows for the integration of Zano's functionalities specifically within iOS applications, ensuring smooth implementation of Zano features on Apple devices.
Github: https://github.com/hyle-team/zano_native_lib_package_ios
## Zano Node Utils (JavaScript)
This utility library supports various backend operations used by mining pools
Github: https://github.com/hyle-team/zano-node-util

View file

@ -4,8 +4,41 @@ sidebar_position: 1
# Building with Zano
Welcome to the "Build with Zano" page — your key resource to initiate and develop projects on the Zano platform. As we relentlessly advance the frontiers of digital privacy, we're here to provide you with the tools and insights necessary to ensure your project not only stands out but also integrates seamlessly with the Zano ecosystem.
## Starting Your Development Journey
Kickstart your journey with our RPC API Guide. Here, you'll gain a comprehensive understanding from the [Overview](rpc-api/overview.md), and delve deeper into the specifics of [How to call the API](rpc-api/how-to-call-api.md). Whether your focus is on the [Daemon RPC API](rpc-api/daemon-rpc-api/get_alias_by_address.md) or the [Wallet RPC API](rpc-api/wallet-rpc-api/atomics_check_htlc_redeemed.md), our guide ensures clarity at every step.
### RPC API Guide
If launching your own project centered around private transactions is your goal, our Confidential Assets section provides a clear [Overview](confidential-assets/overview) along with detailed Methods to give your initiative a solid foundation.
Kickstart your journey with our RPC API Guide [Overview](rpc-api/overview.md). Here, you'll gain a comprehensive understanding from the Overview, and delve deeper into the specifics of [How to call the API](rpc-api/how-to-call-api.md). Whether your focus is on the [Daemon RPC API](rpc-api/daemon-rpc-api/get_alias_by_address.md) or the [Wallet RPC API](rpc-api/wallet-rpc-api/get_bulk_payments.md), our guide ensures clarity at every step.
### Confidential Assets
If launching your own project centered around private transactions is your goal, our [Confidential Assets](confidential-assets/overview.md) section provides detailed methods to give your initiative a solid foundation.
## Exchange Listing Guidelines
If you're looking to list your project or Zano assets on exchanges, it's crucial to follow specific guidelines to ensure compliance and success in your listings. We provide a [detailed set of guidelines](exchange-guidelines/multi-assets-custody-guide) that cover everything from technical requirements to compliance with financial regulations.
## Tools and Resources
We provide a variety of tools and [libraries](libraries/overview.md) to assist you in building robust applications:
- **Zano Web3 TS**: This TypeScript library now includes a server component for RPC interactions, simplifying the connection to Zano wallets and handling transactions directly from web applications.
- **Mobile Libraries** (Flutter/Android & iOS): These have been updated to offer more robust features for mobile developers, enabling seamless integration into a wider range of applications.
- **Native Crypto Library** for iOS/Android (C++): Updated to provide essential cryptographic functionalities needed for secure and reliable app development.
## Community and Support
Join our vibrant community of developers and privacy enthusiasts:
- **Discussions**: Engage with other developers, share your projects, and get feedback in community dev channels in [discord](https://discord.gg/wE3rmYY) and [telegram](https://t.me/zanocoin).
- **Technical Support**: Our technical team is ready to assist you with any questions or challenges you may encounter.
## Contributing to Zano
We encourage contributions from developers of all skill levels. If you're interested in contributing to the Zano project, check out our guidelines on how to contribute effectively. Your innovations and contributions help us continue to enhance the security and functionality of the Zano platform.
## Stay Updated
Keep up with the latest updates and enhancements by visiting our official [blog](https://blog.zano.org) and subscribing to our newsletter. As Zano continues to evolve, we remain committed to providing the community with cutting-edge tools and support to build secure and private digital solutions.
Embark on your development journey with Zano and leverage our comprehensive resources to build something truly impactful in the realm of digital privacy.

19
docs/build/public-nodes.md vendored Normal file
View file

@ -0,0 +1,19 @@
---
sidebar_position: 2
---
# Public Nodes
:::warning
For secutity reasons it's not recommended to use private api with public daemon
:::
## Mainnet (daemon)
http://37.27.100.59:10500/json_rpc
## Testnet (daemon)
http://37.27.100.59:10505/json_rpc

View file

@ -0,0 +1,25 @@
Check spent status of given key images.
URL: ```http:://127.0.0.1:11211/check_keyimages.bin```
### Request:
```json
{
}
```
### Request description:
```
```
### Response:
```json
{
"images_stat": [0],
"status": "OK"
}
```
### Response description:
```
"images_stat": List of spent states, where 1 means unspent and 0 means spent.
"status": Status of the call.
```

View file

@ -0,0 +1,55 @@
Decrypts transaction private information. Should be used only with your own local daemon for security reasons.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "decrypt_tx_details",
"params": {
"outputs_addresses": ["ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf","ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp"],
"tx_blob": "ewogICJ2ZXJzaW9uIjogMSwgC....iAgInZpbiI6IFsgewogICAgIC",
"tx_id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8",
"tx_secret_key": "2e0b840e70dba386effd64c5d988622dea8c064040566e6bf035034cbb54a5c08"
}
}
```
### Request description:
```
"outputs_addresses": Address of each of tx's output. Order is important and should correspond to order of tx's outputs. Empty strings are ignored.
"tx_blob": [or] base64-encoded or hex-encoded tx blob. Can be ommited if tx_id is provided.
"tx_id": [either] ID for a transaction if it is already in the blockchain. Can be ommited if tx_blob is provided.
"tx_secret_key": Hex-encoded transaction secret key.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"decoded_outputs": [{
"address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp",
"amount": 10000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"out_index": 1
}],
"status": "OK",
"tx_in_json": "ewogICJ2ZXJzaW9uIjogMSwgC....iAgInZpbiI6IFsgewogICAgIC",
"verified_tx_id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8"
}
}
```
### Response description:
```
"decoded_outputs": Transaction's decoded outputs
"address": Destination address.
"amount": Amount begin transferred.
"asset_id": Asset id.
"out_index": Index of the corresponding output in the transaction.
"status": Status code of operation, OK if success
"tx_in_json": Serialized transaction represented in JSON, encoded in Base64.
"verified_tx_id": (Re)calculated transaction id. Can be used in third-party proof generation.
```

View file

@ -0,0 +1,55 @@
Retrieves information about outputs in recent blocks that are targeted for the given address with the corresponding secret view key.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "find_outs_in_recent_blocks",
"params": {
"address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7",
"blocks_limit": 1711021795,
"viewkey": "5fa8eaaf231a305053260ff91d69c6ef1ecbd0f5"
}
}
```
### Request description:
```
"address": Target address for which outputs are being searched
"blocks_limit": Block count limit. If 0, only the transaction pool will be searched. Maximum and default is 5.
"viewkey": Secret view key corresponding to the given address.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"blockchain_top_block_height": 2555000,
"blocks_limit": 5,
"outputs": [{
"amount": 1000000000000,
"asset_id": "cc4e69455e63f4a581257382191de6856c2156630b3fba0db4bdd73ffcfb36b6",
"output_tx_index": 2,
"tx_block_height": 2555000,
"tx_id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8"
}],
"status": "OK"
}
}
```
### Response description:
```
"blockchain_top_block_height": Height of the most recent block in the blockchain.
"blocks_limit": Used limit for block count.
"outputs": List of found outputs.
"amount": The amount of the output.
"asset_id": Asset ID of the output.
"output_tx_index": Index of the output in the transaction.
"tx_block_height": Block height where the transaction is present.
"tx_id": Transaction ID where the output is present, if found.
"status": Status of the call.
```

View file

@ -0,0 +1,25 @@
NO DESCRIPTION
URL: ```http:://127.0.0.1:11211/force_relay```
### Request:
```json
{
"txs_as_hex": ["000535b8b2e.....3685a86","00087368b2e.....349b77f"]
}
```
### Request description:
```
"txs_as_hex": List of transactions as a hexadecimal strings.
```
### Response:
```json
{
"status": "OK"
}
```
### Response description:
```
"status": Status of the call.
```

View file

@ -1,32 +1,42 @@
Returns alias details by alias address.
### Request
Retrieves all aliases registered for a given address.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_alias_by_address",
"params": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf"
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_alias_by_address",
"params": ""
}
```
---
### Response
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_alias_by_address",
"params": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf"
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"alias_info_list": [{
"address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7",
"alias": "zxdya6q6whzwqjkmtcsjpc3ku",
"comment": "Society is never gonna make any progress until we all learn to pretend to like each other.",
"tracking_key": "18bb94f69ed61b47b6556f3871b89dff8f9a6f4f798f706fd199b05ccf8ef20c"
}],
"status": "OK"
}
}
```
### Response description:
```
"alias_info_list": List of alias_rpc_details objects, each containing detailed information about each alias registered to the specified address.
"address": Address of the alias.
"alias": Alias itself, a brief shortcut for an address.
"comment": Arbitrary comment (optional).
"tracking_key": View secret key of the corresponding address (optional).
"status": Status of the call.
- address - string; public address associated with requested alias.
- alias - string; alias associated with the provided address
- comment - string; an arbitrary comment set by the owner. Can be empty.
- tracking_key - string; private view key for public address. Can be empty.
```

View file

@ -1,39 +1,43 @@
Returns alias details by alias name.
### Request
Retrieves information about a specific address alias.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_alias_details",
"params": {
"alias": "kekzploit"
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_alias_details",
"params": {
"alias": "gigabyted"
}
}
```
### Request description:
```
"alias": The alias name for which details are being requested.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"alias_details": {
"address": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf",
"comment": "",
"tracking_key": ""
},
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"alias_details": {
"address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7",
"comment": "Society is never gonna make any progress until we all learn to pretend to like each other.",
"tracking_key": "18bb94f69ed61b47b6556f3871b89dff8f9a6f4f798f706fd199b05ccf8ef20c"
},
"status": "OK"
}
}
```
### Response description:
```
"alias_details": Contains the detailed information about the specified alias, including the associated wallet address, tracking key, comment etc..
"address": Address of the alias.
"comment": Arbitrary comment (optional).
"tracking_key": View secret key of the corresponding address (optional).
"status": Status of the call.
### Response information
- address - string; public address associated with requested alias.
- comment - string; an arbitrary comment set by the owner. Can be empty.
- tracking_key - string; private view key for public address. Can be empty.
```

View file

@ -1,33 +1,36 @@
Returns current reward that must be paid to register an alias name.
### Request
Retrieves the cost of registering an alias on the blockchain.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_alias_reward",
"params": {
"alias": "mickymouse"
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_alias_reward",
"params": {
"alias": "zxdya6q6whzwqjkmtcsjpc3ku"
}
}
```
### Request description:
```
"alias": The alias name for which the registration cost is being queried.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"reward": 100000000000,
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"reward": 100000000000,
"status": "OK"
}
}
```
### Response description:
```
"reward": The registration cost for the specified alias.
"status": Status of the call.
### Response information
- reward - unsigned int; current reward (in atomic units) to be paid for an alias.
```

View file

@ -0,0 +1,56 @@
Retrieves a specified portion of all registered aliases, allowing pagination through large sets of aliases.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_aliases",
"params": {
"count": 2,
"offset": 0
}
}
```
### Request description:
```
"count": The number of aliases to retrieve from the specified offset.
"offset": The offset in the list of all aliases from which to start retrieving.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"aliases": [{
"address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7",
"alias": "zxdya6q6whzwqjkmtcsjpc3ku",
"comment": "Society is never gonna make any progress until we all learn to pretend to like each other.",
"tracking_key": "18bb94f69ed61b47b6556f3871b89dff8f9a6f4f798f706fd199b05ccf8ef20c"
},{
"address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7",
"alias": "zxdya6q6whzwqjkmtcsjpc3ku",
"comment": "Society is never gonna make any progress until we all learn to pretend to like each other.",
"tracking_key": "18bb94f69ed61b47b6556f3871b89dff8f9a6f4f798f706fd199b05ccf8ef20c"
}],
"status": "OK"
}
}
```
### Response description:
```
"aliases": List of alias_rpc_details objects, each containing information about an individual alias retrieved based on the request parameters.
"address": Address of the alias.
"alias": Alias itself, a brief shortcut for an address.
"comment": Arbitrary comment (optional).
"tracking_key": View secret key of the corresponding address (optional).
"address": Address of the alias.
"alias": Alias itself, a brief shortcut for an address.
"comment": Arbitrary comment (optional).
"tracking_key": View secret key of the corresponding address (optional).
"status": Status of the call.
```

View file

@ -1,48 +1,52 @@
Returns all registered aliases
### Request
Retrieves all registered aliases along with associated information.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_all_alias_details"
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_all_alias_details",
"params": {
}
}
```
---
### Response
:::danger
This request has been shortened for the sake of the example, a real response will return many more aliases.
:::
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"aliases": [
{
"address": "ZxCn8fKmvenQRNdoFFsDinWMfucfC5H9Abb71HjUFbPcEgaCk1fdjqSe4ZDskYgLQtRUFYDH1AqUAWDHjmu84hSG394mceDgb",
"alias": "------",
"comment": "Coolest username",
"tracking_key": ""
},
],
"status": "OK"
}
}
### Request description:
```
### Reponse information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"aliases": [{
"address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7",
"alias": "zxdya6q6whzwqjkmtcsjpc3ku",
"comment": "Society is never gonna make any progress until we all learn to pretend to like each other.",
"tracking_key": "18bb94f69ed61b47b6556f3871b89dff8f9a6f4f798f706fd199b05ccf8ef20c"
},{
"address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7",
"alias": "zxdya6q6whzwqjkmtcsjpc3ku",
"comment": "Society is never gonna make any progress until we all learn to pretend to like each other.",
"tracking_key": "18bb94f69ed61b47b6556f3871b89dff8f9a6f4f798f706fd199b05ccf8ef20c"
}],
"status": "OK"
}
}
```
### Response description:
```
"aliases": List of alias_rpc_details objects, each containing information about an individual alias.
"address": Address of the alias.
"alias": Alias itself, a brief shortcut for an address.
"comment": Arbitrary comment (optional).
"tracking_key": View secret key of the corresponding address (optional).
"address": Address of the alias.
"alias": Alias itself, a brief shortcut for an address.
"comment": Arbitrary comment (optional).
"tracking_key": View secret key of the corresponding address (optional).
"status": Status of the call.
- address - string; address of a corresponding wallet.
- alias - string; alias name.
- comment - string; user-defined comment, made by alias owner (optional).
- tracking_key - string; hex-encoded secret view key (optional) of the wallet.
```

View file

@ -1,33 +1,34 @@
Returns IDs for all txs in the pool.
### Request
Retrieves a list of all transaction IDs currently in the transaction pool.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_all_pool_tx_list"
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_all_pool_tx_list",
"params": {
}
}
```
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"ids": [
"07af9af51abace52c6c9f5e96eac1f4123e56d8d2b2e1ac2ba5c6d68be94680f",
"968d44f9443b067debc4a467174ad5b640690e165a2f8d45b2904d082bc1312e"
],
"status": "OK"
}
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"ids": [""],
"status": "OK"
}
}
```
### Response description:
```
"ids": List of all transaction IDs currently in the transaction pool.
"status": Status of the call.
- ids - array of strings; list of hash identifiers for all transactions that are currently in the pool.
```

View file

@ -1,142 +1,147 @@
Returns block details for a specified identifier. Only for blocks in alternative chains.
### Request
Retrieves detailed information about a specific block identified by its hash.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_alt_block_details",
"params": {
"id": "498cafd7ae8d7a82abd5267a005ce01482d5580eddd9805dd0162e465cacb7df"
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_alt_block_details",
"params": {
"id": "4cf2c7c7e16d1a2a0771cd552c696dd94e7db4e1031982ed88eff99d5006ee4a"
}
}
```
### Request description:
```
"id": The hash ID of the block for which detailed information is being requested.
### Request parameters
- id - hash identifier for a block.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_details": {
"actual_timestamp": 1558705296,
"already_generated_coins": "0",
"base_reward": 1000000000000,
"blob": "",
"block_cumulative_size": 0,
"block_tself_size": 0,
"cumulative_diff_adjusted": "47701129767973676",
"cumulative_diff_precise": "12602457701330728735458",
"difficulty": "2053263042953598309",
"effective_fee_median": 0,
"height": 23138,
"id": "5391963eb274af8391fa89bc711122b5db9b6c3703cb8865d45505f919f9842b",
"is_orphan": true,
"miner_text_info": "1.0.31[29c0487]",
"object_in_json": "...",
"penalty": 0,
"pow_seed": "",
"prev_id": "62c3d7a0a2f7d253b78a8e48dc0407e7d8f0d26b4fdb8b52687b07a7c4020ba9",
"summary_reward": 1000000000000,
"this_block_fee_median": 0,
"timestamp": 1558705800,
"total_fee": 0,
"total_txs_size": 0,
"transactions_details": [
{
"amount": 2000000000000,
"blob": "",
"blob_size": 203,
"extra": [
{
"datails_view": "",
"short_view": "7eaeb2490d85b17773b30ffe9f32fce50a1e89ee5ed258531e6b66ae13b00327",
"type": "pub_key"
},
{
"datails_view": "312e302e33315b323963303438375d",
"short_view": "15 bytes",
"type": "user_data"
},
{
"datails_view": "",
"short_view": "0 bytes",
"type": "extra_padding"
},
{
"datails_view": "cefd",
"short_view": "cefd",
"type": "XOR"
},
{
"datails_view": "",
"short_view": "height: 23148",
"type": "unlock_time"
},
{
"datails_view": "",
"short_view": "timestamp: 1558705296 Fri, 24 May 2019 13:41:36 GMT",
"type": "pos_time"
}
],
"fee": 0,
"id": "a88f4ae2a89d5cbf9a76946785b6b45e898177cc0acd0b9c6ec5e35ccd73d9e8",
"ins": [
{
"amount": 0,
"kimage_or_ms_id": "",
"multisig_count": 0
},
{
"amount": 1000000000000,
"global_indexes": [
32159
],
"kimage_or_ms_id": "5125de7598e723efba04d83258f31a3b30b21ed036f8e52b0669b12b93264267",
"multisig_count": 0
}
],
"keeper_block": 0,
"object_in_json": "",
"outs": [
{
"amount": 1000000000000,
"global_index": 0,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": [
"6acb06f7e4916d38ecafb537065e4dedaf0949fd49787fad55256770eaa8b029"
]
},
{
"amount": 1000000000000,
"global_index": 0,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": [
"c5179786faf5fe9f0d2adfcf6c9b069aae0e1393b771efddef8efade4bb4ce73"
]
}
],
"pub_key": "7eaeb2490d85b17773b30ffe9f32fce50a1e89ee5ed258531e6b66ae13b00327",
"timestamp": 1558705296
}
],
"type": 0
},
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_details": {
"actual_timestamp": 1557345925,
"already_generated_coins": "17517253670000000000",
"base_reward": 1000000000000,
"blob": "",
"block_cumulative_size": 6794,
"block_tself_size": 0,
"cumulative_diff_adjusted": "42413051198",
"cumulative_diff_precise": "28881828324942",
"difficulty": "951296929031",
"effective_fee_median": 0,
"height": 51,
"id": "af05b814c75e10872afc0345108e830884bc4c32091db783505abe3dac9929cf",
"is_orphan": false,
"miner_text_info": "",
"object_in_json": "",
"penalty": 0,
"pow_seed": "",
"prev_id": "37fe382c755bb8869e4f5255f2aed6a8fb503e195bb4180b65b8e1450b84cafe",
"summary_reward": 1001000000000,
"this_block_fee_median": 1000000000,
"timestamp": 1557345925,
"total_fee": 1000000000,
"total_txs_size": 6794,
"transactions_details": [{
"amount": 18999000000000,
"attachments": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"blob": "ARMBgKCUpY0dBBoAAAAAAAAAABoCAAAAAAAAABoKAAAAAAAAABoPAAAAAAAAACVA4FRLH",
"blob_size": 6794,
"extra": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"fee": 1000000000,
"id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8",
"ins": [{
"amount": 1000000000000,
"global_indexes": [0,2,12,27],
"htlc_origin": "",
"kimage_or_ms_id": "2540e0544b1fed3b104976f803dbd83681335c427f9d601d9d5aecf86ef276d2",
"multisig_count": 0
}],
"keeper_block": 51,
"object_in_json": "ewogICJ2ZXJzaW9uIjogMSwgCiAgInZpbiI6IFsgewogICAgIC",
"outs": [{
"amount": 9000000000,
"global_index": 0,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": ["7d0c755e7e24a241847176c9a3cf4c970bcd6377018068abe6fe4535b23f5323"]
}],
"pub_key": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"timestamp": 1557345925
}],
"type": 1
},
"status": "OK"
}
}
```
### Response description:
```
"block_details": Detailed information about the block retrieved based on the provided hash ID.
"actual_timestamp": Actual timestamp encoded in the block's extra data for PoS blocks.
"already_generated_coins": Total amount of coins generated in the blockchain up to this block.
"base_reward": Base mining reward for the block.
"blob": Serialized form of the block.
"block_cumulative_size": Cumulative size of the block including all transactions.
"cumulative_diff_adjusted": Adjusted cumulative difficulty of the blockchain up to this block.
"cumulative_diff_precise": Precise cumulative difficulty of the blockchain up to this block.
"difficulty": Mining difficulty of the block.
"height": Height of the block in the blockchain.
"id": Unique identifier of the block.
"is_orphan": Indicates whether the block is an orphan.
"miner_text_info": Additional textual information provided by the miner of the block.
"object_in_json": Serialized representation of the block in JSON format.
"penalty": Penalty applied to the reward if the block is larger than median but not large enough to be rejected.
"prev_id": Hash of the previous block in the chain.
"summary_reward": Total reward for the block, including base reward and transaction fees (legacy).
"this_block_fee_median": Median transaction fee of the transactions within this block.
"timestamp": Timestamp when the block was created, in PoS blocks used for mining.
"total_fee": Total transaction fees included in the block.
"total_txs_size": Total size of all transactions included in the block.
"transactions_details": Detailed information about each transaction included in the block.
"amount": Total output amount of the transaction (legacy, for pre-Zarcanum txs).
"attachments": Additional attachments to the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"blob": Serialized form of the transaction, encoded in Base64.
"blob_size": Size of the serialized transaction in bytes.
"extra": Extra data associated with the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"fee": Transaction fee in the smallest currency unit.
"id": Hash of the transaction.
"ins": Inputs of the transaction.
"amount": The amount of coins being transacted.
"global_indexes": List of global indexes indicating the outputs referenced by this input, where only one is actually being spent.
"htlc_origin": Origin hash for HTLC (Hash Time Locked Contract).
"kimage_or_ms_id": Contains either the key image for the input or the multisig output ID, depending on the input type.
"multisig_count": Number of multisig signatures used, relevant only for multisig outputs.
"keeper_block": Block height where the transaction is confirmed, or -1 if it is unconfirmed.
"object_in_json": Serialized transaction represented in JSON, encoded in Base64.
"outs": Outputs of the transaction.
"amount": The output's amount, 0 for ZC outputs.
"global_index": Global index of the output for this specific amount.
"is_spent": Indicates whether the output has been spent.
"minimum_sigs": Minimum number of signatures required to spend the output, for multisig outputs only.
"pub_keys": List of public keys associated with the output.
"pub_key": Public key associated with the transaction.
"timestamp": Timestamp when the transaction was created.
"type": Type of the block.
"status": Status of the call.
### Response information
- see get_blocks_details method for more details.
```

View file

@ -1,53 +1,149 @@
Returns alternative blocks details for a specified range.
### Request
Retrieves details of alternative blocks in the blockchain, allowing for pagination through large datasets.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_alt_blocks_details",
"params": {
"offset": 1,
"count": 1
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_alt_blocks_details",
"params": {
"count": 1,
"offset": 0
}
}
```
### Request description:
```
"count": The number of alternative blocks to retrieve from the specified offset.
"offset": The offset in the list of alternative blocks from which to start retrieval.
### Request parameters
- offset - starting offset in the global list of alternative blocks
- count - number of blocks to be requested
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"blocks": [{
"actual_timestamp": 1537462404,
"already_generated_coins": 0,
"base_reward": 0,
"blob": "",
"block_cumulative_size": 0,
....
},{
"actual_timestamp": 1537462619,
"already_generated_coins": 0,
"base_reward": 0,
"blob": "",
"block_cumulative_size": 0,
....
}],
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"blocks": [{
"actual_timestamp": 1557345925,
"already_generated_coins": "17517253670000000000",
"base_reward": 1000000000000,
"blob": "",
"block_cumulative_size": 6794,
"block_tself_size": 0,
"cumulative_diff_adjusted": "42413051198",
"cumulative_diff_precise": "28881828324942",
"difficulty": "951296929031",
"effective_fee_median": 0,
"height": 51,
"id": "af05b814c75e10872afc0345108e830884bc4c32091db783505abe3dac9929cf",
"is_orphan": false,
"miner_text_info": "",
"object_in_json": "",
"penalty": 0,
"pow_seed": "",
"prev_id": "37fe382c755bb8869e4f5255f2aed6a8fb503e195bb4180b65b8e1450b84cafe",
"summary_reward": 1001000000000,
"this_block_fee_median": 1000000000,
"timestamp": 1557345925,
"total_fee": 1000000000,
"total_txs_size": 6794,
"transactions_details": [{
"amount": 18999000000000,
"attachments": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"blob": "ARMBgKCUpY0dBBoAAAAAAAAAABoCAAAAAAAAABoKAAAAAAAAABoPAAAAAAAAACVA4FRLH",
"blob_size": 6794,
"extra": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"fee": 1000000000,
"id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8",
"ins": [{
"amount": 1000000000000,
"global_indexes": [0,2,12,27],
"htlc_origin": "",
"kimage_or_ms_id": "2540e0544b1fed3b104976f803dbd83681335c427f9d601d9d5aecf86ef276d2",
"multisig_count": 0
}],
"keeper_block": 51,
"object_in_json": "ewogICJ2ZXJzaW9uIjogMSwgCiAgInZpbiI6IFsgewogICAgIC",
"outs": [{
"amount": 9000000000,
"global_index": 0,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": ["7d0c755e7e24a241847176c9a3cf4c970bcd6377018068abe6fe4535b23f5323"]
}],
"pub_key": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"timestamp": 1557345925
}],
"type": 1
}],
"status": "OK"
}
}
```
### Response description:
```
"blocks": List of alternative blocks with detailed information, retrieved based on the specified parameters.
"actual_timestamp": Actual timestamp encoded in the block's extra data for PoS blocks.
"already_generated_coins": Total amount of coins generated in the blockchain up to this block.
"base_reward": Base mining reward for the block.
"blob": Serialized form of the block.
"block_cumulative_size": Cumulative size of the block including all transactions.
"cumulative_diff_adjusted": Adjusted cumulative difficulty of the blockchain up to this block.
"cumulative_diff_precise": Precise cumulative difficulty of the blockchain up to this block.
"difficulty": Mining difficulty of the block.
"height": Height of the block in the blockchain.
"id": Unique identifier of the block.
"is_orphan": Indicates whether the block is an orphan.
"miner_text_info": Additional textual information provided by the miner of the block.
"object_in_json": Serialized representation of the block in JSON format.
"penalty": Penalty applied to the reward if the block is larger than median but not large enough to be rejected.
"prev_id": Hash of the previous block in the chain.
"summary_reward": Total reward for the block, including base reward and transaction fees (legacy).
"this_block_fee_median": Median transaction fee of the transactions within this block.
"timestamp": Timestamp when the block was created, in PoS blocks used for mining.
"total_fee": Total transaction fees included in the block.
"total_txs_size": Total size of all transactions included in the block.
"transactions_details": Detailed information about each transaction included in the block.
"amount": Total output amount of the transaction (legacy, for pre-Zarcanum txs).
"attachments": Additional attachments to the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"blob": Serialized form of the transaction, encoded in Base64.
"blob_size": Size of the serialized transaction in bytes.
"extra": Extra data associated with the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"fee": Transaction fee in the smallest currency unit.
"id": Hash of the transaction.
"ins": Inputs of the transaction.
"amount": The amount of coins being transacted.
"global_indexes": List of global indexes indicating the outputs referenced by this input, where only one is actually being spent.
"htlc_origin": Origin hash for HTLC (Hash Time Locked Contract).
"kimage_or_ms_id": Contains either the key image for the input or the multisig output ID, depending on the input type.
"multisig_count": Number of multisig signatures used, relevant only for multisig outputs.
"keeper_block": Block height where the transaction is confirmed, or -1 if it is unconfirmed.
"object_in_json": Serialized transaction represented in JSON, encoded in Base64.
"outs": Outputs of the transaction.
"amount": The output's amount, 0 for ZC outputs.
"global_index": Global index of the output for this specific amount.
"is_spent": Indicates whether the output has been spent.
"minimum_sigs": Minimum number of signatures required to spend the output, for multisig outputs only.
"pub_keys": List of public keys associated with the output.
"pub_key": Public key associated with the transaction.
"timestamp": Timestamp when the transaction was created.
"type": Type of the block.
"status": Status of the call.
### Response information
- see get_blocks_details method for more details.
```

View file

@ -0,0 +1,55 @@
Obtain information for the given asset by its ID.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_asset_info",
"params": {
"asset_id": "cc4e69455e63f4a581257382191de6856c2156630b3fba0db4bdd73ffcfb36b6"
}
}
```
### Request description:
```
"asset_id": ID of an asset.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"asset_descriptor": {
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped ABC",
"hidden_supply": false,
"meta_info": "{ \"logo_url\": \"https:\/\/some.nice.logo.png\"}",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"owner_eth_pub_key": "",
"ticker": "ZABC",
"total_max_supply": 1000000000000000000
},
"status": "OK"
}
}
```
### Response description:
```
"asset_descriptor": Descriptor of the given asset.
"current_supply": Currently emitted supply for the given asset (ignored for REGISTER operation).
"decimal_point": Decimal point.
"full_name": Full name of the asset.
"hidden_supply": This field is reserved for future use and will be documented later.
"meta_info": Any other information associated with the asset, by default in a json format.
"owner": Owner's key, used only for EMIT and UPDATE validation, can be changed by transferring asset ownership.
"owner_eth_pub_key": [Optional] Owner's key in the case when ETH signature is used.
"ticker": Ticker associated with the asset.
"total_max_supply": Maximum possible supply for a given asset, cannot be changed after deployment.
"status": Status of the call.
```

View file

@ -0,0 +1,59 @@
Return list of assets registered in Zano blockchain
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_assets_list",
"params": {
"count": 100,
"offset": 0
}
}
```
### Request description:
```
"count": Number of items to recieve
"offset": Offset for the item to start copying
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"assets": [{
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped ABC",
"hidden_supply": false,
"meta_info": "{ \"logo_url\": \"https:\/\/some.nice.logo.png\"}",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"owner_eth_pub_key": "",
"ticker": "ZABC",
"total_max_supply": 1000000000000000000
}],
"status": "OK"
}
}
```
### Response description:
```
"assets": List of assets registered in Zano blockchain
"asset_id": Asset ID
"current_supply": Currently emitted supply for the given asset (ignored for REGISTER operation).
"decimal_point": Decimal point.
"full_name": Full name of the asset.
"hidden_supply": This field is reserved for future use and will be documented later.
"meta_info": Any other information associated with the asset, by default in a json format.
"owner": Owner's key, used only for EMIT and UPDATE validation, can be changed by transferring asset ownership.
"owner_eth_pub_key": [Optional] Owner's key in the case when ETH signature is used.
"ticker": Ticker associated with the asset.
"total_max_supply": Maximum possible supply for a given asset, cannot be changed after deployment.
"status": Status code of operation, OK if success
```

View file

@ -1,112 +1,150 @@
Return blocks details for a specified range of heights.
### Request
Retrieves detailed information about a sequence of blocks starting from a specific height.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_blocks_details",
"params": {
"height_start": 1,
"count": 1
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_blocks_details",
"params": {
"count": 1,
"height_start": 51,
"ignore_transactions": false
}
}
```
### Request description:
```
"count": The number of blocks to retrieve from the starting height.
"height_start": The starting block height from which block details are retrieved.
### Request parameters
- height_start - starting height
- count - number of blocks to be requested
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"blocks": [
{
"actual_timestamp": 1557342384,
"already_generated_coins": "17517204000000000000",
"base_reward": 1000000000000,
"blob": "",
"block_cumulative_size": 0,
"block_tself_size": 0,
"cumulative_diff_adjusted": "2",
"cumulative_diff_precise": "1",
"difficulty": "1",
"effective_fee_median": 10000,
"height": 1,
"id": "901214ab938219f5b33b547008607aee14d29950a34834a2e9973b96269bd0b0",
"is_orphan": false,
"miner_text_info": "",
"object_in_json": "{\n \"major_version\": 0, \n \"nonce\": 1532031558827332528, \n \"prev_id\": \"cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852\", \n \"minor_version\": 0, \n \"timestamp\": 1557342384, \n \"flags\": 0, \n \"miner_tx\": {\n \"version\": 1, \n \"vin\": [ {\n \"gen\": {\n \"height\": 1\n }\n }\n ], \n \"vout\": [ {\n \"amount\": 1000000000000, \n \"target\": {\n \"key\": \"ffd231f5386282c281f58c8d578c95b429b1b8ed5bddd6472d58b911384cd99300\"\n }\n }\n ], \n \"extra\": [ {\n \"pub_key\": \"24196c9ab3f827a586cc906a6133f0b4b0663eb15491fae33e9ade63d34ae398\"\n }, {\n \"extra_padding\": , \n \"buff\": [ ]\n }, {\n \"etc_tx_flags16\": , \n \"v\": 63119\n }, {\n \"unlock_time\": , \n \"v\": 11\n }, {\n \"string\": 8\"8f3f4736b24f69a8\"\n }], \n \"signatures\": [ ], \n \"attachment\": [ ]\n }, \n \"tx_hashes\": [ ]\n}",
"penalty": 0,
"pow_seed": "",
"prev_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"summary_reward": 1000000000000,
"this_block_fee_median": 0,
"timestamp": 1557342384,
"total_fee": 0,
"total_txs_size": 0,
"transactions_details": [
{
"amount": 1000000000000,
"blob": "",
"blob_size": 96,
"fee": 0,
"id": "8d0fbc9ee9948bc74bf6b80914e95997e9769641f3a20ef963c4264922ac004b",
"keeper_block": 1,
"object_in_json": "",
"pub_key": "24196c9ab3f827a586cc906a6133f0b4b0663eb15491fae33e9ade63d34ae398",
"timestamp": 1557342384
}
],
"type": 1
}
],
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"blocks": [{
"actual_timestamp": 1557345925,
"already_generated_coins": "17517253670000000000",
"base_reward": 1000000000000,
"blob": "",
"block_cumulative_size": 6794,
"block_tself_size": 0,
"cumulative_diff_adjusted": "42413051198",
"cumulative_diff_precise": "28881828324942",
"difficulty": "951296929031",
"effective_fee_median": 0,
"height": 51,
"id": "af05b814c75e10872afc0345108e830884bc4c32091db783505abe3dac9929cf",
"is_orphan": false,
"miner_text_info": "",
"object_in_json": "",
"penalty": 0,
"pow_seed": "",
"prev_id": "37fe382c755bb8869e4f5255f2aed6a8fb503e195bb4180b65b8e1450b84cafe",
"summary_reward": 1001000000000,
"this_block_fee_median": 1000000000,
"timestamp": 1557345925,
"total_fee": 1000000000,
"total_txs_size": 6794,
"transactions_details": [{
"amount": 18999000000000,
"attachments": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"blob": "ARMBgKCUpY0dBBoAAAAAAAAAABoCAAAAAAAAABoKAAAAAAAAABoPAAAAAAAAACVA4FRLH",
"blob_size": 6794,
"extra": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"fee": 1000000000,
"id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8",
"ins": [{
"amount": 1000000000000,
"global_indexes": [0,2,12,27],
"htlc_origin": "",
"kimage_or_ms_id": "2540e0544b1fed3b104976f803dbd83681335c427f9d601d9d5aecf86ef276d2",
"multisig_count": 0
}],
"keeper_block": 51,
"object_in_json": "ewogICJ2ZXJzaW9uIjogMSwgCiAgInZpbiI6IFsgewogICAgIC",
"outs": [{
"amount": 9000000000,
"global_index": 0,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": ["7d0c755e7e24a241847176c9a3cf4c970bcd6377018068abe6fe4535b23f5323"]
}],
"pub_key": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"timestamp": 1557345925
}],
"type": 1
}],
"status": "OK"
}
}
```
### Response description:
```
"blocks": List of blocks with detailed information, starting from the specified height.
"actual_timestamp": Actual timestamp encoded in the block's extra data for PoS blocks.
"already_generated_coins": Total amount of coins generated in the blockchain up to this block.
"base_reward": Base mining reward for the block.
"blob": Serialized form of the block.
"block_cumulative_size": Cumulative size of the block including all transactions.
"cumulative_diff_adjusted": Adjusted cumulative difficulty of the blockchain up to this block.
"cumulative_diff_precise": Precise cumulative difficulty of the blockchain up to this block.
"difficulty": Mining difficulty of the block.
"height": Height of the block in the blockchain.
"id": Unique identifier of the block.
"is_orphan": Indicates whether the block is an orphan.
"miner_text_info": Additional textual information provided by the miner of the block.
"object_in_json": Serialized representation of the block in JSON format.
"penalty": Penalty applied to the reward if the block is larger than median but not large enough to be rejected.
"prev_id": Hash of the previous block in the chain.
"summary_reward": Total reward for the block, including base reward and transaction fees (legacy).
"this_block_fee_median": Median transaction fee of the transactions within this block.
"timestamp": Timestamp when the block was created, in PoS blocks used for mining.
"total_fee": Total transaction fees included in the block.
"total_txs_size": Total size of all transactions included in the block.
"transactions_details": Detailed information about each transaction included in the block.
"amount": Total output amount of the transaction (legacy, for pre-Zarcanum txs).
"attachments": Additional attachments to the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"blob": Serialized form of the transaction, encoded in Base64.
"blob_size": Size of the serialized transaction in bytes.
"extra": Extra data associated with the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"fee": Transaction fee in the smallest currency unit.
"id": Hash of the transaction.
"ins": Inputs of the transaction.
"amount": The amount of coins being transacted.
"global_indexes": List of global indexes indicating the outputs referenced by this input, where only one is actually being spent.
"htlc_origin": Origin hash for HTLC (Hash Time Locked Contract).
"kimage_or_ms_id": Contains either the key image for the input or the multisig output ID, depending on the input type.
"multisig_count": Number of multisig signatures used, relevant only for multisig outputs.
"keeper_block": Block height where the transaction is confirmed, or -1 if it is unconfirmed.
"object_in_json": Serialized transaction represented in JSON, encoded in Base64.
"outs": Outputs of the transaction.
"amount": The output's amount, 0 for ZC outputs.
"global_index": Global index of the output for this specific amount.
"is_spent": Indicates whether the output has been spent.
"minimum_sigs": Minimum number of signatures required to spend the output, for multisig outputs only.
"pub_keys": List of public keys associated with the output.
"pub_key": Public key associated with the transaction.
"timestamp": Timestamp when the transaction was created.
"type": Type of the block.
"status": Status of the call.
### Response parameters
- actual_timestamp — unsigned int; timestamp for the moment of block creation (for PoW blocks equal to timestamp, for PoS they differ).
- already_generated_coins — unsigned int; total number of coins generated, including this block.
- base_reward — unsigned int; base reward for the block (equal to reward if there are no transactions except the miner tx).
- blob
- block_cumulative_size — unsigned int; total size of block's transactions, in bytes. Miner tx is included in special cases.
- block_tself_size
- cumulative_diff_adjusted — unsigned int; cumulative PoS or PoW difficulty for the block, adjusted by the sequence factor (number of same type - blocks going sequentially one-by-one).
- cumulative_diff_precise — unsigned int; precise cumulative PoS or PoW difficulty for the block.
- difficulty — unsigned int; difficulty of the block.
- effective_fee_median — unsigned int; median of transaction fees within a specific window used in calculations for this block.
- height — unsigned int; block height.
- id — string; block hash identifier.
- is_orphan — boolean; orphan status for the block. False for normal blocks.
- miner_text_info — string; undefined text inserted by miner when the block was mined.
- object_in_json — string; JSON-serialized block object.
- penalty — unsigned int; difference between summary_reward and base_reward.
- pow_seed — some hex string .
- prev_id — string; hash identifier of the previous block.
- summary_reward — unsigned int; amount of coins this block has generated in miner tx.
- this_block_fee_median — unsigned int; median fee among the transactions for this block.
- timestamp — unsigned int; block timestamp (serves a special purpose for PoS blocks, which is why actual_timestamp should be used as actual block timestamp).
- total_fee — unsigned int; sum of transaction fees in this block.
- total_txs_size — unsigned int; total transaction size in this block (excluding the miner tx).
- transactions_details — array of tx_rpc_extended_info objects (see below get_tx_details description).
- amount
- blob
- blob_size
- fee
- id
- keeper_block
- object_in_json
- pub_key
- timestamp
- type — unsigned int; 0 if this is PoS block, 1 if this is PoW block
```

View file

@ -1,32 +1,34 @@
Returns the median for timestamps of the last 20 blocks
Displayed as returned median value plus 600 seconds, this is used to check the expiration time of parameters.
### Request
Retrieves the current core transaction expiration median.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_current_core_tx_expiration_median"
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_current_core_tx_expiration_median",
"params": {
}
}
```
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"expiration_median": 1684416559,
"status": "OK"
}
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"expiration_median": 1719591540,
"status": "OK"
}
}
```
### Response description:
```
"expiration_median": The median timestamp from the last N blocks, used to determine if transactions are expired based on their timestamp.
"status": Status of the call.
- expiration_median - unsigned int; median value.
```

View file

@ -1,37 +1,36 @@
Returns approximate block height for requested timestamp
### Request
Give an estimation of block height by the given date.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_est_height_from_date",
"params": {
"date": ""
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_est_height_from_date",
"params": {
"timestamp": 1711021795
}
}
```
### Request description:
```
"timestamp": Linux timestamp for the required date.
### Request parameters
- date - unix timestamp
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"h": 0,
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"h": 2555000,
"status": "OK"
}
}
```
### Response description:
```
"h": Estimated height of a block.
"status": Status of the call.
### Response parameters
- h - block height approximation
```

View file

@ -1,108 +1,147 @@
Returns block details for a specified identifier. Only for main chain blocks.
### Request
Retrieves detailed information about a specific block identified by its hash.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_main_block_details",
"params": {
"id": "498cafd7ae8d7a82abd5267a005ce01482d5580eddd9805dd0162e465cacb7df"
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_main_block_details",
"params": {
"id": "4cf2c7c7e16d1a2a0771cd552c696dd94e7db4e1031982ed88eff99d5006ee4a"
}
}
```
### Request description:
```
"id": The hash ID of the block for which detailed information is being requested.
### Request parameters
- id - hash identifier for a block.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_details": {
"actual_timestamp": 1684411963,
"already_generated_coins": "13723707515881367168",
"base_reward": 1000000000000,
"blob": "",
"block_cumulative_size": 13786,
"block_tself_size": 0,
"cumulative_diff_adjusted": "2832707833905824613",
"cumulative_diff_precise": "1273127049356910428816679621",
"difficulty": "2128820872519086150618",
"effective_fee_median": 10000000000,
"height": 2111653,
"id": "498cafd7ae8d7a82abd5267a005ce01482d5580eddd9805dd0162e465cacb7df",
"is_orphan": false,
"miner_text_info": "",
"object_in_json": "{\n \"major_version\": 2, \n \"nonce\": 0, \n \"prev_id\": \"5c4fd7994c0fbdb419def7afc89fd7914e8f5b07daf6d8bf92cdf85c6dc83840\", \n \"minor_version\": 0, \n \"timestamp\": 1684410675, \n \"flags\": 1, \n \"miner_tx\": {\n \"version\": 1, \n \"vin\": [ {\n \"gen\": {\n \"height\": 2111653\n }\n }, {\n \"key\": {\n \"amount\": 900000000000000, \n \"key_offsets\": [ {\n \"uint64_t\": 18826\n }\n ], \n \"k_image\": \"c4f3351243326f66c1ba6fc5b744d8295992de2c210e28243a221092f3977fe9\", \n \"etc_details\": [ ]\n }\n }], \n \"vout\": [ {\n \"amount\": 30000000000, \n \"target\": {\n \"key\": \"7efc881ec1c060ca9a066ca6a5afcdc48537d74e1bfbaa068cf40cdb10cb086400\"\n }\n }, {\n \"amount\": 1000000000000, \n \"target\": {\n \"key\": \"b4b2021f61cf1a8db85edc27832afc25ab469b962d684fc00699dfa282c9448200\"\n }\n }, {\n \"amount\": 900000000000000, \n \"target\": {\n \"key\": \"d732ccf5d481e5fd834924fa0a3bab6ff51b9dd7064e675f160a4f4253cb91bd00\"\n }\n }\n ], \n \"extra\": [ {\n \"pub_key\": \"c093b0757ecae81a8322140aed69759faa200836ac4a4f32c9633ba32a8d488b\"\n }, {\n \"extra_padding\": , \n \"buff\": [ ]\n }, {\n \"derivation_hint\": , \n \"msg\": 2\"98ee\"\n }, {\n \"unlock_time\": , \n \"v\": 2111663\n }, {\n \"attachment\": , \n \"service_id\": 1\"64\", \n \"instruction\": 0\"\", \n \"body\": 8\"3b16666400000000\", \n \"security\": [ ], \n \"flags\": 0\n }], \n \"signatures\": [ [ \"d030c37a1feae460f3d15c146ec092abc54d3858d1c58d8d03c1148d5b953b0ee70f0633a95696b54f01f550f83b2b04b75e128f2fdc3ac53c3f4a3b934eda08\"\n ]\n ], \n \"attachment\": [ ]\n }, \n \"tx_hashes\": [ \"6348ae8c649404d26cbee8e0edbad018b64051499b4e1c02567862a1a74a5a3a\", \"a9492df7468241c1b26ab59abf600cbf336281992afd5c896cbc1f5f7336895b\", \"a5b06721f8d36d6e654fce9fbfaa7366499a46f1f98c2a47d79dd55a4c9653ac\"\n ]\n}",
"penalty": 0,
"pow_seed": "",
"prev_id": "5c4fd7994c0fbdb419def7afc89fd7914e8f5b07daf6d8bf92cdf85c6dc83840",
"summary_reward": 1030000000000,
"this_block_fee_median": 10000000000,
"timestamp": 1684410675,
"total_fee": 30000000000,
"total_txs_size": 13786,
"transactions_details": [
{
"amount": 901030000000000,
"blob": "",
"blob_size": 241,
"fee": 0,
"id": "de6b824024bbf3ab1240f86122d93a0f3b9e539026e58c9ca40937bbd54bfd04",
"keeper_block": 2111653,
"object_in_json": "",
"pub_key": "c093b0757ecae81a8322140aed69759faa200836ac4a4f32c9633ba32a8d488b",
"timestamp": 1684411963
},
{
"amount": 1390000000000,
"blob": "",
"blob_size": 2131,
"fee": 10000000000,
"id": "6348ae8c649404d26cbee8e0edbad018b64051499b4e1c02567862a1a74a5a3a",
"keeper_block": 2111653,
"object_in_json": "",
"pub_key": "116316309f51a8007ae95f8fa1aa54ad6de4357b7d9c2e4c12dad919b7fce578",
"timestamp": 1684411963
},
{
"amount": 1390000000000,
"blob": "",
"blob_size": 2171,
"fee": 10000000000,
"id": "a9492df7468241c1b26ab59abf600cbf336281992afd5c896cbc1f5f7336895b",
"keeper_block": 2111653,
"object_in_json": "",
"pub_key": "feecb2ae6efb4e03e392b4f33f512c1a36632346978c478d15cd3eee33708255",
"timestamp": 1684411963
},
{
"amount": 10000000000000,
"blob": "",
"blob_size": 9484,
"fee": 10000000000,
"id": "a5b06721f8d36d6e654fce9fbfaa7366499a46f1f98c2a47d79dd55a4c9653ac",
"keeper_block": 2111653,
"object_in_json": "",
"pub_key": "e66ad0eaf2a11e3325a12c7e5bd4cdeba1e3cc82396b50ae6cc2ad71d9cd542f",
"timestamp": 1684411963
}
],
"type": 0
},
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_details": {
"actual_timestamp": 1557345925,
"already_generated_coins": "17517253670000000000",
"base_reward": 1000000000000,
"blob": "",
"block_cumulative_size": 6794,
"block_tself_size": 0,
"cumulative_diff_adjusted": "42413051198",
"cumulative_diff_precise": "28881828324942",
"difficulty": "951296929031",
"effective_fee_median": 0,
"height": 51,
"id": "af05b814c75e10872afc0345108e830884bc4c32091db783505abe3dac9929cf",
"is_orphan": false,
"miner_text_info": "",
"object_in_json": "",
"penalty": 0,
"pow_seed": "",
"prev_id": "37fe382c755bb8869e4f5255f2aed6a8fb503e195bb4180b65b8e1450b84cafe",
"summary_reward": 1001000000000,
"this_block_fee_median": 1000000000,
"timestamp": 1557345925,
"total_fee": 1000000000,
"total_txs_size": 6794,
"transactions_details": [{
"amount": 18999000000000,
"attachments": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"blob": "ARMBgKCUpY0dBBoAAAAAAAAAABoCAAAAAAAAABoKAAAAAAAAABoPAAAAAAAAACVA4FRLH",
"blob_size": 6794,
"extra": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"fee": 1000000000,
"id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8",
"ins": [{
"amount": 1000000000000,
"global_indexes": [0,2,12,27],
"htlc_origin": "",
"kimage_or_ms_id": "2540e0544b1fed3b104976f803dbd83681335c427f9d601d9d5aecf86ef276d2",
"multisig_count": 0
}],
"keeper_block": 51,
"object_in_json": "ewogICJ2ZXJzaW9uIjogMSwgCiAgInZpbiI6IFsgewogICAgIC",
"outs": [{
"amount": 9000000000,
"global_index": 0,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": ["7d0c755e7e24a241847176c9a3cf4c970bcd6377018068abe6fe4535b23f5323"]
}],
"pub_key": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"timestamp": 1557345925
}],
"type": 1
},
"status": "OK"
}
}
```
### Response description:
```
"block_details": Detailed information about the block retrieved based on the provided hash ID.
"actual_timestamp": Actual timestamp encoded in the block's extra data for PoS blocks.
"already_generated_coins": Total amount of coins generated in the blockchain up to this block.
"base_reward": Base mining reward for the block.
"blob": Serialized form of the block.
"block_cumulative_size": Cumulative size of the block including all transactions.
"cumulative_diff_adjusted": Adjusted cumulative difficulty of the blockchain up to this block.
"cumulative_diff_precise": Precise cumulative difficulty of the blockchain up to this block.
"difficulty": Mining difficulty of the block.
"height": Height of the block in the blockchain.
"id": Unique identifier of the block.
"is_orphan": Indicates whether the block is an orphan.
"miner_text_info": Additional textual information provided by the miner of the block.
"object_in_json": Serialized representation of the block in JSON format.
"penalty": Penalty applied to the reward if the block is larger than median but not large enough to be rejected.
"prev_id": Hash of the previous block in the chain.
"summary_reward": Total reward for the block, including base reward and transaction fees (legacy).
"this_block_fee_median": Median transaction fee of the transactions within this block.
"timestamp": Timestamp when the block was created, in PoS blocks used for mining.
"total_fee": Total transaction fees included in the block.
"total_txs_size": Total size of all transactions included in the block.
"transactions_details": Detailed information about each transaction included in the block.
"amount": Total output amount of the transaction (legacy, for pre-Zarcanum txs).
"attachments": Additional attachments to the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"blob": Serialized form of the transaction, encoded in Base64.
"blob_size": Size of the serialized transaction in bytes.
"extra": Extra data associated with the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"fee": Transaction fee in the smallest currency unit.
"id": Hash of the transaction.
"ins": Inputs of the transaction.
"amount": The amount of coins being transacted.
"global_indexes": List of global indexes indicating the outputs referenced by this input, where only one is actually being spent.
"htlc_origin": Origin hash for HTLC (Hash Time Locked Contract).
"kimage_or_ms_id": Contains either the key image for the input or the multisig output ID, depending on the input type.
"multisig_count": Number of multisig signatures used, relevant only for multisig outputs.
"keeper_block": Block height where the transaction is confirmed, or -1 if it is unconfirmed.
"object_in_json": Serialized transaction represented in JSON, encoded in Base64.
"outs": Outputs of the transaction.
"amount": The output's amount, 0 for ZC outputs.
"global_index": Global index of the output for this specific amount.
"is_spent": Indicates whether the output has been spent.
"minimum_sigs": Minimum number of signatures required to spend the output, for multisig outputs only.
"pub_keys": List of public keys associated with the output.
"pub_key": Public key associated with the transaction.
"timestamp": Timestamp when the transaction was created.
"type": Type of the block.
"status": Status of the call.
### Response information
- see get_blocks_details method for more details.
```

View file

@ -1,41 +1,38 @@
Looks up multi-sig output by specified identifier.
### Request
Retrieve basic information about a multisig output using its unique identifier (hash).
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_multisig_info",
"params": {
"ms_id": ""
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_multisig_info",
"params": {
"ms_id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8"
}
}
```
### Request description:
```
"ms_id": The multisig output's unique identifier (hash).
### Request parameters
- ms_id - hash identifier of a multisig output
---
### Response
```
### Response:
```json
{
"id": "0",
"jsonrpc": "2.0",
"result": {
"out_no": 3,
"status": "OK",
"tx_id": "2df88a09b2d8b73a45824526c26e7f21836bbe0b111e1e8a6896c1a7fc8e03eb"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"out_no": 11,
"status": "OK",
"tx_id": "a88541e38d64f87c41b9153412d1d7667f6e4337fe429ed1374722355fa7b423"
}
}
```
### Response description:
```
"out_no": Local output index within the transaction.
"status": Status of the call.
"tx_id": Transaction ID where the multisig output is present, if found.
### Response information
- out_no - string; hash identifier of transaction, containing the given multisig output.
- status - string; "OK" if the output was found, "NOT FOUND" if the requested output was not found.
- tx_id - string; hash identifier of output's source transaction.
out_no — unsigned int; output local index in its source transaction.
```

View file

@ -0,0 +1,23 @@
Obtain global outputs' indexes for the given txs.
URL: ```http:://127.0.0.1:11211/get_o_indexes.bin```
### Request:
```json
{
}
```
### Request description:
```
```
### Response:
```json
{
"status": "OK"
}
```
### Response description:
```
"status": Status of the call.
```

View file

@ -1,37 +1,40 @@
Looks up an output in the global outputs table by specified amount and output global index.
### Request
Returns transaction ID and local output index for a given output amount and its global index.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_out_info",
"params": {
"amount": 1,
"i": 1
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_out_info",
"params": {
"amount": 3000000000000,
"i": 0
}
}
```
### Request description:
```
"amount": The specific amount of output to query.
"i": The global index of the output amount to be queried.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"out_no": 0,
"status": "OK",
"tx_id": "5b3bb20dee6307b11f65f8fe2b976efdec570b46241e41df33e85f4cf2332b2a"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"out_no": 7,
"status": "OK",
"tx_id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8"
}
}
```
### Response description:
```
"out_no": Local output index within the transaction.
"status": Status of the call.
"tx_id": Transaction ID where the queried output is present, if found.
### Response information
- out_no - unsigned int; output local index in its source transaction.
- status - string; "OK" if the output was found, "NOT FOUND" if the requested output was not found.
- tx_id - string; hash identifier of output's source transaction.
```

View file

@ -0,0 +1,45 @@
Obtain basic information about the transaction pool.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_pool_info",
"params": {
}
}
```
### Request description:
```
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"aliases_que": [{
"address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7",
"alias": "zxdya6q6whzwqjkmtcsjpc3ku",
"comment": "Society is never gonna make any progress until we all learn to pretend to like each other.",
"tracking_key": "18bb94f69ed61b47b6556f3871b89dff8f9a6f4f798f706fd199b05ccf8ef20c"
}],
"error_code": "",
"status": "OK"
}
}
```
### Response description:
```
"aliases_que": List of aliases from txs that are currently in the tx pool.
"address": Address of the alias.
"alias": Alias itself, a brief shortcut for an address.
"comment": Arbitrary comment (optional).
"tracking_key": View secret key of the corresponding address (optional).
"error_code": Error code, if there's any error (optional).
"status": Status code, OK if succeeded.
```

View file

@ -1,47 +1,45 @@
Returns brief information for transactions currently in the pool.
### Request
Retrieves brief details about specific transactions in the transaction pool, identified by their IDs.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_pool_txs_brief_details",
"params": {
"ids": ["", ""]
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_pool_txs_brief_details",
"params": {
"ids": ["bd9a89f95c9115d29540c6778dab9d9798eb251143dcd4b8960fcd9730a1471c","1c938f04c935d976310c4338fc570ea20777951471609f3edecb341ea4932b0a"]
}
}
```
### Request description:
```
"ids": List of transaction IDs.
### Request parameters
- ids - list of transaction hash identifiers for which information is requested. All transactions from the pool will be returned if ids is empty or if this parameter is omitted
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK",
"txs": [
{
"fee": 10000000000,
"id": "5864f3e061c70b47d4ea6a47e593aad66bb2462fa4036be2cd3dfede9faa7583",
"sz": 57913,
"total_amount": 500000000000000
}
]
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK",
"txs": [{
"fee": 1000000000,
"id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8",
"sz": 6142,
"total_amount": 9000000000
}]
}
}
```
### Response description:
```
"status": Status of the call.
"txs": List of transactions with detailed information.
"fee": Transaction fee in the smallest currency unit.
"id": Hash of the transaction.
"sz": Size of the transaction in bytes.
"total_amount": Total amount transferred in the transaction (legacy, for pre-Zarcanum txs).
### Response information
- fee - unsigned int; transaction fee.
- id - string; hash identifier.
- sz - unsigned int; size of serialized transaction in bytes (the same as blob_size in tx_rpc_extended_info).
- total_amount - unsigned int; sum of all transaction outputs.
```

View file

@ -1,52 +1,99 @@
Returns transactions that are currently in the pool
Note: Output is less detailed if ids parameter is empty or omitted.
### Request
Retrieves detailed information about specific transactions in the transaction pool, identified by their IDs.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_pool_txs_details",
"params": {
"ids": ["", ""]
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_pool_txs_details",
"params": {
"ids": ["bd9a89f95c9115d29540c6778dab9d9798eb251143dcd4b8960fcd9730a1471c","1c938f04c935d976310c4338fc570ea20777951471609f3edecb341ea4932b0a"]
}
}
```
### Request description:
```
"ids": List of transaction IDs.
### Request parameters
- ids - list of transaction hash identifiers for which information is requested. All transactions from the pool will be returned if ids is empty or if this parameter is omitted
---
### Response
```
### Response:
```json
{
"id": "0",
"jsonrpc": "2.0",
"result": {
"status": "OK",
"txs": [
{
"amount": 500000000000000,
"blob": "",
"blob_size": 57913,
"fee": 10000000000,
"id": "5864f3e061c70b47d4ea6a47e593aad66bb2462fa4036be2cd3dfede9faa7583",
"keeper_block": 0,
"object_in_json": "",
"pub_key": "24a523aea7d0b1e69e5a393a7e5531455c4317e527ad83be7a871fea716dc45c",
"timestamp": 1558557359
}
]
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK",
"txs": [{
"amount": 18999000000000,
"attachments": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"blob": "ARMBgKCUpY0dBBoAAAAAAAAAABoCAAAAAAAAABoKAAAAAAAAABoPAAAAAAAAACVA4FRLH",
"blob_size": 6794,
"extra": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"fee": 1000000000,
"id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8",
"ins": [{
"amount": 1000000000000,
"global_indexes": [0,2,12,27],
"htlc_origin": "",
"kimage_or_ms_id": "2540e0544b1fed3b104976f803dbd83681335c427f9d601d9d5aecf86ef276d2",
"multisig_count": 0
}],
"keeper_block": 51,
"object_in_json": "ewogICJ2ZXJzaW9uIjogMSwgCiAgInZpbiI6IFsgewogICAgIC",
"outs": [{
"amount": 9000000000,
"global_index": 0,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": ["7d0c755e7e24a241847176c9a3cf4c970bcd6377018068abe6fe4535b23f5323"]
}],
"pub_key": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"timestamp": 1557345925
}]
}
}
```
### Response description:
```
"status": Status of the call.
"txs": List of transactions with detailed information.
"amount": Total output amount of the transaction (legacy, for pre-Zarcanum txs).
"attachments": Additional attachments to the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"blob": Serialized form of the transaction, encoded in Base64.
"blob_size": Size of the serialized transaction in bytes.
"extra": Extra data associated with the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"fee": Transaction fee in the smallest currency unit.
"id": Hash of the transaction.
"ins": Inputs of the transaction.
"amount": The amount of coins being transacted.
"global_indexes": List of global indexes indicating the outputs referenced by this input, where only one is actually being spent.
"htlc_origin": Origin hash for HTLC (Hash Time Locked Contract).
"kimage_or_ms_id": Contains either the key image for the input or the multisig output ID, depending on the input type.
"multisig_count": Number of multisig signatures used, relevant only for multisig outputs.
"keeper_block": Block height where the transaction is confirmed, or -1 if it is unconfirmed.
"object_in_json": Serialized transaction represented in JSON, encoded in Base64.
"outs": Outputs of the transaction.
"amount": The output's amount, 0 for ZC outputs.
"global_index": Global index of the output for this specific amount.
"is_spent": Indicates whether the output has been spent.
"minimum_sigs": Minimum number of signatures required to spend the output, for multisig outputs only.
"pub_keys": List of public keys associated with the output.
"pub_key": Public key associated with the transaction.
"timestamp": Timestamp when the transaction was created.
### Response information
- txs - array of tx_rpc_extended_info objects; see get_tx_details method description for details.
```

View file

@ -0,0 +1,33 @@
Retrieves basic information regarding PoS mining, including current PoS conditions and constraints.
URL: ```http:://127.0.0.1:11211/get_pos_details.bin```
### Request:
```json
{
}
```
### Request description:
```
```
### Response:
```json
{
"last_block_hash": "\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000",
"pos_basic_difficulty": "",
"pos_mining_allowed": false,
"pos_sequence_factor_is_good": false,
"sm": "\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000",
"starter_timestamp": 0,
"status": "OK"
}
```
### Response description:
```
"pos_basic_difficulty": Current PoS difficulty.
"pos_mining_allowed": Indicates whether PoS mining is currently allowed, which may be restricted under certain blockchain conditions or in testnets.
"pos_sequence_factor_is_good": Indicates whether the PoS sequence factor is at a level that allows for continued PoS mining, requiring a PoW block to reset if too high.
"starter_timestamp": Timestamp from which timestamps are evaluated for meeting PoS win condition.
"status": Status of the call.
```

View file

@ -1,234 +1,99 @@
Returns transaction details by specified transaction hash identifier.
### Request
Retrieves detailed information about a specific transaction.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_tx_details",
"params": {
"tx_hash": "ee25a5503726368eef558737f81f15fdc5f1e705b678df81315c83d8789ed4b3"
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_tx_details",
"params": {
"tx_hash": "d46c415c3aa3f3e17bd0bf85ffb813cacf4d9595d2d5392f42dacbaffcffdc70"
}
}
```
### Request description:
```
"tx_hash": The hash of the transaction for which detailed information is being requested.
### Request parameters
- tx_hash - hash identifier of a transaction
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK",
"tx_info": {
"amount": 50000000000000,
"attachments": [
{
"datails_view": "ei<65><16><>(<28>",
"short_view": "P:",
"type": "service"
}
],
"blob": "",
"blob_size": 5377,
"extra": [
{
"datails_view": "",
"short_view": "(encrypted)",
"type": "payer"
},
{
"datails_view": "",
"short_view": "(encrypted)",
"type": "receiver"
},
{
"datails_view": "",
"short_view": "76a7575f488a5a32a766fc5da6d190cab4e90b1ab6d0178eed622a79e922a70d",
"type": "pub_key"
},
{
"datails_view": "0000",
"short_view": "0000",
"type": "FLAGS16"
},
{
"datails_view": "derivation_hash: 1c6e466c\nencrypted_key_derivation: 3d4cf9081c1abea76b595f7226a7d12faa596d33c93f16f4bbfb8856c4895ea9",
"short_view": "derivation_hash: 1c6e466c",
"type": "crypto_checksum"
},
{
"datails_view": "2013",
"short_view": "2 bytes",
"type": "derivation_hint"
},
{
"datails_view": ", \n\"sz\": 16, \n\"hsh\": \"eb9562934daa508c1f0d5a91cbe9322f0e363287676ab4398f65c9cb5bae8a99\", \n\"cnt\": 1",
"short_view": "16 bytes",
"type": "attachment_info"
}
],
"fee": 10000000000,
"id": "ee25a5503726368eef558737f81f15fdc5f1e705b678df81315c83d8789ed4b3",
"ins": [
{
"amount": 40000000000000,
"global_indexes": [
1471,
2212,
2224,
2231,
2410,
2508,
2689,
2823,
2969,
3017,
3379
],
"htlc_origin": "",
"kimage_or_ms_id": "e254e999afba8b58a608b2634a9420652b7ad084f27bc1a54328c67ea3a9ccad",
"multisig_count": 0
},
{
"amount": 5000000000000,
"global_indexes": [
1075,
1298,
12282,
12776,
14376,
15954,
16160,
17428,
18450,
24724,
27140
],
"htlc_origin": "",
"kimage_or_ms_id": "b4bbead78a93497bfc6e824f8912cde9293094086f8b9a1ece7a1de86bbe78b2",
"multisig_count": 0
},
{
"amount": 4000000000000,
"global_indexes": [
1426,
1664,
3516,
4478,
6674,
7302,
9144,
10512,
12721,
13115,
16637
],
"htlc_origin": "",
"kimage_or_ms_id": "8e59f6489a30ec67742dc81ab183b97f8a77bd9417f1a3d2578cf4091d32c564",
"multisig_count": 0
},
{
"amount": 900000000000,
"global_indexes": [
15912,
18039,
19507,
20049,
23693,
24192,
24966,
31687,
42782,
43082,
48814
],
"htlc_origin": "",
"kimage_or_ms_id": "3a684270c3ec0a32ed15123a17bd7f29ff0ee3ad2500831cbbc570f7b20b8c0e",
"multisig_count": 0
},
{
"amount": 90000000000,
"global_indexes": [
67559,
76419,
87859,
117969,
119009,
126366,
136622,
161655,
215760,
229083,
250363
],
"htlc_origin": "",
"kimage_or_ms_id": "61ff1dfb6b724c3dba0c16859aa72d014be37c92a44a7b48a17d8ae92d41030a",
"multisig_count": 0
},
{
"amount": 20000000000,
"global_indexes": [
13363,
17153,
34369,
46685,
65871,
75813,
93056,
97252,
113935,
120851,
133386
],
"htlc_origin": "",
"kimage_or_ms_id": "ec65b4482a5f8e49e09303da57f4054f19e68f4a4aeab935bca62a9d4297def7",
"multisig_count": 0
}
],
"keeper_block": 2110251,
"object_in_json": "",
"outs": [
{
"amount": 50000000000000,
"global_index": 3950,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": [
"e04eda49011a30b81629a279285ffda8d69e712b438ecfcc094a26481d8663de"
]
}
],
"pub_key": "76a7575f488a5a32a766fc5da6d190cab4e90b1ab6d0178eed622a79e922a70d",
"timestamp": 1684328300
}
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK",
"tx_info": {
"amount": 18999000000000,
"attachments": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"blob": "ARMBgKCUpY0dBBoAAAAAAAAAABoCAAAAAAAAABoKAAAAAAAAABoPAAAAAAAAACVA4FRLH",
"blob_size": 6794,
"extra": [{
"details_view": "",
"short_view": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"type": "pub_key"
}],
"fee": 1000000000,
"id": "a6e8da986858e6825fce7a192097e6afae4e889cabe853a9c29b964985b23da8",
"ins": [{
"amount": 1000000000000,
"global_indexes": [0,2,12,27],
"htlc_origin": "",
"kimage_or_ms_id": "2540e0544b1fed3b104976f803dbd83681335c427f9d601d9d5aecf86ef276d2",
"multisig_count": 0
}],
"keeper_block": 51,
"object_in_json": "ewogICJ2ZXJzaW9uIjogMSwgCiAgInZpbiI6IFsgewogICAgIC",
"outs": [{
"amount": 9000000000,
"global_index": 0,
"is_spent": false,
"minimum_sigs": 0,
"pub_keys": ["7d0c755e7e24a241847176c9a3cf4c970bcd6377018068abe6fe4535b23f5323"]
}],
"pub_key": "0feef5e2ea0e88b592c0a0e6639ce73e12ea9b3136d89464748fcb60bb6f18f5",
"timestamp": 1557345925
}
}
}
```
### Response description:
```
"status": Status of the call.
"tx_info": Detailed information about the transaction.
"amount": Total output amount of the transaction (legacy, for pre-Zarcanum txs).
"attachments": Additional attachments to the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"blob": Serialized form of the transaction, encoded in Base64.
"blob_size": Size of the serialized transaction in bytes.
"extra": Extra data associated with the transaction.
"details_view": A detailed representation of the extra entry.
"short_view": A concise representation of the extra entry.
"type": Type of the extra entry in the transaction.
"fee": Transaction fee in the smallest currency unit.
"id": Hash of the transaction.
"ins": Inputs of the transaction.
"amount": The amount of coins being transacted.
"global_indexes": List of global indexes indicating the outputs referenced by this input, where only one is actually being spent.
"htlc_origin": Origin hash for HTLC (Hash Time Locked Contract).
"kimage_or_ms_id": Contains either the key image for the input or the multisig output ID, depending on the input type.
"multisig_count": Number of multisig signatures used, relevant only for multisig outputs.
"keeper_block": Block height where the transaction is confirmed, or -1 if it is unconfirmed.
"object_in_json": Serialized transaction represented in JSON, encoded in Base64.
"outs": Outputs of the transaction.
"amount": The output's amount, 0 for ZC outputs.
"global_index": Global index of the output for this specific amount.
"is_spent": Indicates whether the output has been spent.
"minimum_sigs": Minimum number of signatures required to spend the output, for multisig outputs only.
"pub_keys": List of public keys associated with the output.
"pub_key": Public key associated with the transaction.
"timestamp": Timestamp when the transaction was created.
### Response information
- amount - unsigned int; sum of transaction outputs.
- attachments - array of objects; list of transaction attachments.
- blob_size - unsigned int; size of serialized transaction in bytes.
- extra - array of objects; list of extra items.
- fee - unsigned int; transaction fee.
- id - string; hash identifier of the transaction.
- ins - array of objects; list of inputs.
- keeper_block - unsigned int; height of the block containing this transaction.
- object_in_json -
- outs
- amount -
- global_index -
- is_spent -
- minimum_sigs -
- pub_keys -
- pub_key - string; transaction public key.
- timestamp - unsigned int; actual timestamp of the block containing this transaction.
```

View file

@ -0,0 +1,27 @@
Retreives transactions from tx pool (and other information).
URL: ```http:://127.0.0.1:11211/get_tx_pool.bin```
### Request:
```json
{
}
```
### Request description:
```
```
### Response:
```json
{
"status": "OK",
"tx_expiration_ts_median": 1711021795,
"txs": ["7d914497d91442f8f3c2268397d914497d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc2f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"]
}
```
### Response description:
```
"status": Status of the call.
"tx_expiration_ts_median": Timestamp median value of last TX_EXPIRATION_TIMESTAMP_CHECK_WINDOW blocks.
"txs": Transactions as blobs.
```

View file

@ -0,0 +1,59 @@
Get votes' results from the given block range.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_votes",
"params": {
"h_end": 40000,
"h_start": 0
}
}
```
### Request description:
```
"h_end": End of the block range to serach in (excluding).
"h_start": Start of the block range to search in (including).
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"error_code": "",
"status": "OK",
"votes": {
"total_pos_blocks": 87482,
"votes": [{
"no": 37,
"proposal_id": "ZAP999",
"yes": 42
},{
"no": 37,
"proposal_id": "ZAP999",
"yes": 42
}]
}
}
}
```
### Response description:
```
"error_code": Error code, if any.
"status": Status of the call.
"votes": Found votes in the given range.
"total_pos_blocks": Number of blocks in a given range.
"votes": Result of votes in a given range.
"no": Number of negative votes.
"proposal_id": ID of the proposal.
"yes": Nubmer of positve votes.
"no": Number of negative votes.
"proposal_id": ID of the proposal.
"yes": Nubmer of positve votes.
```

View file

@ -1,30 +1,34 @@
Retrieves the current number of blocks in the longest chain known to this node
### Request
Returns the total number of blocks in the blockchain (the height of the top block plus one).
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "getblockcount"
{
"id": 0,
"jsonrpc": "2.0",
"method": "getblockcount",
"params": {
}
}
```
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"count": 2114936,
"status": "OK"
}
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"count": 2697388,
"status": "OK"
}
}
```
### Response description:
```
"count": The total number of blocks in the blockchain, equivalent to the top block's height plus one.
"status": Status of the call.
- count - unsigned integer; total number of blocks in the blockchain, including genesis block at height zero.
```

View file

@ -1,56 +1,59 @@
Returns a block header by the given hash identifier.
### Request
Retrieves the block header information for a given block hash.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "getblockheaderbyhash",
"params": {
"hash": "067fb9861f702b4eabee2e2f9265db3b9adde8a2c43e5afe6887574a12923652"
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "getblockheaderbyhash",
"params": {
"hash": "a1b4359c02985720b0cf542678e08f0d4075e518fbd0cd54bd280269545e0e6f"
}
}
```
---
### Response
### Request description:
```
"hash": The hash of the block for which the header information is being requested.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_header": {
"depth": 3336,
"difficulty": "6867412547068",
"hash": "067fb9861f702b4eabee2e2f9265db3b9adde8a2c43e5afe6887574a12923652",
"height": 2111612,
"major_version": 2,
"minor_version": 0,
"nonce": 5464575110210072335,
"orphan_status": false,
"prev_hash": "6860a4742f167fcf7c46e121c8e139fd5232537f580a22ae76ce8013c06d0f09",
"reward": 1000000000000,
"timestamp": 1684409286
},
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_header": {
"depth": 0,
"difficulty": "1849593878843995770114",
"hash": "f5df39c4b1590394976aa6e72f04df7836e22dbdfc1e6f61f6cc1b624d83cd94",
"height": 2697404,
"major_version": 3,
"minor_version": 0,
"nonce": 0,
"orphan_status": false,
"prev_hash": "a1b4359c02985720b0cf542678e08f0d4075e518fbd0cd54bd280269545e0e6f",
"reward": 0,
"timestamp": 1719588270
},
"status": "OK"
}
}
```
### Response description:
```
"block_header": Detailed header information of the block.
"depth": Depth of the block in the blockchain. Depth 0 indicates the most recent block.
"difficulty": Network difficulty target that the block met.
"hash": Hash of the block.
"height": Height of the block in the blockchain.
"major_version": Major version of the block.
"minor_version": Minor version of the block.
"nonce": Nonce used for generating the block to meet the network difficulty.
"orphan_status": Indicates if the block is an orphan (true) or a normal block (false).
"prev_hash": Hash of the previous block in the chain.
"reward": Total mining reward of the block including transaction fees (if applicable).
"timestamp": Timestamp of the block creation.
"status": Status of the call.
### Response information
- depth - unsigned int; distance in blocks from the blockchain top. Always zero for this call.
- difficulty - unsigned int; block difficulty.
- hash - string; block identifier.
- height - unsigned int; block height.
- major_version - unsigned int; major version of a block.
- minor_version - unsigned int; minor version of a block.
- nonce - unsigned int; block nonce.
- orphan_status - boolean; is this block orphan or not? Always false for this call.
- prev_hash -
- reward - unsigned int; how much money this block has generated.
- timestamp - unsigned int; block timestamp.
---
```

View file

@ -1,55 +1,59 @@
Returns a block header by the given block height.
### Request
Retrieves the block header information for a given block height.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "getblockheaderbyheight",
"params": {
"height": 1
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "getblockheaderbyheight",
"params": {
"height": 2555000
}
}
```
### Request description:
```
"height": The height of the block for which the header information is being requested.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_header": {
"- depth": 2114588,
"difficulty": "1",
"hash": "901214ab938219f5b33b547008607aee14d29950a34834a2e9973b96269bd0b0",
"height": 1,
"major_version": 0,
"minor_version": 0,
"nonce": 1532031558827332528,
"orphan_status": false,
"prev_hash": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"reward": 1000000000000,
"timestamp": 1557342384
},
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_header": {
"depth": 0,
"difficulty": "1849593878843995770114",
"hash": "f5df39c4b1590394976aa6e72f04df7836e22dbdfc1e6f61f6cc1b624d83cd94",
"height": 2697404,
"major_version": 3,
"minor_version": 0,
"nonce": 0,
"orphan_status": false,
"prev_hash": "a1b4359c02985720b0cf542678e08f0d4075e518fbd0cd54bd280269545e0e6f",
"reward": 0,
"timestamp": 1719588270
},
"status": "OK"
}
}
```
### Response description:
```
"block_header": Detailed header information of the block.
"depth": Depth of the block in the blockchain. Depth 0 indicates the most recent block.
"difficulty": Network difficulty target that the block met.
"hash": Hash of the block.
"height": Height of the block in the blockchain.
"major_version": Major version of the block.
"minor_version": Minor version of the block.
"nonce": Nonce used for generating the block to meet the network difficulty.
"orphan_status": Indicates if the block is an orphan (true) or a normal block (false).
"prev_hash": Hash of the previous block in the chain.
"reward": Total mining reward of the block including transaction fees (if applicable).
"timestamp": Timestamp of the block creation.
"status": Status of the call.
### Response information
- depth - unsigned int; distance in blocks from the blockchain top.
- difficulty - unsigned int; block difficulty.
- hash - string; block identifier.
- height - unsigned int; block height.
- major_version - unsigned int; major version of a block.
- minor_version - unsigned int; minor version of a block.
- nonce - unsigned int; block nonce.
- orphan_status - boolean.
- prev_hash
- reward - unsigned int; how much money this block has generated.
- timestamp - unsigned int; block timestamp.
```

View file

@ -0,0 +1,33 @@
NO DESCRIPTION
URL: ```http:://127.0.0.1:11211/getblocks.bin```
### Request:
```json
{
"minimum_height": 0
}
```
### Request description:
```
"minimum_height": The minimum height of the returning buch of blocks.
```
### Response:
```json
{
"blocks": [{
"block": ""
}],
"current_height": 2555000,
"start_height": 2000000,
"status": "OK"
}
```
### Response description:
```
"blocks": Bunch of blocks
"current_height": Current height of the blockchain.
"start_height": Starting height of the resulting bunch of blocks.
"status": Status of the call.
```

View file

@ -1,53 +1,93 @@
Creates a template for the next block
### Request
Generates a block template for mining, intended for both PoW and PoS types of blocks based on the provided parameters.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "getblocktemplate",
"params": {
"wallet_address": "ZxDbSpgDzyaMecaMUi6orsLimz3M8ptCzYzEuboTdYmwai8xhyATWnkHCt26Ts2kT75ajPGgmDAWR6xdpVBto8Vz1dmQJp8AJ",
"extra_text": "",
"pos_block": false,
"stakeholder_address": "",
"pos_amount": 2,
"pos_index": 1
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "getblocktemplate",
"params": {
"explicit_transaction": "5fa8eaaf231a305053260ff91d69c6ef1ecbd0f5",
"extra_text": "OMG, you can't just ask people why they're PoW-maxi",
"pe": {
"amount": 0,
"block_timestamp": 0,
"g_index": 0,
"keyimage": "\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000",
"stake_unlock_time": 0,
"tx_id": "0000000000000000000000000000000000000000000000000000000000000000",
"tx_out_index": 0
},
"pos_block": false,
"stakeholder_address": "",
"wallet_address": "ZxCSpsGGeJsS8fwvQ4HktDU3qBeauoJTR6j73jAWWZxFXdF7XTbGm4YfS2kXJmAP4Rf5BVsSQ9iZ45XANXEYsrLN2L2W77dH7"
}
}
```
### Request description:
```
"explicit_transaction": A transaction blob that must be explicitly included in the block.
"extra_text": Arbitrary data added to the extra field of the miner transaction.
"pe": PoS entry details, relevant only for PoS block generation.
"pos_block": Flag indicating whether the block is a PoS block.
"stakeholder_address": Address where the stake is returned for PoS blocks (usually the same as 'wallet_address').
"wallet_address": Address where mining rewards will be deposited.
### Request parameters
- wallet_address - miner's address for receiving newly generated coins
- extra_text - additional text included into miner transaction. Cannot exceed 255 bytes.
- pos_block - specify type of block template to be created: PoS (true) or PoW (false). Default: false.
- stakeholder_address - specify miner's address to which the stake coins used in PoS block generation will be returned.
- pos_amount - amount of an output used as a stake.
- pos_index - global index of an output used as a stake.
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"blocktemplate_blob": "020000000000000000c0ca345270aba4a14d8aa121bce0e520922e9408617b3fe7d538119dc5501d8200af8ea3a306000101009a8881010180a094a58d1d03c877d75e0c47484beac7fa33cf844230dbfdc5319a1b96ecd6540d23b4e16e1e000416ccff48a0e1aadf652945377b9a22eee97c2b7c0e051afb354425b4cc50451b1215000b0277610ea4888101000000",
"difficulty": "7192110102967",
"height": 2114586,
"prev_hash": "c0ca345270aba4a14d8aa121bce0e520922e9408617b3fe7d538119dc5501d82",
"seed": "ef86c183c51ed4fb2d1a7eec0a752fb2eeb1731d33ae58cb9bfe54880af23e7b",
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_reward": 1000000000000,
"block_reward_without_fee": 1000000000000,
"blocktemplate_blob": "030000000000000000ae73338b792......6258a2b5ee340700",
"difficulty": "12936195379842",
"height": 2555002,
"miner_tx_tgc": {
"amount_blinding_masks": "",
"amount_blinding_masks_sum": "0000000000000000000000000000000000000000000000000000000000000000",
"amount_commitments": "",
"amount_commitments_sum": "00000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"amounts": "",
"ao_amount_blinding_mask": "0000000000000000000000000000000000000000000000000000000000000000",
"ao_amount_commitment": "00000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"ao_asset_id": "0000000000000000000000000000000000000000000000000000000000000000",
"ao_asset_id_pt": "00000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"ao_commitment_in_outputs": "00",
"asset_id_blinding_mask_x_amount_sum": "0000000000000000000000000000000000000000000000000000000000000000",
"asset_id_blinding_masks": "",
"asset_ids": "",
"blinded_asset_ids": "",
"pseudo_out_amount_blinding_masks_sum": "0000000000000000000000000000000000000000000000000000000000000000",
"pseudo_out_amount_commitments_sum": "00000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"pseudo_outs_blinded_asset_ids": "",
"pseudo_outs_plus_real_out_blinding_masks": "",
"real_in_asset_id_blinding_mask_x_amount_sum": "0000000000000000000000000000000000000000000000000000000000000000",
"real_zc_ins_asset_ids": "",
"tx_key": "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"tx_pub_key_p": "00000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000"
},
"prev_hash": "ae73338b7927df71b6ed477937625c230172219306750ba97995fb5109dda703",
"seed": "0518e1373ff88ccabb28493cac10cb0731313135d880dae0d846be6016ab9acf",
"status": "OK",
"txs_fee": 0
}
}
```
### Response description:
```
"block_reward": Total block reward, including transaction fees if they are given to the miner (legacy), or the base reward if fees are burnt (current state).
"block_reward_without_fee": Base block reward excluding any transaction fees.
"blocktemplate_blob": Serialized block template blob.
"difficulty": The mining difficulty targeted by the block template.
"height": The height of the block template in the blockchain.
"miner_tx_tgc": Miner transaction generation context. Intended for PoS blocks and Zarcanum.
"prev_hash": Hash of the previous block in the chain.
"seed": Seed value for the ProgPoWZ mining algorithm's epoch.
"status": Status of the call.
"txs_fee": Total fees from transactions included in the block.
### Response parameters
- blocktemplate_blob- hex-encoded serialized block template.
- difficulty - difficulty for the block template.
- height - height corresponding to the block template.
- prev_hash - previous block hash.
- seed - ethash epoch seed (for mining purposes).
```

View file

@ -0,0 +1,25 @@
Return current blockchain height
URL: ```http:://127.0.0.1:11211/getheight```
### Request:
```json
{
}
```
### Request description:
```
```
### Response:
```json
{
"height": 11111,
"status": "OK"
}
```
### Response description:
```
"height": Height of the blockchain (equals to top block's height + 1).
"status": Status of the call.
```

View file

@ -1,204 +1,195 @@
Retrieves various information about the blockchain node. The user must specify their needs via a 'flags' field in the request by combining necessary flags using binary OR. Some values are always calculated and provided, others only if the corresponding flag is specified.
### Request
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "getinfo",
"params": {
"flags": 1
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "getinfo",
"params": {
"flags": 1048575
}
}
```
### Reponse parameters
- flags -
---
### Response
### Request description:
```
"flags": Combination of flags to request specific data elements that are computationally expensive to calculate.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"alias_count": 1241,
"alt_blocks_count": 0,
"block_reward": 1000000000000,
"current_blocks_median": 125000,
"current_max_allowed_block_size": 250000,
"current_network_hashrate_350": 0,
"current_network_hashrate_50": 0,
"daemon_network_state": 2,
"default_fee": 10000000000,
"expiration_median_timestamp": 0,
"grey_peerlist_size": 351,
"height": 2116212,
"incoming_connections_count": 3,
"last_block_hash": "93e27dcc1cf28962fe38561f09719a20766df0a888d57700ea1a86be9f605256",
"last_block_size": 0,
"last_block_timestamp": 1684684006,
"last_block_total_reward": 1000000000000,
"last_pos_timestamp": 0,
"last_pow_timestamp": 0,
"max_net_seen_height": 2116208,
"mi": {
"build_no": 121,
"mode": 0,
"ver_major": 1,
"ver_minor": 2,
"ver_revision": 0
},
"minimum_fee": 10000000000,
"net_time_delta_median": 0,
"offers_count": 0,
"outgoing_connections_count": 8,
"outs_stat": {
"amount_0_001": 0,
"amount_0_01": 0,
"amount_0_1": 0,
"amount_1": 0,
"amount_10": 0,
"amount_100": 0,
"amount_1000": 0,
"amount_10000": 0,
"amount_100000": 0,
"amount_1000000": 0
},
"performance_data": {
"all_txs_insert_time_5": 0,
"block_processing_time_0": 0,
"block_processing_time_1": 0,
"etc_stuff_6": 0,
"insert_time_4": 0,
"longhash_calculating_time_3": 0,
"map_size": 0,
"raise_block_core_event": 0,
"target_calculating_calc": 0,
"target_calculating_enum_blocks": 0,
"target_calculating_time_2": 0,
"tx_add_one_tx_time": 0,
"tx_append_is_expired": 0,
"tx_append_rl_wait": 0,
"tx_append_time": 0,
"tx_check_exist": 0,
"tx_check_inputs_attachment_check": 0,
"tx_check_inputs_loop": 0,
"tx_check_inputs_loop_ch_in_val_sig": 0,
"tx_check_inputs_loop_kimage_check": 0,
"tx_check_inputs_loop_scan_outputkeys_get_item_size": 0,
"tx_check_inputs_loop_scan_outputkeys_loop": 0,
"tx_check_inputs_loop_scan_outputkeys_loop_find_tx": 0,
"tx_check_inputs_loop_scan_outputkeys_loop_get_subitem": 0,
"tx_check_inputs_loop_scan_outputkeys_loop_handle_output": 0,
"tx_check_inputs_loop_scan_outputkeys_relative_to_absolute": 0,
"tx_check_inputs_prefix_hash": 0,
"tx_check_inputs_time": 0,
"tx_count": 0,
"tx_mixin_count": 0,
"tx_prapare_append": 0,
"tx_print_log": 0,
"tx_process_attachment": 0,
"tx_process_extra": 0,
"tx_process_inputs": 0,
"tx_push_global_index": 0,
"tx_store_db": 0,
"writer_tx_count": 0
},
"pos_allowed": true,
"pos_block_ts_shift_vs_actual": 0,
"pos_diff_total_coins_rate": 0,
"pos_difficulty": "2091093243540034788799",
"pos_sequence_factor": 0,
"pow_difficulty": 7499957992531,
"pow_sequence_factor": 0,
"seconds_for_10_blocks": 0,
"seconds_for_30_blocks": 0,
"status": "OK",
"synchronization_start_height": 2116099,
"synchronized_connections_count": 11,
"total_coins": "",
"transactions_cnt_per_day": 0,
"transactions_volume_per_day": 0,
"tx_count": 557235,
"tx_count_in_last_block": 0,
"tx_pool_performance_data": {
"begin_tx_time": 0,
"check_inputs_time": 0,
"check_inputs_types_supported_time": 0,
"check_keyimages_ws_ms_time": 0,
"db_commit_time": 0,
"expiration_validate_time": 0,
"tx_processing_time": 0,
"update_db_time": 0,
"validate_alias_time": 0,
"validate_amount_time": 0
},
"tx_pool_size": 1,
"white_peerlist_size": 21
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"alias_count": 1653,
"alt_blocks_count": 99,
"block_reward": 1000000000000,
"current_blocks_median": 0,
"current_max_allowed_block_size": 250000,
"current_network_hashrate_350": 107939216153,
"current_network_hashrate_50": 109575236643,
"daemon_network_state": 2,
"default_fee": 10000000000,
"expiration_median_timestamp": 1719585827,
"grey_peerlist_size": 321,
"height": 2555000,
"incoming_connections_count": 0,
"is_hardfok_active": [true,true,true,true,true,false],
"last_block_hash": "153af86fd0d7d0a427526258e30505a4d21b8f77261f5276c7669e0a6c83efa0",
"last_block_size": 0,
"last_block_timestamp": 1719586493,
"last_block_total_reward": 0,
"last_pos_timestamp": 1719585105,
"last_pow_timestamp": 1719586493,
"max_net_seen_height": 2555743,
"mi": {
"build_no": 0,
"mode": 0,
"ver_major": 0,
"ver_minor": 0,
"ver_revision": 0
},
"minimum_fee": 10000000000,
"net_time_delta_median": 0,
"offers_count": 0,
"outgoing_connections_count": 8,
"outs_stat": {
"amount_0": 0,
"amount_0_001": 0,
"amount_0_01": 0,
"amount_0_1": 0,
"amount_1": 0,
"amount_10": 0,
"amount_100": 0,
"amount_1000": 0,
"amount_10000": 0,
"amount_100000": 0,
"amount_1000000": 0
},
"performance_data": {
"all_txs_insert_time_5": 0,
"block_processing_time_0": 0,
"block_processing_time_1": 0,
"etc_stuff_6": 0,
"insert_time_4": 0,
"longhash_calculating_time_3": 0,
"map_size": 0,
"raise_block_core_event": 0,
"target_calculating_calc": 0,
"target_calculating_enum_blocks": 0,
"target_calculating_time_2": 0,
"tx_add_one_tx_time": 0,
"tx_append_is_expired": 0,
"tx_append_rl_wait": 0,
"tx_append_time": 0,
"tx_check_exist": 0,
"tx_check_inputs_attachment_check": 0,
"tx_check_inputs_loop": 0,
"tx_check_inputs_loop_ch_in_val_sig": 0,
"tx_check_inputs_loop_kimage_check": 0,
"tx_check_inputs_loop_scan_outputkeys_get_item_size": 0,
"tx_check_inputs_loop_scan_outputkeys_loop": 0,
"tx_check_inputs_loop_scan_outputkeys_loop_find_tx": 0,
"tx_check_inputs_loop_scan_outputkeys_loop_get_subitem": 0,
"tx_check_inputs_loop_scan_outputkeys_loop_handle_output": 0,
"tx_check_inputs_loop_scan_outputkeys_relative_to_absolute": 0,
"tx_check_inputs_prefix_hash": 0,
"tx_check_inputs_time": 0,
"tx_count": 0,
"tx_mixin_count": 0,
"tx_prapare_append": 0,
"tx_print_log": 0,
"tx_process_attachment": 0,
"tx_process_extra": 0,
"tx_process_inputs": 0,
"tx_push_global_index": 0,
"tx_store_db": 0,
"writer_tx_count": 0
},
"pos_allowed": true,
"pos_block_ts_shift_vs_actual": -1387,
"pos_diff_total_coins_rate": 0,
"pos_difficulty": "1848455949616658404658",
"pos_sequence_factor": 0,
"pow_difficulty": 12777323347117,
"pow_sequence_factor": 1,
"seconds_for_10_blocks": 476,
"seconds_for_30_blocks": 1264,
"status": "OK",
"synchronization_start_height": 2555000,
"synchronized_connections_count": 8,
"total_coins": "14308874719144585856",
"transactions_cnt_per_day": 1325,
"transactions_volume_per_day": 6615220203700000,
"tx_count": 767742,
"tx_count_in_last_block": 0,
"tx_pool_performance_data": {
"begin_tx_time": 0,
"check_inputs_time": 0,
"check_inputs_types_supported_time": 0,
"check_keyimages_ws_ms_time": 0,
"db_commit_time": 0,
"expiration_validate_time": 0,
"tx_processing_time": 0,
"update_db_time": 0,
"validate_alias_time": 0,
"validate_amount_time": 0
},
"tx_pool_size": 0,
"white_peerlist_size": 12
}
}
```
### Response description:
```
"alias_count": The total number of unique aliases registered on the blockchain. Aliases are alternate, human-readable names associated with addresses.
"alt_blocks_count": Number of alternative blocks on the blockchain.
"block_reward": The base block reward that is effective for the next block. Calculated only if either COMMAND_RPC_GET_INFO_FLAG_POS_DIFFICULTY or COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flag is set.
"current_max_allowed_block_size": Current maximum allowed cummulative block size in bytes.
"current_network_hashrate_350": The PoW hash rate calculated over the last 350 blocks of any type. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_CURRENT_NETWORK_HASHRATE_350 flag is set.
"current_network_hashrate_50": The PoW hash rate calculated over the last 50 blocks of any type. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_CURRENT_NETWORK_HASHRATE_50 flag is set.
"daemon_network_state": Current network state of the daemon, which could be connecting, synchronizing, online, loading core, internal error, unloading core, or downloading database.
"default_fee": Default fee for transactions.
"expiration_median_timestamp": Median of timestamps of the last N blocks, used to determine the expiration status of transactions. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_EXPIRATIONS_MEDIAN flag is set.
"grey_peerlist_size": Size of the grey peer list, which includes addresses of nodes with less consistent availability.
"height": The current size of the blockchain, equal to the height of the top block plus one.
"incoming_connections_count": Number of incoming P2P connections established by other nodes.
"is_hardfok_active": A list of boolean values indicating whether each corresponding hardfork is active. For example, a list 'true, true, false' indicates that the first hardfork is activated, while the second is not. Hardfork #0 is always active as it is a stub.
"last_block_hash": Hash of the last block. Calculated only if either COMMAND_RPC_GET_INFO_FLAG_POS_DIFFICULTY or COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flag is set.
"last_block_size": The size of the last block in bytes. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_LAST_BLOCK_SIZE flag is set.
"last_block_timestamp": Timestamp of the last block. Calculated only if either COMMAND_RPC_GET_INFO_FLAG_POS_DIFFICULTY or COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flag is set.
"last_block_total_reward": Reward for the last block, including base reward and transaction fees. Calculated only if either COMMAND_RPC_GET_INFO_FLAG_POS_DIFFICULTY or COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flag is set.
"last_pos_timestamp": The timestamp of the most recent PoS block. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_LAST_POS_TIMESTAMP flag is set.
"last_pow_timestamp": The timestamp of the most recent PoW block. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_LAST_POW_TIMESTAMP flag is set.
"max_net_seen_height": Maximum blockchain height observed in the network by this node.
"mi": The most recent mainterner's info.
"minimum_fee": Minimum fee for transactions.
"net_time_delta_median": A value of 0 indicates no time synchronization issues, while a value of 1 indicates the presence of time sync issues. Only available if the COMMAND_RPC_GET_INFO_FLAG_NET_TIME_DELTA_MEDIAN flag is set.
"offers_count": Current number of offers in the offers service. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_PERFORMANCE flag is set.
"outgoing_connections_count": Number of outgoing P2P connections to other nodes.
"outs_stat": Statistics for the number of outputs that have a specific amount. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_OUTS_STAT flag is set.
"performance_data": Detailed technical performance data intended for developers. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_PERFORMANCE flag is set.
"pos_allowed": Boolean value indicating whether PoS mining is currently allowed based on network rules and state.
"pos_block_ts_shift_vs_actual": The difference between the timestamp used in the last PoS block for mining purposes and its actual timestamp as stored in the miner's transaction extra data. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_POS_BLOCK_TS_SHIFT_VS_ACTUAL flag is set.
"pos_diff_total_coins_rate": PoS difficulty divided by the total amount of all coins in the system minus a premined amount (17,517,203). Calculated only if either COMMAND_RPC_GET_INFO_FLAG_POS_DIFFICULTY or COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flag is set.
"pos_difficulty": Current difficulty for Proof of Stake mining.
"pos_sequence_factor": The current PoS sequence factor, representing the number of consecutive PoS blocks. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_POS_SEQUENCE_FACTOR flag is set.
"pow_difficulty": Current difficulty for Proof of Work mining.
"pow_sequence_factor": The current PoW sequence factor, representing the number of consecutive PoW blocks. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_POW_SEQUENCE_FACTOR flag is set.
"seconds_for_10_blocks": The time period in seconds between the most recent block and the 10th block older. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_SECONDS_FOR_10_BLOCKS flag is set.
"seconds_for_30_blocks": The time period in seconds between the most recent block and the 30th block older. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_SECONDS_FOR_30_BLOCKS flag is set.
"status": Status of the call.
"synchronization_start_height": Blockchain height at which the current synchronization process started. Indicates the starting point for catching up to the network's latest state.
"synchronized_connections_count": Number of P2P connections to nodes that have a fully synchronized blockchain.
"total_coins": The total amount of all emitted coins in the system. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flag is set.
"transactions_cnt_per_day": The number of non-mining transactions recorded over the last 24 hours. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_TRANSACTIONS_DAILY_STAT flag is set.
"transactions_volume_per_day": The total sum of input amounts from all non-mining transactions over the last 24 hours. Only old bare inputs with explicit amounts are considered. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_TRANSACTIONS_DAILY_STAT flag is set.
"tx_count": Total number of transactions in the blockchain.
"tx_count_in_last_block": The number of non-mining transactions in the last block. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_TX_COUNT_IN_LAST_BLOCK flag is set.
"tx_pool_performance_data": Detailed technical performance data intended for developers. This information is only provided if the COMMAND_RPC_GET_INFO_FLAG_PERFORMANCE flag is set.
"tx_pool_size": Number of transactions currently in the pool.
"white_peerlist_size": Size of the white peer list, which includes addresses of reliable nodes.
### Response information
- alias_count — unsigned int; number of total aliases registered.
- alt_blocks_count — unsigned int; number of alternative blocks known to this node.
- block_reward — unsigned int; base block reward for the next block (excluding fees and txs size penalty). Calculated only if both COMMAND_RPC_GET_INFO_FLAG_POS_DIFFICULTY and COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flags are present.
- current_blocks_median — unsigned int; median of cumulative block sizes for the recent N blocks.
- current_max_allowed_block_size — unsigned int; maximum allowed cumulative size of a block in bytes.
- current_network_hashrate_350 — unsigned int; network hashrate calculated by difficulty within a window of the last 350 blocks. Calculated only if COMMAND_RPC_GET_INFO_FLAG_CURRENT_NETWORK_HASHRATE_350 flag is present.
- current_network_hashrate_50 — unsigned int; the same as above for last 50 blocks. Calculated only if COMMAND_RPC_GET_INFO_FLAG_CURRENT_NETWORK_HASHRATE_50 flag is present.
- daemon_network_state — unsigned int; current daemon state. Possible values and their meaning: <br />
daemon_network_state_connecting = 0, <br />
daemon_network_state_synchronizing = 1, <br />
daemon_network_state_online = 2, <br />
daemon_network_state_loading_core = 3, <br />
daemon_network_state_internal_error = 4, <br />
daemon_network_state_unloading_core = 5 <br />
- default_fee — unsigned int; current default fee.
- grey_peerlist_size — unsigned int; number of peers in the gray list (these are peers received from another node and this node has not yet attempted to connect to them).
- height — unsigned int; number of blocks in the main chain.
- incoming_connections_count — unsigned int; number of incoming P2P connections.
- last_block_size — unsigned int; cumulative size of the last block. Returned only if COMMAND_RPC_GET_INFO_FLAG_LAST_BLOCK_SIZE flag is present.
- last_block_total_reward — unsigned int; actual reward for the last block. Calculated only if both COMMAND_RPC_GET_INFO_FLAG_POS_DIFFICULTY and COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flags are present.
- last_pos_timestamp — unsigned int; timestamp of the last PoS block in the main chain. Calculated only if COMMAND_RPC_GET_INFO_FLAG_LAST_POS_TIMESTAMP flag is present.
- last_pow_timestamp — unsigned int; timestamp of the last PoW block in the main chain. Calculated only if COMMAND_RPC_GET_INFO_FLAG_LAST_POW_TIMESTAMP flag is present.
- max_net_seen_height — unsigned int; size of the longest chain among this nodes peers.
- mi — object; the last received maintainer info message with recommended build versions from project maintainers. See below detailed description of maintainers_info_external object.
- minimum_fee — unsigned int; current tx fee minimum required by tx pool.
- net_time_delta_median — signed int; median of system time differences among this nodes peers. Calculated only if COMMAND_RPC_GET_INFO_FLAG_NET_TIME_DELTA_MEDIAN flag is present.
- offers_count — unsigned int; total number of market offers known to this node. Calculated only if COMMAND_RPC_GET_INFO_FLAG_PERFORMANCE flag is present and no --disable-market CLI option was specified.
- outgoing_connections_count — unsigned int; number of outgoing P2P connections.
- outs_stat — object; brief output statistics.
- pos_allowed — boolean; false if PoS blocks cannot be accepted yet, otherwise — true.
- pos_block_ts_shift_vs_actual — signed int; the difference between the block timestamp and actual block timestamp for the last PoS block in the main chain. Calculated only if COMMAND_RPC_GET_INFO_FLAG_POS_BLOCK_TS_SHIFT_VS_ACTUAL flag is present.
- pos_diff_total_coins_rate — unsigned int; current ratio of PoS difficulty to total coins mined. Calculated only if both COMMAND_RPC_GET_INFO_FLAG_POS_DIFFICULTY and COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS flags are present.
- pos_difficulty — unsigned int; difficulty for the next PoS block.
- pos_sequence_factor — unsigned int; size of a continuous sequence of PoS blocks starting from the top block. Calculated only if COMMAND_RPC_GET_INFO_FLAG_POS_SEQUENCE_FACTOR flag is present.
- pow_difficulty — unsigned int; difficulty for the next PoW block.
- pow_sequence_factor — unsigned int; size of a continuous sequence of PoW blocks starting from the top block. (Required flag: COMMAND_RPC_GET_INFO_FLAG_POW_SEQUENcE_FACTOR)
- seconds_for_10_blocks — unsigned int; timestamp difference between the top block and the 10th from the top. (Required flag: - COMMAND_RPC_GET_INFO_FLAG_SECONDS_FOR_10_BLOCKS)
- seconds_for_30_blocks — unsigned int; timestamp difference between the top block and the 30th from the top. (Required flag: COMMAND_RPC_GET_INFO_FLAG_SECONDS_FOR_30_BLOCKS)
- synchronization_start_height — unsigned int; size of the local blockchain when the synchronization process started for the first time after daemon start.
- synchronized_connections_count — unsigned int; number of synchronized peers.
- total_coins — unsigned int; number of emitted coins. (Required flag: COMMAND_RPC_GET_INFO_FLAG_TOTAL_COINS)
- transactions_cnt_per_day — unsigned int; number of non-coinbase transactions for the last 24 hours. (Required flag: COMMAND_RPC_GET_INFO_FLAG_TRANSACTIONS_DAILY_STAT)
- transactions_volume_per_day — unsigned int; total amount of non-miner transactions for the last 24 hours. (Required flag: COMMAND_RPC_GET_INFO_FLAG_TRANSACTIONS_DAILY_STAT)
- tx_count — unsigned int; total number of all non-coinbase transactions.
- tx_count_in_last_block — unsigned int; number of non-coinbase transactions in the last block. (Required flag: COMMAND_RPC_GET_INFO_FLAG_TX_COUNT_IN_LAST_BLOCK)
- tx_pool_size — unsigned int; number of transactions in the tx pool.
- white_peerlist_size — unsigned int; number of peers in the white list (total number of peers to which this node has ever been connected).
#### Fields of maintainers_info_external object:
- ver_major — unsigned int; major build version from project maintainers.
- ver_minor — unsigned int; minor build version from project maintainers.
- ver_revision — unsigned int; revision build version from project maintainers.
- mode — unsigned int; maintainers info message type: <br />
#define ALERT_TYPE_CALM 1 <br />
#define ALERT_TYPE_URGENT 2 <br />
#define ALERT_TYPE_CRITICAL 3 <br />
```

View file

@ -1,65 +1,56 @@
Returns the header of the last block in the blockchain.
### Request
Returns the block header information of the most recent block.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "getlastblockheader",
"params": {
"depth": 1,
"difficulty": 1,
"hash": "",
"prev_hash": "",
"height": 1,
"major_version": 2,
"minor_version": 2,
"nonce": 1,
"orphan_status": true,
"reward": 1,
"timestamp": 1
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "getlastblockheader",
"params": [""]
}
```
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_header": {
"depth": 0,
"difficulty": "7420770173471",
"hash": "5aaa041b0b0f805638a252a6646cfed727c119f38081fda99ceb06cafc00dd7c",
"height": 2114944,
"major_version": 2,
"minor_version": 0,
"nonce": 3074457348328269179,
"orphan_status": false,
"prev_hash": "15e89f8d63b814391d58a103a5314b3d37817e263201d92ab413ee680ea45a95",
"reward": 1000000000000,
"timestamp": 1684610354
},
"status": "OK"
}
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"block_header": {
"depth": 0,
"difficulty": "1849593878843995770114",
"hash": "f5df39c4b1590394976aa6e72f04df7836e22dbdfc1e6f61f6cc1b624d83cd94",
"height": 2697404,
"major_version": 3,
"minor_version": 0,
"nonce": 0,
"orphan_status": false,
"prev_hash": "a1b4359c02985720b0cf542678e08f0d4075e518fbd0cd54bd280269545e0e6f",
"reward": 0,
"timestamp": 1719588270
},
"status": "OK"
}
}
```
### Response description:
```
"block_header": Detailed header information of the block.
"depth": Depth of the block in the blockchain. Depth 0 indicates the most recent block.
"difficulty": Network difficulty target that the block met.
"hash": Hash of the block.
"height": Height of the block in the blockchain.
"major_version": Major version of the block.
"minor_version": Minor version of the block.
"nonce": Nonce used for generating the block to meet the network difficulty.
"orphan_status": Indicates if the block is an orphan (true) or a normal block (false).
"prev_hash": Hash of the previous block in the chain.
"reward": Total mining reward of the block including transaction fees (if applicable).
"timestamp": Timestamp of the block creation.
"status": Status of the call.
- depth - unsigned int; distance in blocks from the blockchain top. Always zero for this call.
- difficulty - unsigned int; block difficulty.
- hash - string; block identifier.
- height - unsigned int; block height.
- major_version - unsigned int; major version of a block.
- minor_version - unsigned int; minor version of a block.
- nonce - unsigned int; block nonce.
- orphan_status - boolean; is this block orphan or not? Always false for this call.
- prev_hash -
- reward - unsigned int; how much money this block has generated.
- timestamp - unsigned int; block timestamp.
```

View file

@ -0,0 +1,34 @@
Retrieve random decoy outputs for specified amounts (legacy format).
URL: ```http:://127.0.0.1:11211/getrandom_outs.bin```
### Request:
```json
{
"amounts": [0,10000000000],
"outs_count": 2,
"use_forced_mix_outs": false
}
```
### Request description:
```
"amounts": List of amounts for which decoy outputs are requested.
"outs_count": Number of decoy outputs requested for each amount.
"use_forced_mix_outs": If true, only outputs with a 'mix_attr' greater than 0 are used as decoys.
```
### Response:
```json
{
"outs": [{
"amount": 10000000000
}],
"status": "OK"
}
```
### Response description:
```
"outs": List of 'outs_for_amount' structures, each containing decoys for a specific amount.
"amount": The amount for which decoys are returned.
"status": Status of the call.
```

View file

@ -0,0 +1,43 @@
Retrieve random decoy outputs for specified amounts (legacy format).
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "getrandom_outs",
"params": {
"amounts": [0,10000000000],
"outs_count": 2,
"use_forced_mix_outs": false
}
}
```
### Request description:
```
"amounts": List of amounts for which decoy outputs are requested.
"outs_count": Number of decoy outputs requested for each amount.
"use_forced_mix_outs": If true, only outputs with a 'mix_attr' greater than 0 are used as decoys.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"outs": [{
"amount": 10000000000
}],
"status": "OK"
}
}
```
### Response description:
```
"outs": List of 'outs_for_amount' structures, each containing decoys for a specific amount.
"amount": The amount for which decoys are returned.
"status": Status of the call.
```

View file

@ -0,0 +1,36 @@
Retrieve random decoy outputs for specified amounts, to be used for mixing in transactions.
URL: ```http:://127.0.0.1:11211/getrandom_outs1.bin```
### Request:
```json
{
"amounts": [0,10000000000,5000000000000],
"decoys_count": 10,
"height_upper_limit": 2555000,
"use_forced_mix_outs": false
}
```
### Request description:
```
"amounts": List of amounts for which decoy outputs are requested.
"decoys_count": Number of decoy outputs required for each amount specified.
"height_upper_limit": Maximum blockchain height from which decoys can be taken. If nonzero, decoys must be at this height or older.
"use_forced_mix_outs": If true, only outputs with a 'mix_attr' greater than 0 are used as decoys.
```
### Response:
```json
{
"outs": [{
"amount": 10000000000
}],
"status": "OK"
}
```
### Response description:
```
"outs": List of 'outs_for_amount' structures, each containing decoys for a specific amount.
"amount": The amount for which decoys are returned.
"status": Status of the call.
```

View file

@ -0,0 +1,45 @@
Retrieve random decoy outputs for specified amounts, to be used for mixing in transactions.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "getrandom_outs1",
"params": {
"amounts": [0,10000000000,5000000000000],
"decoys_count": 10,
"height_upper_limit": 2555000,
"use_forced_mix_outs": false
}
}
```
### Request description:
```
"amounts": List of amounts for which decoy outputs are requested.
"decoys_count": Number of decoy outputs required for each amount specified.
"height_upper_limit": Maximum blockchain height from which decoys can be taken. If nonzero, decoys must be at this height or older.
"use_forced_mix_outs": If true, only outputs with a 'mix_attr' greater than 0 are used as decoys.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"outs": [{
"amount": 10000000000
}],
"status": "OK"
}
}
```
### Response description:
```
"outs": List of 'outs_for_amount' structures, each containing decoys for a specific amount.
"amount": The amount for which decoys are returned.
"status": Status of the call.
```

View file

@ -0,0 +1,41 @@
Version 3 of the command to retrieve random decoy outputs for specified amounts, focusing on either pre-zarcanum or post-zarcanum zones based on the amount value.
URL: ```http:://127.0.0.1:11211/getrandom_outs3.bin```
### Request:
```json
{
"amounts": [{
"amount": 0,
"global_offsets": [1,3,5928,2811]
}],
"coinbase_percents": 15,
"height_upper_limit": 2555000,
"use_forced_mix_outs": false
}
```
### Request description:
```
"amounts": List of amount distributions specifying where to look for decoys, based on old bare outputs or ZC outputs.
"amount": If set to 0, only ZC outputs are considered. If nonzero, only old bare outputs are considered.
"global_offsets": List of global indices for picking decoys. Each index corresponds to a potential decoy output.
"coinbase_percents": Specifies the estimated percentage of coinbase outputs to be included in the decoy sets, ranging from 0 to 100.
"height_upper_limit": Maximum blockchain height from which decoys can be taken. If nonzero, decoys must be at this height or older.
"use_forced_mix_outs": If true, only outputs with a 'mix_attr' greater than 0 are used as decoys.
```
### Response:
```json
{
"outs": [{
"amount": 10000000000
}],
"status": "OK"
}
```
### Response description:
```
"outs": List of 'outs_for_amount' structures, each containing decoys for a specific amount.
"amount": The amount for which decoys are returned.
"status": Status of the call.
```

View file

@ -0,0 +1,50 @@
Version 3 of the command to retrieve random decoy outputs for specified amounts, focusing on either pre-zarcanum or post-zarcanum zones based on the amount value.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "getrandom_outs3",
"params": {
"amounts": [{
"amount": 0,
"global_offsets": [1,3,5928,2811]
}],
"coinbase_percents": 15,
"height_upper_limit": 2555000,
"use_forced_mix_outs": false
}
}
```
### Request description:
```
"amounts": List of amount distributions specifying where to look for decoys, based on old bare outputs or ZC outputs.
"amount": If set to 0, only ZC outputs are considered. If nonzero, only old bare outputs are considered.
"global_offsets": List of global indices for picking decoys. Each index corresponds to a potential decoy output.
"coinbase_percents": Specifies the estimated percentage of coinbase outputs to be included in the decoy sets, ranging from 0 to 100.
"height_upper_limit": Maximum blockchain height from which decoys can be taken. If nonzero, decoys must be at this height or older.
"use_forced_mix_outs": If true, only outputs with a 'mix_attr' greater than 0 are used as decoys.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"outs": [{
"amount": 10000000000
}],
"status": "OK"
}
}
```
### Response description:
```
"outs": List of 'outs_for_amount' structures, each containing decoys for a specific amount.
"amount": The amount for which decoys are returned.
"status": Status of the call.
```

View file

@ -0,0 +1,29 @@
Retreive transactions by their IDs.
URL: ```http:://127.0.0.1:11211/gettransactions```
### Request:
```json
{
"txs_hashes": ["146791c4f5ca94bcf423557e5eb859a3a69991bd33960d52f709d88bf5d1ac6d","ec4d913a40a9ac1fbd9d33b71ef507b5c85d1f503b89096618a18b08991b5171"]
}
```
### Request description:
```
"txs_hashes": List of transactions' IDs.
```
### Response:
```json
{
"missed_tx": ["ec4d913a40a9ac1fbd9d33b71ef507b5c85d1f503b89096618a18b08991b5171"],
"status": "OK",
"txs_as_hex": ["7d914497d91442f8f3c2268397d914497d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc2f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"]
}
```
### Response description:
```
"missed_tx": Missed transactions hashes
"status": Status of the call.
"txs_as_hex": Transactions stored as blobs
```

View file

@ -1,39 +0,0 @@
Mark offer as not active
### Request
```json
{
"jsonrpc": "2.0",
"id": "0",
"method": "marketplace_cancel_offer",
"params": {
"tx_id": "",
"no": 0
}
}
```
### Request parameters
- tx_id - id of the transaction with original offer posting(returned in marketplace_push_offer). Basically offers identified by carrier transactions id. Theoretically, one transaction can carry more than one offer, so then there is a second parameter which specifies an index of the offer inside carrier transaction, but since we didn't want to make the user interface and whole system way too complicated for using, by default API place only one offer per transaction.
- no - this parameter is 0 by default, must be used if transaction carries more then one offer.
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"tx_blob_size": 368,
"tx_hash": "d52014dae0b65168e0551acef9e95972041f3f38d92455d18c8b886baece3d90"
}
}
```
### Response information
- tx_blob_size
- tx_hash - string; tx hash of the transaction related to the offer being cancelled

View file

@ -1,156 +1,118 @@
General marketplace API which lets read offers related to given wallet
### Request
Fetch from daemon offers listed in the marketplace with given filters
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": "0",
"method": "marketplace_global_get_offers_ex",
"params": {
"filter": {
"amount_low_limit": 0,
"amount_up_limit": 0,
"bonus": false,
"category": "",
"fake": false,
"keyword": "",
"limit": 100,
"location_city": "",
"location_country": "",
"offer_type_mask": 0,
"offset": 0,
"order_by": 0,
"primary": "",
"rate_low_limit": "0.000000",
"rate_up_limit": "0.000000",
"reverse": false,
"target": "",
"timestamp_start": 0,
"timestamp_stop": 0,
}
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "marketplace_global_get_offers_ex",
"params": {
"filter": {
"amount_low_limit": 0,
"amount_up_limit": 0,
"bonus": false,
"category": "",
"keyword": "tubes",
"limit": 100,
"location_city": "",
"location_country": "",
"offer_type_mask": 0,
"offset": 0,
"order_by": 0,
"primary": "",
"rate_low_limit": "0.1",
"rate_up_limit": "0.1",
"reverse": false,
"target": "",
"timestamp_start": 0,
"timestamp_stop": 0
}
}
}
```
### Request description:
```
"filter": Filter options.
"amount_low_limit": Lower limit for the amount of offers
"amount_up_limit": Upper limit for the amount of offers
"bonus": Bonus associated with the offers
"category": Category of the offers
"keyword": Keyword for searching offers
"limit": Maximum number of results to return
"location_city": City of the location for the offers
"location_country": Country of the location for the offers
"offer_type_mask": Mask representing the types of offers to include in the results, conbination of this: OFFER_TYPE_MASK_PRIMARY_TO_TARGET 0x00000001, OFFER_TYPE_MASK_TARGET_TO_PRIMARY 0x00000002, OFFER_TYPE_MASK_GOODS_TO_PRIMARY 0x00000004, OFFER_TYPE_MASK_PRIMARY_TO_GOODS 0x00000008
"offset": Offset for pagination
"order_by": Field to order the results by one on this: ORDER_BY_TIMESTAMP=0,ORDER_BY_AMOUNT_PRIMARY=1,ORDER_BY_AMOUNT_TARGET=2,ORDER_BY_AMOUNT_RATE=3,ORDER_BY_PAYMENT_TYPES=4,ORDER_BY_CONTACTS=5,ORDER_BY_LOCATION=6,ORDER_BY_NAME=7
"primary": Primary field for the offers
"rate_low_limit": Lower limit for the rate
"rate_up_limit": Upper limit for the rate
"reverse": Flag to indicate whether the results should be sorted in reverse order
"target": Target entity of the offers
"timestamp_start": Start timestamp for filtering results
"timestamp_stop": Stop timestamp for filtering results
### Request parameters
- amount_low_limit - filter offers selection by field amount of specified currency at lower boundary.
- amount_up_limit - filter offers selection by field amoun of specified currency t at higher boundary.
-bonus
- category - fiter by category, work's as substring matching, i.e. if categories set to "CLS:MAN:TSH" and filters category fileds set to "MAN" then it fits category condition.
- fake
- keyword - This use search by keyword throught the all fields.
- limit - Maximum records to return.
- location_city - Used to filter by city name or geo-tag
- location_country - Filters by country code.
- offer_type_mask - Specify type of the offer:
- offset - Offeset regarding first item which fit specified filter, count include only items which fit the filter. Userful for enumeration big amount or records, up to whole offers database enumeration.
- order_by - chose in how to order offers in selection. At this moment supported following ordering:
"order_by" |
--- | ---
0 | Order by timestamp (most usable)
1 | Order by an amount of Zano
2 | Order by the amount of specified currency
3 | Order by rate, which calculated as the amount currency divided to amount Zano
4 | Order by payment type(as string)
5 | Order by contact field(as string)
6 | Order by location: country string concatenated with city string
7 | Order by target string, basically title string
- primary -
- rate_low_limit - Filter by low limit of the rate between Zano and currency amount currency divided to amount Zano
- reverse - Reverse order
- target - Basically a title for subject of the Offer - could be the name of the goods or currency which supposed to be traded.
- timestamp_start - Setup a lower timestamp boundary. Useful if the offers are selecting for given time range.
- timestamp_stop - Setup a higher timestamp boundary. Useful if the offers are selecting for given time range.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"offers": [
{
"ap": "20",
"at": "1",
"b": "",
"cat": "CLS:MAN:TSH",
"cnt": "Skype: some_skype, discord: some_user#01012",
"com": "Some nice comments about tshirt",
"do": "Additional conditions",
"et": 10,
"fee": 10000000000,
"index_in_tx": 0,
"lci": "",
"lco": "World Wide",
"ot": 1,
"p": "USD",
"pt": "Credit cards, BTC, ZANO, ETH",
"security": "0000000000000000000000000000000000000000000000000000000000000000",
"t": "T-shirt with Zano logo, made by Crypjunkie",
"timestamp": 1570219600,
"tx_hash": "6ba12c5d2c66d31f770bfdc88ae9dc90d007b9b33f946fc7c1d9750f8655331c",
"tx_original_hash": "0000000000000000000000000000000000000000000000000000000000000000"
},
{
"ap": "20",
"at": "1",
"b": "",
"cat": "CLS:MAN:TSH",
"cnt": "Skype: some_skype, discord: some_user#01012",
"com": "Some nice comments about tshirt",
"do": "Additional conditions",
"et": 10,
"fee": 10000000000,
"index_in_tx": 0,
"lci": "",
"lco": "World Wide",
"ot": 1,
"p": "USD",
"pt": "Credit cards, BTC, ZANO, ETH",
"security": "0000000000000000000000000000000000000000000000000000000000000000",
"t": "T-shirt with Zano logo, made by Crypjunkie",
"timestamp": 1570219840,
"tx_hash": "2987b671cc337203628a3a1bb7ac811e41f110864d6162d3c2276d2c79f694d6",
"tx_original_hash": "0000000000000000000000000000000000000000000000000000000000000000"
}
],
"status": "",
"total_offers": 0
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"offers": [{
"ap": "100000",
"at": "10000000",
"b": "",
"cat": "",
"cnt": "Ranko +38211111111",
"com": "Dobr dan",
"do": "full amount, by parts",
"et": 0,
"fee": 10000000000,
"index_in_tx": 0,
"lci": "Kolasin",
"lco": "Montenegro",
"ot": 0,
"p": "ZANO",
"pt": "zano",
"security": "40fa6db923728b38962718c61b4dc3af1acaa1967479c73703e260dc3609c58d",
"t": "USDT",
"timestamp": 1712683857,
"tx_hash": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"tx_original_hash": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"url": ""
}],
"status": "OK",
"total_offers": 1
}
}
```
### Response description:
```
"offers": List of offers related to the operation.
"ap": Amount of the currency
"at": Smount of other currency or goods
"b": Bonus associated with the offer
"cat": Category of the offer
"cnt": Contacts related to the offer
"com": Comment associated with the offer
"do": Deal option for the offer
"et": Expiration time of the offer
"fee": Fee associated with the transaction
"index_in_tx": Index of the tx_service_attachment entrie in transaction
"lci": City of the offer location
"lco": Country of the offer location
"ot": Type of the offer: OFFER_TYPE_PRIMARY_TO_TARGET(SELL ORDER) - 0, OFFER_TYPE_TARGET_TO_PRIMARY(BUY ORDER) - 1 etc.
"p": Currency for goods
"pt": Types of payment accepted for the offer
"security": Onwer's public key for access control
"t": Target: currency / goods
"timestamp": Timestamp of the transaction
"tx_hash": Transaction hash represented as a hexadecimal string
"tx_original_hash": Origin transaction hash represented as a hexadecimal string(if offer updated)
"url": URL for previewing the offer
"status": Status of the operation.
"total_offers": Total number of offers.
### Response information
- ap - the amount of the currency specified for use in this offer
- at - the amount of the items to be sold/bought
- b -
- cat - category of the goods, could be specified with subcategories by separation CLS:MAN:TSH, which could mean Clothes->Man->Tshirts
- cnt - contacts, like skype, discord, telegram, whatever
- com - comments regarding this offer
- do - additional conditions, if need to specify
- et - expiration time, set in days, eg 5 - expire in 5 days after creation
- fee - fee paid for this transaction with the offer, it can be default offer, but the higher fee may bring offers to be higher in search results
- index_in_tx -
- lci - location city, if the also make sense for an offer, could be google geo-autocomplete id, like ChIJD7fiBh9u5kcRYJSMaMOCCwQ
- lco - location country, if this makes sense for an offer
- ot - offer type, 0 - buy currency for Zano, 1 - buy Zano for currency, 2 - buy goods for Zano, 3 - sell goods for Zano
- p -
- pt - payment type, Credit cards, Crypto, Paypal, Flexa
- security -
- t - description for the goods/service which is selling/seeking
- timestamp -
- tx_hash -
- tx_original_hash -
```

View file

@ -1,67 +0,0 @@
Broadcasts transaction that was previously signed using sign_transfer call
### Request
```json
{
"jsonrpc": "2.0",
"id": "0",
"method": "marketplace_push_offer",
"params": {
"od": {
"ap": "1000",
"at": "1",
"cat": "CLS:MAN:TSH",
"cnt": "https://zanobazaar.com",
"com": "This field is where you write a detailed overview of your product or service, make it good",
"do": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf",
"et": 10,
"fee": 10000000000,
"lci": "THE ZANOVERSE",
"lco": "Decentralized",
"ot": 3,
"pt": "$ZANO",
"t": "Product Title",
"url": "QmVWxCy7JyEuvxMPpcQ4jBzsRxtMFjbF6VGMc4CGuN6iqK"
}
}
}
```
### Request parameters
- ap - the amount of the currency specified for use in this offer
- at - the amount of the items to be sold/bought
- cat - string; category of the goods, could be specified with subcategories by separation CLS:MAN:TSH, which could mean Clothes->Man->Tshirts
- cnt - string; contacts, like skype, discord, telegram, whatever
- com - string; comments regarding this offer
- do - string; additional conditions, if need to specify
- et - integer; expiration time, set in days, eg 5 - expire in 5 days after creation
- fee - fee paid for this transaction with the offer, it can be default offer, but the higher fee may bring offers to be higher in search results
- lci - string; location city, if the also make sense for an offer, could be google geo-autocomplete id, like ChIJD7fiBh9u5kcRYJSMaMOCCwQ
- lco - string; location country, if this makes sense for an offer
- ot - integer; offer type, 0 - buy currency for Zano, 1 - buy Zano for currency, 2 - buy goods for Zano, 3 - sell goods for Zano
- pt - string; payment type, Credit cards, Crypto, Paypal, Flexa
- t - string; description for the goods/service which is selling/seeking
- url - string; url of your stores web presence etc
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"tx_blob_size": 549,
"tx_hash": "2987b671cc337203628a3a1bb7ac811e41f110864d6162d3c2276d2c79f694d6"
}
}
```
### Response information
- tx_blob_size
- tx_hash - string; tx hash of the transaction related to the offer being pushed

View file

@ -1,68 +0,0 @@
This method update marketplace offer details
### Request
```json
{
"jsonrpc": "2.0",
"id": "0",
"method": "marketplace_push_update_offer",
"params": {
"tx_id": "",
"no": 0,
"od": {
"ap": "1000",
"at": "1",
"cat": "CLS:MAN:TSH",
"cnt": "https://zanobazaar.com",
"com": "This field is where you write a detailed overview of your product or service, make it good",
"do": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf",
"et": 10,
"fee": 10000000000,
"lci": "THE ZANOVERSE",
"lco": "Decentralized",
"ot": 3,
"pt": "$ZANO",
"t": "Product Title",
"url": "QmVWxCy7JyEuvxMPpcQ4jBzsRxtMFjbF6VGMc4CGuN6iqK"
}
}
}
```
### Request parameters
- ap - the amount of the currency specified for use in this offer
- at - the amount of the items to be sold/bought
- cat - category of the goods, could be specified with subcategories by separation CLS:MAN:TSH, which could mean Clothes->Man->Tshirts
- cnt - contacts, like skype, discord, telegram, whatever
- com - comments regarding this offer
- do - additional conditions, if need to specify
- et - expiration time, set in days, eg 5 - expire in 5 days after creation
- fee - fee paid for this transaction with the offer, it can be default offer, but the higher fee may bring offers to be higher in search results
- lci - location city, if the also make sense for an offer, could be google geo-autocomplete id, like ChIJD7fiBh9u5kcRYJSMaMOCCwQ
- lco - location country, if this makes sense for an offer
- ot - offer type, 0 - buy currency for Zano, 1 - buy Zano for currency, 2 - buy goods for Zano, 3 - sell goods for Zano
- pt - payment type, Credit cards, Crypto, Paypal, Flexa
- t - description for the goods/service which is selling/seeking
- url - string; url of your stores web presence etc
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"tx_blob_size": 725,
"tx_hash": "06da9bac0f15fd7ab41983f9437f95835b1baef6810fe15b2ea831f60b058b4b"
}
}
```
### Response information
- tx_blob_size
- tx_hash - string; tx hash of the transaction related to the offer being pushed

View file

@ -1,24 +1,28 @@
Obtains block hash by given block height
### Request
Returns block hash by the given height.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "on_getblockhash",
"params": [2111]
{
"id": 0,
"jsonrpc": "2.0",
"method": "on_getblockhash",
"params": [0]
}
```
### Request description:
```
---
### Response
```
### Response:
```json
{
"id": "0",
"jsonrpc": "2.0",
"result": "68b3bcf941431fe76420059ce3104bb34ee122a49d0b541af1041ab06e0015bb"
{
"id": 0,
"jsonrpc": "2.0",
"result": ""
}
```
### Response description:
```
```

View file

@ -0,0 +1,34 @@
Removes specified transactions from the transaction pool, typically to clear out transactions that are no longer valid or needed.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "remove_tx_from_pool",
"params": {
"tx_to_remove": ["c5efacd06128fc5a73f58392c84534cd1a146de7d47ffbe770486cce5130dc1f","c2f0de2ef4753dc0ec8dd2da5ebf8e77f07d2ac0791357a9e3f2537071b33762"]
}
}
```
### Request description:
```
"tx_to_remove": List of transaction IDs that are to be removed from the transaction pool.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
}
```
### Response description:
```
"status": Status of the call.
```

View file

@ -1,25 +1,32 @@
Clears the transaction pool.
### Request
Clears transaction pool.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "reset_transaction_pool"
{
"id": 0,
"jsonrpc": "2.0",
"method": "reset_transaction_pool",
"params": {
}
}
```
### Request description:
```
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
}
```
```
### Response description:
```
"status": Status of the call.
```

View file

@ -1,35 +1,36 @@
Returns type of an entity by specified hash identifier.
### Request
Searches for a given ID across various entity types such as blocks, transactions, key images, multisig outputs, and alternative blocks, useful when the entity type is unknown or unspecified.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "search_by_id",
"params": {
"id": "ee25a5503726368eef558737f81f15fdc5f1e705b678df81315c83d8789ed4b3"
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "search_by_id",
"params": {
"id": "729811f9340537e8d5641949e6cc58261f91f109687a706f39bae9514757e819"
}
}
```
### Request description:
```
"id": The identifier used to search across various types of entities.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK",
"types_found": [
"tx"
]
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK",
"types_found": ["key_image"]
}
}
```
### Response description:
```
"status": Status of the call.
"types_found": List of entity types where the identifier was found.
### Response information
- types_found — array of strings; a set of the types found (usually only one). Possible values: block, alt_block, key_image, tx, multisig_id.
```

View file

@ -0,0 +1,25 @@
Broadcasts a raw transaction encoded in hexadecimal format to the network.
URL: ```http:://127.0.0.1:11211/sendrawtransaction```
### Request:
```json
{
"tx_as_hex": "00018ed1535b8b4862e.....368cdc5a86"
}
```
### Request description:
```
"tx_as_hex": The transaction data as a hexadecimal string, ready for network broadcast.
```
### Response:
```json
{
"status": "OK"
}
```
### Response description:
```
"status": Status of the call.
```

View file

@ -0,0 +1,25 @@
NO DESCRIPTION
URL: ```http:://127.0.0.1:11211/set_maintainers_info.bin```
### Request:
```json
{
"maintainers_info_buff": "",
"sign": "\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000"
}
```
### Request description:
```
```
### Response:
```json
{
"status": "OK"
}
```
### Response description:
```
"status": Status of the call.
```

View file

@ -1,38 +1,31 @@
Submits the given block, i.e., adds it to the local blockchain and broadcasts it to the network
### Request
Adds new block to the blockchain. Request should contain one string with hex-encoded block blob.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "submitblock",
"params": {
"blocks_blob": [
"03000000000000000082c9bcdac5235a4e99e3862875a3e27137e623bd63f94ba66f7841ba22baa6e300c4a5d9a30600020100b8560416ab8369d10446e568bb09e692f88406547ea58e2feb8ea63f24be11d0b1cc8f0715000b0207f30ec25602264191c581563790e0df16ad75a42102d43428f6012fb460840980f29ddda9940bafe8d36221a9f8b86b492ba34127637f5dbd5679165ba2e899ad2a0c9cc33f95416228327e1739264d2f5cfe3dcb7541d9d688e9e5e6c9880a20eae15106772d74c32d3eaafafc623bf483e858d42e8bf4ec7df064ada2e34934469cff6b6268db894cb01aebc2a00026bd94233b6997d82f0bb10c816c71fa5dd617422bbb36fd0456fb8ea7499a97790de72a34afbf045859a1f12017ba2e3b87f3dd386ffdb8793b93982f2bba9544ea02c54f6c6a668610cb505a30e1fc8e9ee0088b8c1fecb800e34f1f3f88829374c32d3eaafafc623bf483e858d42e8bf4ec7df064ada2e34934469cff6b6268232da30f20273b5f000000032e002f07f77dc653e37b3a38a6e53fbfcbe47cefd7e27d5130dbfdc6be972a5162577ac6d822a876cd674a8df26781ec5c7a72f05f4fa20d8b83bcbee1107beeaceb926a8490a1953610ec9f25f5f0829001d816ab7e4db77277492f5ce0862b0d6f3bbd0b9d9829eb95103dbe45a00885dd2d920a0936bf584846e160852304a79911fd9fdb7e5da94a5b1c4f43d32199e7b74cce272098f47db56fb3536045a097ed72916646c916a1c14364a8358cee02d483d17b36bc6f412abf8d7382c9c31fa757e8b3e063533b5308eae4daf691ed0f0b437cd95816ba869cd7980daf0e2272fa07d2ced19035c4caaa974606e14235d003aae6ae6dcc570ba8e53500b96e2abc3c82eeda787fcd791364f822e5b353956a06eeb4635b995ce0843c0172fb61416d8a440c4113b3a4a66d4808262c27b9fa1585f99bb41e6ad663a676e67f225cbd39cbb2925428999ee766609c65345b6c1fd6bcf2357eeea2be20b14b4b7956cb7cb176c55de60bfc1927e67ef581d82cd140dedf5659a3512d59cf9fa5ba66c7a7f26b4a65d1a999f3f315ec14a47cfd785357273166558b04dea07ac96101e2036d9f81018f818810ca0faacc205ea939e409f79c80b7ad44ffa624315dcc4be7a85f97402c336c65e9130b134dfa32248f41e0d829e71a138a966f6e60b323872b9a8e5b82ed84b93d20155b32bc716f79d70aa22ba1514674dbef464029ca0854ca74b997a1ed8fda26be726f052fb6ca68ccc44b24da7ca0dbde4b3846a61d86521ef167f5d3f550fd30bb207499670e2c6ca8fdee61fcb9e045de76130465cd7d96590c85ca7ee534f729661a10fe268c8e481c115276d637a0e8655905c490360fa73286412d241b640bd586199a9fdf5f771faa61499751ab34fd3101028c788f39b8dcc1dcb263b31acf33d3af868530c6dc891a808a8066f48aa1c4652962f6b67e389e20e82ed3580643a46e737b27031d2b6a91e19abbf77eba400b021f8570961711802534d6d30a697d971124a3a1b50bc529f34210be08ee6203041eda2f0be95c7c1a77a7a8a00d5b1262296553f80fbfd8fa0fd6d54c6327250e02f5b9cc5104c7c4ce33698b1925fa03b60bb45a89d2be4bd57dec396f8e461806aecedd7e3f0c2216fb14026e05f8696232248e52b587aab8c40fa6c78174da04c2a65a9c02836303e5c3e983d1aaa98ba5e188f5ca3ff824902eda5d567bfe033035b18fb2e9a7171f7f4bf66ab9d637a16b07ac87c0b65ca1b9d89448cdf3ea0db71b06c3422729b7f1538d62b00af94144ebbdb01c90acdf898a4d753767460f00"
]
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "submitblock",
"params": [""]
}
```
### Request parameters
- blocks_blob - array of a single string; block's blob.
---
### Response
```json
{
"id": "0",
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
}
```
### Response description:
```
"status": Status of the call.
- status - describes if the rpc call was successful
```

View file

@ -0,0 +1,40 @@
Adds new block to the blockchain.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "submitblock2",
"params": {
"b": "030000000000000000ae73338b7926258a2b5ee340700",
"explicit_txs": [{
"blob": "36323538613262356565376139633230"
},{
"blob": "38653066306132636565333430373030"
}]
}
}
```
### Request description:
```
"b": Hex-encoded serialized block.
"explicit_txs": List of hex-encoded transactions to be explicitly included in the block.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
}
```
### Response description:
```
"status": Status of the call.
```

View file

@ -1,38 +1,40 @@
Validates a Schnorr signature for arbitrary data. The public key for verification is provided directly or retrieved using an associated alias.
### Request
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
curl -i -X POST \
-H "Content-Type:application/json" \
-d \
'{
"jsonrpc": "2.0",
"id": 0,
"method": "validate_signature",
"params":
{
"buff": "aGFoYWhh",
"alias": "ravaga"
"pkey": "",
"sig": "80229d7660ad61a565af8f980cc86723b7a67d5d2f205e5f6895294ed700cd08e4be15bfb00889ad9731d51d7e8687585c2e27c031e214229a3fcc1ce3a17d0d"
}
}
}' \
'http://127.0.0.1:12111/json_rpc'
```
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "validate_signature",
"params": {
"alias": "sowle",
"buff": "SSBkaWRuJ3QgZXhwZWN0IGFueW9uZSB0byBkZWNyeXB0IHRoaXMgZGF0YSwgc2luY2UgaXQncyBqdXN0IGFuIGV4YW1wbGUuIEJ1dCB5b3UgZGVjcnlwdGVkIGl0ISBJJ20gYW1hemVkLg==",
"pkey": "",
"sig": "5c202d4bf82c2dd3c6354e2f02826ca72c797950dbe8db5bc5e3b2e60290a407ac2ef85bfc905ace8fe3b3819217084c00faf7237fee3ad2f6a7f662636cd20f"
}
}
```
### Request description:
```
"alias": Alias to retrieve the associated public spend key if no explicit public key is provided for verification.
"buff": Base64 encoded data for which the signature is to be validated.
"pkey": Public key used for signature verification, encoded as a hexadecimal string. If null or not set, the public key is retrieved using the provided alias.
"sig": Schnorr signature to validate, encoded as a hexadecimal string.
```
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
}
```
### Response description:
```
"status": Status of the call.
```

View file

@ -0,0 +1,55 @@
Add given asset id to local whitelist. This whitelist is stored with the wallet file and reset in case of wallet resync or restoring wallet from seed phrase.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "assets_whitelist_add",
"params": {
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8"
}
}
```
### Request description:
```
"asset_id": Asset id that needed to be added to local whitelist, asset_id must exist in the network
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"asset_descriptor": {
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped ABC",
"hidden_supply": false,
"meta_info": "{ \"logo_url\": \"https:\/\/some.nice.logo.png\"}",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"owner_eth_pub_key": "",
"ticker": "ZABC",
"total_max_supply": 1000000000000000000
},
"status": "OK"
}
}
```
### Response description:
```
"asset_descriptor": Details of the asset, recieved from node
"current_supply": Currently emitted supply for the given asset (ignored for REGISTER operation).
"decimal_point": Decimal point.
"full_name": Full name of the asset.
"hidden_supply": This field is reserved for future use and will be documented later.
"meta_info": Any other information associated with the asset, by default in a json format.
"owner": Owner's key, used only for EMIT and UPDATE validation, can be changed by transferring asset ownership.
"owner_eth_pub_key": [Optional] Owner's key in the case when ETH signature is used.
"ticker": Ticker associated with the asset.
"total_max_supply": Maximum possible supply for a given asset, cannot be changed after deployment.
"status": Status of the asset
```

View file

@ -0,0 +1,99 @@
Get whitelisted assets for this wallet, assets descriptors present in any of the lists in results would be present in balance() call results(if those assets are part of the wallet transfers). Assets that are not included in those lists won't be included in balance even if the wallet own inputs with such assets.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "assets_whitelist_get",
"params": {
}
}
```
### Request description:
```
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"global_whitelist": [{
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped ABC",
"hidden_supply": false,
"meta_info": "{ \"logo_url\": \"https:\/\/some.nice.logo.png\"}",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"owner_eth_pub_key": "",
"ticker": "ZABC",
"total_max_supply": 1000000000000000000
}],
"local_whitelist": [{
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped ABC",
"hidden_supply": false,
"meta_info": "{ \"logo_url\": \"https:\/\/some.nice.logo.png\"}",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"owner_eth_pub_key": "",
"ticker": "ZABC",
"total_max_supply": 1000000000000000000
}],
"own_assets": [{
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped ABC",
"hidden_supply": false,
"meta_info": "{ \"logo_url\": \"https:\/\/some.nice.logo.png\"}",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"owner_eth_pub_key": "",
"ticker": "ZABC",
"total_max_supply": 1000000000000000000
}]
}
}
```
### Response description:
```
"global_whitelist": Global whitelist, well-known assets with adoption, mantained by the team and community
"asset_id": Asset ID
"current_supply": Currently emitted supply for the given asset (ignored for REGISTER operation).
"decimal_point": Decimal point.
"full_name": Full name of the asset.
"hidden_supply": This field is reserved for future use and will be documented later.
"meta_info": Any other information associated with the asset, by default in a json format.
"owner": Owner's key, used only for EMIT and UPDATE validation, can be changed by transferring asset ownership.
"owner_eth_pub_key": [Optional] Owner's key in the case when ETH signature is used.
"ticker": Ticker associated with the asset.
"total_max_supply": Maximum possible supply for a given asset, cannot be changed after deployment.
"local_whitelist": Local whitelist, assets that hase been added to this wallet file manually(!)
"asset_id": Asset ID
"current_supply": Currently emitted supply for the given asset (ignored for REGISTER operation).
"decimal_point": Decimal point.
"full_name": Full name of the asset.
"hidden_supply": This field is reserved for future use and will be documented later.
"meta_info": Any other information associated with the asset, by default in a json format.
"owner": Owner's key, used only for EMIT and UPDATE validation, can be changed by transferring asset ownership.
"owner_eth_pub_key": [Optional] Owner's key in the case when ETH signature is used.
"ticker": Ticker associated with the asset.
"total_max_supply": Maximum possible supply for a given asset, cannot be changed after deployment.
"own_assets": Own assets, the ones that is under control of this wallet
"asset_id": Asset ID
"current_supply": Currently emitted supply for the given asset (ignored for REGISTER operation).
"decimal_point": Decimal point.
"full_name": Full name of the asset.
"hidden_supply": This field is reserved for future use and will be documented later.
"meta_info": Any other information associated with the asset, by default in a json format.
"owner": Owner's key, used only for EMIT and UPDATE validation, can be changed by transferring asset ownership.
"owner_eth_pub_key": [Optional] Owner's key in the case when ETH signature is used.
"ticker": Ticker associated with the asset.
"total_max_supply": Maximum possible supply for a given asset, cannot be changed after deployment.
```

View file

@ -0,0 +1,34 @@
Remove given asset id from local whitelist. This whitelist is stored with the wallet file and reset in case of wallet resync or restoring wallet from seed phrase.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "assets_whitelist_remove",
"params": {
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8"
}
}
```
### Request description:
```
"asset_id": Asset id to be removed from local whitelist
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"status": "OK"
}
}
```
### Response description:
```
"status": Command result (OK if success)
```

View file

@ -1,128 +0,0 @@
Checks redeemed proposal
### Request
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "atomics_check_htlc_redeemed",
"params": {
"htlc_tx_id": ""
}
}
```
### Request parameters
- htlc_tx_id - ID for transaction carrying HTLC.
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"last_item_index": 72,
"pi": {
"balance": 2260000000000,
"curent_height": 1623835,
"transfer_entries_count": 96,
"transfers_count": 3,
"unlocked_balance": 2260000000000
},
"total_transfers": 3,
"transfers": [
{
"amount": 1000000000000,
"comment": "",
"fee": 10000000000,
"height": 1131972,
"is_income": true,
"is_mining": false,
"is_mixing": false,
"is_service": false,
"payment_id": "",
"remote_addresses": [
"ZxCD4JQoUw6MD343aKyJx2Zx44fdkc2r22rwULfcBDrAKyfcqYPNjiFKfnXVyRcHgMLdJLrhmmvN4ViRBDfanhLZ1EdqY8vbk"
],
"show_sender": false,
"td": {
"rcv": [
1000000000000
]
},
"timestamp": 1625569494,
"transfer_internal_index": 0,
"tx_blob_size": 1225,
"tx_hash": "b4f6335a3d476629448aad0cbb5a56cbd36ea60d00dcfdb79b501d3f2d4abede",
"tx_type": 0,
"unlock_time": 0
},
{
"amount": 1000000000000,
"comment": "",
"fee": 10000000000,
"height": 1131972,
"is_income": true,
"is_mining": false,
"is_mixing": false,
"is_service": false,
"payment_id": "",
"remote_addresses": [
"ZxCD4JQoUw6MD343aKyJx2Zx44fdkc2r22rwULfcBDrAKyfcqYPNjiFKfnXVyRcHgMLdJLrhmmvN4ViRBDfanhLZ1EdqY8vbk"
],
"show_sender": false,
"td": {
"rcv": [
1000000000000
]
},
"timestamp": 1625569494,
"transfer_internal_index": 1,
"tx_blob_size": 1226,
"tx_hash": "0a7551887a82f893aedfe72aa32189a84743d0044d47b05a5000a2a08ce791a3",
"tx_type": 0,
"unlock_time": 0
},
{
"amount": 0,
"comment": "",
"fee": 10000000000,
"height": 1555055,
"is_income": false,
"is_mining": false,
"is_mixing": false,
"is_service": true,
"payment_id": "",
"recipients_aliases": [
"testtest"
],
"remote_addresses": [
"ZxDEMMwyGBE1JE1b5pYH4vExnTeFfN3gMeiC1wb7n5dVC43oLHAJXkq5pmiZqRMegTi4LzepmddWWAiUZBc44HJL2iStSuRPV"
],
"show_sender": false,
"td": {
"spn": [
10000000000
]
},
"timestamp": 1651003337,
"transfer_internal_index": 72,
"tx_blob_size": 324,
"tx_hash": "78695ec5cd55bc507955c53dcca11a08d13d91498d5edfd2b61415783f23c133",
"tx_type": 5,
"unlock_time": 0
}
]
}
}
```
### Response information
- origin_secrete_as_hex - Revealed origin secret, encoded in HEX. If this field is empty, then HTLC have not been redeemed yet.
- redeem_tx_id - ID of transaction that redeem HTLC. Likely you won't need this field, put it here just in case.

View file

@ -1,46 +0,0 @@
Creates atomic swap proposal
### Request
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "atomics_create_htlc_proposal",
"params": {
"amount": 1,
"counterparty_address": "",
"lock_blocks_count": 1,
"htlc_hash": ""
}
}
```
### Request parameters
- amount - amount of the coins going into HTLC. Fee for redeem transaction will be withheld from this amount too.
- counterparty_address - an address of the other part of atomic swap process
- lock_blocks_count - amount of blocks, which define a period of time, allotted for the redeem operation. 1 block - 1 minute, 1440 blocks is est 1 day.
- htlc_hash - Hash of the secret, if this field specified, then HTLC created with this hash, if this is empty, then wallet will derive secret in deterministic way, and in response will be returned derived_origin_secret, which will be the key for redeem of this HTLC and, obviously, for HTLC created by counter-party in the other blockchain. At this moment by default RPC API in wallet support only sha256 as hashing for HTLC, but we also have implemented support of RIPEMD-160 in core and wallet, so if anyone need access to this hash, please make a issue in our github, and we'll be happy to enable support of this hash too.
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"result_tx_blob": "b329cce92a23fdaf89a5ad907ca9c4c1fbd052b79ec8414438533c83b39afc2bb329cce92a23fdaf89a5ad907ca9c4c1fbd052b79ec8414438533c83b39afc2bb329cce92a23fdaf89a5ad907ca9c4c1fbd052b79ec8414438533c83",
"result_tx_id": "b329cce92a23fdaf89a5ad907ca9c4c1fbd052b79ec8414438533c83b39afc2b",
"derived_origin_secret_as_hex": "fe42b8c4742d2dbe4d5de5ae5212f75acb62b75e4b66b758ff8e252825c2d7a5"
}
}
```
### Response information
- result_tx_blob - Created and broadcasted transaction itself.
- result_tx_id - Created transaction id .
- derived_origin_secret_as_hex - If htlc_hash field in request was empty, then this field will keep secret, which was deterministically created by sender wallet(If wallet file was lost and recovered from backup with seed phrase, then secret for any particular HTLC created by this wallet will be possible to restore). This field is HEX-encoded, but sha256 supposed to be calculated from raw blob of this secret.

View file

@ -1,46 +0,0 @@
Shows the list of active proposals
### Request
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "atomics_get_list_of_active_htlc",
"params": {
"income_redeem_only": true
}
}
```
### Request parameters
- income_redeem_only - Shows only incoming HTLCs, ie only those contracts which might be redeemed by this wallet.
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"htlcs": {
"counterparty_address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp",
"sha256_hash": "8ee7377d6ee3632ea5b43bed2a5ea41c035abb3fe6146aec63e6c5cbbc4257f1",
"tx_id": "018c8bcf749063ee4a8127b84586a03f9bbd1909d9e5cfdb92007ebc463462d4",
"amount": 100000,
"is_redeem": "true"
}
}
}
```
### Response information
- counterparty_address - Address of the party created HTLC
- sha256_hash - Hash of the HTLC, by default sha256
- tx_id - ID of transaction carrying this HTLC(this ID needed for call of atomics_redeem_htlc)
- amount - Amount being transfered by this HTLC
- is_redeem - define, if this HTLC is incoming with respect to the current wallet

View file

@ -1,40 +0,0 @@
Redeems atomic swap
### Request
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "atomics_redeem_htlc",
"params": {
"tx_id": "",
"origin_secret_as_hex": ""
}
}
```
### Request parameters
- tx_id - Identify transaction which carry needed HTLC, by this we basically identify HTLC itself. (Theoretically one transaction can carry more then 1 HTLC, but since this unlikely will ever be used, current implementation of the wallet assume it only one HTLC per tx, and we identify HTLC by carrying tx_id. This can be changed in future, if needed, without hardfork).
- origin_secret_as_hex - Secret for HTLC, encoded in HEX. (sha256 supposed to be calculated from raw secret blob).
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"result_tx_blob": "df956c7c82cc2658333de5ca3c860edf956c7c82cc2658333de5ca3c860edf956c7c82cc2658333de5ca3c860edf956c7c82cc2658333de5ca3c860edf956c7c82cc2658333de5ca3c860e",
"result_tx_id": "612ca0baf8a1a8b7b86d9b56e3b9e1ef4bf6af6296ece8d75e85601fe3987b7b"
}
}
```
### Response information
- result_tx_blob - Created and broadcasted transaction in a hex encoded blob.
- result_tx_id - Created and broadcasted transaction's ID.

View file

@ -0,0 +1,53 @@
Burn some owned amount of the coins for the given asset.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "burn_asset",
"params": {
"asset_id": "40fa6db923728b38962718c61b4dc3af1acaa1967479c73703e260dc3609c58d",
"burn_amount": 10000000,
"native_amount": 0,
"point_tx_to_address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp",
"service_entries": [{
"body": "dcfd7e055a6a3043ea3541a571a57a63e25dcc64e4a270f14fa9a58ac5dbec85dcfd7e055a6a3043ea3541a571a57a63e25dcc64e4a270f14fa9a58ac5dbec85",
"flags": 0,
"instruction": "K",
"security": "d8f6e37f28a632c06b0b3466db1b9d2d1b36a580ee35edfd971dc1423bc412a5",
"service_id": "C"
}]
}
}
```
### Request description:
```
"asset_id": Id of the asset to burn
"burn_amount": Amount to burn
"native_amount": Optional, if we need this transaction to be seen by particular wallet
"point_tx_to_address": Optional, if we need this transaction to be seen by particular wallet
"service_entries": Optional, if we need to include service entries for burn transaction
"body": Hex-encoded body of the attachment
"flags": Flags that help wallet to automatically process some properties of the attachment(combination of TX_SERVICE_ATTACHMENT_ENCRYPT_BODY=1, TX_SERVICE_ATTACHMENT_DEFLATE_BODY=2, TX_SERVICE_ATTACHMENT_ENCRYPT_BODY_ISOLATE_AUDITABLE=4,TX_SERVICE_ATTACHMENT_ENCRYPT_ADD_PROOF=8 )
"instruction": Instruction that make sence for this particular service
"security": Hex-encoded public key of the owner, optional
"service_id": Service ID, identificator that diferent one service from another
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"tx_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8"
}
}
```
### Response description:
```
"tx_id": Id of transaction that carries asset burn operation
```

View file

@ -0,0 +1,34 @@
Trivially decrypt base64 encoded data message with chacha using wallet spend key
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "decrypt_data",
"params": {
"buff": "ZGNjc2Ztc2xrZm12O2xrZm12OydlbGtmdm0nbGtmbXY="
}
}
```
### Request description:
```
"buff": base64 encoded data message to be decrypted
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"res_buff": "ZGNjc2Ztc2xrZm12O2xrZm12OydlbGtmdm0nbGtmbXY="
}
}
```
### Response description:
```
"res_buff": base64 encoded resulted data message
```

View file

@ -0,0 +1,66 @@
Deploy new asset in the system.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "deploy_asset",
"params": {
"asset_descriptor": {
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped ABC",
"hidden_supply": false,
"meta_info": "{ \"logo_url\": \"https:\/\/some.nice.logo.png\"}",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"owner_eth_pub_key": "",
"ticker": "ZABC",
"total_max_supply": 1000000000000000000
},
"destinations": [{
"address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp",
"amount": 10000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852"
}],
"do_not_split_destinations": false
}
}
```
### Request description:
```
"asset_descriptor": Descriptor that holds all information about asset - ticker, emission, description etc
"current_supply": Currently emitted supply for the given asset (ignored for REGISTER operation).
"decimal_point": Decimal point.
"full_name": Full name of the asset.
"hidden_supply": This field is reserved for future use and will be documented later.
"meta_info": Any other information associated with the asset, by default in a json format.
"owner": Owner's key, used only for EMIT and UPDATE validation, can be changed by transferring asset ownership.
"owner_eth_pub_key": [Optional] Owner's key in the case when ETH signature is used.
"ticker": Ticker associated with the asset.
"total_max_supply": Maximum possible supply for a given asset, cannot be changed after deployment.
"destinations": Addresses where to receive emitted coins. Asset id in the destinations is irreleant and can be omitted.
"address": Destination address
"amount": Amount to transfer to destination
"asset_id": Asset id to transfer
"do_not_split_destinations": If true, the provided destinations will be used as-is and won't be splitted (or altered) to avoid common issues. Default is false.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"new_asset_id": "40fa6db923728b38962718c61b4dc3af1acaa1967479c73703e260dc3609c58d",
"tx_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8"
}
}
```
### Response description:
```
"new_asset_id": Issued asset id
"tx_id": Id of transaction that carries asset registration command, asset would be registered as soon as transaction got confirmed
```

View file

@ -0,0 +1,45 @@
Emmit new coins of the the asset, that is controlled by this wallet.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "emit_asset",
"params": {
"asset_id": "40fa6db923728b38962718c61b4dc3af1acaa1967479c73703e260dc3609c58d",
"destinations": [{
"address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp",
"amount": 10000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852"
}],
"do_not_split_destinations": false
}
}
```
### Request description:
```
"asset_id": Id of the asset to emit more coins
"destinations": Addresses where to receive emitted coins. Asset id in the destinations is irreleant and can be omitted.
"address": Destination address
"amount": Amount to transfer to destination
"asset_id": Asset id to transfer
"do_not_split_destinations": If true, the provided destinations will be used as-is and won't be splitted (or altered) to avoid common issues. Default is false.
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"tx_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8"
}
}
```
### Response description:
```
"tx_id": Id of transaction that emits the required asset.
```

View file

@ -0,0 +1,34 @@
Trivially encrypt base64 encoded data message with chacha using wallet spend key
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "encrypt_data",
"params": {
"buff": "ZGNjc2Ztc2xrZm12O2xrZm12OydlbGtmdm0nbGtmbXY="
}
}
```
### Request description:
```
"buff": base64 encoded data message to be encrypted
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"res_buff": "ZGNjc2Ztc2xrZm12O2xrZm12OydlbGtmdm0nbGtmbXY="
}
}
```
### Response description:
```
"res_buff": base64 encoded resulted data message
```

View file

@ -0,0 +1,38 @@
Return information about wallet's pre-zarcanum era outputs. Those outputs should be converted to post-zarcanum varian with trnasfering it sooner or later. (Only outputs that have been created in Zarcanum era can participaet in staking)
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_bare_outs_stats",
"params": {
}
}
```
### Request description:
```
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"expected_total_fee": 10000000000,
"total_amount": 12000000000000,
"total_bare_outs": 112,
"txs_count": 2
}
}
```
### Response description:
```
"expected_total_fee": Expected total transaction fee required for processing the transaction.
"total_amount": Total amount of native coins involved in bare outputs.
"total_bare_outs": Total number of inspent bare outputs in the wallet.
"txs_count": Total number of transactions needed to convert all bare outputs .
```

View file

@ -1,48 +1,49 @@
Gets list of incoming transfers by given payment IDs
### Request
Gets list of incoming transfers by a given multiple payment_ids
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_payments",
"params": {
"payment_id": "",
"allow_locked_transactions": false
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_bulk_payments",
"params": {
"allow_locked_transactions": false,
"min_block_height": 0,
"payment_ids": ["1dfe5a88ff9effb3","1dfe5a88ff9effb3"]
}
}
```
### Request description:
```
"allow_locked_transactions": Says to wallet if locked transfers should be included or not (false is strongly recomennded)
"min_block_height": Minimal block height to consider
"payment_ids": Payment ids that is used to identify transfers
### Request parameters
- payment_id - payment id of txs to search
- allow_locked_transactions - include transactions that are currently locked
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"payments": [
{
"amount": 100000000,
"block_height": 202556,
"tx_hash": "01220e8304d46b940a86e383d55ca5887b34f158a7365bbcdd17c5a305814a93",
"unlock_time": 0
}
]
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"payments": [{
"amount": 100000000000,
"block_height": 12321,
"payment_id": "1dfe5a88ff9effb3",
"tx_hash": "01220e8304d46b940a86e383d55ca5887b34f158a7365bbcdd17c5a305814a93",
"unlock_time": 0
}]
}
}
```
### Response description:
```
"payments": Array of payments that connected to given payment_id
"amount": Amount of native coins transfered
"block_height": Block height that holds transaction
"payment_id": Payment id that related to this payment
"tx_hash": Transaction ID that is holding this payment
"unlock_time": Timestamp/blocknumber after which this money would become availabe, recommended don't count transfers that has this field not 0
### Response information
- amount - unsigned int; amount of coins in atomic units.
- block_height - unsigned int; height of the block containing corresponding transaction.
- tx_hash - string; transactions hash.
- unlock_time - unsigned int; if nonzero — unix timestamp since then this transfers coins can be spent. If it is less than 500000000, the value is treated as a minimum block height at which this transfers coin can be spent.
```

View file

@ -1,11 +1,40 @@
Returns wallet statistic on mining. As an argument 'v' it receive timestamp from which history is reviewed
### Request
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_mining_history"
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_mining_history",
"params": {
"v": 0
}
}
```
```
### Request description:
```
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"mined_entries": [{
"a": 1000000000000,
"h": 102000,
"t": 1712683857
}]
}
}
```
### Response description:
```
"mined_entries": Mined blocks entries.
"a": Mined amount(block reward)
"h": height
"t": Timestamp
```

View file

@ -1,48 +1,47 @@
Gets list of incoming transfers by a given payment ID
### Request
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_payments",
"params": {
"payment_id": "",
"allow_locked_transactions": false
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_payments",
"params": {
"allow_locked_transactions": false,
"payment_id": "1dfe5a88ff9effb3"
}
}
```
### Request description:
```
"allow_locked_transactions": Says to wallet if locked transfers should be included or not (false is strongly recomennded)
"payment_id": Payment id that is used to identify transfers
### Request parameters
- payment_id - string; payment id to be searched
- allow_locked_transactions - include currently locked transactions
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"payments": [
{
"amount": 100000000,
"block_height": 202556,
"tx_hash": "01220e8304d46b940a86e383d55ca5887b34f158a7365bbcdd17c5a305814a93",
"unlock_time": 0
}
]
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"payments": [{
"amount": 100000000000,
"block_height": 12321,
"payment_id": "1dfe5a88ff9effb3",
"tx_hash": "01220e8304d46b940a86e383d55ca5887b34f158a7365bbcdd17c5a305814a93",
"unlock_time": 0
}]
}
}
```
### Response description:
```
"payments": Array of payments that connected to given payment_id
"amount": Amount of native coins transfered
"block_height": Block height that holds transaction
"payment_id": Payment id that related to this payment
"tx_hash": Transaction ID that is holding this payment
"unlock_time": Timestamp/blocknumber after which this money would become availabe, recommended don't count transfers that has this field not 0
### Response information
- amount - unsigned int; amount of coins in atomic units.
- block_height - unsigned int; height of the block containing corresponding transaction.
- tx_hash - string; transactions hash.
- unlock_time - unsigned int; if nonzero — unix timestamp since then this transfers coins can be spent. If it is less than 500000000, the value is treated as a minimum block height at which this transfers coin can be spent.
```

View file

@ -0,0 +1,154 @@
Returns wallet history of transactions
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_recent_txs_and_info",
"params": {
"count": 100,
"exclude_mining_txs": false,
"exclude_unconfirmed": false,
"offset": 0,
"order": "FROM_END_TO_BEGIN",
"update_provision_info": true
}
}
```
### Request description:
```
"count": How many items to fetch, if items fetched is less then count, then it enumeration is over
"exclude_mining_txs": Exclude mining/staking transactions from results(last_item_index should be used for subsequential calls)
"exclude_unconfirmed": Do not include uncomfirmed transactions in results (it also not included is offset is non zero)
"offset": Offset from what index to start fetching transfers entries(if filters are used then last_item_index could be used from previous call)
"order": Order: "FROM_BEGIN_TO_END" or "FROM_END_TO_BEGIN"
"update_provision_info": If update pi is required, could be false only if need to optimize performance(appliable for a veru big wallets)
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"last_item_index": 1,
"pi": {
"balance": 100000000000,
"curent_height": 121212,
"transfer_entries_count": 3,
"transfers_count": 1,
"unlocked_balance": 90000000000
},
"total_transfers": 1,
"transfers": [{
"ado": {
"operation_type": 1,
"opt_amount_commitment": "5688b56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"opt_asset_id": "cc4e69455e63f4a581257382191de6856c2156630b3fba0db4bdd73ffcfb36b6",
"version": 2
},
"amount": 1000000000000,
"comment": "Comment here",
"contract": [{
"cancel_expiration_time": 0,
"contract_id": "0000000000000000000000000000000000000000000000000000000000000000",
"expiration_time": 0,
"height": 0,
"is_a": false,
"payment_id": "",
"private_detailes": {
"a_addr": "ZxBiDtnzhro111111111111111111111111111111111111111111111111111111111111111111111111111111116xzE1X",
"a_pledge": 0,
"b_addr": "ZxBiDtnzhro111111111111111111111111111111111111111111111111111111111111111111111111111111116xzE1X",
"b_pledge": 0,
"c": "",
"t": "",
"to_pay": 0
},
"state": 0,
"timestamp": 0
}],
"employed_entries": {
},
"fee": 10000000000,
"height": 0,
"is_income": false,
"is_mining": false,
"is_mixing": false,
"is_service": false,
"payment_id": "00000000ff00ff00",
"remote_addresses": ["ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp"],
"remote_aliases": ["roger"],
"service_entries": [{
"body": "dcfd7e055a6a3043ea3541a571a57a63e25dcc64e4a270f14fa9a58ac5dbec85dcfd7e055a6a3043ea3541a571a57a63e25dcc64e4a270f14fa9a58ac5dbec85",
"flags": 0,
"instruction": "K",
"security": "d8f6e37f28a632c06b0b3466db1b9d2d1b36a580ee35edfd971dc1423bc412a5",
"service_id": "C"
}],
"show_sender": false,
"subtransfers": [{
"amount": 1000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"is_income": false
}],
"timestamp": 1712590951,
"transfer_internal_index": 12,
"tx_blob_size": 0,
"tx_hash": "5509650e12c8f901e6731a2bfaf3abfd64409e3e1366d3d94cd11db8beddb0c3",
"tx_type": 0,
"unlock_time": 0
}]
}
}
```
### Response description:
```
"last_item_index": Index of last returned item(might be needed if filters are used)
"pi": Additiona details about balance state
"balance": Current balance of native coins
"curent_height": Current sync height of the wallet
"transfer_entries_count": Number of UTXO entries in wallet
"transfers_count": Number of transfers in wallet
"unlocked_balance": Unlocked balance oof native coins
"total_transfers": Total number of transfers in the tx history
"transfers": Transfers history array
"ado": "Asset Descriptor Operation" if it was present in transaction
"operation_type": Asset operation type identifier
"opt_amount_commitment": (optional) Asset operation amount commitment (register/emit/burn).
"opt_asset_id": (optional) ID of an asset (emit/burn/update).
"version": Asset operation type struct version
"amount": Native coins amount
"comment": Some human-readable comment
"contract": Escrow contract if it's part of transaction
"employed_entries": Mark entries from transaction that was connected to this wallet
"fee": Transaction fee
"height": Height of the block that included transaction(0 i transaction is unconfirmed)
"is_income": If trnasfer entrie is income (taken from native subtransfer)
"is_mining": Tells if this transaction is coinbase transaction(ie generated by PoW mining or by PoS staking)
"is_mixing": Tells if this transaction using mixins or not(auditble wallets normally don't use mixins)
"is_service": Tells if this transaction is used as utility by one of Zano services(contracts, ionic swaps, etc)
"payment_id": HEX-encoded payment id blob, if it was present
"remote_addresses": Remote addresses of this transfer(destination if it's outgoing transfer or sender if it's incoming transaction)
"remote_aliases": Aliases for remot addresses, of discovered
"service_entries": Additional entries that might be stored in transaction but not part of it's consensus
"body": Hex-encoded body of the attachment
"flags": Flags that help wallet to automatically process some properties of the attachment(combination of TX_SERVICE_ATTACHMENT_ENCRYPT_BODY=1, TX_SERVICE_ATTACHMENT_DEFLATE_BODY=2, TX_SERVICE_ATTACHMENT_ENCRYPT_BODY_ISOLATE_AUDITABLE=4,TX_SERVICE_ATTACHMENT_ENCRYPT_ADD_PROOF=8 )
"instruction": Instruction that make sence for this particular service
"security": Hex-encoded public key of the owner, optional
"service_id": Service ID, identificator that diferent one service from another
"show_sender": If sender is included in tx
"subtransfers": Essential part of transfer entry: amounts that been transfered in this transaction grouped by asset id
"amount": Amount of asset the had been transfered
"asset_id": Asset id
"is_income": Indicates if transfer was income our outgoing
"timestamp": Timestamp of the block that included transaction in blockchain, 0 for unconfirmed
"transfer_internal_index": Index of this entry in the wallet's array of transaction's history
"tx_blob_size": Size of transaction in bytes
"tx_hash": Transaction ID(hash)
"tx_type": Could be one of this: GUI_TX_TYPE_NORMAL=0, GUI_TX_TYPE_PUSH_OFFER=1, GUI_TX_TYPE_UPDATE_OFFER=2, GUI_TX_TYPE_CANCEL_OFFER=3, GUI_TX_TYPE_NEW_ALIAS=4,GUI_TX_TYPE_UPDATE_ALIAS=5,GUI_TX_TYPE_COIN_BASE=6,GUI_TX_TYPE_ESCROW_PROPOSAL=7,GUI_TX_TYPE_ESCROW_TRANSFER=8,GUI_TX_TYPE_ESCROW_RELEASE_NORMAL=9,GUI_TX_TYPE_ESCROW_RELEASE_BURN=10,GUI_TX_TYPE_ESCROW_CANCEL_PROPOSAL=11,GUI_TX_TYPE_ESCROW_RELEASE_CANCEL=12,GUI_TX_TYPE_HTLC_DEPOSIT=13,GUI_TX_TYPE_HTLC_REDEEM=14
"unlock_time": Unlock time of this transfer (if present)
```

View file

@ -0,0 +1,150 @@
Returns wallet history of transactions V2(post-zarcanum version)
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_recent_txs_and_info2",
"params": {
"count": 100,
"exclude_mining_txs": false,
"exclude_unconfirmed": false,
"offset": 0,
"order": "FROM_END_TO_BEGIN",
"update_provision_info": true
}
}
```
### Request description:
```
"count": How many items to fetch, if items fetched is less then count, then it enumeration is over
"exclude_mining_txs": Exclude mining/staking transactions from results(last_item_index should be used for subsequential calls)
"exclude_unconfirmed": Do not include uncomfirmed transactions in results (it also not included is offset is non zero)
"offset": Offset from what index to start fetching transfers entries(if filters are used then last_item_index could be used from previous call)
"order": Order: "FROM_BEGIN_TO_END" or "FROM_END_TO_BEGIN"
"update_provision_info": If update pi is required, could be false only if need to optimize performance(appliable for a veru big wallets)
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"last_item_index": 1,
"pi": {
"balance": 100000000000,
"curent_height": 121212,
"transfer_entries_count": 3,
"transfers_count": 1,
"unlocked_balance": 90000000000
},
"total_transfers": 1,
"transfers": [{
"ado": {
"operation_type": 1,
"opt_amount_commitment": "5688b56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"opt_asset_id": "cc4e69455e63f4a581257382191de6856c2156630b3fba0db4bdd73ffcfb36b6",
"version": 2
},
"comment": "Comment here",
"contract": [{
"cancel_expiration_time": 0,
"contract_id": "0000000000000000000000000000000000000000000000000000000000000000",
"expiration_time": 0,
"height": 0,
"is_a": false,
"payment_id": "",
"private_detailes": {
"a_addr": "ZxBiDtnzhro111111111111111111111111111111111111111111111111111111111111111111111111111111116xzE1X",
"a_pledge": 0,
"b_addr": "ZxBiDtnzhro111111111111111111111111111111111111111111111111111111111111111111111111111111116xzE1X",
"b_pledge": 0,
"c": "",
"t": "",
"to_pay": 0
},
"state": 0,
"timestamp": 0
}],
"employed_entries": {
},
"fee": 10000000000,
"height": 0,
"is_mining": false,
"is_mixing": false,
"is_service": false,
"payment_id": "00000000ff00ff00",
"remote_addresses": ["ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp"],
"remote_aliases": ["roger"],
"service_entries": [{
"body": "dcfd7e055a6a3043ea3541a571a57a63e25dcc64e4a270f14fa9a58ac5dbec85dcfd7e055a6a3043ea3541a571a57a63e25dcc64e4a270f14fa9a58ac5dbec85",
"flags": 0,
"instruction": "K",
"security": "d8f6e37f28a632c06b0b3466db1b9d2d1b36a580ee35edfd971dc1423bc412a5",
"service_id": "C"
}],
"show_sender": false,
"subtransfers": [{
"amount": 1000000000000,
"asset_id": "cc608f59f8080e2fbfe3c8c80eb6e6a953d47cf2d6aebd345bada3a1cab99852",
"is_income": false
}],
"timestamp": 1712590951,
"transfer_internal_index": 12,
"tx_blob_size": 0,
"tx_hash": "5509650e12c8f901e6731a2bfaf3abfd64409e3e1366d3d94cd11db8beddb0c3",
"tx_type": 0,
"unlock_time": 0
}]
}
}
```
### Response description:
```
"last_item_index": Last item index
"pi": Details on wallet balance etc
"balance": Current balance of native coins
"curent_height": Current sync height of the wallet
"transfer_entries_count": Number of UTXO entries in wallet
"transfers_count": Number of transfers in wallet
"unlocked_balance": Unlocked balance oof native coins
"total_transfers": Total transfers
"transfers": Transfers
"ado": "Asset Descriptor Operation" if it was present in transaction
"operation_type": Asset operation type identifier
"opt_amount_commitment": (optional) Asset operation amount commitment (register/emit/burn).
"opt_asset_id": (optional) ID of an asset (emit/burn/update).
"version": Asset operation type struct version
"comment": Some human-readable comment
"contract": Escrow contract if it's part of transaction
"employed_entries": Mark entries from transaction that was connected to this wallet
"fee": Transaction fee
"height": Height of the block that included transaction(0 i transaction is unconfirmed)
"is_mining": Tells if this transaction is coinbase transaction(ie generated by PoW mining or by PoS staking)
"is_mixing": Tells if this transaction using mixins or not(auditble wallets normally don't use mixins)
"is_service": Tells if this transaction is used as utility by one of Zano services(contracts, ionic swaps, etc)
"payment_id": HEX-encoded payment id blob, if it was present
"remote_addresses": Remote addresses of this transfer(destination if it's outgoing transfer or sender if it's incoming transaction)
"remote_aliases": Aliases for remot addresses, of discovered
"service_entries": Additional entries that might be stored in transaction but not part of it's consensus
"body": Hex-encoded body of the attachment
"flags": Flags that help wallet to automatically process some properties of the attachment(combination of TX_SERVICE_ATTACHMENT_ENCRYPT_BODY=1, TX_SERVICE_ATTACHMENT_DEFLATE_BODY=2, TX_SERVICE_ATTACHMENT_ENCRYPT_BODY_ISOLATE_AUDITABLE=4,TX_SERVICE_ATTACHMENT_ENCRYPT_ADD_PROOF=8 )
"instruction": Instruction that make sence for this particular service
"security": Hex-encoded public key of the owner, optional
"service_id": Service ID, identificator that diferent one service from another
"show_sender": If sender is included in tx
"subtransfers": Essential part of transfer entry: amounts that been transfered in this transaction grouped by asset id
"amount": Amount of asset the had been transfered
"asset_id": Asset id
"is_income": Indicates if transfer was income our outgoing
"timestamp": Timestamp of the block that included transaction in blockchain, 0 for unconfirmed
"transfer_internal_index": Index of this entry in the wallet's array of transaction's history
"tx_blob_size": Size of transaction in bytes
"tx_hash": Transaction ID(hash)
"tx_type": Could be one of this: GUI_TX_TYPE_NORMAL=0, GUI_TX_TYPE_PUSH_OFFER=1, GUI_TX_TYPE_UPDATE_OFFER=2, GUI_TX_TYPE_CANCEL_OFFER=3, GUI_TX_TYPE_NEW_ALIAS=4,GUI_TX_TYPE_UPDATE_ALIAS=5,GUI_TX_TYPE_COIN_BASE=6,GUI_TX_TYPE_ESCROW_PROPOSAL=7,GUI_TX_TYPE_ESCROW_TRANSFER=8,GUI_TX_TYPE_ESCROW_RELEASE_NORMAL=9,GUI_TX_TYPE_ESCROW_RELEASE_BURN=10,GUI_TX_TYPE_ESCROW_CANCEL_PROPOSAL=11,GUI_TX_TYPE_ESCROW_RELEASE_CANCEL=12,GUI_TX_TYPE_HTLC_DEPOSIT=13,GUI_TX_TYPE_HTLC_REDEEM=14
"unlock_time": Unlock time of this transfer (if present)
```

View file

@ -0,0 +1,34 @@
Return wallet seed, which could be password-protected(seed secured with passphrase) or open(unsecured seed). If no password provided it returns open (unsecured) seed.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_restore_info",
"params": {
"seed_password": "010101012"
}
}
```
### Request description:
```
"seed_password": Password to secure wallet's seed
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"seed_phrase": "girlfriend unlike offer mutter tightly social silent expect constant bid nowhere reach flower bite salt becomeconversation dog rush quietly become usually lightning midnight each secret class"
}
}
```
### Response description:
```
"seed_phrase": Wallet's seed(secured with password if it was provided in argument)
```

View file

@ -1,40 +1,44 @@
This endpoint wasnt on original docs and was found in GitHub code, needs a description of what the endpoint does, any required request parameters? and descriptions for json response parameters
:::info
Check with Ravaga what this endpoint does.
:::
### Request
This call is used to validate seed phrase and to fetch additional information about it
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_seed_phrase_info"
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_seed_phrase_info",
"params": {
"seed_password": "0101010103",
"seed_phrase": "girlfriend unlike mutter tightly social silent expect constant bid nowhere reach flower bite salt lightning conversation dog rush quietly become usually midnight each secret offer class"
}
}
```
### Request description:
```
"seed_password": Password used to encrypt or decrypt the mnemonic seed phrase, if applicable.
"seed_phrase": Mnemonic seed phrase used for wallet recovery or generation.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"hash_sum_matched": false,
"require_password": false,
"syntax_correct": false,
"tracking": false
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"address": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf",
"hash_sum_matched": true,
"require_password": true,
"syntax_correct": true,
"tracking": false
}
}
```
### Response description:
```
"address": Return address of the seed phrase.
"hash_sum_matched": Indicates whether the hash sum matches.
"require_password": Indicates whether a password is required.
"syntax_correct": Indicates whether the syntax is correct.
"tracking": Indicates whether tracking is enabled.
### Response information
- hash_sum_matched - ?
- require_password - ?
- syntax_correct - ?
- tracking - ?
```

View file

@ -1,38 +1,46 @@
Gets information related to wallet
### Request
Returns wallet helpful wallet information
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "get_wallet_info"
{
"id": 0,
"jsonrpc": "2.0",
"method": "get_wallet_info",
"params": {
}
}
```
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"address": "ZxDbSpgDzyaMecaMUi6orsLimz3M8ptCzYzEuboTdYmwai8xhyATWnkHCt26Ts2kT75ajPGgmDAWR6xdpVBto8Vz1dmQJp8AJ",
"current_height": 2116310,
"is_whatch_only": false,
"path": "docs.wallet",
"transfer_entries_count": 0,
"transfers_count": 0
}
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"address": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf",
"current_height": 112132,
"has_bare_unspent_outputs": false,
"is_whatch_only": false,
"path": "\/some\/path\/to\/wallet\/file.zan",
"transfer_entries_count": 24,
"transfers_count": 11,
"utxo_distribution": ["1"]
}
}
```
### Response description:
```
"address": string; standard public address of the wallet.
"current_height": Current wallet/daemon height
"has_bare_unspent_outputs": Shows if the wallet still has UTXO from pre-zarcanum era
"is_whatch_only": Shows if the wallet is watch-only
"path": Path to wallet file location
"transfer_entries_count": Represent number of internal entries count(each entry represent tx output that have been addressed to this wallet)
"transfers_count": Represent number of transactions that happened to this wallet(basically tx history)
"utxo_distribution": UTXO distribution for this particular wallet: disabled right now
- address - string; address associated with wallet
- current_height - current block height
- is_whatch_only
- path - string; path to wallet file
- transfer_entries_count - the number of transfers conducted by the wallet
```

View file

@ -1,29 +1,32 @@
Obtains wallets public address
### Request
Obtains wallet's public address
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "getaddress"
{
"id": 0,
"jsonrpc": "2.0",
"method": "getaddress",
"params": {
}
}
```
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"address": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf"
}
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"address": "ZxDNaMeZjwCjnHuU5gUNyrP1pM3U5vckbakzzV6dEHyDYeCpW8XGLBFTshcaY8LkG9RQn7FsQx8w2JeJzJwPwuDm2NfixPAXf"
}
}
```
### Response description:
```
"address": string; standard public address of the wallet.
- address - string; standard public address of the wallet.
```

View file

@ -1,31 +1,74 @@
Retrieves current wallet balance: total and unlocked.
### Request
Return the balances across all whitelisted assets of the wallet
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "getbalance"
{
"id": 0,
"jsonrpc": "2.0",
"method": "getbalance",
"params": {
}
}
```
---
### Response
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"balance": 50000000033,
"unlocked_balance": 50000000033
}
}
### Request description:
```
### Response information
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"balance": 10000000000,
"balances": [{
"asset_info": {
"asset_id": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"current_supply": 500000000000000000,
"decimal_point": 12,
"full_name": "Zano wrapped ABC",
"hidden_supply": false,
"meta_info": "{ \"logo_url\": \"https:\/\/some.nice.logo.png\"}",
"owner": "f74bb56a5b4fa562e679ccaadd697463498a66de4f1760b2cd40f11c3a00a7a8",
"owner_eth_pub_key": "",
"ticker": "ZABC",
"total_max_supply": 1000000000000000000
},
"awaiting_in": 1000000000000,
"awaiting_out": 2000000000000,
"outs_amount_max": 2000000000000,
"outs_amount_min": 2000000000000,
"outs_count": 7,
"total": 100000000000000,
"unlocked": 50000000000000
}],
"unlocked_balance": 11000000000
}
}
```
### Response description:
```
"balance": Native coins total amount
"balances": Balances groupped by it's asset_id
"asset_info": Asset info details
"asset_id": Asset ID
"current_supply": Currently emitted supply for the given asset (ignored for REGISTER operation).
"decimal_point": Decimal point.
"full_name": Full name of the asset.
"hidden_supply": This field is reserved for future use and will be documented later.
"meta_info": Any other information associated with the asset, by default in a json format.
"owner": Owner's key, used only for EMIT and UPDATE validation, can be changed by transferring asset ownership.
"owner_eth_pub_key": [Optional] Owner's key in the case when ETH signature is used.
"ticker": Ticker associated with the asset.
"total_max_supply": Maximum possible supply for a given asset, cannot be changed after deployment.
"awaiting_in": Unconfirmed amount for receive
"awaiting_out": Unconfirmed amount for send
"outs_amount_max": Output's maximum amount
"outs_amount_min": Output's minimum amount
"outs_count": Number of total unspent outputs (including locked)
"total": Total coins available(including locked)
"unlocked": Unlocked coins available(the ones that could be used right now)
"unlocked_balance": Native coins total unlocked amount
- balance - unsigned integer; total fund, that the wallet has (unlocked and locked coins).
- unlocked_balance - unsigned integer; unlocked funds, i.e. coins that are stored deep enough in the blockchain to be considered relatively safe to spend. Only this many coins are immediately spendable. Unlocked_balance is always less or equal to balance.
```

View file

@ -0,0 +1,34 @@
This essential command actually execute proposal that was sent by counter party, by completing and signing transaction template that was in proposal, and sending it to the network.
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "ionic_swap_accept_proposal",
"params": {
"hex_raw_proposal": "97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"
}
}
```
### Request description:
```
"hex_raw_proposal": Hex-encoded proposal raw data(encrypted with common shared key). Includes half-created transaction template and some extra information that would be needed counterparty to finialize and sign transaction
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"result_tx_id": "97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"
}
}
```
### Response description:
```
"result_tx_id": Result transaction id
```

View file

@ -0,0 +1,49 @@
Generates ionic swap proposal according to details provided in request, result present as hex-encoded blob, that should be passed to recepient to validate this proposal and executing on it
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "ionic_swap_generate_proposal",
"params": {
"destination_address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp",
"proposal": {
"fee_paid_by_a": 10000000000,
"to_finalizer": [{
"amount": 1000000000000,
"asset_id": "97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"
}],
"to_initiator": [{
"amount": 10000000000,
"asset_id": "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a"
}]
}
}
}
```
### Request description:
```
"destination_address": Destination address
"proposal": Proposal details
"fee_paid_by_a": Fee paid by party A(initiator)
"to_finalizer": Assets sent to the finalizer
"to_initiator": Assets sent to the initiator
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"hex_raw_proposal": "97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"
}
}
```
### Response description:
```
"hex_raw_proposal": Hex-encoded proposal raw data(encrypted with common shared key). Includes half-created transaction template and some extra information that would be needed counterparty to finialize and sign transaction
```

View file

@ -0,0 +1,47 @@
Reads hex-encoded ionic swap proposal info, generated by other user and addressed to this wallet
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "ionic_swap_get_proposal_info",
"params": {
"hex_raw_proposal": "97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"
}
}
```
### Request description:
```
"hex_raw_proposal": Hex-encoded proposal raw data(encrypted with common shared key). Includes half-created transaction template and some extra information that would be needed counterparty to finialize and sign transaction
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"proposal": {
"fee_paid_by_a": 10000000000,
"to_finalizer": [{
"amount": 1000000000000,
"asset_id": "97d91442f8f3c22683585eaa60b53757d49bf046a96269cef45c1bc9ff7300cc"
}],
"to_initiator": [{
"amount": 10000000000,
"asset_id": "d6329b5b1f7c0805b5c345f4957554002a2f557845f64d7645dae0e051a6498a"
}]
}
}
}
```
### Response description:
```
"proposal": Proposal details
"fee_paid_by_a": Fee paid by party A(initiator)
"to_finalizer": Assets sent to the finalizer
"to_initiator": Assets sent to the initiator
```

View file

@ -1,38 +1,36 @@
Creates an integrated address for the wallet by embedding the given payment ID together with the wallet's public address.
### Request
Generate integrated address
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"jsonrpc": "2.0",
"id": 0,
"method": "make_integrated_address",
"params": {
"payment_id": ""
}
{
"id": 0,
"jsonrpc": "2.0",
"method": "make_integrated_address",
"params": {
"payment_id": "1dfe5a88ff9effb3"
}
}
```
### Request description:
```
"payment_id": Hex-encoded Payment ID to be associated with the this address. If empty then wallet would generate new payment id using system random library
### Request parameters
- payment_id - hex-encoded payment identifier. If empty, random 8-byte payment ID will be generated and used.
---
### Response
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"integrated_address": "ZxBvJDuQjMG9R2j4WnYUhBYNrwZPwuyXrC7FHdVmWqaESgowDvgfWtiXeNGu8Px9B24pkmjsA39fzSSiEQG1ekB225ZnrMTBp",
"payment_id": "00000000ff00ff00"
}
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"integrated_address": "iZ2EMyPD7g28hgBfboZeCENaYrHBYZ1bLFi5cgWvn4WJLaxfgs4kqG6cJi9ai2zrXWSCpsvRXit14gKjeijx6YPCLJEv6Fx4rVm1hdAGQFis",
"payment_id": "1dfe5a88ff9effb3"
}
}
```
### Response description:
```
"integrated_address": Integrated address combining a standard address and payment ID, if applicable.
"payment_id": Payment ID associated with the this address.
### Response inforamtion
- integrated_address - string; the result.
- payment_id - string; hex-encoded payment ID, that was used (useful if an empty payment_id was given as an input).
```

View file

@ -0,0 +1,40 @@
Cancel existing offer that this wallet created(it actually create transaction that says that existing order got canceled)
URL: ```http:://127.0.0.1:11211/json_rpc```
### Request:
```json
{
"id": 0,
"jsonrpc": "2.0",
"method": "marketplace_cancel_offer",
"params": {
"fee": 10000000000,
"no": 0,
"tx_id": "40fa6db923728b38962718c61b4dc3af1acaa1967479c73703e260dc3609c58d"
}
}
```
### Request description:
```
"fee": Fee for operation
"no": Number of offer entrie inside transacton(likely 0)
"tx_id": Transaction ID represented as a hexadecimal string
```
### Response:
```json
{
"id": 0,
"jsonrpc": "2.0",
"result": {
"tx_blob_size": 1232,
"tx_hash": "40fa6db923728b38962718c61b4dc3af1acaa1967479c73703e260dc3609c58d"
}
}
```
### Response description:
```
"tx_blob_size": Size of the transaction blob
"tx_hash": Transaction hash
```

Some files were not shown because too many files have changed in this diff Show more