Credit Loops GUIDE

Credit Loops Guide

Marmara Credit Loops GUIDE

General Guide for Credit Loops

General Guide

How to Make Marmara Credit Loops

The current Marmara Credit loops currently work based on Protocol 1 which is in 100% collateralization mode. 100 % collateralization is made by issuer on behalf of both himself/herself and holder. Both issuer and holder have the 3x staking chance to get blockchain rewards. Issuer has the 3x staking chance until maturity date of credit whereas holder has the 3x staking chance until he/she endorses/transfers the credit to a new holder who will continue staking with the issuer. The Credit loops can be made using only activated coins.

Terminology

Issuer: The person who first creates a credit in a credit loop. It is the person who forms the first node in the credit loop. The credit may be collateralized 100% or with even zero-collateralization until maturity date of a credit.

Bearer (Holder): The last node in a credit loop is always called bearer (holder). When someone transfers a credit in a loop, that node becomes immediately an endorser.

Endorser: All other nodes that fall between the issuer, which is the first node in the credit loop, and the last node, and transfer the credit to the next node.

Maturity: The time a credit expires. It is measured as blocks in estimation. The block per day is 1440 (60 blocks an hour times 24 hours a day). Suppose a credit is for 100 days, the maturity is 1440×100, i.e. 144,000 blocks.

Settlement: When a credit matures, settlement is made to the holder, the last node in a loop. Settlement may be automatic or manual.

Escrow: Trust based parties for Protocol 2. If EscrowOn is false, then 100% collateralization is used and settlement is automatic. There is no need for escrows in protocol 1 which works as complete trustless version.

Avalist: Avalists support issuer or endorsers with MCL as additional colletarization and can earn with 3x staking with those support. In case of non-redemption, their funds are utilized. Avalists are available only in Protocol 2. The parameter avalcount is always zero for protocol 1.

BlockageAmount: This is a term for protocol 2. An issuer may be asked to put some collateralization by a holder. In that case, the issuer gets benefit of 3x staking in protocol 2.

Dispute Expiry: It is grace period for solving non-redemption problem in credit loops in protocol 2. An issuer may have this time as blocks when creating a credit under protocol 2 without or insufficient collateralization. Before this period expires, an escrow should do all actions according to aggrement with the issuer to solve non-redemption. Otherwise, the escrow is penalized in the system.

###Important Commands for Making Credit Loops

  • marmarareceive

This command is used to get a credit from an issuer or an endorser. When asking a credit from an issuer, i.e. the first node, it has a unique use. In other nodes, it is the same.

Scenario 1: Two nodes are making a credit loop for the first time. This credit loop may be created for a sale of a good or service in the market. In such case, the holder (the one selling the product/service) should request for a credit from the issuer (the one paying the product/service) by writing down the following command:

./komodo-cli -ac_name=MCL marmarareceive senderpk amount currency matures '{"avalcount":"n"}'

senderpk is the pubkey address of the issuer (the one paying the product/service)

amount is the payment amount. Please note that this amount should be available in activated fund of the issuer and if not then must be activated thru marmaralock command by th issuer.

currency is MARMARA

matures is the time that respective credit expires, 60 blocks an hour times 24 hours a day making 1440 blocks per day.

'{"avalcount":"n"}' is the number of avalists i.e. ‘{“avalcount”:”0″}’ for protocol 1.

This marmarareceive call generates a hex code. This HEXCODE needs to be verified by the holder by executing the sendrawtransaction command:

./komodo-cli -ac_name=MCL sendrawtransaction HEXCODE

Once this command is executed, a transaction id named txid gets generated. This txid along with the receiverpk needs to be communicated to the issuer to complete the credit loop. But, an alternative to this communication would be the use of marmarareceivelist method which could be used to see the receive requests made to the issuer himself/herself.

marmarareceivelist method would be executed by the issuer by the following command:

./komodo-cli -ac_name=MCL marmarareceivelist pubkey

pubkey is the pubkey address of the issuer connected to the Marmara Chain The response of this command is a list of pair of txid’s created by the respective pubkeys.

  • marmaraissue

This command is only used by issuer, the first node to create/issue a credit. By this, a credit is also transferred to the first holder, i.e. the second node. Many of the parameters for a credit loop is decided between the issuer and the first holder. marmaraissue method takes in the following arguments:

./komodo-cli -ac_name=MCL marmaraissue receiverpk '{"avalcount":"n", "autosettlement":"true"|"false", "autoinsurance":"true"|"false", "disputeexpires":"offset", "EscrowOn":"true"|"false", "BlockageAmount":"amount" }' requesttxid

