Commit 1bd3966e authored by Johan Nordberg's avatar Johan Nordberg

Version 0.8.5

parent d35f348c
......@@ -354,6 +354,7 @@ declare module 'dsteem/steem/serializer' {
* You acknowledge that this software is not designed, licensed or intended for use
* in the design, construction, operation or maintenance of any military facility.
*/
import * as ByteBuffer from 'bytebuffer';
import { PublicKey } from 'dsteem/crypto';
import { Asset } from 'dsteem/steem/asset';
import { HexBuffer } from 'dsteem/steem/misc';
......@@ -2153,7 +2154,7 @@ declare module 'dsteem/client' {
private timeout;
private backoff;
/**
* @param address The address to the Steem RPC server, e.g. `https://steemd.steemit.com`.
* @param address The address to the Steem RPC server, e.g. `https://api.steemit.com`.
* @param options Client options.
*/
constructor(address: string, options?: ClientOptions);
......
This diff is collapsed.
No preview for this file type
This diff is collapsed.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -84,6 +84,12 @@
<li class="tsd-kind-constructor tsd-parent-kind-class"><a href="blockchain.html#constructor" class="tsd-kind-icon">constructor</a></li>
</ul>
</section>
<section class="tsd-index-section ">
<h3>Properties</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-property tsd-parent-kind-class"><a href="blockchain.html#client" class="tsd-kind-icon">client</a></li>
</ul>
</section>
<section class="tsd-index-section ">
<h3>Methods</h3>
<ul class="tsd-index-list">
......@@ -127,6 +133,19 @@
</ul>
</section>
</section>
<section class="tsd-panel-group tsd-member-group ">
<h2>Properties</h2>
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
<a name="client" class="tsd-anchor"></a>
<h3>client</h3>
<div class="tsd-signature tsd-kind-icon">client<span class="tsd-signature-symbol">:</span> <a href="client.html" class="tsd-signature-type">Client</a></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/jnordberg/dsteem/blob/master/src/helpers/blockchain.ts#L70">helpers/blockchain.ts:70</a></li>
</ul>
</aside>
</section>
</section>
<section class="tsd-panel-group tsd-member-group ">
<h2>Methods</h2>
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
......@@ -304,7 +323,7 @@
<a name="getcurrentblocknum" class="tsd-anchor"></a>
<h3>get<wbr>Current<wbr>Block<wbr>Num</h3>
<ul class="tsd-signatures tsd-kind-method tsd-parent-kind-class">
<li class="tsd-signature tsd-kind-icon">get<wbr>Current<wbr>Block<wbr>Num<span class="tsd-signature-symbol">(</span>mode<span class="tsd-signature-symbol">?: </span><span class="tsd-signature-type">BlockchainMode.Irreversible</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">BlockchainMode.Latest</span><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span></li>
<li class="tsd-signature tsd-kind-icon">get<wbr>Current<wbr>Block<wbr>Num<span class="tsd-signature-symbol">(</span>mode<span class="tsd-signature-symbol">?: </span><a href="../enums/blockchainmode.html" class="tsd-signature-type">BlockchainMode</a><span class="tsd-signature-symbol">)</span><span class="tsd-signature-symbol">: </span><span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span></li>
</ul>
<ul class="tsd-descriptions">
<li class="tsd-description">
......@@ -321,7 +340,7 @@
<h4 class="tsd-parameters-title">Parameters</h4>
<ul class="tsd-parameters">
<li>
<h5><span class="tsd-flag ts-flagDefault value">Default value</span> mode: <span class="tsd-signature-type">BlockchainMode.Irreversible</span><span class="tsd-signature-symbol"> | </span><span class="tsd-signature-type">BlockchainMode.Latest</span><span class="tsd-signature-symbol"> =&nbsp;BlockchainMode.Irreversible</span></h5>
<h5><span class="tsd-flag ts-flagDefault value">Default value</span> mode: <a href="../enums/blockchainmode.html" class="tsd-signature-type">BlockchainMode</a><span class="tsd-signature-symbol"> =&nbsp;BlockchainMode.Irreversible</span></h5>
</li>
</ul>
<h4 class="tsd-returns-title">Returns <span class="tsd-signature-type">Promise</span><span class="tsd-signature-symbol">&lt;</span><span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">&gt;</span></h4>
......@@ -404,6 +423,9 @@
<li class=" tsd-kind-constructor tsd-parent-kind-class">
<a href="blockchain.html#constructor" class="tsd-kind-icon">constructor</a>
</li>
<li class=" tsd-kind-property tsd-parent-kind-class">
<a href="blockchain.html#client" class="tsd-kind-icon">client</a>
</li>
<li class=" tsd-kind-method tsd-parent-kind-class">
<a href="blockchain.html#getblocknumberstream" class="tsd-kind-icon">get<wbr>Block<wbr>Number<wbr>Stream</a>
</li>
......
......@@ -87,6 +87,7 @@
<section class="tsd-index-section ">
<h3>Properties</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-property tsd-parent-kind-class"><a href="broadcastapi.html#client" class="tsd-kind-icon">client</a></li>
<li class="tsd-kind-property tsd-parent-kind-class"><a href="broadcastapi.html#expiretime" class="tsd-kind-icon">expire<wbr>Time</a></li>
</ul>
</section>
......@@ -138,6 +139,16 @@
</section>
<section class="tsd-panel-group tsd-member-group ">
<h2>Properties</h2>
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
<a name="client" class="tsd-anchor"></a>
<h3>client</h3>
<div class="tsd-signature tsd-kind-icon">client<span class="tsd-signature-symbol">:</span> <a href="client.html" class="tsd-signature-type">Client</a></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/jnordberg/dsteem/blob/master/src/helpers/broadcast.ts#L105">helpers/broadcast.ts:105</a></li>
</ul>
</aside>
</section>
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
<a name="expiretime" class="tsd-anchor"></a>
<h3>expire<wbr>Time</h3>
......@@ -824,6 +835,9 @@
<li class=" tsd-kind-constructor tsd-parent-kind-class">
<a href="broadcastapi.html#constructor" class="tsd-kind-icon">constructor</a>
</li>
<li class=" tsd-kind-property tsd-parent-kind-class">
<a href="broadcastapi.html#client" class="tsd-kind-icon">client</a>
</li>
<li class=" tsd-kind-property tsd-parent-kind-class">
<a href="broadcastapi.html#expiretime" class="tsd-kind-icon">expire<wbr>Time</a>
</li>
......
......@@ -140,7 +140,7 @@
<h5>address: <span class="tsd-signature-type">string</span></h5>
<div class="tsd-comment tsd-typography">
<div class="lead">
<p>The address to the Steem RPC server, e.g. <code>https://steemd.steemit.com</code>.</p>
<p>The address to the Steem RPC server, e.g. <code>https://api.steemit.com</code>.</p>
</div>
</div>
</li>
......
......@@ -84,6 +84,12 @@
<li class="tsd-kind-constructor tsd-parent-kind-class"><a href="databaseapi.html#constructor" class="tsd-kind-icon">constructor</a></li>
</ul>
</section>
<section class="tsd-index-section ">
<h3>Properties</h3>
<ul class="tsd-index-list">
<li class="tsd-kind-property tsd-parent-kind-class"><a href="databaseapi.html#client" class="tsd-kind-icon">client</a></li>
</ul>
</section>
<section class="tsd-index-section ">
<h3>Methods</h3>
<ul class="tsd-index-list">
......@@ -132,6 +138,19 @@
</ul>
</section>
</section>
<section class="tsd-panel-group tsd-member-group ">
<h2>Properties</h2>
<section class="tsd-panel tsd-member tsd-kind-property tsd-parent-kind-class">
<a name="client" class="tsd-anchor"></a>
<h3>client</h3>
<div class="tsd-signature tsd-kind-icon">client<span class="tsd-signature-symbol">:</span> <a href="client.html" class="tsd-signature-type">Client</a></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/jnordberg/dsteem/blob/master/src/helpers/database.ts#L84">helpers/database.ts:84</a></li>
</ul>
</aside>
</section>
</section>
<section class="tsd-panel-group tsd-member-group ">
<h2>Methods</h2>
<section class="tsd-panel tsd-member tsd-kind-method tsd-parent-kind-class">
......@@ -560,6 +579,9 @@
<li class=" tsd-kind-constructor tsd-parent-kind-class">
<a href="databaseapi.html#constructor" class="tsd-kind-icon">constructor</a>
</li>
<li class=" tsd-kind-property tsd-parent-kind-class">
<a href="databaseapi.html#client" class="tsd-kind-icon">client</a>
</li>
<li class=" tsd-kind-method tsd-parent-kind-class">
<a href="databaseapi.html#call" class="tsd-kind-icon">call</a>
</li>
......
This diff is collapsed.
......@@ -93,7 +93,7 @@
<h3 id="in-the-browser">In the browser</h3>
<pre><code class="lang-html"><span class="hljs-tag">&lt;<span class="hljs-name">script</span> <span class="hljs-attr">src</span>=<span class="hljs-string">"https://unpkg.com/dsteem@latest/dist/dsteem.js"</span>&gt;</span><span class="undefined"></span><span class="hljs-tag">&lt;/<span class="hljs-name">script</span>&gt;</span>
<span class="hljs-tag">&lt;<span class="hljs-name">script</span>&gt;</span><span class="javascript">
<span class="hljs-keyword">var</span> client = <span class="hljs-keyword">new</span> dsteem.Client(<span class="hljs-string">'https://steemd.steemit.com'</span>)
<span class="hljs-keyword">var</span> client = <span class="hljs-keyword">new</span> dsteem.Client(<span class="hljs-string">'https://api.steemit.com'</span>)
client.database.getDiscussions(<span class="hljs-string">'trending'</span>, {<span class="hljs-attr">tag</span>: <span class="hljs-string">'writing'</span>, <span class="hljs-attr">limit</span>: <span class="hljs-number">1</span>}).then(<span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">discussions</span>)</span>{
<span class="hljs-built_in">document</span>.body.innerHTML += <span class="hljs-string">'&lt;h1&gt;'</span> + discussions[<span class="hljs-number">0</span>].title + <span class="hljs-string">'&lt;/h1&gt;'</span>
<span class="hljs-built_in">document</span>.body.innerHTML += <span class="hljs-string">'&lt;h2&gt;by '</span> + discussions[<span class="hljs-number">0</span>].author + <span class="hljs-string">'&lt;/h2&gt;'</span>
......@@ -106,7 +106,7 @@
<p>With TypeScript:</p>
<pre><code class="lang-typescript"><span class="hljs-keyword">import</span> {Client} <span class="hljs-keyword">from</span> <span class="hljs-string">'dsteem'</span>
<span class="hljs-keyword">const</span> client = <span class="hljs-keyword">new</span> Client(<span class="hljs-string">'https://steemd.steemit.com'</span>)
<span class="hljs-keyword">const</span> client = <span class="hljs-keyword">new</span> Client(<span class="hljs-string">'https://api.steemit.com'</span>)
<span class="hljs-keyword">for</span> <span class="hljs-keyword">await</span> (<span class="hljs-keyword">const</span> block of client.blockchain.getBlocks()) {
<span class="hljs-built_in">console</span>.log(<span class="hljs-string">`New block, id: <span class="hljs-subst">${ block.block_id }</span>`</span>)
......@@ -115,7 +115,7 @@
<p>With JavaScript:</p>
<pre><code class="lang-javascript"><span class="hljs-keyword">var</span> dsteem = <span class="hljs-built_in">require</span>(<span class="hljs-string">'dsteem'</span>)
<span class="hljs-keyword">var</span> client = <span class="hljs-keyword">new</span> Client(<span class="hljs-string">'https://steemd.steemit.com'</span>)
<span class="hljs-keyword">var</span> client = <span class="hljs-keyword">new</span> Client(<span class="hljs-string">'https://api.steemit.com'</span>)
<span class="hljs-keyword">var</span> key = dsteem.PrivateKey.fromLogin(<span class="hljs-string">'username'</span>, <span class="hljs-string">'password'</span>, <span class="hljs-string">'posting'</span>)
client.broadcast.comment({
......@@ -132,7 +132,7 @@ client.broadcast.comment({
<p>With ES2016 (node.js 7+):</p>
<pre><code class="lang-javascript"><span class="hljs-keyword">const</span> {Client} = <span class="hljs-built_in">require</span>(<span class="hljs-string">'dsteem'</span>)
<span class="hljs-keyword">const</span> client = <span class="hljs-keyword">new</span> Client(<span class="hljs-string">'https://steemd.steemit.com'</span>)
<span class="hljs-keyword">const</span> client = <span class="hljs-keyword">new</span> Client(<span class="hljs-string">'https://api.steemit.com'</span>)
<span class="hljs-keyword">async</span> <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">main</span>(<span class="hljs-params"></span>) </span>{
<span class="hljs-keyword">const</span> props = <span class="hljs-keyword">await</span> client.database.getChainProperties()
......@@ -147,7 +147,7 @@ main().catch(<span class="hljs-built_in">console</span>.error)
<span class="hljs-keyword">var</span> es = <span class="hljs-built_in">require</span>(<span class="hljs-string">'event-stream'</span>) <span class="hljs-comment">// npm install event-stream</span>
<span class="hljs-keyword">var</span> util = <span class="hljs-built_in">require</span>(<span class="hljs-string">'util'</span>)
<span class="hljs-keyword">var</span> client = <span class="hljs-keyword">new</span> dsteem.Client(<span class="hljs-string">'https://steemd.steemit.com'</span>)
<span class="hljs-keyword">var</span> client = <span class="hljs-keyword">new</span> dsteem.Client(<span class="hljs-string">'https://api.steemit.com'</span>)
<span class="hljs-keyword">var</span> stream = client.blockchain.getBlockStream()
......
......@@ -95,7 +95,7 @@
<div class="tsd-signature tsd-kind-icon">address<wbr>Prefix<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/jnordberg/dsteem/blob/master/src/steem/serializer.ts#L42">steem/serializer.ts:42</a></li>
<li>Defined in <a href="https://github.com/jnordberg/dsteem/blob/master/src/steem/serializer.ts#L43">steem/serializer.ts:43</a></li>
</ul>
</aside>
</section>
......
This diff is collapsed.
{
"name": "dsteem",
"version": "0.8.4",
"version": "0.8.5",
"description": "Steem blockchain RPC client library",
"author": "Johan Nordberg",
"license": "BSD-3-Clause",
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment