Transactions

From Open Transactions
Jump to navigation Jump to search

If you haven't first read the article on basic messages, start there. (It continues to this article.)

Let’s say I want to withdraw some cash. In that case, my OTMessage will have an OTLedger attached to it.

Here’s what the message looks like:

-----BEGIN SIGNED MESSAGE-----
Hash: SAMY

<?xml version="1.0"?>

<OTmessage
 version="1.0">

<notarizeTransactions
 nymID="Bg2QrSTomOEU5ICfvhfYfBYxQZPktDSnaVPpMLYxUnz"
 serverID="44FmyPAgrmGu671RywGnhrt8aR6tzmNFn9WKQ92BXn"
 accountID="PhmhKernutijMa2XXxH1dZnTluIDQUVn1tifSOq9H4x"
 requestNum="274" >

<accountLedger>
eJx1eMcOhEqS7az5iqu7Rd1415rbUuG9p6DY4V3hC/v1Q08/ad4sBgmJTIjkhMnI
E/G3vz0XK0iK+YenSKbA/6ELvCS4/5r+GyAna/2PP7yX8QGA/0yybNyGn17kVbH8
sRfL2ozDX38if4f/BP74XVPx1599sa5JVTzj//exwv/1J0VQJc4QaFZkGEEXdJmg
NFrkZF4iSYGSCEaUGVngDFkgDEEWBZUiCJOSyTNgcDghGTKnk4zCUiQnCzpPspIi
4RzJ0IKhGATDEQKDEwIm0wRJH1ESJhP6uRkSQbKUydMHzbYWy39DecTKkiQSqizS
JEsSOE2TlMLKnCRgDC1IEoWL5xEpceSRT9G0wJKcIB4EDJLjJZElKYE+utFUBlN5
wiBlmmcPyjyhSQLFmSwlCzjFErIsqJwkSzLFSrpIGZxgkJTI/wQeIPu/seBZhuc5
AT8iCZUzGZXDzwpwATN5Uj4/LrMcoRkMe7RmEpgqqTxHkCKnH3tQeYGgGVOWOV5g
GZpTcA7nVAKjD8oCpeESfWxb5iVMEPhjcpLGn6m0pFKMynGUYZLH+MWff/zzcepv
SYY1yX6PK/8JFOrJhEZmLUJzleEG4tu0wS5KJzTym0uup0XW+WUmpek3Ac7SIDLW
UuNeoLK9q8L0CBjrtUdQyXOT2kDy6325PC4T1G2Yh0xcfU/nBRThr+wugtJmLhmq
kld5MT5iMO76dXkA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Tf0kRk1vkFp3CY3iGBLYR2J2IvE/0wBOCqF1IzB/fO+UhAyVtI2lu5OBwQXkhc
9+9ZT6hfosyCpG22XIQLhcV3LbmWbTDJr4Oe/X6KmQES9oI0rr5akWeBKLKBANvN
H+nqNen9Pqr5w9SCtsvXpRDLPkimj1IM9NpJCdIYl6IV8GI6qEIgOpEgaEzsCwOu
Uj5KocQ3qjyvOSWinZJ5yEoZH3wIUf8paR46euklUeNGEhlUTr5O7zBfjU8A5yUO
RFhOcJ9vjB4UpafqN/VjtrwGnAloERZxRHReAs+YoN68uo90RnqyeY0JUrUqMJzc
OwAJV63sipXgDOQd5apu9ofg4PwGmZUOw9FntJNKYSnQmonfU+UX+eXSZdDQVJgw
/ekBpehrPtwEjW4zROtmgQFmHl3w7jgz6BEcZ5PgR4u8+vG3eb6BPhttCkdzzzdf
LmUyBZB5gTW6iN+4NG9BW3uODUHTih4FD9mM9oKg1eY/+kPo/voL+E/ofzWxnvH/
6lT+E/jb//Q4/93c/O9W58sPXOHfbc73v3uZ//jDmorhD/9/Vlv/gP+OwwA39n0x
/P7xR/37Tf+AoKr51Vv692zsIbH4fsfjEdmLb7FA/1rgb///AtDRdA0A2DKEVUJd
n5QGe9e8ChIFGu6ps5FkZqwoYlPbjN+ii72Ayl7hu1C8ecIWvsw/SchyGPBqjTZk
znBj/c34vLy1tZ1J1fuQ+YZrHMKrv60aWlheRNavFzkl0/RjZslE99llRnABpDuH
DjZ1zfbhLRETTLPsxHn1fV9qSGikS4S8SUTWamrZX/+2mGDy/4e9gP/4L4nKO0Q=
</accountLedger>