receiverpk is the pubkey of the receiver which is the holder.

"avalcount":"n" is the number of avalists i.e. ‘{“avalcount”:”0″}’ for protocol 1.

"autosettlement":"true"|"false" AutoSettlement is true due to 100% collateralization in Protocol 1.

"autoinsurance":"true"|"false" Autoinsurance is true due to 100% collateralization in Protocol 1.

"disputeexpires":"offset" Dispute expiry is set to 0 due to 100 collateralization in Protocol 1.

"EscrowOn":"true"|"false" EscrowOn is set to false due to 100% collateralization in Protocol 1.

"BlockageAmount":"amount" } blockage amount is set to 0 due to 100 collateralization in Protocol 1.

requesttxid is the txid generated by the holder communicated to the issuer.

A typical example of a marmaraissue command to complete the credit loop by the issuer is given below:

./komodo-cli -ac_name=MCL marmaraissue receiverpk '{"avalcount":"0", "autosettlement":"true", "autoinsurance":"true", "disputeexpires":"0", "EscrowOn":"false", "BlockageAmount":"0" }' requesttxid

This marmaraissue command in turn returns a hex code response, and now the issuer has to execute the sendrawtransaction method to get the transaction executed on the blockchain as follows:

./komodo-cli -ac_name=MCL sendrawtransaction HEXCODE

This creates a credit loop between the issuer and the holder. The credits locked in a loop can be circulated to buy things during shopping. The issuer and the holder get 3 times of chances of staking on the MCL funds until the maturity of the credit loop.

  • marmaracreditloop

To display the credit loop between the issuer and the holder, the following marmaracreditloop command may be executed:

./komodo-cli -ac_name=MCL marmaracreditloop txid

txid is the baton transfer id of the Marmara Credit Loop.

  • marmaratransfer

Scenario 2: The holder from the previous scenario wishes to utilize the coins locked in loop by buying goods/services on the same credit loop created earlier. For such case, when the holder transfers a credit in a loop, that node immediately becomes an endorser. And in such way, the last node in a credit loop is always called the bearer (holder). In other words, all endorsers are previously holders. One should bear in mind that endorsers lose the 3x staking power when a credit is transferred to a new holder.

For this purpose, the new holder makes a marmarareceive request to the endorser to get the credit for selling the goods/services by the following command:

./komodo-cli -ac_name=MCL marmarareceive senderpk batontxid '{"avalcount":"n"}'

senderpk is the pubkey address of the endorser (the one buying the product/service) batontxid is the baton transaction id of the previously created credit loop '{"avalcount":"n"}' is the number of avalists i.e. ‘{“avalcount”:”0″}’ for protocol 1.

This marmarareceive call generates a hex code. This HEXCODE needs to be verified by the new holder by executing the sendrawtransaction command:

./komodo-cli -ac_name=MCL sendrawtransaction HEXCODE

Once this command is executed, a transaction id named txid gets generated. This txid along with the receiverpk needs to be communicated to the endorser to complete the credit loop. But, an alternative to this communication would be the use of marmarareceivelist method which could be used by the endorser to see the receive requests made to himself/herself. Then, the endorser executes the following marmaratransfercommand to get the credits transferred to the new holder:

./komodo-cli -ac_name=MCL marmaratransfer receiverpk '{"avalcount":"n"}' requesttxid

receiverpk is the pubkey of the receiver which is the new holder.

"avalcount":"n" is the number of avalists i.e. ‘{“avalcount”:”0″}’ for protocol 1.

requesttxid is the txid generated by the new holder communicated to the endorser.

Then the endorser executes the sendrawtransaction command with the hex code resulting from marmaratransfercommand.

Please Note that sendrawtransaction command is used after marmarareceivemarmaraissuemarmaratransfer and marmaralock to make the results of commands to be executed on blockchain. The usage is presented throughout the scenario 1 and 2.

In this way, the credit loops can circulate up to 1000th node within the maturity time to buy goods/services.

Taking Backup of Wallet

Backing up the wallet.dat file is very essential as it holds the assets of one. On a Linux machine, the file could be found in: ~/.komodo/MCL/wallet.dat

One method to backup this file is to archive a copy of the file.

#Copy the wallet.dat file
cp -av ~/.komodo/MCL/wallet.dat ~/wallet.dat

#Rename the wallet.dat file
mv ~/wallet.dat ~/2020-08-09-wallet_backup.dat

# Make an archieve of the wallet.dat file
tar -czvf ~/2020-08-09-wallet_backup.dat.tgz ~/2020-08-09-wallet_backup.dat

