New file structure for concepts & tutorials

This commit is contained in:
mDuo13
2018-05-03 11:19:45 -07:00
parent 2e02611855
commit c072b2622c
44 changed files with 441 additions and 860 deletions

View File

@@ -0,0 +1,3 @@
# Complex Payment Types
In addition to simple point-to-point XRP Payments, the XRP Ledger supports a number of complex payment types for a variety of use cases and situations.

View File

@@ -0,0 +1,3 @@
# Decentralized Exchange
The XRP Ledger contains a fully-functional exchange where users can trade issued currencies for XRP or each other.

View File

@@ -126,7 +126,7 @@ The rest of the [transaction flow](reference-rippleapi.html#transaction-flow) is
Example JavaScript (ECMAScript 6) code to enable Individual Freeze on a trust line:
```js
{% include 'code_samples/freeze/set-individual-freeze.js' %}
{% include '_code-samples/freeze/set-individual-freeze.js' %}
```
@@ -173,7 +173,7 @@ The rest of the [transaction flow](reference-rippleapi.html#transaction-flow) is
Example JavaScript (ECMAScript 6) code to enable Global Freeze on an address:
```js
{% include 'code_samples/freeze/set-global-freeze.js' %}
{% include '_code-samples/freeze/set-global-freeze.js' %}
```
@@ -222,7 +222,7 @@ You must [sign](reference-rippleapi.html#sign) this transaction using the master
Example JavaScript (ECMAScript 6) code to enable No Freeze on an address:
```js
{% include 'code_samples/freeze/set-no-freeze.js' %}
{% include '_code-samples/freeze/set-no-freeze.js' %}
```
@@ -305,7 +305,7 @@ The response contains an array of trust lines, for each currency in which the is
Example JavaScript (ECMAScript 6) code to check whether a trust line is frozen:
```js
{% include 'code_samples/freeze/check-individual-freeze.js' %}
{% include '_code-samples/freeze/check-individual-freeze.js' %}
```
@@ -401,7 +401,7 @@ Look for the following values in the response object:
Example JavaScript (ECMAScript 6) code to check whether an address has Global Freeze or No Freeze enabled:
```js
{% include 'code_samples/freeze/check-global-freeze-no-freeze.js' %}
{% include '_code-samples/freeze/check-global-freeze-no-freeze.js' %}
```
# See Also

View File

@@ -1,4 +1,4 @@
# About rippled
# The rippled Server
`rippled` is the core peer-to-peer server that manages the XRP Ledger. This section covers concepts that help you learn the "what" and "why" behind fundamental aspects of the `rippled` server.

View File

@@ -56,7 +56,7 @@ Use the following template, which includes:
* (Optional) [ESLint](http://eslint.org/) (`eslint`) for checking code quality.
```
{% include 'code_samples/rippleapi_quickstart/package.json' %}
{% include '_code-samples/rippleapi_quickstart/package.json' %}
```
@@ -81,7 +81,7 @@ npm WARN ajv@1.4.10 requires a peer of ajv-i18n@0.1.x but none was installed.
This script, `get-account-info.js`, fetches information about a hard-coded account. Use it to test that RippleAPI works:
```
{% include 'code_samples/rippleapi_quickstart/get-account-info.js' %}
{% include '_code-samples/rippleapi_quickstart/get-account-info.js' %}
```
## Running the script
@@ -197,7 +197,7 @@ The `catch` method ends this Promise chain. The callback provided here runs if a
One of the biggest challenges in using the XRP Ledger (or any decentralized system) is knowing the final, immutable transaction results. Even if you [follow the best practices](tutorial-reliable-transaction-submission.html) you still have to wait for the [consensus process](https://ripple.com/build/ripple-ledger-consensus-process/) to finally accept or reject your transaction. The following example code demonstrates how to wait for the final outcome of a transaction:
```
{% include 'code_samples/rippleapi_quickstart/submit-and-verify.js' %}
{% include '_code-samples/rippleapi_quickstart/submit-and-verify.js' %}
```
This code creates and submits an order transaction, although the same principles apply to other types of transactions as well. After submitting the transaction, the code uses a new Promise, which queries the ledger again after using setTimeout to wait a fixed amount of time, to see if the transaction has been verified. If it hasn't been verified, the process repeats until either the transaction is found in a validated ledger or the returned ledger is higher than the LastLedgerSequence parameter.
@@ -285,5 +285,5 @@ To use this example, you must first [build RippleAPI](#build-instructions) and t
[**browser-demo.html:**](https://github.com/ripple/ripple-dev-portal/blob/master/content/code_samples/rippleapi_quickstart/browser-demo.html "Source on GitHub")
```
{% include 'code_samples/rippleapi_quickstart/browser-demo.html' %}
{% include '_code-samples/rippleapi_quickstart/browser-demo.html' %}
```

View File

@@ -0,0 +1,3 @@
# Manage Issued Currencies
These tutorials walk through monitoring and managing issued currencies in the XRP Ledger, both as an issuer and as a user of issued currencies.

View File

@@ -0,0 +1,3 @@
# Manage the rippled Server
This category encompasses various procedures for running stable and effective `rippled` servers.

View File

@@ -52,7 +52,7 @@ The following examples demonstrate how to cancel a Check.
*RippleAPI*
```js
{% include 'code_samples/checks/js/prepareCancel.js' %}
{% include '_code-samples/checks/js/prepareCancel.js' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -68,13 +68,13 @@ The following examples demonstrate how to cancel a Check.
*RippleAPI*
```js
{% include 'code_samples/checks/js/signCancel.js' %}
{% include '_code-samples/checks/js/signCancel.js' %}
```
*Commandline*
```bash
{% include 'code_samples/checks/cli/sign-cancel-req.sh' %}
{% include '_code-samples/checks/cli/sign-cancel-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -87,13 +87,13 @@ The following examples demonstrate how to cancel a Check.
*RippleAPI*
```
{% include 'code_samples/checks/js/sign-cancel-resp.txt' %}
{% include '_code-samples/checks/js/sign-cancel-resp.txt' %}
```
*Commandline*
```json
{% include 'code_samples/checks/cli/sign-cancel-resp.txt' %}
{% include '_code-samples/checks/cli/sign-cancel-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -111,13 +111,13 @@ The following examples demonstrate how to cancel a Check.
*RippleAPI*
```js
{% include 'code_samples/checks/js/submitCancel.js' %}
{% include '_code-samples/checks/js/submitCancel.js' %}
```
*Commandline*
```bash
{% include 'code_samples/checks/cli/submit-cancel-req.sh' %}
{% include '_code-samples/checks/cli/submit-cancel-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -130,13 +130,13 @@ The following examples demonstrate how to cancel a Check.
*RippleAPI*
```js
{% include 'code_samples/checks/js/submit-cancel-resp.txt' %}
{% include '_code-samples/checks/js/submit-cancel-resp.txt' %}
```
*Commandline*
```json
{% include 'code_samples/checks/cli/submit-cancel-resp.txt' %}
{% include '_code-samples/checks/cli/submit-cancel-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -158,13 +158,13 @@ Look for a `DeletedNode` object in the transaction metadata with `"LedgerEntryTy
*RippleAPI*
```js
{% include 'code_samples/checks/js/getCancelTx.js' %}
{% include '_code-samples/checks/js/getCancelTx.js' %}
```
*Commandline*
```bash
{% include 'code_samples/checks/cli/tx-cancel-req.sh' %}
{% include '_code-samples/checks/cli/tx-cancel-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -177,13 +177,13 @@ Look for a `DeletedNode` object in the transaction metadata with `"LedgerEntryTy
*RippleAPI*
```json
{% include 'code_samples/checks/js/get-cancel-tx-resp.txt' %}
{% include '_code-samples/checks/js/get-cancel-tx-resp.txt' %}
```
*Commandline*
```json
{% include 'code_samples/checks/cli/tx-cancel-resp.txt' %}
{% include '_code-samples/checks/cli/tx-cancel-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->

View File

@@ -43,7 +43,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*RippleAPI*
```js
{% include 'code_samples/checks/js/prepareCashExact.js' %}
{% include '_code-samples/checks/js/prepareCashExact.js' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -59,7 +59,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*Commandline*
```bash
{% include 'code_samples/checks/cli/sign-cash-exact-req.sh' %}
{% include '_code-samples/checks/cli/sign-cash-exact-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -72,7 +72,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*Commandline*
```json
{% include 'code_samples/checks/cli/sign-cash-exact-resp.txt' %}
{% include '_code-samples/checks/cli/sign-cash-exact-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -90,7 +90,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*Commandline*
```bash
{% include 'code_samples/checks/cli/submit-cash-exact-req.sh' %}
{% include '_code-samples/checks/cli/submit-cash-exact-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -103,7 +103,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*Commandline*
```json
{% include 'code_samples/checks/cli/submit-cash-exact-resp.txt' %}
{% include '_code-samples/checks/cli/submit-cash-exact-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -127,7 +127,7 @@ If cashing the Check failed, the Check remains in the ledger so you can try cash
*Commandline*
```bash
{% include 'code_samples/checks/cli/tx-cash-exact-req.sh' %}
{% include '_code-samples/checks/cli/tx-cash-exact-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -140,7 +140,7 @@ If cashing the Check failed, the Check remains in the ledger so you can try cash
*Commandline*
```json
{% include 'code_samples/checks/cli/tx-cash-exact-resp.txt' %}
{% include '_code-samples/checks/cli/tx-cash-exact-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->

View File

@@ -44,7 +44,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*RippleAPI*
```js
{% include 'code_samples/checks/js/prepareCashFlex.js' %}
{% include '_code-samples/checks/js/prepareCashFlex.js' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -60,7 +60,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*Commandline*
```bash
{% include 'code_samples/checks/cli/sign-cash-flex-req.sh' %}
{% include '_code-samples/checks/cli/sign-cash-flex-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -73,7 +73,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*Commandline*
```json
{% include 'code_samples/checks/cli/sign-cash-flex-resp.txt' %}
{% include '_code-samples/checks/cli/sign-cash-flex-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -91,7 +91,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*Commandline*
```bash
{% include 'code_samples/checks/cli/submit-cash-flex-req.sh' %}
{% include '_code-samples/checks/cli/submit-cash-flex-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -104,7 +104,7 @@ The following examples show how to prepare a transaction to cash a Check for a f
*Commandline*
```json
{% include 'code_samples/checks/cli/submit-cash-flex-resp.txt' %}
{% include '_code-samples/checks/cli/submit-cash-flex-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -124,7 +124,7 @@ Use the [`tx` method](reference-rippled.html#tx) with the CheckCash transaction'
*Commandline*
```bash
{% include 'code_samples/checks/cli/tx-cash-flex-req.sh' %}
{% include '_code-samples/checks/cli/tx-cash-flex-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -137,7 +137,7 @@ Use the [`tx` method](reference-rippled.html#tx) with the CheckCash transaction'
*Commandline*
```json
{% include 'code_samples/checks/cli/tx-cash-flex-resp.txt' %}
{% include '_code-samples/checks/cli/tx-cash-flex-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->

View File

@@ -17,13 +17,13 @@ To get a list of all incoming and outgoing Checks for an account, use the `accou
*RippleAPI*
```js
{% include 'code_samples/checks/js/getChecks.js' %}
{% include '_code-samples/checks/js/getChecks.js' %}
```
*JSON-RPC*
```json
{% include 'code_samples/checks/json-rpc/account_objects-req.json' %}
{% include '_code-samples/checks/json-rpc/account_objects-req.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -35,7 +35,7 @@ To get a list of all incoming and outgoing Checks for an account, use the `accou
*RippleAPI*
```
{% include 'code_samples/checks/js/get-checks-resp.txt' %}
{% include '_code-samples/checks/js/get-checks-resp.txt' %}
```
*JSON-RPC*
@@ -43,7 +43,7 @@ To get a list of all incoming and outgoing Checks for an account, use the `accou
```json
200 OK
{% include 'code_samples/checks/json-rpc/account_objects-resp.json' %}
{% include '_code-samples/checks/json-rpc/account_objects-resp.json' %}
```
<!-- MULTICODE_BLOCK_END -->

View File

@@ -19,13 +19,13 @@ To get a list of all incoming and outgoing Checks for an account, use the `accou
*RippleAPI*
```js
{% include 'code_samples/checks/js/getChecks.js' %}
{% include '_code-samples/checks/js/getChecks.js' %}
```
*JSON-RPC*
```json
{% include 'code_samples/checks/json-rpc/account_objects-req.json' %}
{% include '_code-samples/checks/json-rpc/account_objects-req.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -37,7 +37,7 @@ To get a list of all incoming and outgoing Checks for an account, use the `accou
*RippleAPI*
```
{% include 'code_samples/checks/js/get-checks-resp.txt' %}
{% include '_code-samples/checks/js/get-checks-resp.txt' %}
```
*JSON-RPC*
@@ -45,7 +45,7 @@ To get a list of all incoming and outgoing Checks for an account, use the `accou
```json
200 OK
{% include 'code_samples/checks/json-rpc/account_objects-resp.json' %}
{% include '_code-samples/checks/json-rpc/account_objects-resp.json' %}
```
<!-- MULTICODE_BLOCK_END -->

View File

@@ -57,7 +57,7 @@ The following example shows a prepared Check from BoxSend SG (rBXsgNkPcDN2runsvW
*RippleAPI*
```js
{% include 'code_samples/checks/js/prepareCreate.js' %}
{% include '_code-samples/checks/js/prepareCreate.js' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -73,19 +73,19 @@ The following example shows a prepared Check from BoxSend SG (rBXsgNkPcDN2runsvW
*RippleAPI*
```js
{% include 'code_samples/checks/js/signCreate.js' %}
{% include '_code-samples/checks/js/signCreate.js' %}
```
*WebSocket*
```json
{% include 'code_samples/checks/websocket/sign-create-req.json' %}
{% include '_code-samples/checks/websocket/sign-create-req.json' %}
```
*Commandline*
```bash
{% include 'code_samples/checks/cli/sign-create-req.sh' %}
{% include '_code-samples/checks/cli/sign-create-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -97,19 +97,19 @@ The following example shows a prepared Check from BoxSend SG (rBXsgNkPcDN2runsvW
*RippleAPI*
```js
{% include 'code_samples/checks/js/sign-create-resp.txt' %}
{% include '_code-samples/checks/js/sign-create-resp.txt' %}
```
*WebSocket*
```json
{% include 'code_samples/checks/websocket/sign-create-resp.json' %}
{% include '_code-samples/checks/websocket/sign-create-resp.json' %}
```
*Commandline*
```json
{% include 'code_samples/checks/cli/sign-create-resp.txt' %}
{% include '_code-samples/checks/cli/sign-create-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -126,19 +126,19 @@ The following example shows a prepared Check from BoxSend SG (rBXsgNkPcDN2runsvW
*RippleAPI*
```js
{% include 'code_samples/checks/js/submitCreate.js' %}
{% include '_code-samples/checks/js/submitCreate.js' %}
```
*WebSocket*
```json
{% include 'code_samples/checks/websocket/submit-create-req.json' %}
{% include '_code-samples/checks/websocket/submit-create-req.json' %}
```
*Commandline*
```bash
{% include 'code_samples/checks/cli/submit-create-req.sh' %}
{% include '_code-samples/checks/cli/submit-create-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -150,19 +150,19 @@ The following example shows a prepared Check from BoxSend SG (rBXsgNkPcDN2runsvW
*RippleAPI*
```js
{% include 'code_samples/checks/js/submit-create-resp.txt' %}
{% include '_code-samples/checks/js/submit-create-resp.txt' %}
```
*WebSocket*
```json
{% include 'code_samples/checks/websocket/submit-create-resp.json' %}
{% include '_code-samples/checks/websocket/submit-create-resp.json' %}
```
*Commandline*
```json
{% include 'code_samples/checks/cli/submit-create-resp.txt' %}
{% include '_code-samples/checks/cli/submit-create-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -187,19 +187,19 @@ Look for a `CreatedNode` object in the transaction metadata to indicate that the
*RippleAPI*
```
{% include 'code_samples/checks/js/getCreateTx.js' %}
{% include '_code-samples/checks/js/getCreateTx.js' %}
```
*WebSocket*
```json
{% include 'code_samples/checks/websocket/tx-create-req.json' %}
{% include '_code-samples/checks/websocket/tx-create-req.json' %}
```
*Commandline*
```bash
{% include 'code_samples/checks/cli/tx-create-req.sh' %}
{% include '_code-samples/checks/cli/tx-create-req.sh' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -211,19 +211,19 @@ Look for a `CreatedNode` object in the transaction metadata to indicate that the
*RippleAPI*
```
{% include 'code_samples/checks/js/get-create-tx-resp.txt' %}
{% include '_code-samples/checks/js/get-create-tx-resp.txt' %}
```
*WebSocket*
```json
{% include 'code_samples/checks/websocket/tx-create-resp.json' %}
{% include '_code-samples/checks/websocket/tx-create-resp.json' %}
```
*Commandline*
```json
{% include 'code_samples/checks/cli/tx-create-resp.txt' %}
{% include '_code-samples/checks/cli/tx-create-resp.txt' %}
```
<!-- MULTICODE_BLOCK_END -->

View File

@@ -0,0 +1,5 @@
# Use Checks
Checks in the XRP Ledger authorize another account to claim funds later, similar to how personal paper checks work.
**Caution:** As of 2018-05-03, the Checks amendment is not enabled on the XRP Ledger. You can use Checks on the [XRP Test Net](TODO:link) only.

View File

@@ -0,0 +1,3 @@
# Use Complex Payment Types
In addition to [simple, direct XRP Payments](TODO:link), the XRP Ledger supports a variety of more complex payments for building smart apps on the decentralized ledger.

View File

@@ -58,7 +58,7 @@ Request:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/submit-request-escrowcreate-time.json' %}
{% include '_code-samples/escrow/websocket/submit-request-escrowcreate-time.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -70,7 +70,7 @@ Response:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/submit-response-escrowcreate-time.json' %}
{% include '_code-samples/escrow/websocket/submit-response-escrowcreate-time.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -93,7 +93,7 @@ Request:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/tx-request-escrowcreate-time.json' %}
{% include '_code-samples/escrow/websocket/tx-request-escrowcreate-time.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -105,7 +105,7 @@ Response:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/tx-response-escrowcreate-time.json' %}
{% include '_code-samples/escrow/websocket/tx-response-escrowcreate-time.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -123,7 +123,7 @@ Request:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/ledger-request.json' %}
{% include '_code-samples/escrow/websocket/ledger-request.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -135,7 +135,7 @@ Response:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/ledger-response.json' %}
{% include '_code-samples/escrow/websocket/ledger-response.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -158,7 +158,7 @@ Request:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/submit-request-escrowfinish-time.json' %}
{% include '_code-samples/escrow/websocket/submit-request-escrowfinish-time.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -170,7 +170,7 @@ Response:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/submit-response-escrowfinish-time.json' %}
{% include '_code-samples/escrow/websocket/submit-response-escrowfinish-time.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -192,7 +192,7 @@ Request:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/tx-request-escrowfinish-time.json' %}
{% include '_code-samples/escrow/websocket/tx-request-escrowfinish-time.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -204,7 +204,7 @@ Response:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/tx-response-escrowfinish-time.json' %}
{% include '_code-samples/escrow/websocket/tx-response-escrowfinish-time.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -283,7 +283,7 @@ Request:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/submit-request-escrowcreate-condition.json' %}
{% include '_code-samples/escrow/websocket/submit-request-escrowcreate-condition.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -295,7 +295,7 @@ Response:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/submit-response-escrowcreate-condition.json' %}
{% include '_code-samples/escrow/websocket/submit-response-escrowcreate-condition.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -315,7 +315,7 @@ Request:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/tx-request-escrowcreate-condition.json' %}
{% include '_code-samples/escrow/websocket/tx-request-escrowcreate-condition.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -327,7 +327,7 @@ Response:
*Websocket*
```json
{% include 'code_samples/escrow/websocket/tx-response-escrowcreate-condition.json' %}
{% include '_code-samples/escrow/websocket/tx-response-escrowcreate-condition.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -347,7 +347,7 @@ If the escrow has expired, you can only [cancel the escrow](#cancel-an-expired-e
_Websocket_
```json
{% include 'code_samples/escrow/websocket/submit-request-escrowfinish-condition.json' %}
{% include '_code-samples/escrow/websocket/submit-request-escrowfinish-condition.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -359,7 +359,7 @@ Response:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/submit-response-escrowfinish-condition.json' %}
{% include '_code-samples/escrow/websocket/submit-response-escrowfinish-condition.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -377,13 +377,13 @@ Use the [`tx` command](reference-rippled.html#tx) with the EscrowFinish transact
Request:
```json
{% include 'code_samples/escrow/websocket/tx-request-escrowfinish-condition.json' %}
{% include '_code-samples/escrow/websocket/tx-request-escrowfinish-condition.json' %}
```
Response:
```json
{% include 'code_samples/escrow/websocket/tx-response-escrowfinish-condition.json' %}
{% include '_code-samples/escrow/websocket/tx-response-escrowfinish-condition.json' %}
```
## Cancel an expired escrow
@@ -399,7 +399,7 @@ Request:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/ledger-request-expiration.json' %}
{% include '_code-samples/escrow/websocket/ledger-request-expiration.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -411,7 +411,7 @@ Response:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/ledger-response-expiration.json' %}
{% include '_code-samples/escrow/websocket/ledger-response-expiration.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -426,7 +426,7 @@ Request:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/account_objects-request-expiration.json' %}
{% include '_code-samples/escrow/websocket/account_objects-request-expiration.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -438,7 +438,7 @@ Response:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/account_objects-response-expiration.json' %}
{% include '_code-samples/escrow/websocket/account_objects-response-expiration.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -456,7 +456,7 @@ Request:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/submit-request-escrowcancel.json' %}
{% include '_code-samples/escrow/websocket/submit-request-escrowcancel.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -468,7 +468,7 @@ Response:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/submit-response-escrowcancel.json' %}
{% include '_code-samples/escrow/websocket/submit-response-escrowcancel.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -491,7 +491,7 @@ _Websocket_
```json
{% include 'code_samples/escrow/websocket/tx-request-escrowcancel.json' %}
{% include '_code-samples/escrow/websocket/tx-request-escrowcancel.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -503,7 +503,7 @@ Response:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/tx-response-escrowcancel.json' %}
{% include '_code-samples/escrow/websocket/tx-response-escrowcancel.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -531,7 +531,7 @@ Request:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/account_objects-request.json' %}
{% include '_code-samples/escrow/websocket/account_objects-request.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -548,7 +548,7 @@ Response:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/account_objects-response.json' %}
{% include '_code-samples/escrow/websocket/account_objects-response.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -568,7 +568,7 @@ Request:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/account_objects-request.json' %}
{% include '_code-samples/escrow/websocket/account_objects-request.json' %}
```
<!-- MULTICODE_BLOCK_END -->
@@ -585,7 +585,7 @@ Response:
_Websocket_
```json
{% include 'code_samples/escrow/websocket/account_objects-response.json' %}
{% include '_code-samples/escrow/websocket/account_objects-response.json' %}
```
<!-- MULTICODE_BLOCK_END -->

View File

@@ -0,0 +1,3 @@
# Use Simple XRP Payments
Direct XRP payments from one account to another are the simplest way to transact in the XRP Ledger. This section includes tutorials for how to use simple transactions proficiently and robustly.

View File

@@ -16,13 +16,13 @@ For illustrative purposes, this document uses a fictitious business called _Alph
### User Benefits
Alpha Exchange wants to list BTC/XRP and XRP/USD trading pairs partially because listing these pairs will benefit its users. Specifically, this support will allow its users to:
Alpha Exchange wants to list BTC/XRP and XRP/USD trading pairs partially because listing these pairs benefits its users. Specifically, this support wants to enable its users to:
* Deposit XRP _to_ Alpha Exchange _from_ the XRP Ledger
* Withdraw XRP _from_ Alpha Exchange _to_ the XRP Ledger
* Trade XRP with other currencies, such as BTC, USD, amongst others
* Trade XRP with other currencies, such as BTC, USD, among others
## Prerequisites for Supporting XRP
@@ -34,48 +34,72 @@ To support XRP, Alpha Exchange must:
See also:
* [Gateway Compliance](https://ripple.com/build/gateway-guide/#gateway-compliance) — Gateways and exchanges are different, but exchanges should also ensure that they are complying with local regulations and reporting to the appropriate agencies.
* [Gateway Compliance](tutorial-gateway-guide.html#gateway-compliance) — Gateways and exchanges are different, but exchanges should also ensure that they are complying with local regulations and reporting to the appropriate agencies.
* [Requirements for Sending to XRP Ledger](https://ripple.com/build/gateway-guide/#requirements-for-sending-to-rcl)
* [Requirements for Sending to XRP Ledger](tutorial-gateway-guide.html#requirements-for-sending-to-xrp-ledger)
* [Requirements for Receiving from XRP Ledger](https://ripple.com/build/gateway-guide/#requirements-for-receiving-from-rcl)
* [Requirements for Receiving from XRP Ledger](tutorial-gateway-guide.html#requirements-for-receiving-from-xrp-ledger)
* [Gateway Precautions](https://ripple.com/build/gateway-guide/#precautions)
* [Gateway Precautions](tutorial-gateway-guide.html#precautions)
### Partial Payments
Before integrating, exchanges should be aware of the [partial payments](reference-transaction-format.html#partial-payments) feature. This feature allows XRP Ledger users to send successful payments that reduce the amount received instead of increasing the `SendMax`. This feature can be useful for [returning payments](tutorial-gateway-guide.html#bouncing-payments) without incurring additional cost as the sender.
#### Partial Payments Warning
When the [tfPartialPayment flag](reference-transaction-format.html#payment-flags) is enabled, the `Amount` field **_is not guaranteed to be the amount received_**. The `delivered_amount` field of a payment's metadata indicates the amount of currency actually received by the destination account. When receiving a payment, use `delivered_amount` instead of the Amount field to determine how much your account received instead.
**Warning:** Be aware that malicious actors could exploit this. For more information, see [Partial Payments](concept-partial-payments.html).
### Accounts
XRP is held in *accounts* (sometimes referred to as *wallets* ) on the XRP Ledger. Accounts on the XRP Ledger are different than accounts on other blockchain ledgers, such as Bitcoin, where accounts incur little to no overhead. To submit transactions (for example, [OfferCreate](https://ripple.com/build/transactions/#offercreate) and others used for trading), XRP Ledger accounts require XRP [reserves](https://ripple.com/build/reserves/) to protect the ledger against spam and malicious usage. On other blockchains, balances are derived from the previous block. On the XRP Ledger, [account objects](https://ripple.com/build/ledger-format/#accountroot) describe several other properties of the account in addition to balances, so accounts are represented in each ledger and can never be destroyed or removed. Exchanges do not need to create accounts for each customer that holds XRP; they can store all of their customers XRP in just a few XRP Ledger accounts. For more information about XRP Ledger accounts, see the [Accounts](https://ripple.com/build/accounts/) article.
XRP is held in _accounts_ (also referred to as _wallets_ or _addresses_ ) on the XRP Ledger. Accounts on the XRP Ledger are different than accounts on other blockchain ledgers, such as Bitcoin, where accounts incur little to no overhead. In the XRP Ledger, accounts can [never be deleted](concept-accounts.html#permanence-of-accounts), and each account must hold a separate [reserve of XRP](concept-reserves.html) that cannot be sent to others. For these reasons, Ripple recommends that institutions not create excessive or needless accounts.
To comply with Ripple's recommend best practices, Alpha Exchange should create at least two new [accounts](https://ripple.com/build/accounts/) on the XRP Ledger. To minimize the risks associated with a compromised secret key, Ripple recommends creating [_issuing_, _operational_, and _standby_ accounts](https://ripple.com/build/issuing-operational-addresses/) (these are sometimes referred to, respectively, as cold, hot, and warm wallets). The operational/standby/issuing model is intended to balance security and convenience. Exchanges listing XRP should create the following accounts:
<!-- STYLE_OVERRIDE: hot wallet, warm wallet, cold wallet, wallet -->
* An [_issuing_ account](https://ripple.com/build/issuing-operational-addresses/#issuing-address) to securely hold the majority of XRP and customers' funds. To provide optimal security, this account should be offline.
To follow Ripple's recommended best practices, Alpha Exchange should create at least two new accounts on the XRP Ledger. To minimize the risks associated with a compromised secret key, Ripple recommends creating [_cold_, _hot_, and _warm_ accounts](https://ripple.com/build/issuing-operational-addresses/) (these are sometimes referred to, respectively, as cold, hot, and warm wallets). The hot/warm/cold model is intended to balance security and convenience. Exchanges listing XRP should create the following accounts:
For more information about the possible consequences of a compromised issuing account, see [Issuing Account Compromise](https://ripple.com/build/issuing-operational-addresses/#issuing-address-compromise).
* A [_cold wallet_](concept-issuing-and-operational-addresses.html#issuing-address) to securely hold the majority of XRP and customers' funds. For exchanges, this is also the address to which its users send [deposits](#deposit-xrp-into-exchange). To provide optimal security, this account's secret key should be offline.
* One or more [_operational_ accounts](https://ripple.com/build/issuing-operational-addresses/#operational-addresses) to conduct the day-to-day business of managing customers' XRP withdrawals and deposits. For example, with an opertaitional wallet, exchanges can securely support these types of automated XRP transfers. Operational accounts need to be online to service instant withdrawal requests.
If a malicious actor compromises an exchange's cold wallet, the possible consequences are:
For more information about the possible consequences of a compromised operational account, see [Operational Account Compromise](https://ripple.com/build/issuing-operational-addresses/#operational-address-compromise).
* The malicious actor gets full access to all XRP in the cold wallet.
* Optionally, one or more standby accounts to provide an additional layer of security between the issuing and operational accounts. Unlike an operational account, the secret key of a standby account does not need to be online. Additionally, you can distribute the secret keys for the standby account to several different people and implement [multisigning](https://ripple.com/build/how-to-multi-sign/) to increase security.
* If the master key is compromised, the malicious actor can irrevocably take control of the cold wallet forever (by disabling the master key and setting a new regular key or signer list). This would also give the malicious actor control over all future XRP received by the cold wallet.
For more information about the possible consequences of a compromised standby account, see [Standby Account Compromise](https://ripple.com/build/issuing-operational-addresses/#standby-address-compromise).
* If this happens, the exchange has to make a new cold wallet address and tell its customers the new address.
* If the regular key or signer list are comromised, the exchange can regain control of the cold wallet. However, some of a malicious actor's actions cannot easily be undone: <!-- STYLE_OVERRIDE: easily -->
* The malicious actor could issue currency in the XRP Ledger by using the cold wallet, but that currency should not be valued by anyone (unless the exchange explicitly stated it was also a gateway).
* If a malicious actor sets the asfRequireAuth flag for the account, that cannot be unset, although this only relates to issuing currency and should not affect an exchange that is not also a gateway. Any other settings a malicious actor sets or unsets with a master key can be reverted.
* One or more [_hot wallets_](concept-issuing-and-operational-addresses.html#operational-addresses) to conduct the day-to-day business of managing customers' XRP withdrawals and deposits. For example, with a hot wallet, exchanges can securely support these types of automated XRP transfers. Hot wallets need to be online to service instant withdrawal requests.
For more information about the possible consequences of a compromised hot wallet, see [Operational Account Compromise](concept-issuing-and-operational-addresses.html#operational-address-compromise).
* Optionally, one or more warm wallets to provide an additional layer of security between the cold and hot wallets. Unlike a hot wallet, the secret key of a warm wallet does not need to be online. Additionally, you can distribute the secret keys for the warm wallet to several different people and implement [multisigning](tutorial-multisign.html) to increase security.
For more information about the possible consequences of a compromised warm wallet, see [Standby Account Compromise](concept-issuing-and-operational-addresses.html#standby-address-compromise).
See also:
* ["Suggested Business Practices" in the _Gateway Guide_](https://ripple.com/build/gateway-guide/#suggested-business-practices)
* ["Suggested Business Practices" in the _Gateway Guide_](tutorial-gateway-guide.html#suggested-business-practices)
* [Issuing and Operational Addresses](https://ripple.com/build/issuing-operational-addresses/)
* [Issuing and Operational Addresses](concept-issuing-and-operational-addresses.html)
* [Creating Accounts](https://ripple.com/build/transactions/#creating-accounts)
* [Creating Accounts](reference-transaction-format.html#creating-accounts)
* [Reserves](https://ripple.com/build/reserves/)
* [Reserves](concept-reserves.html)
### Balance Sheets
Alpha Exchange will custody its customers' XRP, so it needs to track each customer's balance(s). To do this, Alpha Exchange must create and maintain an additional balance sheet. The following table illustrates what this balance sheet might look like.
To custody its ccustomers' XRP, Alpha Exchange must track each customer's XRP balance and its own holdings. To do this, Alpha Exchange must create and maintain an additional balance sheet or accounting system. The following table illustrates what this balance sheet might look like.
The new XRP Ledger accounts (_Alpha Operational_, _Alpha Standby_, _Alpha Issuing_) are in the *User* column of the *XRP Balances on XRP Ledger* table.
The new XRP Ledger accounts (_Alpha Hot_, _Alpha Warm_, _Alpha Cold_) are in the *User* column of the *XRP Balances on XRP Ledger* table.
The *Alpha Exchange XRP Balances* table represents new, additional balance sheet. Alpha Exchanges software manages their users balances of XRP on this accounting system.
@@ -124,7 +148,7 @@ XRP Balances</i></b></td>
<td>0</td>
</tr>
<tr>
<td><i>Alpha Operational</i></td>
<td><i>Alpha Hot</i></td>
<td>0</td>
<td></td>
<td>...</td>
@@ -132,7 +156,7 @@ XRP Balances</i></b></td>
<td></td>
</tr>
<tr>
<td><i>Alpha Standby</i></td>
<td><i>Alpha Warm</i></td>
<td>0</td>
<td></td>
<td></td>
@@ -140,7 +164,7 @@ XRP Balances</i></b></td>
<td></td>
</tr>
<tr>
<td><i>Alpha Issuing</i></td>
<td><i>Alpha Cold</i></td>
<td>0</td>
<td></td>
<td></td>
@@ -159,17 +183,17 @@ XRP Balances</i></b></td>
#### XRP Amounts
Amounts of XRP are represented on the XRP Ledger as an unsigned integer count of *drops*, where one XRP == 1,000,000 drops. Ripple recommends that software store XRP balances as integer amounts of drops, and perform integer arithmetic on these values. However, user interfaces should present balances in units of XRP.
Amounts of XRP are represented on the XRP Ledger as an unsigned integer count of _drops_, where one XRP is 1,000,000 drops. Ripple recommends that software store XRP balances as integer amounts of drops, and perform integer arithmetic on these values. However, user interfaces should present balances in units of XRP.
One drop (.000001 XRP) cannot be further subdivided. Bear this in mind when calculating and displaying FX rates between XRP and other assets.
One drop (.000001 XRP) cannot be further subdivided. Keep this in mind when calculating and displaying FX rates between XRP and other assets.
For more informtion, see [Specifying Currency Amounts](https://ripple.com/build/rippled-apis/#specifying-currency-amounts).
For more information, see [Specifying Currency Amounts](reference-rippled.html#specifying-currency-amounts).
#### On-Ledger and Off-Ledger
With exchanges like _Alpha Exchange_, XRP can be "on-ledger" or "off-ledger":
* **On-Ledger XRP**: XRP that can be queried through the public XRP Ledger by specifying the public [address](https://ripple.com/build/accounts/#addresses) of the XRP holder. The counterparty to these balances is the XRP Ledger. For more information, see [Currencies](https://ripple.com/build/rippled-apis/#currencies).
* **On-Ledger XRP**: XRP that can be queried through the public XRP Ledger by specifying the public [address](concept-accounts.html#addresses) of the XRP holder. The counterparty to these balances is the XRP Ledger. For more information, see [Currencies](reference-rippled.html#currencies).
* **Off-Ledger XRP**: XRP that is held by the accounting system of an exchange and can be queried through the exchange interface. Off-ledger XRP balances are credit-based. The counterparty is the exchange holding the XRP.
@@ -193,7 +217,7 @@ There are four main steps involved in an exchange's typical flow of funds:
This list does not include the [prerequisites](#prerequisites-for-supporting-xrp) required of an exchange.
At this point, _Alpha Exchange_ has created [operational, standby, and issuing accounts](#accounts) on the XRP Ledger and added them to its balance sheet, but has not accepted any deposits from its users.
At this point, _Alpha Exchange_ has created [hot, warm, and cold wallets](#accounts) on the XRP Ledger and added them to its balance sheet, but has not accepted any deposits from its users.
<table>
@@ -240,7 +264,7 @@ XRP Balances</i></b></td>
<td>0</td>
</tr>
<tr>
<td><i>Alpha Operational</i></td>
<td><i>Alpha Hot</i></td>
<td>0</td>
<td></td>
<td>...</td>
@@ -248,7 +272,7 @@ XRP Balances</i></b></td>
<td></td>
</tr>
<tr>
<td><i>Alpha Standby</i></td>
<td><i>Alpha Warm</i></td>
<td>0</td>
<td></td>
<td></td>
@@ -256,7 +280,7 @@ XRP Balances</i></b></td>
<td></td>
</tr>
<tr>
<td><i>Alpha Issuing</i></td>
<td><i>Alpha Cold</i></td>
<td>0</td>
<td></td>
<td></td>
@@ -276,13 +300,13 @@ XRP Balances</i></b></td>
### Deposit XRP into Exchange
To track [off-ledger XRP balances](#on-ledger-and-off-ledger) exchanges need to create new [balance sheets](#balance-sheets) (or similar accounting systems). The following table illustrates the balance changes that take place on Alpha Exchange's new balance sheet as users begin to deposit XRP.
To track [off-ledger XRP balances](#on-ledger-and-off-ledger), exchanges need to create new [balance sheets](#balance-sheets) (or similar accounting systems). The following table illustrates the balance changes that take place on Alpha Exchange's new balance sheet as users begin to deposit XRP.
A user named Charlie wants to deposit 50,000 XRP to Alpha Exchange. Doing this involves the following steps:
1. Charlie submits a payment of 50,000 XRP (by using [RippleAPI](https://ripple.com/build/rippleapi/) or similar software) to Alpha Exchange's [issuing account](#accounts).
1. Charlie submits a payment of 50,000 XRP (by using [RippleAPI](reference-rippleapi.html) or similar software) to Alpha Exchange's [cold wallet](#accounts).
a. Charlie adds an identifier (in this case, `789`) to the payment to associate it with his account at Alpha Exchange. This is called a [_destination tag_](https://ripple.com/build/gateway-guide/#source-and-destination-tags). (To use this, Alpha Exchange must have set the asfRequireDest flag on all of its accounts. This flag requires all incoming payments to have a destination tag like Charlie's. For more information, see [AccountSet Flags](https://ripple.com/build/transactions/#accountset-flags).
a. Charlie adds an identifier (in this case, `789`) to the payment to associate it with his account at Alpha Exchange. This is called a [_destination tag_](tutorial-gateway-guide.html#source-and-destination-tags). (To use this, Alpha Exchange should have set the asfRequireDest flag on all of its accounts to require all incoming payments to have a destination tag like Charlie's. For more information, see [AccountSet Flags](reference-transaction-format.html#accountset-flags)).
2. The software at Alpha Exchange detects the incoming payment, and recognizes `789` as the destination tag for Charlies account.
@@ -344,7 +368,7 @@ XRP Balances</i></b></td>
<td></td>
</tr>
<tr>
<td>Alpha Operational</td>
<td>Alpha Hot</td>
<td>0</td>
<td></td>
<td>...</td>
@@ -352,7 +376,7 @@ XRP Balances</i></b></td>
<td></td>
</tr>
<tr>
<td>Alpha Standby</td>
<td>Alpha Warm</td>
<td>0</td>
<td></td>
<td></td>
@@ -360,7 +384,7 @@ XRP Balances</i></b></td>
<td></td>
</tr>
<tr>
<td>Alpha Issuing</td>
<td>Alpha Cold</td>
<td><s>0</s>
<br>50,000</td>
<td></td>
@@ -379,18 +403,18 @@ XRP Balances</i></b></td>
</table>
### Trade XRP on The Exchange
### Trade XRP on the Exchange
Alpha Exchange users (like Charlie) can trade credit-based balances on Alpha Exchange. Alpha Exchange should keep track of user balances on its new balance sheet as these trades are made. These trades are _off-ledger_ and independent from the XRP Ledger, so the balance changes are not recorded there.
Alpha Exchange users (like Charlie) can trade credit-based balances on Alpha Exchange. Alpha Exchange should keep track of user balances on its new balance sheet as these trades are made. These trades are _off-ledger_ and independent from the XRP Ledger, so the balance changes are not recorded on the XRP Ledger.
For more information about trading _on_ the XRP Ledger, see [Lifecycle of an Offer](https://ripple.com/build/transactions/#lifecycle-of-an-offer).
Customers who hold XRP in their own XRP Ledger accounts can also use the distributed exchange built into the XRP Ledger to trade currencies issued by gateways. For more information about trading _on_ the XRP Ledger, see [Lifecycle of an Offer](reference-transaction-format.html#lifecycle-of-an-offer).
### Rebalance XRP Holdings
Exchanges can adjust the balances between their operational and issuing accounts at any time. Each balance adjustment consumes a [transaction fee](https://ripple.com/build/fees-disambiguation/), but does not otherwise affect the aggregate balance of all the accounts. The aggregate, on-ledger balance should always exceed the total balance available for trade on the exchange. (The excess should be sufficient to cover the XRP Ledger's [transaction fees](https://ripple.com/build/transaction-cost/).)
Exchanges can adjust the balances between their hot and cold wallets at any time. Each balance adjustment consumes a [transaction cost](concept-transaction-cost.html), but does not otherwise affect the aggregate balance of all the accounts. The aggregate, on-ledger balance should always exceed the total balance available for trade on the exchange. (The excess should be enough to cover the XRP Ledger's transaction costs.)
The following table demonstrates a balance adjustment of 80,000 XRP (via a [_payment_](https://ripple.com/build/transactions/#payment) on the XRP Ledger) between Alpha Exchange's issuing account and its operational account, where the issuing account was debited and the operational account was credited. If the payment were reversed (debit the operational account and credit the issuing account), the operational account balance would decrease. Balance adjustments like these allow an exchange to limit the risks associated with holding XRP in online operational accounts.
The following table demonstrates a balance adjustment of 80,000 XRP (via a [_payment_](reference-transaction-format.html#payment) on the XRP Ledger) between Alpha Exchange's cold wallet and its hot wallet, where the cold wallet was debited and the hot wallet was credited. If the payment were reversed (debiting the hot wallet and crediting the cold wallet), the hot wallet balance would decrease. Balance adjustments like these allow an exchange to limit the risks associated with holding XRP in online hot wallets.
<table>
@@ -416,7 +440,7 @@ Off-Ledger Balances</i></b></td>
<td>Alice</td>
<td>80,000</td>
<td></td>
<td>Operational</td>
<td>Hot</td>
<td><s>0</s>
<br>80,000</td>
</tr>
@@ -425,7 +449,7 @@ Off-Ledger Balances</i></b></td>
<td>Bob</td>
<td>50,000</td>
<td></td>
<td>Standby</td>
<td>Warm</td>
<td>0</td>
</tr>
<tr>
@@ -441,7 +465,7 @@ Off-Ledger Balances</i></b></td>
<td>Charlie</td>
<td>50,000</td>
<td></td>
<td>Issuing</td>
<td>Cold</td>
<td><s>180,000</s>
<br>100,000</td>
</tr>
@@ -476,7 +500,7 @@ In this example, Charlie withdraws 25,000 XRP from Alpha Exchange. This involves
a. Debits the amount (25,000 XRP) from Charlies account on its off-ledger balance sheet
b. Submits a payment on the XRP Ledger for the same amount (25,000 XRP), from Alpha Exchange's operational account to Charlies XRP Ledger account
b. Submits a payment on the XRP Ledger for the same amount (25,000 XRP), from Alpha Exchange's hot wallet to Charlies XRP Ledger account
<table>
@@ -511,7 +535,7 @@ Off-Ledger Balances</td>
<td>Alice</td>
<td>80,000</td>
<td></td>
<td>Operational</td>
<td>Hot</td>
<td><s>80,000</s>
<br>55,000</td>
</tr>
@@ -523,7 +547,7 @@ Off-Ledger Balances</td>
<td>Bob</td>
<td>50,000</td>
<td></td>
<td>Standby</td>
<td>Warm</td>
<td>0</td>
</tr>
<tr>
@@ -547,7 +571,7 @@ Off-Ledger Balances</td>
<td><s>50,000</s>
<br>25,000</td>
<td></td>
<td>Issuing</td>
<td>Cold</td>
<td>100,000</td>
</tr>
<tr>
@@ -573,3 +597,6 @@ Off-Ledger Balances</td>
<td></td>
</tr>
</table>
{% include '_snippets/tx-type-links.md' %}

View File

@@ -1,602 +0,0 @@
# Listing XRP as an Exchange
This document describes the steps that an exchange needs to take to list XRP. For details about other aspects of `rippled` and the XRP Ledger, see the [Ripple Developer Center](https://ripple.com/build).
## Alpha Exchange
For illustrative purposes, this document uses a fictitious business called _Alpha Exchange_ to explain the high-level steps required to list XRP. For the purposes of this document, Alpha Exchange:
* Currently specializes in listing BTC/USD
* Wants to add BTC/XRP and XRP/USD trading pairs
* Maintains balances for all of its customers
* Maintains balances for each of its supported currencies
### User Benefits
Alpha Exchange wants to list BTC/XRP and XRP/USD trading pairs partially because listing these pairs benefits its users. Specifically, this support wants to enable its users to:
* Deposit XRP _to_ Alpha Exchange _from_ the XRP Ledger
* Withdraw XRP _from_ Alpha Exchange _to_ the XRP Ledger
* Trade XRP with other currencies, such as BTC, USD, among others
## Prerequisites for Supporting XRP
To support XRP, Alpha Exchange must:
* Create and maintain new [accounts](#accounts)
* Create and maintain [balance sheets](#balance-sheets)
See also:
* [Gateway Compliance](tutorial-gateway-guide.html#gateway-compliance) — Gateways and exchanges are different, but exchanges should also ensure that they are complying with local regulations and reporting to the appropriate agencies.
* [Requirements for Sending to XRP Ledger](tutorial-gateway-guide.html#requirements-for-sending-to-xrp-ledger)
* [Requirements for Receiving from XRP Ledger](tutorial-gateway-guide.html#requirements-for-receiving-from-xrp-ledger)
* [Gateway Precautions](tutorial-gateway-guide.html#precautions)
### Partial Payments
Before integrating, exchanges should be aware of the [partial payments](reference-transaction-format.html#partial-payments) feature. This feature allows XRP Ledger users to send successful payments that reduce the amount received instead of increasing the `SendMax`. This feature can be useful for [returning payments](tutorial-gateway-guide.html#bouncing-payments) without incurring additional cost as the sender.
#### Partial Payments Warning
When the [tfPartialPayment flag](reference-transaction-format.html#payment-flags) is enabled, the `Amount` field **_is not guaranteed to be the amount received_**. The `delivered_amount` field of a payment's metadata indicates the amount of currency actually received by the destination account. When receiving a payment, use `delivered_amount` instead of the Amount field to determine how much your account received instead.
**Warning:** Be aware that malicious actors could exploit this. For more information, see [Partial Payments](concept-partial-payments.html).
### Accounts
XRP is held in _accounts_ (also referred to as _wallets_ or _addresses_ ) on the XRP Ledger. Accounts on the XRP Ledger are different than accounts on other blockchain ledgers, such as Bitcoin, where accounts incur little to no overhead. In the XRP Ledger, accounts can [never be deleted](concept-accounts.html#permanence-of-accounts), and each account must hold a separate [reserve of XRP](concept-reserves.html) that cannot be sent to others. For these reasons, Ripple recommends that institutions not create excessive or needless accounts.
<!-- STYLE_OVERRIDE: hot wallet, warm wallet, cold wallet, wallet -->
To follow Ripple's recommended best practices, Alpha Exchange should create at least two new accounts on the XRP Ledger. To minimize the risks associated with a compromised secret key, Ripple recommends creating [_cold_, _hot_, and _warm_ accounts](https://ripple.com/build/issuing-operational-addresses/) (these are sometimes referred to, respectively, as cold, hot, and warm wallets). The hot/warm/cold model is intended to balance security and convenience. Exchanges listing XRP should create the following accounts:
* A [_cold wallet_](concept-issuing-and-operational-addresses.html#issuing-address) to securely hold the majority of XRP and customers' funds. For exchanges, this is also the address to which its users send [deposits](#deposit-xrp-into-exchange). To provide optimal security, this account's secret key should be offline.
If a malicious actor compromises an exchange's cold wallet, the possible consequences are:
* The malicious actor gets full access to all XRP in the cold wallet.
* If the master key is compromised, the malicious actor can irrevocably take control of the cold wallet forever (by disabling the master key and setting a new regular key or signer list). This would also give the malicious actor control over all future XRP received by the cold wallet.
* If this happens, the exchange has to make a new cold wallet address and tell its customers the new address.
* If the regular key or signer list are comromised, the exchange can regain control of the cold wallet. However, some of a malicious actor's actions cannot easily be undone: <!-- STYLE_OVERRIDE: easily -->
* The malicious actor could issue currency in the XRP Ledger by using the cold wallet, but that currency should not be valued by anyone (unless the exchange explicitly stated it was also a gateway).
* If a malicious actor sets the asfRequireAuth flag for the account, that cannot be unset, although this only relates to issuing currency and should not affect an exchange that is not also a gateway. Any other settings a malicious actor sets or unsets with a master key can be reverted.
* One or more [_hot wallets_](concept-issuing-and-operational-addresses.html#operational-addresses) to conduct the day-to-day business of managing customers' XRP withdrawals and deposits. For example, with a hot wallet, exchanges can securely support these types of automated XRP transfers. Hot wallets need to be online to service instant withdrawal requests.
For more information about the possible consequences of a compromised hot wallet, see [Operational Account Compromise](concept-issuing-and-operational-addresses.html#operational-address-compromise).
* Optionally, one or more warm wallets to provide an additional layer of security between the cold and hot wallets. Unlike a hot wallet, the secret key of a warm wallet does not need to be online. Additionally, you can distribute the secret keys for the warm wallet to several different people and implement [multisigning](tutorial-multisign.html) to increase security.
For more information about the possible consequences of a compromised warm wallet, see [Standby Account Compromise](concept-issuing-and-operational-addresses.html#standby-address-compromise).
See also:
* ["Suggested Business Practices" in the _Gateway Guide_](tutorial-gateway-guide.html#suggested-business-practices)
* [Issuing and Operational Addresses](concept-issuing-and-operational-addresses.html)
* [Creating Accounts](reference-transaction-format.html#creating-accounts)
* [Reserves](concept-reserves.html)
### Balance Sheets
To custody its ccustomers' XRP, Alpha Exchange must track each customer's XRP balance and its own holdings. To do this, Alpha Exchange must create and maintain an additional balance sheet or accounting system. The following table illustrates what this balance sheet might look like.
The new XRP Ledger accounts (_Alpha Hot_, _Alpha Warm_, _Alpha Cold_) are in the *User* column of the *XRP Balances on XRP Ledger* table.
The *Alpha Exchange XRP Balances* table represents new, additional balance sheet. Alpha Exchanges software manages their users balances of XRP on this accounting system.
<table>
<tr>
<td><b><i>XRP Balances
on XRP Ledger</i></b></td>
<td></td>
<td></td>
<td><b><i>Alpha Exchange
XRP Balances</i></b></td>
<td></td>
<td></td>
</tr>
<tr>
<td><b>User</b></td>
<td><b>Balance</b></td>
<td></td>
<td><b>Acct #</b></td>
<td><b>User</b></td>
<td><b>Balance</b></td>
</tr>
<tr>
<td>Dave</td>
<td>25,000</td>
<td></td>
<td>123</td>
<td>Alice</td>
<td>0</td>
</tr>
<tr>
<td>Edward</td>
<td>45,000</td>
<td></td>
<td>456</td>
<td>Bob</td>
<td>0</td>
</tr>
<tr>
<td>Charlie</td>
<td>50,000</td>
<td></td>
<td>789</td>
<td>Charlie</td>
<td>0</td>
</tr>
<tr>
<td><i>Alpha Hot</i></td>
<td>0</td>
<td></td>
<td>...</td>
<td></td>
<td></td>
</tr>
<tr>
<td><i>Alpha Warm</i></td>
<td>0</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td><i>Alpha Cold</i></td>
<td>0</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td>...</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</table>
#### XRP Amounts
Amounts of XRP are represented on the XRP Ledger as an unsigned integer count of _drops_, where one XRP is 1,000,000 drops. Ripple recommends that software store XRP balances as integer amounts of drops, and perform integer arithmetic on these values. However, user interfaces should present balances in units of XRP.
One drop (.000001 XRP) cannot be further subdivided. Keep this in mind when calculating and displaying FX rates between XRP and other assets.
For more information, see [Specifying Currency Amounts](reference-rippled.html#specifying-currency-amounts).
#### On-Ledger and Off-Ledger
With exchanges like _Alpha Exchange_, XRP can be "on-ledger" or "off-ledger":
* **On-Ledger XRP**: XRP that can be queried through the public XRP Ledger by specifying the public [address](concept-accounts.html#addresses) of the XRP holder. The counterparty to these balances is the XRP Ledger. For more information, see [Currencies](reference-rippled.html#currencies).
* **Off-Ledger XRP**: XRP that is held by the accounting system of an exchange and can be queried through the exchange interface. Off-ledger XRP balances are credit-based. The counterparty is the exchange holding the XRP.
Off-ledger XRP balances are traded between the participants of an exchange. To support these trades, the exchange must hold a balance of _on-ledger XRP_ equal to the aggregate amount of _off-ledger XRP_ that it makes available for trade.
## Flow of Funds
The remaining sections describe how funds flow through the accounts managed by Alpha Exchange as its users begin to deposit, trade, and redeem XRP balances. To illustrate the flow of funds, this document uses the tables introduced in the ["Balance Sheets" section](#balance-sheets).
There are four main steps involved in an exchange's typical flow of funds:
1. [Deposit XRP into Exchange](#deposit-xrp-into-exchange)
2. [Rebalance XRP Holdings](#rebalance-xrp-holdings)
3. [Withdraw XRP from Exchange](#withdraw-xrp-from-exchange)
4. [Trade XRP on the Exchange](#trade-xrp-on-the-exchange)
This list does not include the [prerequisites](#prerequisites-for-supporting-xrp) required of an exchange.
At this point, _Alpha Exchange_ has created [hot, warm, and cold wallets](#accounts) on the XRP Ledger and added them to its balance sheet, but has not accepted any deposits from its users.
<table>
<tr>
<td><b><i>XRP Balances
on XRP Ledger</i></b></td>
<td></td>
<td></td>
<td><b><i>Alpha Exchange
XRP Balances</i></b></td>
<td></td>
<td></td>
</tr>
<tr>
<td><b>User</b></td>
<td><b>Balance</b></td>
<td></td>
<td><b>Acct #</b></td>
<td><b>User</b></td>
<td><b>Balance</b></td>
</tr>
<tr>
<td>Dave</td>
<td>25,000</td>
<td></td>
<td>123</td>
<td>Alice</td>
<td>0</td>
</tr>
<tr>
<td>Edward</td>
<td>45,000</td>
<td></td>
<td>456</td>
<td>Bob</td>
<td>0</td>
</tr>
<tr>
<td>Charlie</td>
<td>50,000</td>
<td></td>
<td>789</td>
<td>Charlie</td>
<td>0</td>
</tr>
<tr>
<td><i>Alpha Hot</i></td>
<td>0</td>
<td></td>
<td>...</td>
<td></td>
<td></td>
</tr>
<tr>
<td><i>Alpha Warm</i></td>
<td>0</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td><i>Alpha Cold</i></td>
<td>0</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td>...</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</table>
### Deposit XRP into Exchange
To track [off-ledger XRP balances](#on-ledger-and-off-ledger), exchanges need to create new [balance sheets](#balance-sheets) (or similar accounting systems). The following table illustrates the balance changes that take place on Alpha Exchange's new balance sheet as users begin to deposit XRP.
A user named Charlie wants to deposit 50,000 XRP to Alpha Exchange. Doing this involves the following steps:
1. Charlie submits a payment of 50,000 XRP (by using [RippleAPI](reference-rippleapi.html) or similar software) to Alpha Exchange's [cold wallet](#accounts).
a. Charlie adds an identifier (in this case, `789`) to the payment to associate it with his account at Alpha Exchange. This is called a [_destination tag_](tutorial-gateway-guide.html#source-and-destination-tags). (To use this, Alpha Exchange should have set the asfRequireDest flag on all of its accounts to require all incoming payments to have a destination tag like Charlie's. For more information, see [AccountSet Flags](reference-transaction-format.html#accountset-flags)).
2. The software at Alpha Exchange detects the incoming payment, and recognizes `789` as the destination tag for Charlies account.
3. When it detects the incoming payment, Alpha Exchange's software updates its balance sheet to indicate that the 50,000 XRP it received is controlled by Charlie.
Charlie can now use up to 50,000 XRP on the exchange. For example, he can create offers to trade XRP with BTC or any of the other currencies Alpha Exchange supports.
<table>
<tr>
<td><b><i>XRP Balances
on XRP Ledger</i></b></td>
<td></td>
<td></td>
<td><b><i>Alpha Exchange
XRP Balances</i></b></td>
<td></td>
<td></td>
</tr>
<tr>
<td><b>User</b></td>
<td><b>Balance</b></td>
<td></td>
<td><b>Acct #</b></td>
<td><b>User</b></td>
<td><b>Balance</b></td>
</tr>
<tr>
<td>Dave</td>
<td>25,000</td>
<td></td>
<td>123</td>
<td>Alice</td>
<td>0</td>
</tr>
<tr>
<td>Edward</td>
<td>45,000</td>
<td></td>
<td>456</td>
<td>Bob</td>
<td>0</td>
</tr>
<tr>
<td>Charlie</td>
<td><s>100,000</s>
<br>50,000</td>
<td></td>
<td>789</td>
<td>Charlie</td>
<td><s>0</s>
<br>50,000</td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td>Alpha Hot</td>
<td>0</td>
<td></td>
<td>...</td>
<td></td>
<td></td>
</tr>
<tr>
<td>Alpha Warm</td>
<td>0</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td>Alpha Cold</td>
<td><s>0</s>
<br>50,000</td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td>...</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
</table>
### Trade XRP on the Exchange
Alpha Exchange users (like Charlie) can trade credit-based balances on Alpha Exchange. Alpha Exchange should keep track of user balances on its new balance sheet as these trades are made. These trades are _off-ledger_ and independent from the XRP Ledger, so the balance changes are not recorded on the XRP Ledger.
Customers who hold XRP in their own XRP Ledger accounts can also use the distributed exchange built into the XRP Ledger to trade currencies issued by gateways. For more information about trading _on_ the XRP Ledger, see [Lifecycle of an Offer](reference-transaction-format.html#lifecycle-of-an-offer).
### Rebalance XRP Holdings
Exchanges can adjust the balances between their hot and cold wallets at any time. Each balance adjustment consumes a [transaction cost](concept-transaction-cost.html), but does not otherwise affect the aggregate balance of all the accounts. The aggregate, on-ledger balance should always exceed the total balance available for trade on the exchange. (The excess should be enough to cover the XRP Ledger's transaction costs.)
The following table demonstrates a balance adjustment of 80,000 XRP (via a [_payment_](reference-transaction-format.html#payment) on the XRP Ledger) between Alpha Exchange's cold wallet and its hot wallet, where the cold wallet was debited and the hot wallet was credited. If the payment were reversed (debiting the hot wallet and crediting the cold wallet), the hot wallet balance would decrease. Balance adjustments like these allow an exchange to limit the risks associated with holding XRP in online hot wallets.
<table>
<tr>
<td><b><i>Alpha Exchange XRP
Off-Ledger Balances</i></b></td>
<td></td>
<td></td>
<td></td>
<td><b><i>Alpha Exchange XRP On-Ledger Balances</i></b></td>
<td></td>
</tr>
<tr>
<td><b>Acct #</b></td>
<td><b>User</b></td>
<td><b>Balance</b></td>
<td></td>
<td><b>XRP Ledger Account</b></td>
<td><b>Balance</b></td>
</tr>
<tr>
<td>123</td>
<td>Alice</td>
<td>80,000</td>
<td></td>
<td>Hot</td>
<td><s>0</s>
<br>80,000</td>
</tr>
<tr>
<td>456</td>
<td>Bob</td>
<td>50,000</td>
<td></td>
<td>Warm</td>
<td>0</td>
</tr>
<tr>
<td>….</td>
<td></td>
<td></td>
<td></td>
<td>….</td>
<td></td>
</tr>
<tr>
<td>789</td>
<td>Charlie</td>
<td>50,000</td>
<td></td>
<td>Cold</td>
<td><s>180,000</s>
<br>100,000</td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td>...</td>
<td></td>
<td></td>
<td></td>
<td>...</td>
<td></td>
</tr>
</table>
### Withdraw XRP from Exchange
Withdrawals allow an exchange's users to move XRP from the exchange's off-ledger balance sheet to an account on the XRP Ledger.
In this example, Charlie withdraws 25,000 XRP from Alpha Exchange. This involves the following steps:
1. Charlie initiates the process on Alpha Exchanges website. He provides instructions to transfer 25,000 XRP to a specific account on the XRP Ledger (named "Charlie XRP Ledger" in the following table).
2. In response to Charlies instructions, Alpha Exchange does the following:
a. Debits the amount (25,000 XRP) from Charlies account on its off-ledger balance sheet
b. Submits a payment on the XRP Ledger for the same amount (25,000 XRP), from Alpha Exchange's hot wallet to Charlies XRP Ledger account
<table>
<tr>
<td><b><i>XRP Ledger On-Ledger XRP Balances</td>
<td></td>
<td></td>
<td><b><i>Alpha Exchange XRP
Off-Ledger Balances</td>
<td></td>
<td></td>
<td></td>
<td><b><i>Alpha Exchange XRP On-Ledger Balances</td>
<td></td>
</tr>
<tr>
<td><b>User</td>
<td><b>Balance</td>
<td></td>
<td><b>Acct #</td>
<td><b>User</td>
<td><b>Balance</td>
<td></td>
<td><b>XRP Ledger Account</td>
<td><b>Balance</td>
</tr>
<tr>
<td>Dave</td>
<td>25,000</td>
<td></td>
<td>123</td>
<td>Alice</td>
<td>80,000</td>
<td></td>
<td>Hot</td>
<td><s>80,000</s>
<br>55,000</td>
</tr>
<tr>
<td>Edward</td>
<td>45,000</td>
<td></td>
<td>456</td>
<td>Bob</td>
<td>50,000</td>
<td></td>
<td>Warm</td>
<td>0</td>
</tr>
<tr>
<td>….</td>
<td></td>
<td></td>
<td>….</td>
<td></td>
<td></td>
<td></td>
<td>….</td>
<td></td>
</tr>
<tr>
<td>Charlie XRP Ledger</td>
<td><s>50,000</s>
<br>75,000</td>
<td></td>
<td>789</td>
<td>Charlie</td>
<td><s>50,000</s>
<br>25,000</td>
<td></td>
<td>Cold</td>
<td>100,000</td>
</tr>
<tr>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
<td></td>
</tr>
<tr>
<td>...</td>
<td></td>
<td></td>
<td>...</td>
<td></td>
<td></td>
<td></td>
<td>...</td>
<td></td>
</tr>
</table>
{% include '_snippets/tx-type-links.md' %}

View File

@@ -0,0 +1,3 @@
# XRP Ledger Businesses
This section demonstrates how to follow various best practices for running businesses that interface with the XRP Ledger, including exchanges listing XRP, gateways issuing currency in the XRP Ledger, and others.

View File

@@ -59,6 +59,8 @@ pages:
targets:
- local
# Concepts ---------------------------------------------------------------------
- name: Concepts
funnel: Docs
doc_type: Concepts
@@ -109,6 +111,7 @@ pages:
funnel: Docs
doc_type: Concepts
category: Payment System Basics
template: template-landing-children.html
targets:
- local
@@ -140,122 +143,249 @@ pages:
targets:
- local
- md: concepts/complex-payment-types/complex-payment-types.md
html: complex-payment-types.html
funnel: Docs
doc_type: Concepts
category: Complex Payment Types
template: template-landing-children.html
targets:
- local
- md: concepts/complex-payment-types/checks.md
html: checks.html
funnel: Docs
doc_type: Concepts
category: Complex Payment Types
targets:
- local
- md: concepts/complex-payment-types/escrow.md
html: escrow.html
funnel: Docs
doc_type: Concepts
category: Complex Payment Types
targets:
- local
- md: concepts/complex-payment-types/partial-payments.md
html: partial-payments.html
funnel: Docs
doc_type: Concepts
category: Complex Payment Types
targets:
- local
# TODO: payment channels concept
- md: concepts/issued-currencies/issued-currencies.md
html: issued-currencies.html
funnel: Docs
doc_type: Concepts
category: Issued Currencies
template: template-landing-children.html
targets:
- local
# TODO: "Trust Lines and Issuing" (see gateway guide, tx reference on "trust limits" etc.)
- md: concepts/issued-currencies/authorized-trust-lines.md
html: authorized-trust-lines.html
funnel: Docs
doc_type: Concepts
category: Issued Currencies
targets:
- local
# TODO: Freezes, Rippling, Transfer Fees, Paths, Demurrage
- md: concepts/decentralized-exchange/decentralized-exchange.md
html: decentralized-exchange.html
funnel: Docs
doc_type: Concepts
category: Decentralized Exchange
template: template-landing-children.html
targets:
- local
# TODO: Offers, Tick Size, Autobridging, Offer Preference (all compiled from different sources)
- md: concepts/consensus-network/consensus-network.md
html: consensus-network.html
funnel: Docs
doc_type: Concepts
category: Consensus Network
template: template-landing-children.html
targets:
- local
# TODO: consensus principles & rules, validators & UNLs
- md: concepts/consensus-network/amendments.md
html: amendments.html
funnel: Docs
doc_type: Concepts
category: Consensus Network
targets:
- local
# TODO: fee voting, consensus research, pseudo-transactions, parallel networks
- md: concepts/the-rippled-server/the-rippled-server.md
html: the-rippled-server.html
funnel: Docs
doc_type: Concepts
category: The rippled Server
targets:
- local
# TODO: history sharding, stand-alone mode, clustering, peer protocol
# Tutorials --------------------------------------------------------------------
- md: tutorials/tutorials.md
html: tutorials.html
funnel: Docs
doc_type: Tutorials
template: template-landing-children.html
blurb: Get step-by-step guidance to perform common tasks with the XRP Ledger.
targets:
- local
- md: tutorials/get-started/get-started.md
html: get-started.html
funnel: Docs
doc_type: Tutorials
category: Get Started
template: template-landing-children.html
targets:
- local
# TODO: Get Started with the rippled API, Send a Transaction with the rippled API
- md: tutorials/get-started/get-started-with-rippleapi-for-javascript.md
html: get-started-with-rippleapi-for-javascript.html
funnel: Docs
doc_type: Tutorials
category: Get Started
targets:
- local
# TODO: Get Started with API Tools
- md: tutorials/use-simple-xrp-payments/use-simple-xrp-payments.md
html: use-simple-xrp-payments.html
funnel: Docs
doc_type: Tutorials
category: Use Simple XRP Payments
template: template-landing-children.html
targets:
- local
# TODO: "Send XRP"
- md: tutorials/use-simple-xrp-payments/reliable-transaction-submission.md
html: reliable-transaction-submission.html
funnel: Docs
doc_type: Tutorials
category: Use Simple XRP Payments
targets:
- local
# TODO: Cancel or Skip a Transaction, Look Up Transaction Results
- md: tutorials/manage-account-settings/manage-account-settings.md
html: manage-account-settings.html
funnel: Docs
doc_type: Tutorials
category: Manage Account Settings
template: template-landing-children.html
targets:
- local
# TODO: "Get an Account", "Configure a Regular Key Pair", "Use Deposit Authorization to Block Unwanted Payments", "Configure Multi-Signing"
- md: tutorials/use-complex-payment-types/use-complex-payment-types.md
html: use-complex-payment-types.html
funnel: Docs
doc_type: Tutorials
category: Use Complex Payment Types
template: template-landing-children.html
targets:
- local
# TODO: split up "use escrows"
#TODO: split concept info off of the paychan tutorial
- md: tutorials/use-complex-payment-types/use-payment-channels.md
html: use-payment-channels.html
funnel: Docs
doc_type: Tutorials
category: Use Complex Payment Types
targets:
- local
- md: tutorials/use-complex-payment-types/use-checks/use-checks.md
html: use-checks.html
funnel: Docs
doc_type: Tutorials
category: Use Complex Payment Types
subcategory: Use Checks
template: template-landing-children.html
targets:
- local
- md: tutorials/use-complex-payment-types/use-checks/send-a-check.md
html: send-a-check.html
funnel: Docs
doc_type: Tutorials
category: Use Complex Payment Types
subcategory: Use Checks
targets:
- local
# TODO: other 5 checks tutorials
# TODO: "Send a Cross-Currency Payment"
- md: tutorials/manage-issued-currencies/manage-issued-currencies.md
html: manage-issued-currencies.html
funnel: Docs
doc_type: Tutorials
category: Manage Issued Currencies
template: template-landing-children.html
targets:
- local
# TODO: Set up issuing/operational addresses, monitor changes to balances,
# freeze, enable/disable rippling, set transfer fees, use auth'd trust lines
- md: tutorials/xrp-ledger-businesses/xrp-ledger-businesses.md
html: xrp-ledger-businesses.html
funnel: Docs
doc_type: Tutorials
category: XRP Ledger Businesses
template: template-landing-children.html
targets:
- local
# TODO: list XRP as an exchange, become a gateway
# TODO: identify your accounts with ripple.txt (to come later)
- md: tutorials/manage-the-rippled-server/manage-the-rippled-server.md
html: manage-the-rippled-server.html
funnel: Docs
doc_type: Tutorials
category: Manage the rippled Server
template: template-landing-children.html
targets:
- local
# TODO: install rippled, troubleshoot rippled, build & run on ubuntu,
# run a validator, run in stand-alone mode, set up private peers, run in
# a cluster, capacity planning
# - name: Payment System
# funnel: Docs
# doc_type: Concepts
# category: Payment System
# html: concept-payment-system.html
# template: template-landing-children.html
# targets:
# - local
#
# - md: concept-accounts.md
# funnel: Docs
# doc_type: Concepts
# category: Payment System
# subcategory: Accounts
# targets:
# - local
#
# - md: concept-depositauth.md
# funnel: Docs
# doc_type: Concepts
# category: Payment System
# subcategory: Accounts
# targets:
# - local
#
# - md: concept-transaction-cost.md
# funnel: Docs
# doc_type: Concepts
# category: Payment System
# targets:
# - local
#
# - md: concept-money.md
# funnel: Docs
# doc_type: Concepts
# category: Payment System
# targets:
# - local
#
# - md: concept-authorized-trust-lines.md
# funnel: Docs
# doc_type: Concepts
# category: Payment System
# subcategory: Accounts
# targets:
# - local
#
# - name: Consensus Network
# funnel: Docs
# doc_type: Concepts
# category: Consensus Network
# html: concept-consensus-network.html
# template: template-landing-children.html
# targets:
# - local
#
# - md: concept-amendments.md
# funnel: Docs
# doc_type: Concepts
# category: Consensus Network
# targets:
# - local
#
# - md: concept-fee-voting.md
# funnel: Docs
# doc_type: Concepts
# category: Consensus Network
# targets:
# - local
#
# - name: Tutorials #TODO: real page content
# funnel: Docs
# doc_type: Tutorials
# template: template-landing-children.html
# blurb: Get step-by-step guidance to perform common tasks with the XRP Ledger.
# targets:
# - local
#
# - name: Send and Receive Money
# funnel: Docs
# doc_type: Tutorials
# category: Send and Receive Money
# template: template-landing-children.html
# targets:
# - local
#
# - md: tutorial-reliable-transaction-submission.md
# funnel: Docs
# doc_type: Tutorials
# category: Send and Receive Money
# targets:
# - local
#
# - md: tutorial-checks-send.md
# funnel: Docs
# doc_type: Tutorials
# category: Send and Receive Money
# targets:
# - local
#
# - name: Manage the rippled Server
# funnel: Docs
# doc_type: Tutorials
# category: Manage the rippled Server
# template: template-landing-children.html
# targets:
# - local
#
# - md: tutorial-rippled-setup.md
# funnel: Docs
# doc_type: Tutorials
# category: Manage the rippled Server
# targets:
# - local
#
# - name: References
# funnel: Docs
# doc_type: References