You've already forked specification
Minor tweaks for SLP and endian pages.
This commit is contained in:
@@ -67,8 +67,12 @@
|
|||||||
[sendcmpct](/protocol/network/messages/sendcmpct) — [get_xthin](/protocol/network/messages/get_xthin) — [xthinblock](/protocol/network/messages/xthinblock) — [thinblock](/protocol/network/messages/thinblock) — [get_xblocktx](/protocol/network/messages/get_xblocktx) — [xblocktx](/protocol/network/messages/xblocktx) — [xupdate](/protocol/network/messages/xupdate) — [xversion](/protocol/network/messages/xversion) — [xverack](/protocol/network/messages/xverack)
|
[sendcmpct](/protocol/network/messages/sendcmpct) — [get_xthin](/protocol/network/messages/get_xthin) — [xthinblock](/protocol/network/messages/xthinblock) — [thinblock](/protocol/network/messages/thinblock) — [get_xblocktx](/protocol/network/messages/get_xblocktx) — [xblocktx](/protocol/network/messages/xblocktx) — [xupdate](/protocol/network/messages/xupdate) — [xversion](/protocol/network/messages/xversion) — [xverack](/protocol/network/messages/xverack)
|
||||||
|
|
||||||
### Simple Payment Verification (SPV)
|
### Simple Payment Verification (SPV)
|
||||||
|
|
||||||
[SPV](/protocol/spv) — [Bloom Filters](/protocol/spv/bloom-filter)
|
[SPV](/protocol/spv) — [Bloom Filters](/protocol/spv/bloom-filter)
|
||||||
|
|
||||||
### Simple Ledger Protocol
|
### Simple Ledger Protocol
|
||||||
[SLP](/protocol/slp)
|
|
||||||
|
[SLP Overview](/protocol/slp) — [GENESIS](/protocol/slp/genesis) — [MINT](/protocol/slp/mint) — [SEND](/protocol/slp/send) — [COMMIT](/protocol/slp/commit)
|
||||||
|
|
||||||
### Miscellaneous
|
### Miscellaneous
|
||||||
[Endian](/protocol/misc/endian)
|
[Endian](/protocol/misc/endian)
|
||||||
|
|||||||
@@ -1 +1,5 @@
|
|||||||
# Endianness
|
# Endian
|
||||||
|
|
||||||
|
[Endianness](https://en.wikipedia.org/wiki/Endianness) refers to the implies order of bytes for a given value.
|
||||||
|
|
||||||
|
Values are generally either [big-endian](/protocol/misc/endian/big), with the most significant bytes come first, or [little-endian](/protocol/misc/endian/little), with the least significant values first. Bitcoin Cash used a mix of little- and big-endian values, with little-endian byte order generally being used for integers.
|
||||||
+1
-1
@@ -20,7 +20,7 @@ Users and creators of the tokens can utilize the computational power and other b
|
|||||||
Simple Ledger Protocol (SLP) is one of the most prevalent token systems on Bitcoin Cash.
|
Simple Ledger Protocol (SLP) is one of the most prevalent token systems on Bitcoin Cash.
|
||||||
SLP employs a “colored coins” design that associates token amounts with BCH [transaction](/protocol/blockchain/transaction) outputs.
|
SLP employs a “colored coins” design that associates token amounts with BCH [transaction](/protocol/blockchain/transaction) outputs.
|
||||||
An SLP transaction will utilize a [data output](/protocol/blockchain/transaction/locking-script#data-output) to include a message in one of four predefined formats to annotate the SLP transaction information associated with each transaction output in the same transaction.
|
An SLP transaction will utilize a [data output](/protocol/blockchain/transaction/locking-script#data-output) to include a message in one of four predefined formats to annotate the SLP transaction information associated with each transaction output in the same transaction.
|
||||||
The predefined formats include: [GENESIS](/protocol/slp/genesis), [MINT](protocol/slp/mint), [SEND](/protocol/slp/send), and [COMMIT](/protocol/slp/commit).
|
The predefined formats include: [GENESIS](/protocol/slp/genesis), [MINT](/protocol/slp/mint), [SEND](/protocol/slp/send), and [COMMIT](/protocol/slp/commit).
|
||||||
The GENESIS message defines the SLP token and issues the first batch of tokens.
|
The GENESIS message defines the SLP token and issues the first batch of tokens.
|
||||||
The MINT message issues further batches of tokens.
|
The MINT message issues further batches of tokens.
|
||||||
The SEND message denotes the number of tokens sent to each output.
|
The SEND message denotes the number of tokens sent to each output.
|
||||||
|
|||||||
@@ -23,6 +23,6 @@ The set will be carefully chosen to satisfy the above requirements with a minima
|
|||||||
**Transaction outputs**:
|
**Transaction outputs**:
|
||||||
|
|
||||||
| v<sub>out</sub> | ScriptPubKey ("Address") | BCH amount |
|
| v<sub>out</sub> | ScriptPubKey ("Address") | BCH amount |
|
||||||
|-|-|-|
|
|--|--|--|
|
||||||
| 0 | OP_RETURN<br><lokad_id: 'SLP\x00'> (4 bytes, ascii)<br><token_type: 1> (1 to 2 byte integer)<br><transaction_type: 'COMMIT'> (6 bytes, ascii)<br><token_id> (32 bytes)<br><for_bitcoin_block_hash> (32 bytes)<br><block_height> (8 byte integer)<br><token_txn_set_hash> (32 bytes)<br><txn_set_data_url> (0 to ∞ bytes, ascii) [to be determined] | any |
|
| 0 | OP_RETURN<br><lokad_id: 'SLP\x00'> (4 bytes, ascii)<br><token_type: 1> (1 to 2 byte integer)<br><transaction_type: 'COMMIT'> (6 bytes, ascii)<br><token_id> (32 bytes)<br><for_bitcoin_block_hash> (32 bytes)<br><block_height> (8 byte integer)<br><token_txn_set_hash> (32 bytes)<br><txn_set_data_url> (0 to ∞ bytes, ascii) [to be determined] | any |
|
||||||
| ... | Any | any |
|
| ... | Any | any |
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ The genesis transaction includes an initial minting of `initial_token_mint_quant
|
|||||||
**Transaction outputs**:
|
**Transaction outputs**:
|
||||||
|
|
||||||
| v<sub>out</sub> | ScriptPubKey ("Address")| BCH amount| Implied token amount (base units) |
|
| v<sub>out</sub> | ScriptPubKey ("Address")| BCH amount| Implied token amount (base units) |
|
||||||
| - | - | - | - |
|
|--|--|--|--|
|
||||||
| 0 | OP_RETURN<br><lokad_id: 'SLP\x00'> (4 bytes, ascii)<sup>1</sup><br><token_type: 1> (1 to 2 byte integer)<br><transaction_type: 'GENESIS'> (7 bytes, ascii)<br><token_ticker> (0 to ∞ bytes, suggested utf-8)<br><token_name> (0 to ∞ bytes, suggested utf-8)<br><token_document_url> (0 to ∞ bytes, suggested ascii)<br><token_document_hash> (0 bytes or 32 bytes)<br><decimals> (1 byte in range 0x00-0x09)<br><mint_baton_vout> (0 bytes, or 1 byte in range 0x02-0xff)<br><initial_token_mint_quantity> (8 byte integer)<br> | any<sup>2</sup> | 0 |
|
| 0 | OP_RETURN<br><lokad_id: 'SLP\x00'> (4 bytes, ascii)<sup>1</sup><br><token_type: 1> (1 to 2 byte integer)<br><transaction_type: 'GENESIS'> (7 bytes, ascii)<br><token_ticker> (0 to ∞ bytes, suggested utf-8)<br><token_name> (0 to ∞ bytes, suggested utf-8)<br><token_document_url> (0 to ∞ bytes, suggested ascii)<br><token_document_hash> (0 bytes or 32 bytes)<br><decimals> (1 byte in range 0x00-0x09)<br><mint_baton_vout> (0 bytes, or 1 byte in range 0x02-0xff)<br><initial_token_mint_quantity> (8 byte integer)<br> | any<sup>2</sup> | 0 |
|
||||||
| 1 | Initial mint receiver | any<sup>2</sup> | initial_token_mint_quantity |
|
| 1 | Initial mint receiver | any<sup>2</sup> | initial_token_mint_quantity |
|
||||||
| ... | Any | any<sup>2</sup> | 0 |
|
| ... | Any | any<sup>2</sup> | 0 |
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ This makes it possible to prove end-of-minting capabilities for a token even aft
|
|||||||
**Transaction outputs**:
|
**Transaction outputs**:
|
||||||
|
|
||||||
| v<sub>out</sub> | ScriptPubKey ("Address") | BCH amount | Implied token amount (base units) |
|
| v<sub>out</sub> | ScriptPubKey ("Address") | BCH amount | Implied token amount (base units) |
|
||||||
|-|-|-|-|
|
|--|--|--|--|
|
||||||
| 0 | OP_RETURN<br>< lokad_id: 'SLP\x00'> (4 bytes, ascii)<br>< token_type: 1> (1 to 2 byte integer)<br>< transaction_type: 'MINT'> (4 bytes, ascii)<br>< token_id> (32 bytes)<br>< mint_baton_vout> (0 bytes or 1 byte between 0x02-0xff)<br>< additional_token_quantity> (8 byte integer) | any | 0 |
|
| 0 | OP_RETURN<br>< lokad_id: 'SLP\x00'> (4 bytes, ascii)<br>< token_type: 1> (1 to 2 byte integer)<br>< transaction_type: 'MINT'> (4 bytes, ascii)<br>< token_id> (32 bytes)<br>< mint_baton_vout> (0 bytes or 1 byte between 0x02-0xff)<br>< additional_token_quantity> (8 byte integer) | any | 0 |
|
||||||
| 1 | Token mint receiver | any | additional_token_quantity |
|
| 1 | Token mint receiver | any | additional_token_quantity |
|
||||||
| ... | Any | any | 0 |
|
| ... | Any | any | 0 |
|
||||||
|
|||||||
@@ -6,12 +6,12 @@ Tokens will be assigned to the outputs with indexes 1 to 19 as indicated within
|
|||||||
Any number of additional BCH-only outputs will be allowed.
|
Any number of additional BCH-only outputs will be allowed.
|
||||||
A BCH-only output can come before token outputs, but a token quantity of 0 must be specified for this output.
|
A BCH-only output can come before token outputs, but a token quantity of 0 must be specified for this output.
|
||||||
|
|
||||||
**Transaction inputs**: Any number of inputs or content of inputs, in any order, but must include sufficient tokens coming from valid token transactions of matching `token_id`, `token_type` (see [Consensus Rules](/protocol/slp#Consensus-Rules)).
|
**Transaction inputs**: Any number of inputs or content of inputs, in any order, but must include sufficient tokens coming from valid token transactions of matching `token_id`, `token_type` (see [SLP consensus rules](/protocol/slp#consensus-rules)).
|
||||||
|
|
||||||
**Transaction outputs**:
|
**Transaction outputs**:
|
||||||
|
|
||||||
| v<sub>out</sub> | ScriptPubKey ("Address") | BCH amount | Implied token amount (base units) |
|
| v<sub>out</sub> | ScriptPubKey ("Address") | BCH amount | Implied token amount (base units) |
|
||||||
|-|-|-|-|
|
|--|--|--|--|
|
||||||
| 0 | OP_RETURN<br><lokad id: 'SLP\x00'> (4 bytes, ascii)<br><token_type: 1> (1 to 2 byte integer)<br><transaction_type: 'SEND'> (4 bytes, ascii)<br><token_id> (32 bytes)<br><token_output_quantity1> (required, 8 byte integer)<br><token_output_quantity2> (optional, 8 byte integer)<br>...<br><token_output_quantity19> (optional, 8 byte integer)<br>| any | 0 |
|
| 0 | OP_RETURN<br><lokad id: 'SLP\x00'> (4 bytes, ascii)<br><token_type: 1> (1 to 2 byte integer)<br><transaction_type: 'SEND'> (4 bytes, ascii)<br><token_id> (32 bytes)<br><token_output_quantity1> (required, 8 byte integer)<br><token_output_quantity2> (optional, 8 byte integer)<br>...<br><token_output_quantity19> (optional, 8 byte integer)<br>| any | 0 |
|
||||||
| 1 | Receiver 1 | any | token_output_quantity1 |
|
| 1 | Receiver 1 | any | token_output_quantity1 |
|
||||||
| ... | ... | any | ... |
|
| ... | ... | any | ... |
|
||||||
|
|||||||
Reference in New Issue
Block a user