# Move the final file to a secure location

References

For more detailed information on Komodo Antara Framework and its details, please refer to its extended developer documentation.

For more detailed information on how Marmara Credit Loops work, kindly refer to detailed article here.

Important Notice

Marmara Credit Loops is experimental and a work-in-progress. Use at your own risk.

License

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

PUBKEYS FOR EXAMPLE

Pubkey-1 : 021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a
Pubkey-2 : 036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517
Pubkey-3 : 03499750cc3961988fd15db27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c815810

Test Pubkey

Pubkey 1
Pubkey 2
Pubkey 3

{
“result”: “success”,
“myNormalAddress”: “RPsZzQCMaWmD9LB2pGG2vz2DQXX1sqXubU”,
“myNormalAmount”: 1180.00005000,
“myCCActivatedAddress”: “RB1aVLruiuKYQkC9fEBVWXFDUSuvz6VzvZ”,
“myActivatedAmount”: 9000.00000000,
“myAmountOnActivatedAddress-old”: 9000.00000000,
“myCCAddress”: “RQCsTNLA6WCr8KyvudzgL3uLCf4J7DENhV”,
“myCCBalance”: 0.00000000,
“Loops”: [
],
“TotalLockedInLoop”: 0.00000000,
“firstheight”: 0,
“lastheight”: 1073741824,
“minamount”: 0.00000000,
“maxamount”: 11529215046.06846976,
“currency”: “MARMARA”
}

{
“result”: “success”,
“myNormalAddress”: “R9kFZrMRofq4Q82LXx4w1du2GmDo1n9XTS”,
“myNormalAmount”: 359.99990000,
“myCCActivatedAddress”: “RVcmWtf71nRqbq2yeNn4SH4xkGd27zsASR”,
“myActivatedAmount”: 9000.00000000,
“myAmountOnActivatedAddress-old”: 9000.00000000,
“myCCAddress”: “R9WN5P5sSR6iJ9yXG24BXcjXERt7iFjdmn”,
“myCCBalance”: 0.00000000,
“Loops”: [
],
“TotalLockedInLoop”: 0.00000000,
“firstheight”: 0,
“lastheight”: 1073741824,
“minamount”: 0.00000000,
“maxamount”: 11529215046.06846976,
“currency”: “MARMARA”
}

{
“result”: “success”,
“myNormalAddress”: “RFV1Jqo16zwvgtp6KFeQWFWyydYD5EAmU3”,
“myNormalAmount”: 359.99990000,
“myCCActivatedAddress”: “RKJwmbaqNtGVfjRj8wtkyE5kqzKhB9Q7EH”,
“myActivatedAmount”: 9000.00000000,
“myAmountOnActivatedAddress-old”: 9000.00000000,
“myCCAddress”: “RTLcXGDVuf3sbx2VVk6UcxCLdvLYvCiN8x”,
“myCCBalance”: 0.00000000,
“Loops”: [
],
“TotalLockedInLoop”: 0.00000000,
“firstheight”: 0,
“lastheight”: 1073741824,
“minamount”: 0.00000000,
“maxamount”: 11529215046.06846976,
“currency”: “MARMARA”
}

Credit Loop Parameters

"First looping parameter"
./komodo-cli -ac_name=MCL marmarareceive senderpk amount currency matures '{"avalcount":"n"}'

"Credit Loop request parameter"
./komodo-cli -ac_name=MCL marmarareceive senderpk batontxid '{"avalcount":"n"}'

"Credit Loop creation parameter"
./komodo-cli -ac_name=MCL marmaraissue receiverpk '{"avalcount":"n", "autosettlement":"true"|"false", "autoinsurance":"true"|"false", "disputeexpires":"offset", "EscrowOn":"true"|"false", "BlockageAmount":"amount" }' requesttxid

"Credit Cycle transfer parameter"
./komodo-cli -ac_name=MCL marmaratransfer receiverpk '{"avalcount":"n"}' requesttxid

"Approval of the transaction"
./komodo-cli -ac_name=MCL sendrawtransaction "HEX"

"Credit Loop control parameter"
./komodo-cli -ac_name=MCL marmaracreditloop txid(Baton)

"Pubkey 2" receive > "pubkey 1"