</notarizeTransactions>

</OTmessage>
-----BEGIN MESSAGE SIGNATURE-----
Version: Open Transactions 0.40
Comment: http://github.com/FellowTraveler/Open-Transactions/wiki

yTr21U8Xldvs+nhDgLQsetWJEtbZQZ+wwaMTzCWQNiVO+vMVbqq0M0rL5M1i//Im
j35PTAFgHA+StTx5gTPgyWsyPPwveIG5zD6sOUli2nLwZ0w6kR1CJsCmVLqhN3Vi
tsEq708GsIY8A1YGSppnVTN6FJJWd6bapmtpHebfzWA=
-----END MESSAGE SIGNATURE-----

You might notice that the ledger (in the message above) looks like a bunch of gibberish. That’s because it is base64-encoded, which makes it very convenient to attach it to the message as though it were just another “blob of data”.

But if you run it through a base64-decoder, then you can view the ledger:

-----BEGIN SIGNED LEDGER-----
Hash: SAMY

<accountLedger version="1.0"
 type="message"
 accountID="PhmhKernutijMa2XXxH1dZnTluIDQUVn1tifSOq9H4x"
 userID="Bg2QrSTomOEU5ICfvhfYfBYxQZPktDSnaVPpMLYxUnz"
serverID="44FmyPAgrmGu671RywGnhrt8aR6tzmNFn9WKQ92BXn" >

<transaction>
eJx9WMcOrEiyfWu+4upu0R28a81tqfCm8FBQtcN7KLz5+qGnF9Orh4SUJBmRJ08o
MsyvX/fDCpJi/HAVyRD4H57zMNwH5ymm8de/X4AczeUfP9yH/gaAfy9T1M9RslRD
/2M5v9nvn3u1lOkU7VH7E/gRJcmw9ovC//5JEVSOMwSaZAlG0BmdRyiNZimZ5kiU
oSSCEXlCZjhDZghDkFlGxQjCxGR0fzA4HJEMmdJRQmExkpIZnUZJTpFwiiRoxlAM
guEIgcERAZNxhMS3KAmTEX2/DIkgScyk8Y1mnbPpv1BusTwniYjKszhKogiO4yim
sDwlCRhDM5JE4eweIjmO3PIxGmdYlBLEjYBBUjwnkigm0PtsNJXAVBoxSB6nyY0y
jWiSQHEmickMjrGIzDMqJcmcjLGczmIGJxgkJtIbyo1k+xsMniR4mhLwLRNRKZNQ
KXyrgDOYSaP83jlPUoRmMOw+NhPBVE6lKYJkKX0TQqUZgiZMnqd4hiVoSsEpnFIR
jN4wM5SGc/QmN09zmCDwm3OSxu+pOKdijEpxlGGim/3sBvMPIxpr9/snTeD3bNU7
WZ5NWZ9k3vD7J/zzx5+3wasl6/4EMvVoX3S3jnDhUt4rT/IAJfnwemnfWKjjNy/F
UmE0h6ron8s+cow6R+cTjM2HUxTTaoDqzeu1ZV0E1qbHc53zqz9DJxOfTN6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
B6vlFX2k3MZ1+/u1XMevAmtEPtMmpfy7Y5q3uHxP0sZiOleSN/OaAVzkcji5b74z
XykrJxXmNTrYUFpOpVDJIqnkl+z1DMEXKzWZNN93gmc9eTDnd3eQUgmc1BAH510X
grkSYk5RViCkabf/w/Frne5E127por3ZH2Bc8a/0ET8IPgtfmgivggs1gPFWfPI5
xfzp1Gd98LBRZnBSRhvGIJUFzbwAXe01EQ9oIhaKJxbySfhgv1OLHkCMggJyWUs+
eUeALoQHCzkh4j3jR06GhyZOLXZx0IlNqBaBC22rPI1cxwUZYBMRj3hM7vIPsI+P
Xewyweb81e+8Ety5EatJyz6mU2MvFhqYmHpKqN3gTGmEK6LHwtLyruqu2Gd6FoB4
fpl4ERnGHzGp5cOxl+pWnpVW53r5KzaFmH5mnnU+sLeGiqUzvCT1U7HuW6PufrQC
Wy1ZhmVqLa7taIqEGKuPHeWr73ZzhGROPM9atk/AtGxFcM+5Pr1iRLsOXSO+21u+
BkqYGymKGVVwgqY9hEKvHyyI5rvnGNT279/Av6G/K9R78I+y9k/g1/8aG//oaPy3
yfHwfEf4u7fxyqb5Xv7HD/Ob9T+8/ymYf8D/wmGAG7ou65c/fpTL8v0DgopqKdf4
X3d5CYlZ2w77LbJlbTZBfyn49U8F0F41FQAED9N+LiAkYGxXLauSiN+7hJE9CHmQ
60gjHRFgEQn6zXdJLNmwEQ4Du/NgL00XYoPagIB7+Oq5tZ9kedyR8fUi87Wa9mxS
fFTKT0iUiLP95jRcUM+cS8eDRoq92wUwxia4wj1AmotuSTM2YHmpWoNvduTHfH6b
1qr0K8eZV4GquUjhSQP//ps2weD/P9KA//sPDYLsGg==
</transaction>

