{% extends "base.html.jinja" %}

{% block bodyclasses %}rpc-tool{% endblock %}

{% block main %}
<section class="container-fluid pt-3 p-md-3">
  <h1>RPC Tool</h1>
  <div class="content">

  <p>This is a debug tool for printing raw information about an account (by classic address), a transaction (by hash) or a ledger (by sequence number).</p>

  <form id="account-entry">
  <fieldset class="form-group"><input id="target" class="form-control" required="" type="text" placeholder="XRP Ledger address, transaction ID, or ledger index" />
  <span class="help-block"><small>{% trans %}Try an account like <em>rf1BiGeXwwQoi8Z2ueFYTEXSwuJYfV2Jpn</em>.{% endtrans %}</small></span>
  <button class="btn btn-primary">{% trans %}Get info{% endtrans %}</button></fieldset>
  </form>
  <div id="result">
    <h2>{% trans %}Result{% endtrans %}</h2>
    <div id="progress" class="progress">
    <div class="progress-bar progress-bar-striped progress-bar-animated" role="progressbar"></div>
    </div>
    <div id="error" class="devportal-callout warning"></div>
    <ul id="links" class="nav nav-pills">
         <li><a id="permalink" href="#" target="_blank" rel="noopener">{% trans %}Permalink{% endtrans %}</a></li>
         <li><a id="explorerlink" href="#" target="_blank" rel="noopener">{% trans %}Explorer{% endtrans %}</a></li>
    </ul>
    <div class="group group-tx">
    <h3><a href="tx.html">tx</a></h3>
    <ul class="tools nav nav-pills">
         <li><a class="tx-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="tx-collapse">{% trans %}collapse all{% endtrans %}</a></li>
    </ul>
    <pre id="tx_info" class="json"></pre>
    <ul class="tools nav nav-pills">
         <li><a class="tx-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="tx-collapse">{% trans %}collapse all{% endtrans %}</a></li>
    </ul>
    </div>

    <div class="group group-account">
    <h3><a href="account_info.html">account_info</a></h3>
    <pre id="account_info" class="json"></pre>
    <h3><a href="account_lines.html">account_lines</a></h3>
    <ul class="tools nav nav-pills">
         <li><a class="account-lines-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="account-lines-collapse">{% trans %}collapse all{% endtrans %}</a></li>
    </ul>
    <pre id="account_lines" class="json"></pre>
    <ul class="tools nav nav-pills">
         <li><a class="account-lines-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="account-lines-collapse">{% trans %}collapse all{% endtrans %}</a></li>
    </ul>
    <h3><a href="account_tx.html">account_tx</a> (last 20)</h3>
    <ul class="tools nav nav-pills">
         <li><a class="account-tx-expand-tx">{% trans %}expand tx{% endtrans %}</a></li>
         <li><a class="account-tx-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="account-tx-collapse">{% trans %}collapse all{% endtrans %}</a></li>
         <li><a class="account-tx-more">{% trans %}next 20{% endtrans %}</a></li>
         <li><a class="account-tx-back">{% trans %}prev 20{% endtrans %}</a></li>
    </ul>
    <pre id="account_tx" class="json"></pre>
    <ul class="tools nav nav-pills">
         <li><a class="account-tx-expand-tx">{% trans %}expand tx{% endtrans %}</a></li>
         <li><a class="account-tx-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="account-tx-collapse">{% trans %}collapse all{% endtrans %}</a></li>
         <li><a class="account-tx-more">{% trans %}next 20{% endtrans %}</a></li>
         <li><a class="account-tx-back">{% trans %}prev 20{% endtrans %}</a></li>
    </ul>
    <h3><a href="account_objects.html">account_objects</a></h3>
    <ul class="tools nav nav-pills">
         <li><a class="account-objects-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="account-objects-collapse">{% trans %}collapse all{% endtrans %}</a></li>
    </ul>
    <pre id="account_objects" class="json"></pre>
    <ul class="tools nav nav-pills">
         <li><a class="account-objects-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="account-objects-collapse">{% trans %}collapse all{% endtrans %}</a></li>
    </ul>
    </div>

    <div class="group group-ledger">
    <h3><a href="ledger.html">ledger</a></h3>
    <ul class="tools nav nav-pills">
         <li><a class="ledger-expand-tx">{% trans %}expand tx{% endtrans %}</a></li>
         <li><a class="ledger-tx-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="ledger-tx-collapse">{% trans %}collapse all{% endtrans %}</a></li>
    </ul>
    <pre id="ledger_info" class="json"></pre>
    <ul class="tools nav nav-pills">
         <li><a class="ledger-tx-expand-tx">{% trans %}expand tx{% endtrans %}</a></li>
         <li><a class="ledger-tx-expand">{% trans %}expand all{% endtrans %}</a></li>
         <li><a class="ledger-tx-collapse">{% trans %}collapse all{% endtrans %}</a></li>
    </ul>
    </div>

    </div>
  </div>
</section>
{% endblock %}

{% block endbody %}
  {{currentpage.ripple_lib_tag}}
  <script type='text/javascript' src='assets/js/rpc-tool.js'></script>
{% endblock %}

{% block analytics %}
    <script type="application/javascript">
    window.dataLayer = window.dataLayer || [];
    window.dataLayer.push({
      "event": "page_info",
      "page_type": "Tool",
      "page_group": "Docs",
      "page_labels": {{currentpage.labels or []}}
    })
    </script>
{% endblock analytics %}