$ ./komodo-cli -ac_name=MCL marmarareceive 021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a 9000 MARMARA 600 '{"avalcount":"0"}'
{
"result": "success",
"hex": "0400008085202f890138662123b84193ce85b5aa619bbccee102d8f70f89373d38f11406dcbe6e3de9400000004847304402202f2da6805b5
8b8b34e25c03ff246c5a72a86e6274f4acb65b17b6fc1661486a802204ab0aa63993c46cd658378be53fe0fc0a339407f5ac0282e95bcbe3689e
eb05301ffffffff03204e000000000000302ea22c802014d77cc7b853070cc04199d5ea337b7fe86ba0c0db951295b402c66ad4057ff08103120c
008203000401ccc0cbc361080000002321036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517ac000000000000
00003b6a39ef420121021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a00282e8cd100000011030000074d41
524d41524100000000810100000000000000000000000000",
"funcid": "R",
"createtxid": "0000000000000000000000000000000000000000000000000000000000000000",
"senderpk": "021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a",
"amount": 9000.00000000,
"matures": 785,
"currency": "MARMARA"
}

Approval of the transaction:

$ ./komodo-cli -ac_name=MCL sendrawtransaction 0400008085202f890138662123b84193ce85b5aa619bbccee102d8f70f89373d38f11406dcbe6e3de9400000004847304402202f2da6805b58
b8b34e25c03ff246c5a72a86e6274f4acb65b17b6fc1661486a802204ab0aa63993c46cd658378be53fe0fc0a339407f5ac0282e95bcbe3689ee
b05301ffffffff03204e000000000000302ea22c802014d77cc7b853070cc04199d5ea337b7fe86ba0c0db951295b402c66ad4057ff08103120c0
08203000401ccc0cbc361080000002321036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517ac0000000000000
0003b6a39ef420121021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a00282e8cd100000011030000074d415
24d41524100000000810100000000000000000000000000

Baton : a3842fe93b47d9025aac2966731a22debd467f0356822789762a239f05ce21d0

"Pubkey 1" issue confirm loop

$./komodo-cli -ac_name=MCL marmaraissue 036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517 '{"avalcount":"0", "BlockageAmount":"0", "autoinsurance":"true", "autosettlement":"true", "EscrowOn":"false"}' a3842fe93b47d9025aac2966731a22debd467f0356822789762a239f05ce21d0
{
"result": "success",
"hex": "0400008085202f890326b89865d7c950f27ef967d205108097e0159c906fb12242e3c8206f03aa2f0c00000000a74ca5a281a1a0819ca28194
a067a5658021021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a81401a084eae502fba54c38da530319d8df0
504cc4023170f9a0e8a7b02e8020ffd304e718f0d34ed02803677f0d49119dcea16500d063ecb2075e5ee136adc9b568a129a5278020cb962a
1707f09a61a8fe9c72aebe63bed1ab085cb0969728d2687e0c435e91588103020000af038001efa10001ffffffffd021ce059f232a76892782560
37f46bdde221a736629ac5a02d9473be92f84a3000000007b4c79a276a072a26ba067a5658021021130357675e5f1cc892a6e673a6cece74d9
88cf80a48445aad1cd8823ebaa24a814082932d1977b503ce29ca6d037746aa5657313c0951bc21c5edd993f62c3490921de11bd14e1b6f883
6afee4e75b9801aec30feb6ff472a8548de03cadc101a1ca100af038001efa10001ffffffff21ed120a9c0218decb070a2ba97bdfebbc6849250b3
4bcc3edf7fc1dc6b34b200000000049483045022100c1905fc48b357b1ecc174b31b8f2e3f74c050261eacb073abe6e7d830696574402201d2
b23b3cf710ee7ff8c2d69d739977fc503c43e10b212b6afb801a775cfbf3c01ffffffff061027000000000000302ea22c80207933728ab2e23542e
a9b312962d25f2b2a9dbee1e88b1d592b77d3dda603b8d68103120c008203000401cc1027000000000000302ea22c802025854dbc29292bf
0f5f151d10764286c91245183f1edbd19b9974f3da25ab03c8103120c008203000401cc00282e8cd1000000c22ea22c8020f11ec5b159d79aac
b197f4cb3aa460a977eb7d487843e61ab75ce182790c8daa81031210008203000401cc4c8f0401ef01022103afc5be570d0ff419425cfcc580cc
762ab82baad88c148f5b028d7db7bfeee61d2102d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a545ef4b01d0
21ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a321021130357675e5f1cc892a6e673a6cece74d988cf80a48445aa
d1cd8823ebaa24a751027000000000000302ea22c802025854dbc29292bf0f5f151d10764286c91245183f1edbd19b9974f3da25ab03c81031
20c008203000401cce00fd0b2000000002321021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24aac000000000
00000005b6a4c58ef4901d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a321036eeaec4ac8efd0d021f0cc3a2fc
91191337ee6764b98d720985588e2eb47a517010101000000600f180001102700000000000000000000840100000000000000000000000000",
"funcid": "I",
"createtxid": "a3842fe93b47d9025aac2966731a22debd467f0356822789762a239f05ce21d0",
"requesttxid": "a3842fe93b47d9025aac2966731a22debd467f0356822789762a239f05ce21d0",
"receiverpk": "036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517"
}