</accountLedger>
-----BEGIN LEDGER SIGNATURE-----
Version: Open Transactions 0.40
Comment: http://github.com/FellowTraveler/Open-Transactions/wiki

PH/3gEhhx7K0SyqsEG7+MRxLBXGNcBFF3pjiolekZSU7cAWVeISqp3rDfdYaWBC3
AjMjW9xWuBTuMYASsjPQpJLmW9lWsZW0sTusK2eOSX6hAA6pappt9qGN2vqR9o+r
Gzd/wBbRNj9INX9UpqHQZdglVyJW5K6R5WDN5XOsNKc=
-----END LEDGER SIGNATURE-----

As you can see, the ledger above is just another contract. In OT, you can have contracts nested inside contracts. Inside this ledger you can see there is a single transaction. Upon decoding it, the actual withdrawal request appears (below.)

Notice that this transaction has a "Transaction Number" (in this case 854) attached to it. This is a security device, similar to the request number:

Every transaction request must include a transaction number, and you may only use one that has been issued to you by the server.

Some instruments may be written and signed offline, which means you will want to have a supply of transaction numbers in your wallet, in case you want to write a cheque or sign a payment plan, or whatever. (NOTE: these transaction numbers cannot be used to trace the digital cash transactions, since the cash tokens themselves are unlinkable, and cannot be linked from withdrawal back to deposit again. But the withdrawal and deposit _will_ each have a transaction number attached to each message. This in no way violates the untraceability of the cash, FYI. That is, just because you used transaction#5 to withdraw some tokens, and just because I used transaction#9 to deposit those tokens, the tokens themselves are still unlinkable, and the server still has no idea whether I got them from you.)

Transaction numbers are important because they are what make it possible to prove all balances and all closed transactions, without all parties being forced to store their entire transaction history forever. Instead, parties can prove their position in any dispute, simply by saving the last signed receipt. Nifty, eh? Read more about this

Here's the transaction:

-----BEGIN SIGNED TRANSACTION-----
Hash: SAMY

<transaction type="withdrawal"
 accountID="PhmhKernutijMa2XXxH1dZnTluIDQUVn1tifSOq9H4x"
 userID="Bg2QrSTomOEU5ICfvhfYfBYxQZPktDSnaVPpMLYxUnz"
 serverID="44FmyPAgrmGu671RywGnhrt8aR6tzmNFn9WKQ92BXn"
 transactionNum="854"
 inReferenceTo="0" >

<item>
eJxlV8muq0gS7TVfcfW26DXzVKpbEjbYDGbGgNkxJIMZzQxf37yqRZWqkZCIIOPk
iYDMjPPz53ldxLusfznyXReFL9fmdYe/urKhf8muqP0a8BOSorH47cvhtRcE/V5O
oPma9h58/1jLqUiHaI3qH9DXOEXTPH7/GMBnBuN0eqYhascomcqu1efm+wdLkb/G
gWEBgyx8/yCThExTCk1iOmJSLmFSlMJJFKBcGmV4DLIkx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l3zC/y3r2Ka+t8QJD81zxz/N+ka5Abqc586
QxZQgwH5BfDznwDIWlYlBKGtwqdrkQtP2WO3JyG2Qk49hNXu1MbEtlDSJSu3ZrLg
Fyp9btF99Uq3GlDXqnGjlHsIlMCnHpFkgFdZsDBRZ0TuXIPM9DGGnrguwvkJwUau
vjGPNPOKl4Kw2d1X3BMqm7UJYlvREcscTTPtvZW9lBi5CLsjyTgq2mm2uaDmwlDj
h0Cq779qJ+r/rwX/XTnoP/8DmLqWjQ==
</item>

</transaction>
-----BEGIN TRANSACTION SIGNATURE-----
Version: Open Transactions 0.40
Comment: http://github.com/FellowTraveler/Open-Transactions/wiki

WAOQLt+/E3BmituIcFp/XHHT/1A6uq81m5W3a6+UkptcPHNQ1C3+myxBzKMEbN7v
WCAUJyvlZctANwqVV6fuirwerIU2Gfy/FG5ylpf80g7LfCdqx81gwmwE+b3r0i4T
GsgmtdeBWBDGiuWpexfxsypklPiMzf49Vg2JfF74ck0=
-----END TRANSACTION SIGNATURE-----

(By the way, you can decode these things yourself using 'opentxs decode' at the command line.)

In this case, the above transaction contains a single item: the withdrawal request. (Transactions might have multiple items, covering additional functionality such as server fees, balance agreement, etc that may become necessary for each transaction.)

Here is the withdrawal item:

-----BEGIN SIGNED TRANSACTION ITEM-----
Hash: SAMY

<item type="withdrawal"
 status="request"
 transactionNum="854"
 serverID="44FmyPAgrmGu671RywGnhrt8aR6tzmNFn9WKQ92BXn"
 userID="Bg2QrSTomOEU5ICfvhfYfBYxQZPktDSnaVPpMLYxUnz"
 fromAccountID="PhmhKernutijMa2XXxH1dZnTluIDQUVn1tifSOq9H4x"
 toAccountID=""
 inReferenceTo="0"
 amount="1000" >

<note>
eJxzz8zNTVVITizOUFTwdPfzD3JV0NVV8PMPcVUIcHRx8fRzB/FxyHCRroMBAJZj
HCQ=
</note>

<attachment>
eJxtVlfPo0gW3Wd+xad+RT3k1JqeERgwOQfDG6Ew0ZhgwP71S8+MtLvS3qdbp1RV
RzfUPd+/nyZI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/j8b4S1z8pTT4IPT+
kRnR3+Lhx5f9BI+vYM4eS1asJ7J8ob+RKHQZhwE81h9f9bo+fyDIvVnrV/5bMQ6I
DPp+3M8jG+jBjPy64Pt/X4DsTddAULhnQwI7rNbcOhHwzH0Jbb5YnPjue61j7x78
xgHj+RbvUsbKPm+ZNu0cWPlU2SyGlqHlKo4VZ6rO/RWIOoEKNbgblJW6ojgNYry+
h3rNN18czzM0vwyOxlEzwqzgY6XPZYWhitdM3sKQCjkKcXW3Avf9wa9DZdTre8g6
gksHBBaADgl//h0wyRL/f7igf/0bRw0aQw==
</attachment>

</item>
-----BEGIN TRANSACTION ITEM SIGNATURE-----
Version: Open Transactions 0.40
Comment: http://github.com/FellowTraveler/Open-Transactions/wiki

0nJAdwhgDUIV8xU3EnDg5LDwRoKmP1xZHNHQgQu4hAv5dUxaGwViTkr0TQl2OiIp
eieW5LaHOeYih8+3lf3gSCXfPW176t9oa2At/1s9lF7LdfVhYJ/8fGWJTaGwfuMt
8nESEig0dfMjxipHcOgE+Ts47SK0oMRPv0Pv75sq3/k=
-----END TRANSACTION ITEM SIGNATURE-----

I’m sure it’s becoming more clear how central contracts really are to the design of OT. So far, we’ve opened an envelope and retrieved a message from within, with a ledger inside, with a transaction inside of that, with a transaction item inside…

Later, a copy of the above transaction item will be included by the server as part of my withdrawal receipt.

So... the above withdrawal item has an attachment on it -- what is it? It’s an OTPurse, containing the actual prototokens for the cash withdrawal. (The wallet must blind the tokens before sending them to the server, so that the server won't know their IDs when they are signed... that's how they stay unlinkable: their token IDs are only unblinded after being returned to the user's wallet.)

In this case, only a single prototoken was necessary for this withdrawal, as you can see if you look inside the purse:

-----BEGIN SIGNED PURSE-----
Hash: SAMY

<?xml version="1.0"?>

<purse version="1.0"
 totalValue="1000"
 userID=""
 assetTypeID="XUHBvdsWAEmErZMzHaRKaNPaAVsUvKwL4uLY4nOY2s4"
 serverID="44FmyPAgrmGu671RywGnhrt8aR6tzmNFn9WKQ92BXn">

<token>
AAAAg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N5h0L0SuOz2nCrXArmjvAV2GiTtmliEhQ
44rSjCivH7+FSGFRq4P3VxGbaQBQyfCVmq0x6SqdnVJgercO32VRWTH7nRQ/LND+
AiqCmCWgYoTw1xbYCHjVQFKs0+BeRHSWrU3jr+ICqEmDR2bSUPdOIB1DFGlb4Pse
0yxlxub9UZN2RMu3ujiJ7JDAyze2g8HVBQ/VZk9JwMT8byM+UI8mlE7L8o+sptkb
FQW/l5efuYCAqhnsr2uqh/oUXdRe7t6PfE/LNfbTLYN0JDKyR2i+QiqLPFA8NdKE
oRE8CVowlculdhbERdSUbtfg2PAG+RXlJxxFBelIko3Dk/WEG0L3nFQx9FWaXayN
nJEGw3C4kAVXSqtY/6sR2pEU5UEskfyE7lAbMRV+UEh5InYZ5OR5z5HHSNawLTuW
dBuFoKph9tyvd2g9wMI5YZxTMaZF5jArMj/hIlQeWtkSVUhBWcn7NZPKnMcrKznL
wTjosCMBhtqymircD8zNTpw5WQ757fvBtQLiNHNjO6SPG5mMiUYrUT6OSJqqgtrh
Yss34iIPLbUaPMOp+ijKdhywpPUL11k7qy8v++7OkiSk+qYegmlyGL0S22JTl+VD
ljz7TFrTpNDJrYCCBHZKHp0S8z8=
</token>

</purse>
-----BEGIN PURSE SIGNATURE-----
Version: Open Transactions 0.40
Comment: http://github.com/FellowTraveler/Open-Transactions/wiki

UwamY+P8JiXkDeA7gsUOAcsPWgSRjPOwR+y2e7RSNAQ5Lt8pXaJqw9etAZHvN76F
sGDof9MIPguTDK30BhegL5NZQDDqmDWtymhtbvSDoetA6AsmPJ95r/7tezNZpst+
fAJMAN1/f/xcDtQvc2SSmShUHoKhgU8PBQ6T31Tek/U=
-----END PURSE SIGNATURE-----

If you want to write a cheque for a strange amount, such as 1291, or 87622, it's no problem.

But with cash, the cash tokens come in specific denominations, such as 1, 5, 10, etc. (it's a part of what makes them unlinkable. Exact denominations to be configurable in each currency contract.) Due to this, *you do not handle tokens directly, but instead, _purses full of tokens_.* This way you can have a purse worth 1291, or 87622, or any amount you wish. That's why all messages involving cash use an OTPurse.

The token in the purse above cannot be base64-decoded since it was actually encrypted before it was encoded. (Tokens are stored in encrypted form.) As long as you have the right nym loaded, you can use 'opentxs decrypt' at the command line in order to view most encrypted contents. (They might be in binary form, depending on which OT data you are actually decrypting.)

To continue reading about cash tokens, click here.
To see another sample purse, click here.
To read about the OTMint object, click here.
To read about smart contracts, click here
To go back to the basic article on OTMessage, click here.