raiden-ts
Version:
Raiden Light Client Typescript/Javascript SDK
236 lines • 11.3 kB
HTML
<html class="default no-js">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Accounts | raiden-ts - v3.1.1</title>
<meta name="description" content="Documentation for raiden-ts - v3.1.1">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="../../assets/css/main.css">
<link rel="stylesheet" href="../../assets/css/pages.css">
<script async src="../../assets/js/search.js" id="search-script"></script>
</head>
<body>
<header>
<div class="tsd-page-toolbar">
<div class="container">
<div class="table-wrap">
<div class="table-cell" id="tsd-search" data-index="../../assets/js/search.json" data-base="../..">
<div class="field">
<label for="tsd-search-field" class="tsd-widget search no-caption">Search</label>
<input id="tsd-search-field" type="text" />
</div>
<ul class="results">
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
<a href="../../index.html" class="title">raiden-ts - v3.1.1</a>
</div>
<div class="table-cell" id="tsd-widgets">
<div id="tsd-filter">
<a href="#" class="tsd-widget options no-caption" data-toggle="options">Options</a>
<div class="tsd-filter-group">
<div class="tsd-select" id="tsd-filter-visibility">
<span class="tsd-select-label">All</span>
<ul class="tsd-select-list">
<li data-value="public">Public</li>
<li data-value="protected">Public/Protected</li>
<li data-value="private" class="selected">All</li>
</ul>
</div>
<input type="checkbox" id="tsd-filter-inherited" checked />
<label class="tsd-widget" for="tsd-filter-inherited">Inherited</label>
</div>
</div>
<a href="#" class="tsd-widget menu no-caption" data-toggle="menu">Menu</a>
</div>
</div>
</div>
</div>
<div class="tsd-page-title">
<div class="container">
<ul class="tsd-breadcrumb">
<li>
<a href="../../modules.html">raiden-ts - v3.1.1</a>
</li>
<li>
<a href="using-dapp.html">Using the Raiden dApp</a>
</li>
<li>
<a href="account.html">Accounts</a>
</li>
</ul>
<h1>Accounts</h1>
</div>
</div>
</header>
<div class="container container-main">
<div class="row">
<div class="col-8 col-content">
<div class="tsd-panel tsd-typography">
<a href="#managing-various-account-related-functions" id="managing-various-account-related-functions" style="color: inherit; text-decoration: none;">
<h1>Managing Various Account Related Functions</h1>
</a>
<p>As we saw previously there are two accounts, our main account and the raiden account.</p>
<ul>
<li><em>Main Account</em> is your current MetaMask account and the account which is used for generating the Subkey or Raiden account.</li>
<li>The <em>Raiden Account</em> is generated deterministically on each start of the Light Client by letting the <em>Main Account</em> sign a combination of the below information:<ol>
<li><strong>network id</strong> (Goerli, Mainnet, etc.)</li>
<li><strong>Raiden dApp URL</strong> (i.e. <code>https://lightclient.raiden.network/staging</code>, <code>https://lightclient.raiden.network</code> or even <code>http://localhost:8080</code>)</li>
</ol>
</li>
</ul>
<p>The <em>Raiden Account</em> is used to sign the <em>balance proofs</em> and any other messages when making micro-payments on the Raiden network. The address of the Raiden Account is used when sending and receiving micro-payments in the Raiden network.</p>
<a href="#account-screen" id="account-screen" style="color: inherit; text-decoration: none;">
<h2>Account Screen</h2>
</a>
<p>Access the account screen by clicking the identicon on the top right hand corner of the dApp.</p>
<p><img src="https://user-images.githubusercontent.com/15123108/102340538-ac2d8d00-3fbc-11eb-83bd-b5624a3c574f.png" alt="account-screen" title="Account Screen"></p>
<p>On the account screen the address of the <em>Raiden Account</em>, the <em>Main Account</em> ETH Balance as well as <em>RAIDEN Account</em> ETH Balance is displayed along with the following menu items:</p>
<a href="#transfer-eth" id="transfer-eth" style="color: inherit; text-decoration: none;">
<h3>Transfer ETH</h3>
</a>
<p>ETH is required for withdrawing either of the following tokens from a Raiden Account back to the Main Account:</p>
<ul>
<li><em>Service tokens</em> (like <em>SVT</em> on Goerli or <em>RDN</em> on Mainnet) or</li>
<li>tokens that have been used to open any channels, i.e. (<em>TTT</em> or any other TestToken on testnets or <em>DAI</em> and <em>WETH</em> on Mainnet).</li>
</ul>
<p>You can transfer ETH in either direction, from your Main Account to you Raiden Account or vice versa.</p>
<p><img src="https://user-images.githubusercontent.com/15123108/102342273-0596bb80-3fbf-11eb-952c-c65b61a9d47a.png" alt="transfer-eth-account" title="Transfer ETH Account"></p>
<a href="#withdraw-tokens" id="withdraw-tokens" style="color: inherit; text-decoration: none;">
<h3>Withdraw Tokens</h3>
</a>
<p>Tokens are displayed on this screen if:</p>
<ol>
<li>Any tokens have been withdrawn from a channel.</li>
<li>Any tokens have been withdrawn from the UDC.</li>
</ol>
<p><img src="https://user-images.githubusercontent.com/15123108/102354467-9de96c00-3fd0-11eb-8f3e-27a473abe335.png" alt="withdraw-tokens" title="Withdraw tokens"></p>
<a href="#manage-udc-tokens" id="manage-udc-tokens" style="color: inherit; text-decoration: none;">
<h3>Manage UDC Tokens</h3>
</a>
<p>This screen shows the amount of service tokens deposited in the <em>UDC</em> which are used for paying the Raiden services.</p>
<p><img src="https://user-images.githubusercontent.com/15123108/102347600-9fae3200-3fc6-11eb-9815-212095be0b96.png" alt="manage-udc-tokens" title="Manage UDC Tokens"></p>
<p>On the UDC screen you can choose to:</p>
<ol>
<li><em><em>Deposit</em></em>: This is an on-chain transaction in which to top-up the service token balance.</li>
<li><em><em>Withdraw</em></em>: This is an on-chain transaction which would withdraw service tokens back on to the <em>Raiden Account</em>. These tokens will appear on the <em>Withdraw Tokens</em> screen from where they can be transfered back on to the <em>Main Account</em>.</li>
</ol>
<a href="#backup-state" id="backup-state" style="color: inherit; text-decoration: none;">
<h3>Backup State</h3>
</a>
<p>All the off-chain transfers, ethereum events data along with all the account information except the <em>private key</em> is held in the indexed database of the browser that you run the raiden dApp. You could use this backup data to start off in some other browser on some other machine and uploading the data again.
<img src="https://user-images.githubusercontent.com/15123108/102349148-e866ea80-3fc8-11eb-99c1-d78b8ae6a6ba.png" alt="backup-state" title="Backup State"></p>
<a href="#download-logs" id="download-logs" style="color: inherit; text-decoration: none;">
<h3>Download logs</h3>
</a>
<p>This triggers a download of the logs for the dApp. You can use this anytime you encounter an error and open an <a href="https://github.com/raiden-network/light-client/issues/new/choose">issue</a>.</p>
</div>
</div>
<div class="col-4 col-menu menu-sticky-wrap menu-highlight">
<nav class="tsd-navigation primary">
<ul>
<li class="label pp-nav pp-group">
<span>Get <wbr>Started</span>
</li>
<li class=" pp-nav pp-page">
<a href="../Get Started/prerequisites.html">Prerequisites</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Get Started/installing-sdk.html">Installing the SDK</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Get Started/installing-dapp.html">Installing the d<wbr>App</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Get Started/connecting.html">Connecting</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Get Started/private-chain.html">Private chains</a>
</li>
<li class="label pp-nav pp-group">
<span>Usage</span>
</li>
<li class=" pp-nav pp-page">
<a href="../Usage/opening-channel.html">Opening a channel</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Usage/funding-channel.html">Funding a channel</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Usage/direct-transfer.html">Transferring</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Usage/closing-channel.html">Closing a channel</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Usage/settling-channel.html">Settling a channel</a>
</li>
<li class="label pp-nav pp-group">
<span>Using the <wbr>Raiden d<wbr>App</span>
</li>
<li class=" pp-nav pp-page">
<a href="using-dapp.html">Overview</a>
</li>
<li class=" pp-nav pp-page">
<a href="navigate-dapp.html">Navigate the <wbr>Raiden d<wbr>App</a>
</li>
<li class=" pp-nav pp-page">
<a href="hub-selection-channel-opening.html">Hub <wbr>Selection and <wbr>Channel <wbr>Opening</a>
</li>
<li class=" pp-nav pp-page">
<a href="transfers.html">Transfers</a>
</li>
<li class=" pp-nav pp-page">
<a href="channels.html">Channels</a>
</li>
<li class="current pp-nav pp-page">
<a href="account.html">Accounts</a>
</li>
<li class="label pp-nav pp-group">
<span>Using the <wbr>Raiden CLI</span>
</li>
<li class=" pp-nav pp-page">
<a href="../Using the Raiden CLI/README.html">Overview</a>
</li>
<li class=" pp-nav pp-page">
<a href="../Using the Raiden CLI/raspberrypi.html">Running raiden-<wbr>cli on the raspberry pi</a>
</li>
<li class="label pp-nav pp-group">
<span>API</span>
</li>
<li class=" ">
<a href="../../modules.html">Exports</a>
</li>
</ul>
</nav>
<nav class="tsd-navigation secondary menu-sticky">
<ul class="before-current">
</ul>
</nav>
</div>
</div>
</div>
<footer class="with-border-bottom">
<div class="container">
<h2>Legend</h2>
<div class="tsd-legend-group">
<ul class="tsd-legend">
<li class="tsd-kind-constructor tsd-parent-kind-class"><span class="tsd-kind-icon">Constructor</span></li>
<li class="tsd-kind-property tsd-parent-kind-class"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-class"><span class="tsd-kind-icon">Method</span></li>
</ul>
<ul class="tsd-legend">
<li class="tsd-kind-property tsd-parent-kind-interface"><span class="tsd-kind-icon">Property</span></li>
<li class="tsd-kind-method tsd-parent-kind-interface"><span class="tsd-kind-icon">Method</span></li>
</ul>
</div>
</div>
</footer>
<div class="container tsd-generator">
<p>Generated using <a href="https://typedoc.org/" target="_blank">TypeDoc</a></p>
</div>
<div class="overlay"></div>
<script src="../../assets/js/main.js"></script>
</body>
</html>