Approval of the transaction:

$ ./komodo-cli -ac_name=MCL sendrawtransaction 0400008085202f890326b89865d7c950f27ef967d205108097e0159c906fb12242e3c8206f03aa2f0c00000000a74ca5a281a1a0819ca28194a
067a5658021021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a81401a084eae502fba54c38da530319d8df05
04cc4023170f9a0e8a7b02e8020ffd304e718f0d34ed02803677f0d49119dcea16500d063ecb2075e5ee136adc9b568a129a5278020cb962a1
707f09a61a8fe9c72aebe63bed1ab085cb0969728d2687e0c435e91588103020000af038001efa10001ffffffffd021ce059f232a768927825603
7f46bdde221a736629ac5a02d9473be92f84a3000000007b4c79a276a072a26ba067a5658021021130357675e5f1cc892a6e673a6cece74d98
8cf80a48445aad1cd8823ebaa24a814082932d1977b503ce29ca6d037746aa5657313c0951bc21c5edd993f62c3490921de11bd14e1b6f8836
afee4e75b9801aec30feb6ff472a8548de03cadc101a1ca100af038001efa10001ffffffff21ed120a9c0218decb070a2ba97bdfebbc6849250b34
bcc3edf7fc1dc6b34b200000000049483045022100c1905fc48b357b1ecc174b31b8f2e3f74c050261eacb073abe6e7d830696574402201d2b
23b3cf710ee7ff8c2d69d739977fc503c43e10b212b6afb801a775cfbf3c01ffffffff061027000000000000302ea22c80207933728ab2e23542ea9
b312962d25f2b2a9dbee1e88b1d592b77d3dda603b8d68103120c008203000401cc1027000000000000302ea22c802025854dbc29292bf0f5
f151d10764286c91245183f1edbd19b9974f3da25ab03c8103120c008203000401cc00282e8cd1000000c22ea22c8020f11ec5b159d79aacb1
97f4cb3aa460a977eb7d487843e61ab75ce182790c8daa81031210008203000401cc4c8f0401ef01022103afc5be570d0ff419425cfcc580cc76
2ab82baad88c148f5b028d7db7bfeee61d2102d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a545ef4b01d021
ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a321021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1
cd8823ebaa24a751027000000000000302ea22c802025854dbc29292bf0f5f151d10764286c91245183f1edbd19b9974f3da25ab03c8103120
c008203000401cce00fd0b2000000002321021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24aac00000000000
000005b6a4c58ef4901d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a321036eeaec4ac8efd0d021f0cc3a2fc91
191337ee6764b98d720985588e2eb47a517010101000000600f180001102700000000000000000000840100000000000000000000000000

Baton : 6630bc3fb03a5b7713924937ea810f4e5d9aa71b5d7993933175382c8324db89

"Pubkey 3" receive > "Pubkey 2"

$./komodo-cli -ac_name=MCL marmarareceive 036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517 6630bc3fb03a5b7713924937ea810f4e5d9aa71b5d7993933175382c8324db89 '{"avalcount":"0"}'
{
"result": "success",
"hex": "0400008085202f890117bf252fd145574e3189113ced5fee036ea608cb5930682cf1f6cfcb243b351b40000000484730440220066565e18ea5
0bd7eb15039c15863bf179d59c29ad1e4f9a47f78b7b430abe8c0220363554ae42e8f9be8850040a8d05a2b0e3f811cf232b02d83af8656a5f5
adf7c01ffffffff031027000000000000302ea22c80207933728ab2e23542ea9b312962d25f2b2a9dbee1e88b1d592b77d3dda603b8d6810312
0c008203000401ccd0f2c36108000000232103499750cc3961988fd15db27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c815810ac0000000000
000000476a45ef5201d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a321036eeaec4ac8efd0d021f0cc3a2fc91
191337ee6764b98d720985588e2eb47a51700000000880100000000000000000000000000",
"funcid": "R",
"createtxid": "a3842fe93b47d9025aac2966731a22debd467f0356822789762a239f05ce21d0",
"batontxid": "6630bc3fb03a5b7713924937ea810f4e5d9aa71b5d7993933175382c8324db89",
"senderpk": "036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517"
}

Approval of the transaction:

$ ./komodo-cli -ac_name=MCL sendrawtransaction 0400008085202f890117bf252fd145574e3189113ced5fee036ea608cb5930682cf1f6cfcb243b351b40000000484730440220066565e18ea50
bd7eb15039c15863bf179d59c29ad1e4f9a47f78b7b430abe8c0220363554ae42e8f9be8850040a8d05a2b0e3f811cf232b02d83af8656a5f5a
df7c01ffffffff031027000000000000302ea22c80207933728ab2e23542ea9b312962d25f2b2a9dbee1e88b1d592b77d3dda603b8d68103120
c008203000401ccd0f2c36108000000232103499750cc3961988fd15db27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c815810ac00000000000
00000476a45ef5201d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a321036eeaec4ac8efd0d021f0cc3a2fc911
91337ee6764b98d720985588e2eb47a51700000000880100000000000000000000000000

Baton : 716007196782d765fc85e8ae00eee96ba94e368b092b3694a6d705d4a13713de

"Pubkey 2" transfer confirm loop > "Pubkey 3"

$ ./komodo-cli -ac_name=MCL marmaratransfer 03499750cc3961988fd15db27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c815810 '{"avalcount":"0"}' 716007196782d765fc85e8ae00eee96ba94e368b092b3694a6d705d4a13713de
{
"result": "success",
"hex": "0400008085202f8904dcdd5b46ba8e8eaef9a81605dda9d0e330115341da1228b833d885beedccecdb00000000a74ca5a281a1a0819ca281
94a067a5658021036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a5178140e5d151b3b9327425f2537f72a9aba7f
2d8738eda80521e50b26fc189c2e2447e63db4c804026d1b1ac3c88c190703991b3c5256da2f638907da2564c8d96621fa129a5278020cb962
a1707f09a61a8fe9c72aebe63bed1ab085cb0969728d2687e0c435e91588103020000af038001efa10001ffffffffde1337a1d405d7a694362b09
8b364ea96be9ee00aee885fc65d7826719076071000000007b4c79a276a072a26ba067a5658021036eeaec4ac8efd0d021f0cc3a2fc9119133
7ee6764b98d720985588e2eb47a51781402782aecafa03fa54d8d8cc6bca677f85d90f59f31791653eb1b98aa0602bf3cc19acfbacf5632785f3
85fe9c0234cb131751db022c93723379426f467ef9d535a100af038001efa10001ffffffff89db24832c3875319393795d1ba79a5d4e0f81ea3749
9213775b3ab03fbc3066000000007b4c79a276a072a26ba067a5658021036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588
e2eb47a51781408f31d00999f433f8e412ba78aca14af1d2d6bd17feedff5640dc7bc6a5647bbf3262368b374652d5f0edadc3d928730fc324a6
ddad37d1368c967c96cea4968ea100af038001efa10001ffffffff89db24832c3875319393795d1ba79a5d4e0f81ea37499213775b3ab03fbc306
602000000a74ca5a281a1a0819ca28194a067a565802103afc5be570d0ff419425cfcc580cc762ab82baad88c148f5b028d7db7bfeee61d8140
38fb996f1d628afe9d02ed7488a39c79a23c418b7f768bb0311222ffa5eaafed0ce50bc51053d083c7063fcb05be062bdc76048e2132fc57c7db
847e241ef34ba129a5278020e0d0c8e84ebebb6d5aa8661964b7f8056962606fa35794a73f6c1aecd3fd52bf8103020000af038001efa10001ff
ffffff061027000000000000302ea22c8020702c98cc1c749afe370f553f9664c2d85db390ff46eed3a3e7d0607b374a7f2f8103120c0082030004
01cc001417c668000000c22ea22c8020f11ec5b159d79aacb197f4cb3aa460a977eb7d487843e61ab75ce182790c8daa810312100082030004
01cc4c8f0401ef01022103afc5be570d0ff419425cfcc580cc762ab82baad88c148f5b028d7db7bfeee61d2102d021ce059f232a768927825603
7f46bdde221a736629ac5a02d9473be92f84a545ef4b01d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a32103
6eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a51775001417c668000000aa2ea22c80206a6ba191ca7087973c66
70362974e24f95fb9e1ec6e6f8eee5bac72c51dc25d281031210008203000401cc4c770401ef01022103afc5be570d0ff419425cfcc580cc762ab
82baad88c148f5b028d7db7bfeee61d21036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a5172def410121036ee
aec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517c4000000feffff7f75001417c6680000002321021130357675e5f1cc
892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24aac001417c668000000c22ea22c8020f11ec5b159d79aacb197f4cb3aa460a977eb7
d487843e61ab75ce182790c8daa81031210008203000401cc4c8f0401ef01022103afc5be570d0ff419425cfcc580cc762ab82baad88c148f5b0
28d7db7bfeee61d2102d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a545ef4b01d021ce059f232a768927825
6037f46bdde221a736629ac5a02d9473be92f84a321021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a75000
00000000000004b6a49ef5401d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a32103499750cc3961988fd15db
27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c81581001000000000000008b0100000000000000000000000000",
"funcid": "T",
"createtxid": "a3842fe93b47d9025aac2966731a22debd467f0356822789762a239f05ce21d0",
"requesttxid": "716007196782d765fc85e8ae00eee96ba94e368b092b3694a6d705d4a13713de",
"batontxid": "6630bc3fb03a5b7713924937ea810f4e5d9aa71b5d7993933175382c8324db89",
"receiverpk": "03499750cc3961988fd15db27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c815810"
}

Approval of the transaction:

$ ./komodo-cli -ac_name=MCL sendrawtransaction 0400008085202f8904dcdd5b46ba8e8eaef9a81605dda9d0e330115341da1228b833d885beedccecdb00000000a74ca5a281a1a0819ca2819
4a067a5658021036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a5178140e5d151b3b9327425f2537f72a9aba7f2
d8738eda80521e50b26fc189c2e2447e63db4c804026d1b1ac3c88c190703991b3c5256da2f638907da2564c8d96621fa129a5278020cb962a
1707f09a61a8fe9c72aebe63bed1ab085cb0969728d2687e0c435e91588103020000af038001efa10001ffffffffde1337a1d405d7a694362b098
b364ea96be9ee00aee885fc65d7826719076071000000007b4c79a276a072a26ba067a5658021036eeaec4ac8efd0d021f0cc3a2fc91191337
ee6764b98d720985588e2eb47a51781402782aecafa03fa54d8d8cc6bca677f85d90f59f31791653eb1b98aa0602bf3cc19acfbacf5632785f38
5fe9c0234cb131751db022c93723379426f467ef9d535a100af038001efa10001ffffffff89db24832c3875319393795d1ba79a5d4e0f81ea37499
213775b3ab03fbc3066000000007b4c79a276a072a26ba067a5658021036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e
2eb47a51781408f31d00999f433f8e412ba78aca14af1d2d6bd17feedff5640dc7bc6a5647bbf3262368b374652d5f0edadc3d928730fc324a6d
dad37d1368c967c96cea4968ea100af038001efa10001ffffffff89db24832c3875319393795d1ba79a5d4e0f81ea37499213775b3ab03fbc3066
02000000a74ca5a281a1a0819ca28194a067a565802103afc5be570d0ff419425cfcc580cc762ab82baad88c148f5b028d7db7bfeee61d81403
8fb996f1d628afe9d02ed7488a39c79a23c418b7f768bb0311222ffa5eaafed0ce50bc51053d083c7063fcb05be062bdc76048e2132fc57c7db8
47e241ef34ba129a5278020e0d0c8e84ebebb6d5aa8661964b7f8056962606fa35794a73f6c1aecd3fd52bf8103020000af038001efa10001ffff
ffff061027000000000000302ea22c8020702c98cc1c749afe370f553f9664c2d85db390ff46eed3a3e7d0607b374a7f2f8103120c00820300040
1cc001417c668000000c22ea22c8020f11ec5b159d79aacb197f4cb3aa460a977eb7d487843e61ab75ce182790c8daa8103121000820300040
1cc4c8f0401ef01022103afc5be570d0ff419425cfcc580cc762ab82baad88c148f5b028d7db7bfeee61d2102d021ce059f232a7689278256037f
46bdde221a736629ac5a02d9473be92f84a545ef4b01d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a321036e
eaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a51775001417c668000000aa2ea22c80206a6ba191ca7087973c6670
362974e24f95fb9e1ec6e6f8eee5bac72c51dc25d281031210008203000401cc4c770401ef01022103afc5be570d0ff419425cfcc580cc762ab82
baad88c148f5b028d7db7bfeee61d21036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a5172def410121036eeaec
4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517c4000000feffff7f75001417c6680000002321021130357675e5f1cc892
a6e673a6cece74d988cf80a48445aad1cd8823ebaa24aac001417c668000000c22ea22c8020f11ec5b159d79aacb197f4cb3aa460a977eb7d4
87843e61ab75ce182790c8daa81031210008203000401cc4c8f0401ef01022103afc5be570d0ff419425cfcc580cc762ab82baad88c148f5b028
d7db7bfeee61d2102d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a545ef4b01d021ce059f232a76892782560
37f46bdde221a736629ac5a02d9473be92f84a321021130357675e5f1cc892a6e673a6cece74d988cf80a48445aad1cd8823ebaa24a7500000
000000000004b6a49ef5401d021ce059f232a7689278256037f46bdde221a736629ac5a02d9473be92f84a32103499750cc3961988fd15db27
ad9b84dae6005ea5ea8a7c3ab76bbf5a88c81581001000000000000008b0100000000000000000000000000

Baton : c8b6635db6e34b833e02d7abb0d9302a5461b44be4112c056bdd8bb7af2fc9fc

Marmara Credit Loop Info

./komodo-cli -ac_name=MCL marmaracreditloop 6630bc3fb03a5b7713924937ea810f4e5d9aa71b5d7993933175382c8324db89
{
"result": "success",
"myNormalAddress": "R9kFZrMRofq4Q82LXx4w1du2GmDo1n9XTS",
"myCCaddress": "R9WN5P5sSR6iJ9yXG24BXcjXERt7iFjdmn",
"funcid": "S",
"currency": "MARMARA",
"settlement": "c8b6635db6e34b833e02d7abb0d9302a5461b44be4112c056bdd8bb7af2fc9fc",
"createtxid": "a3842fe93b47d9025aac2966731a22debd467f0356822789762a239f05ce21d0",
"remainder": 0.00000000,
"settled": 785,
"pubkey": "03499750cc3961988fd15db27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c815810",
"myNormalAddr": "RFV1Jqo16zwvgtp6KFeQWFWyydYD5EAmU3",
"collected": 9000.00000000,
"LockedInLoopCCaddr": "RTswFa59xzyhXY3QVVXEw7o5WjSb88C4Sv",
"LockedInLoopAmount": 0.00000000,
"amount": 9000.00000000,
"matures": 785,
"n": 2,
"numerrors": 1,
"creditloop": [
{
"txid": "a3842fe93b47d9025aac2966731a22debd467f0356822789762a239f05ce21d0",
"funcid": "B",
"issuerpk": "03499750cc3961988fd15db27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c815810",
"issueraddr": "RFV1Jqo16zwvgtp6KFeQWFWyydYD5EAmU3",
"issuerCCaddr": "RTLcXGDVuf3sbx2VVk6UcxCLdvLYvCiN8x",
"incorrect-vout0address": "RQCsTNLA6WCr8KyvudzgL3uLCf4J7DENhV"
},
{
"txid": "6630bc3fb03a5b7713924937ea810f4e5d9aa71b5d7993933175382c8324db89",
"funcid": "I",
"receiverpk": "036eeaec4ac8efd0d021f0cc3a2fc91191337ee6764b98d720985588e2eb47a517",
"receiveraddr": "R9kFZrMRofq4Q82LXx4w1du2GmDo1n9XTS",
"receiverCCaddr": "R9WN5P5sSR6iJ9yXG24BXcjXERt7iFjdmn"
},
{
"txid": "c8b6635db6e34b833e02d7abb0d9302a5461b44be4112c056bdd8bb7af2fc9fc",
"funcid": "T",
"receiverpk": "03499750cc3961988fd15db27ad9b84dae6005ea5ea8a7c3ab76bbf5a88c815810",
"receiveraddr": "RFV1Jqo16zwvgtp6KFeQWFWyydYD5EAmU3",
"receiverCCaddr": "RTLcXGDVuf3sbx2VVk6UcxCLdvLYvCiN8x"
}
]
}

Alert

You can make 3x staking with only credit loops. Both issuer and holder(s) can make 3x staking until “matures”

When a holder becomes endorser in a particular loop by transferring the credit, he/she cannot have 3x staking any more since endorsers have no 3x staking within a credit loop. They can make 3x staking for other loops if they are issuers or holders. 

After “Settlement (Credit Loops Expiry)”, you cannot make “3x  Staking” since that loop is finished and coins are settled in the last holder’s account as normal coins. The holder can activate the normal coins by activating/locking for 3x staking.

Settlement : Settlement in a loop may happen automatically or manual. In Protocol 1, all credits are settled automatically since credits are fully collateralized by issuers during issuance of a credit.

If settlement is automatic, the last holder gets the funds automatically ready for spending as normal coins. In protocol 2, autosettlement is possible only when the escrow approves initially during issuance of a credit.