[CI Skip] 0.31.11

This commit is contained in:
Travis CI
2018-10-11 13:31:50 +00:00
parent a4fc2c51e8
commit 4be4d8004f
225 changed files with 3166 additions and 6646 deletions
+25 -19
View File
@@ -269,22 +269,23 @@
<li class="chapter " data-level="2.1" data-path="examples/">
<li class="chapter " data-level="2.1" data-path="examples-rpc/">
<a href="examples/">
<a href="examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="examples-rpc/01_simple_connect/">
<a href="examples/01_simple_connect/">
<a href="examples-rpc/01_simple_connect/">
Simple connect
@@ -295,9 +296,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="examples-rpc/02_listen_to_blocks/">
<a href="examples/02_listen_to_blocks/">
<a href="examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -308,9 +309,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="examples-rpc/03_listen_to_balance_change/">
<a href="examples/03_listen_to_balance_change/">
<a href="examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -321,9 +322,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="examples-rpc/04_generate_account/">
<a href="examples/04_generate_account/">
<a href="examples-rpc/04_generate_account/">
Generate Accounts
@@ -334,9 +335,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="examples-rpc/05_read_storage/">
<a href="examples/05_read_storage/">
<a href="examples-rpc/05_read_storage/">
Read Storage
@@ -347,9 +348,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="examples-rpc/06_craft_extrinsic/">
<a href="examples/06_craft_extrinsic/">
<a href="examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -360,9 +361,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="examples-rpc/07_transfer_dots/">
<a href="examples/07_transfer_dots/">
<a href="examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -374,6 +375,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -455,7 +461,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"GLOSSARY.md","mtime":"2018-10-11T11:40:21.739Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":".","book":{"language":""}});
gitbook.page.hasChanged({"page":{"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"GLOSSARY.md","mtime":"2018-10-11T13:27:51.705Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":".","book":{"language":""}});
});
</script>
</div>
-2
View File
@@ -1,6 +1,4 @@
[![polkadotjs](https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square)](https://polkadot.js.org) ![isc](https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square) [![style](https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square)](https://github.com/Flet/semistandard) [![npm](https://img.shields.io/npm/v/@polkadot/api-observable.svg?style=flat-square)](https://www.npmjs.com/package/@polkadot/api-observable) [![travis](https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square)](https://travis-ci.org/polkadot-js/api) [![maintainability](https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square)](https://codeclimate.com/github/polkadot-js/api/maintainability) [![coverage](https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square)](https://coveralls.io/github/polkadot-js/api?branch=master) [![dependency](https://david-dm.org/polkadot-js/api.svg?style=flat-square&path=packages/api-observable)](https://david-dm.org/polkadot-js/api?path=packages/api-observable) [![devDependency](https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&path=packages/api-observable)](https://david-dm.org/polkadot-js/api?path=packages/api-observable#info=devDependencies)
@polkadot/api
=============
-1
View File
@@ -12,4 +12,3 @@
* [RxReferendum](classes/_classes_.rxreferendum.md)
* [&quot;index&quot;](modules/_index_.md)
* [Api](classes/_index_.api.md)
* [&quot;types.d&quot;](modules/_types_d_.md)
+9 -49
View File
@@ -14,7 +14,7 @@
⊕ **new ApiBase**(api: *`RpcRxInterface`*): [ApiBase](_base_.apibase.md)
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
**Parameters:**
@@ -28,31 +28,13 @@ ___
# Properties
<a id="_api"></a>
## `<Protected>` _api
**● _api**: *`RpcRxInterface`*
*Defined in [Base.ts:28](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L28)*
___
<a id="_genesishash"></a>
## `<Protected>` _genesisHash
**● _genesisHash**: *`Hash`*
*Defined in [Base.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L29)*
___
<a id="whenready"></a>
## whenReady
**● whenReady**: *`Observable`<`boolean`>*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
___
<a id="extrinsics"></a>
@@ -61,7 +43,7 @@ ___
**● extrinsics**: *`Extrinsics`* = extrinsicsStatic
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L40)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L40)*
___
<a id="storage"></a>
@@ -70,7 +52,7 @@ ___
**● storage**: *`Storage`* = storageStatic
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L41)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L41)*
___
@@ -82,7 +64,7 @@ ___
getgenesisHash(): `Hash`
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L85)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L85)*
**Returns:** `Hash`
@@ -90,35 +72,13 @@ ___
# Methods
<a id="combine"></a>
## `<Protected>` combine
▸ **combine**<`T`,`R`>(observables: *`Array`<`Observable`<`any`>>*, mapfn?: *`MapFn`<`R`, `T`>*): `Observable`<`T`>
*Defined in [Base.ts:78](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L78)*
**Type parameters:**
#### T
#### R
**Parameters:**
| Param | Type | Default value |
| ------ | ------ | ------ |
| observables | `Array`<`Observable`<`any`>> | - |
| `Default value` mapfn | `MapFn`<`R`, `T`> | defaultMapFn |
**Returns:** `Observable`<`T`>
___
<a id="isconnected"></a>
## isConnected
▸ **isConnected**(): `Observable`<`boolean`>
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L89)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L89)*
**Returns:** `Observable`<`boolean`>
@@ -129,7 +89,7 @@ ___
▸ **rawCall**<`T`>(__namedParameters: *`object`*, ...params: *`Array`<`any`>*): `Observable`<`T`>
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L93)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L93)*
**Type parameters:**
@@ -150,7 +110,7 @@ ___
▸ **rawStorage**<`T`>(key: *`StorageFunction`*, ...params: *`Array`<`any`>*): `Observable`< `T` &#124; `undefined`>
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L106)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L106)*
**Type parameters:**
@@ -171,7 +131,7 @@ ___
▸ **rawStorageMulti**<`T`>(...keys: *`Array`< [`StorageFunction`] &#124; [`StorageFunction`, `any`]>*): `Observable`<`T`>
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L119)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L119)*
**Type parameters:**
+46 -92
View File
@@ -18,7 +18,7 @@
*Inherited from [ApiBase](_base_.apibase.md).[constructor](_base_.apibase.md#constructor)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
**Parameters:**
@@ -32,28 +32,6 @@ ___
# Properties
<a id="_api"></a>
## `<Protected>` _api
**● _api**: *`RpcRxInterface`*
*Inherited from [ApiBase](_base_.apibase.md).[_api](_base_.apibase.md#_api)*
*Defined in [Base.ts:28](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L28)*
___
<a id="_genesishash"></a>
## `<Protected>` _genesisHash
**● _genesisHash**: *`Hash`*
*Inherited from [ApiBase](_base_.apibase.md).[_genesisHash](_base_.apibase.md#_genesishash)*
*Defined in [Base.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L29)*
___
<a id="whenready"></a>
## whenReady
@@ -62,7 +40,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[whenReady](_base_.apibase.md#whenready)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
___
<a id="extrinsics"></a>
@@ -73,7 +51,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[extrinsics](_base_.apibase.md#extrinsics)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L40)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L40)*
___
<a id="storage"></a>
@@ -84,7 +62,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[storage](_base_.apibase.md#storage)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L41)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L41)*
___
@@ -98,7 +76,7 @@ getgenesisHash(): `Hash`
*Inherited from [ApiBase](_base_.apibase.md).[genesisHash](_base_.apibase.md#genesishash)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L85)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L85)*
**Returns:** `Hash`
@@ -114,7 +92,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[accountNonce](_queries_.apiqueries.md#accountnonce)*
*Defined in [Queries.ts:21](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L21)*
*Defined in [Queries.ts:21](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L21)*
**Parameters:**
@@ -133,7 +111,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[balanceFree](_queries_.apiqueries.md#balancefree)*
*Defined in [Queries.ts:25](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L25)*
*Defined in [Queries.ts:25](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L25)*
**Parameters:**
@@ -152,7 +130,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[balanceReserved](_queries_.apiqueries.md#balancereserved)*
*Defined in [Queries.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L29)*
*Defined in [Queries.ts:29](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L29)*
**Parameters:**
@@ -169,7 +147,7 @@ ___
▸ **bestNumber**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Calls.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L13)*
*Defined in [Calls.ts:13](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L13)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -182,7 +160,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[blockNow](_queries_.apiqueries.md#blocknow)*
*Defined in [Queries.ts:37](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L37)*
*Defined in [Queries.ts:37](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L37)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -195,7 +173,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[blockPeriod](_queries_.apiqueries.md#blockperiod)*
*Defined in [Queries.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L33)*
*Defined in [Queries.ts:33](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L33)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -206,34 +184,10 @@ ___
▸ **chain**(): `Observable`< `Text` &#124; `undefined`>
*Defined in [Calls.ts:25](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L25)*
*Defined in [Calls.ts:25](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L25)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
___
<a id="combine"></a>
## `<Protected>` combine
▸ **combine**<`T`,`R`>(observables: *`Array`<`Observable`<`any`>>*, mapfn?: *`MapFn`<`R`, `T`>*): `Observable`<`T`>
*Inherited from [ApiBase](_base_.apibase.md).[combine](_base_.apibase.md#combine)*
*Defined in [Base.ts:78](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L78)*
**Type parameters:**
#### T
#### R
**Parameters:**
| Param | Type | Default value |
| ------ | ------ | ------ |
| observables | `Array`<`Observable`<`any`>> | - |
| `Default value` mapfn | `MapFn`<`R`, `T`> | defaultMapFn |
**Returns:** `Observable`<`T`>
___
<a id="democracylaunchperiod"></a>
@@ -243,7 +197,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyLaunchPeriod](_queries_.apiqueries.md#democracylaunchperiod)*
*Defined in [Queries.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L41)*
*Defined in [Queries.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L41)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -256,7 +210,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyNextTally](_queries_.apiqueries.md#democracynexttally)*
*Defined in [Queries.ts:45](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L45)*
*Defined in [Queries.ts:45](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L45)*
**Returns:** `Observable`< `ReferendumIndex` &#124; `undefined`>
@@ -269,7 +223,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyVotingPeriod](_queries_.apiqueries.md#democracyvotingperiod)*
*Defined in [Queries.ts:115](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L115)*
*Defined in [Queries.ts:115](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L115)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -282,7 +236,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[eraLastLengthChange](_queries_.apiqueries.md#eralastlengthchange)*
*Defined in [Queries.ts:140](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L140)*
*Defined in [Queries.ts:140](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L140)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -291,13 +245,13 @@ ___
## fees
▸ **fees**(): `Observable`<[RxFees](../modules/_types_d_.md#rxfees)>
▸ **fees**(): `Observable`<`RxFees`>
*Inherited from [ApiQueries](_queries_.apiqueries.md).[fees](_queries_.apiqueries.md#fees)*
*Defined in [Queries.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L119)*
*Defined in [Queries.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L119)*
**Returns:** `Observable`<[RxFees](../modules/_types_d_.md#rxfees)>
**Returns:** `Observable`<`RxFees`>
___
<a id="getblock"></a>
@@ -306,7 +260,7 @@ ___
▸ **getBlock**(hash: *`Uint8Array`*): `Observable`< `SignedBlock` &#124; `undefined`>
*Defined in [Calls.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L29)*
*Defined in [Calls.ts:29](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L29)*
**Parameters:**
@@ -325,7 +279,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[isConnected](_base_.apibase.md#isconnected)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L89)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L89)*
**Returns:** `Observable`<`boolean`>
@@ -336,7 +290,7 @@ ___
▸ **newHead**(): `Observable`< `Header` &#124; `undefined`>
*Defined in [Calls.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L33)*
*Defined in [Calls.ts:33](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L33)*
**Returns:** `Observable`< `Header` &#124; `undefined`>
@@ -349,7 +303,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[proposalDeposits](_queries_.apiqueries.md#proposaldeposits)*
*Defined in [Queries.ts:49](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L49)*
*Defined in [Queries.ts:49](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L49)*
**Parameters:**
@@ -368,7 +322,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[publicProposals](_queries_.apiqueries.md#publicproposals)*
*Defined in [Queries.ts:62](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L62)*
*Defined in [Queries.ts:62](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L62)*
**Returns:** `Observable`<`Array`<[RxProposal](_classes_.rxproposal.md)>>
@@ -381,7 +335,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawCall](_base_.apibase.md#rawcall)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L93)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L93)*
**Type parameters:**
@@ -404,7 +358,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawStorage](_base_.apibase.md#rawstorage)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L106)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L106)*
**Type parameters:**
@@ -427,7 +381,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawStorageMulti](_base_.apibase.md#rawstoragemulti)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L119)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L119)*
**Type parameters:**
@@ -449,7 +403,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumCount](_queries_.apiqueries.md#referendumcount)*
*Defined in [Queries.ts:81](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L81)*
*Defined in [Queries.ts:81](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L81)*
**Returns:** `Observable`< `ReferendumIndex` &#124; `undefined`>
@@ -462,7 +416,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumInfo](_queries_.apiqueries.md#referenduminfo)*
*Defined in [Queries.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L85)*
*Defined in [Queries.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L85)*
**Parameters:**
@@ -481,7 +435,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumVote](_queries_.apiqueries.md#referendumvote)*
*Defined in [Queries.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L98)*
*Defined in [Queries.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L98)*
**Parameters:**
@@ -501,7 +455,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumVoters](_queries_.apiqueries.md#referendumvoters)*
*Defined in [Queries.ts:102](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L102)*
*Defined in [Queries.ts:102](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L102)*
**Parameters:**
@@ -520,7 +474,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionCurrentIndex](_queries_.apiqueries.md#sessioncurrentindex)*
*Defined in [Queries.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L152)*
*Defined in [Queries.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L152)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -533,7 +487,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionCurrentStart](_queries_.apiqueries.md#sessioncurrentstart)*
*Defined in [Queries.ts:156](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L156)*
*Defined in [Queries.ts:156](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L156)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -546,7 +500,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionLastLengthChange](_queries_.apiqueries.md#sessionlastlengthchange)*
*Defined in [Queries.ts:160](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L160)*
*Defined in [Queries.ts:160](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L160)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -559,7 +513,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionLength](_queries_.apiqueries.md#sessionlength)*
*Defined in [Queries.ts:164](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L164)*
*Defined in [Queries.ts:164](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L164)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -572,7 +526,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionReward](_queries_.apiqueries.md#sessionreward)*
*Defined in [Queries.ts:144](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L144)*
*Defined in [Queries.ts:144](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L144)*
**Returns:** `Observable`< `Perbill` &#124; `undefined`>
@@ -585,7 +539,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionRewardCurrent](_queries_.apiqueries.md#sessionrewardcurrent)*
*Defined in [Queries.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L148)*
*Defined in [Queries.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L148)*
**Returns:** `Observable`< `Balance` &#124; `undefined`>
@@ -598,7 +552,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionValidators](_queries_.apiqueries.md#sessionvalidators)*
*Defined in [Queries.ts:172](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L172)*
*Defined in [Queries.ts:172](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L172)*
**Returns:** `Observable`<`Array`<`AccountId`>>
@@ -611,7 +565,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionsPerEra](_queries_.apiqueries.md#sessionsperera)*
*Defined in [Queries.ts:168](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L168)*
*Defined in [Queries.ts:168](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L168)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -624,7 +578,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingIntentions](_queries_.apiqueries.md#stakingintentions)*
*Defined in [Queries.ts:185](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L185)*
*Defined in [Queries.ts:185](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L185)*
**Returns:** `Observable`<`Array`<`AccountId`>>
@@ -637,7 +591,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingNominating](_queries_.apiqueries.md#stakingnominating)*
*Defined in [Queries.ts:211](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L211)*
*Defined in [Queries.ts:211](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L211)*
**Parameters:**
@@ -656,7 +610,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingNominatorsFor](_queries_.apiqueries.md#stakingnominatorsfor)*
*Defined in [Queries.ts:198](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L198)*
*Defined in [Queries.ts:198](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L198)*
**Parameters:**
@@ -673,7 +627,7 @@ ___
▸ **submitExtrinsic**(extrinsic: *`Extrinsic`*): `Observable`< `Hash` &#124; `undefined`>
*Defined in [Calls.ts:47](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L47)*
*Defined in [Calls.ts:47](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L47)*
**Parameters:**
@@ -690,7 +644,7 @@ ___
▸ **systemName**(): `Observable`< `Text` &#124; `undefined`>
*Defined in [Calls.ts:39](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L39)*
*Defined in [Calls.ts:39](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L39)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
@@ -701,7 +655,7 @@ ___
▸ **systemVersion**(): `Observable`< `Text` &#124; `undefined`>
*Defined in [Calls.ts:43](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L43)*
*Defined in [Calls.ts:43](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L43)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
@@ -714,7 +668,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[validatorCount](_queries_.apiqueries.md#validatorcount)*
*Defined in [Queries.ts:215](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L215)*
*Defined in [Queries.ts:215](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L215)*
**Returns:** `Observable`< `u32` &#124; `undefined`>
@@ -21,7 +21,7 @@
*Overrides Struct.__constructor*
*Defined in [classes.ts:9](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L9)*
*Defined in [classes.ts:9](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L9)*
**Parameters:**
@@ -35,28 +35,6 @@ ___
# Properties
<a id="_types"></a>
## `<Protected>` _Types
**● _Types**: *`E`*
*Inherited from Struct._Types*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:30](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L30)*
___
<a id="_jsonmap"></a>
## `<Protected>` _jsonMap
**● _jsonMap**: *`Map`<`keyof S`, `string`>*
*Inherited from Struct._jsonMap*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L29)*
___
<a id="raw"></a>
## raw
@@ -65,7 +43,7 @@ ___
*Inherited from Base.raw*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Base.ts#L19)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Base.ts#L19)*
___
@@ -79,7 +57,7 @@ getType(): `E`
*Inherited from Struct.Type*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L108)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L108)*
**Returns:** `E`
@@ -90,7 +68,7 @@ ___
getaddress(): `AccountId`
*Defined in [classes.ts:18](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L18)*
*Defined in [classes.ts:18](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L18)*
**Returns:** `AccountId`
@@ -101,7 +79,7 @@ ___
getid(): `PropIndex`
*Defined in [classes.ts:22](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L22)*
*Defined in [classes.ts:22](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L22)*
**Returns:** `PropIndex`
@@ -112,7 +90,7 @@ ___
getproposal(): `Proposal`
*Defined in [classes.ts:26](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L26)*
*Defined in [classes.ts:26](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L26)*
**Returns:** `Proposal`
@@ -130,7 +108,7 @@ ___
*Overrides Base.byteLength*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:112](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L112)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:112](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L112)*
**Returns:** `number`
@@ -145,7 +123,7 @@ ___
*Overrides Base.fromJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:118](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L118)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:118](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L118)*
**Parameters:**
@@ -166,7 +144,7 @@ ___
*Overrides Base.fromU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:138](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L138)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:138](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L138)*
**Parameters:**
@@ -185,7 +163,7 @@ ___
*Inherited from Struct.get*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L148)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L148)*
**Parameters:**
@@ -204,7 +182,7 @@ ___
*Inherited from Struct.keys*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L163)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L163)*
**Returns:** `Array`<`string`>
@@ -219,7 +197,7 @@ ___
*Overrides Base.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L152)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L152)*
**Returns:** `any`
@@ -234,7 +212,7 @@ ___
*Overrides Base.toString*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L175)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L175)*
**Returns:** `string`
@@ -249,7 +227,7 @@ ___
*Overrides Base.toU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:167](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L167)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:167](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L167)*
**Parameters:**
@@ -268,7 +246,7 @@ ___
*Inherited from Struct.values*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L184)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L184)*
**Returns:** `Array`<`Base`>
@@ -281,7 +259,7 @@ ___
*Inherited from Struct.decodeStruct*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L48)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L48)*
**Type parameters:**
@@ -306,7 +284,7 @@ ___
*Inherited from Struct.with*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L98)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L98)*
**Type parameters:**
@@ -21,7 +21,7 @@
*Overrides Struct.__constructor*
*Defined in [classes.ts:31](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L31)*
*Defined in [classes.ts:31](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L31)*
**Parameters:**
@@ -35,28 +35,6 @@ ___
# Properties
<a id="_types"></a>
## `<Protected>` _Types
**● _Types**: *`E`*
*Inherited from Struct._Types*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:30](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L30)*
___
<a id="_jsonmap"></a>
## `<Protected>` _jsonMap
**● _jsonMap**: *`Map`<`keyof S`, `string`>*
*Inherited from Struct._jsonMap*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L29)*
___
<a id="raw"></a>
## raw
@@ -65,7 +43,7 @@ ___
*Inherited from Base.raw*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Base.ts#L19)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Base.ts#L19)*
___
@@ -79,7 +57,7 @@ getType(): `E`
*Inherited from Struct.Type*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L108)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L108)*
**Returns:** `E`
@@ -90,7 +68,7 @@ ___
getaddresses(): `Vector`<`AccountId`>
*Defined in [classes.ts:39](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L39)*
*Defined in [classes.ts:39](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L39)*
**Returns:** `Vector`<`AccountId`>
@@ -101,7 +79,7 @@ ___
getbalance(): `Balance`
*Defined in [classes.ts:43](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L43)*
*Defined in [classes.ts:43](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L43)*
**Returns:** `Balance`
@@ -119,7 +97,7 @@ ___
*Overrides Base.byteLength*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:112](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L112)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:112](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L112)*
**Returns:** `number`
@@ -134,7 +112,7 @@ ___
*Overrides Base.fromJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:118](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L118)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:118](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L118)*
**Parameters:**
@@ -155,7 +133,7 @@ ___
*Overrides Base.fromU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:138](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L138)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:138](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L138)*
**Parameters:**
@@ -174,7 +152,7 @@ ___
*Inherited from Struct.get*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L148)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L148)*
**Parameters:**
@@ -193,7 +171,7 @@ ___
*Inherited from Struct.keys*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L163)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L163)*
**Returns:** `Array`<`string`>
@@ -208,7 +186,7 @@ ___
*Overrides Base.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L152)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L152)*
**Returns:** `any`
@@ -223,7 +201,7 @@ ___
*Overrides Base.toString*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L175)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L175)*
**Returns:** `string`
@@ -238,7 +216,7 @@ ___
*Overrides Base.toU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:167](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L167)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:167](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L167)*
**Parameters:**
@@ -257,7 +235,7 @@ ___
*Inherited from Struct.values*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L184)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L184)*
**Returns:** `Array`<`Base`>
@@ -270,7 +248,7 @@ ___
*Inherited from Struct.decodeStruct*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L48)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L48)*
**Type parameters:**
@@ -295,7 +273,7 @@ ___
*Inherited from Struct.with*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L98)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L98)*
**Type parameters:**
@@ -21,7 +21,7 @@
*Overrides Struct.__constructor*
*Defined in [classes.ts:48](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L48)*
*Defined in [classes.ts:48](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L48)*
**Parameters:**
@@ -36,28 +36,6 @@ ___
# Properties
<a id="_types"></a>
## `<Protected>` _Types
**● _Types**: *`E`*
*Inherited from Struct._Types*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:30](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L30)*
___
<a id="_jsonmap"></a>
## `<Protected>` _jsonMap
**● _jsonMap**: *`Map`<`keyof S`, `string`>*
*Inherited from Struct._jsonMap*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L29)*
___
<a id="raw"></a>
## raw
@@ -66,7 +44,7 @@ ___
*Inherited from Base.raw*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Base.ts#L19)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Base.ts#L19)*
___
@@ -80,7 +58,7 @@ getType(): `E`
*Inherited from Struct.Type*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L108)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L108)*
**Returns:** `E`
@@ -91,7 +69,7 @@ ___
getblockNumber(): `BlockNumber`
*Defined in [classes.ts:58](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L58)*
*Defined in [classes.ts:58](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L58)*
**Returns:** `BlockNumber`
@@ -102,7 +80,7 @@ ___
getid(): `ReferendumIndex`
*Defined in [classes.ts:62](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L62)*
*Defined in [classes.ts:62](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L62)*
**Returns:** `ReferendumIndex`
@@ -113,7 +91,7 @@ ___
getproposal(): `Proposal`
*Defined in [classes.ts:66](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L66)*
*Defined in [classes.ts:66](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L66)*
**Returns:** `Proposal`
@@ -124,7 +102,7 @@ ___
getvoteThreshold(): `VoteThreshold`
*Defined in [classes.ts:70](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/classes.ts#L70)*
*Defined in [classes.ts:70](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/classes.ts#L70)*
**Returns:** `VoteThreshold`
@@ -142,7 +120,7 @@ ___
*Overrides Base.byteLength*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:112](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L112)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:112](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L112)*
**Returns:** `number`
@@ -157,7 +135,7 @@ ___
*Overrides Base.fromJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:118](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L118)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:118](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L118)*
**Parameters:**
@@ -178,7 +156,7 @@ ___
*Overrides Base.fromU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:138](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L138)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:138](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L138)*
**Parameters:**
@@ -197,7 +175,7 @@ ___
*Inherited from Struct.get*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L148)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L148)*
**Parameters:**
@@ -216,7 +194,7 @@ ___
*Inherited from Struct.keys*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L163)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L163)*
**Returns:** `Array`<`string`>
@@ -231,7 +209,7 @@ ___
*Overrides Base.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L152)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L152)*
**Returns:** `any`
@@ -246,7 +224,7 @@ ___
*Overrides Base.toString*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L175)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L175)*
**Returns:** `string`
@@ -261,7 +239,7 @@ ___
*Overrides Base.toU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:167](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L167)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:167](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L167)*
**Parameters:**
@@ -280,7 +258,7 @@ ___
*Inherited from Struct.values*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L184)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L184)*
**Returns:** `Array`<`Base`>
@@ -293,7 +271,7 @@ ___
*Inherited from Struct.decodeStruct*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L48)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L48)*
**Type parameters:**
@@ -318,7 +296,7 @@ ___
*Inherited from Struct.with*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L98)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L98)*
**Type parameters:**
@@ -18,7 +18,7 @@
*Inherited from [ApiBase](_base_.apibase.md).[constructor](_base_.apibase.md#constructor)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
**Parameters:**
@@ -32,28 +32,6 @@ ___
# Properties
<a id="_api"></a>
## `<Protected>` _api
**● _api**: *`RpcRxInterface`*
*Inherited from [ApiBase](_base_.apibase.md).[_api](_base_.apibase.md#_api)*
*Defined in [Base.ts:28](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L28)*
___
<a id="_genesishash"></a>
## `<Protected>` _genesisHash
**● _genesisHash**: *`Hash`*
*Inherited from [ApiBase](_base_.apibase.md).[_genesisHash](_base_.apibase.md#_genesishash)*
*Defined in [Base.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L29)*
___
<a id="whenready"></a>
## whenReady
@@ -62,7 +40,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[whenReady](_base_.apibase.md#whenready)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
___
<a id="extrinsics"></a>
@@ -73,7 +51,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[extrinsics](_base_.apibase.md#extrinsics)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L40)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L40)*
___
<a id="storage"></a>
@@ -84,7 +62,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[storage](_base_.apibase.md#storage)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L41)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L41)*
___
@@ -98,7 +76,7 @@ getgenesisHash(): `Hash`
*Inherited from [ApiBase](_base_.apibase.md).[genesisHash](_base_.apibase.md#genesishash)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L85)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L85)*
**Returns:** `Hash`
@@ -114,7 +92,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[accountNonce](_queries_.apiqueries.md#accountnonce)*
*Defined in [Queries.ts:21](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L21)*
*Defined in [Queries.ts:21](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L21)*
**Parameters:**
@@ -133,7 +111,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[balanceFree](_queries_.apiqueries.md#balancefree)*
*Defined in [Queries.ts:25](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L25)*
*Defined in [Queries.ts:25](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L25)*
**Parameters:**
@@ -152,7 +130,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[balanceReserved](_queries_.apiqueries.md#balancereserved)*
*Defined in [Queries.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L29)*
*Defined in [Queries.ts:29](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L29)*
**Parameters:**
@@ -171,7 +149,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[bestNumber](_calls_.apicalls.md#bestnumber)*
*Defined in [Calls.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L13)*
*Defined in [Calls.ts:13](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L13)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -184,7 +162,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[blockNow](_queries_.apiqueries.md#blocknow)*
*Defined in [Queries.ts:37](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L37)*
*Defined in [Queries.ts:37](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L37)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -197,7 +175,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[blockPeriod](_queries_.apiqueries.md#blockperiod)*
*Defined in [Queries.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L33)*
*Defined in [Queries.ts:33](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L33)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -210,34 +188,10 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[chain](_calls_.apicalls.md#chain)*
*Defined in [Calls.ts:25](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L25)*
*Defined in [Calls.ts:25](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L25)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
___
<a id="combine"></a>
## `<Protected>` combine
▸ **combine**<`T`,`R`>(observables: *`Array`<`Observable`<`any`>>*, mapfn?: *`MapFn`<`R`, `T`>*): `Observable`<`T`>
*Inherited from [ApiBase](_base_.apibase.md).[combine](_base_.apibase.md#combine)*
*Defined in [Base.ts:78](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L78)*
**Type parameters:**
#### T
#### R
**Parameters:**
| Param | Type | Default value |
| ------ | ------ | ------ |
| observables | `Array`<`Observable`<`any`>> | - |
| `Default value` mapfn | `MapFn`<`R`, `T`> | defaultMapFn |
**Returns:** `Observable`<`T`>
___
<a id="democracylaunchperiod"></a>
@@ -247,7 +201,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyLaunchPeriod](_queries_.apiqueries.md#democracylaunchperiod)*
*Defined in [Queries.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L41)*
*Defined in [Queries.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L41)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -260,7 +214,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyNextTally](_queries_.apiqueries.md#democracynexttally)*
*Defined in [Queries.ts:45](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L45)*
*Defined in [Queries.ts:45](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L45)*
**Returns:** `Observable`< `ReferendumIndex` &#124; `undefined`>
@@ -269,9 +223,9 @@ ___
## democracyReferendumVoters
▸ **democracyReferendumVoters**(referendumId: * `ReferendumIndex` &#124; `BN` &#124; `number`*): `Observable`<`Array`<[RxReferendumVote](../modules/_types_d_.md#rxreferendumvote)>>
▸ **democracyReferendumVoters**(referendumId: * `ReferendumIndex` &#124; `BN` &#124; `number`*): `Observable`<`Array`<`RxReferendumVote`>>
*Defined in [Combined.ts:42](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L42)*
*Defined in [Combined.ts:42](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L42)*
**Parameters:**
@@ -279,7 +233,7 @@ ___
| ------ | ------ |
| referendumId | `ReferendumIndex` &#124; `BN` &#124; `number`|
**Returns:** `Observable`<`Array`<[RxReferendumVote](../modules/_types_d_.md#rxreferendumvote)>>
**Returns:** `Observable`<`Array`<`RxReferendumVote`>>
___
<a id="democracyvotersbalancesof"></a>
@@ -288,7 +242,7 @@ ___
▸ **democracyVotersBalancesOf**(referendumId: * `ReferendumIndex` &#124; `BN` &#124; `number`*): `Observable`<`Array`<`Balance`>>
*Defined in [Combined.ts:87](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L87)*
*Defined in [Combined.ts:87](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L87)*
**Parameters:**
@@ -305,7 +259,7 @@ ___
▸ **democracyVotersVotesOf**(referendumId: * `ReferendumIndex` &#124; `BN` &#124; `number`*): `Observable`<`Array`<`Bool`>>
*Defined in [Combined.ts:103](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L103)*
*Defined in [Combined.ts:103](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L103)*
**Parameters:**
@@ -324,7 +278,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyVotingPeriod](_queries_.apiqueries.md#democracyvotingperiod)*
*Defined in [Queries.ts:115](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L115)*
*Defined in [Queries.ts:115](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L115)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -335,7 +289,7 @@ ___
▸ **eraBlockLength**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Combined.ts:114](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L114)*
*Defined in [Combined.ts:114](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L114)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -346,7 +300,7 @@ ___
▸ **eraBlockProgress**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Combined.ts:129](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L129)*
*Defined in [Combined.ts:129](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L129)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -357,7 +311,7 @@ ___
▸ **eraBlockRemaining**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Combined.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L152)*
*Defined in [Combined.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L152)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -370,7 +324,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[eraLastLengthChange](_queries_.apiqueries.md#eralastlengthchange)*
*Defined in [Queries.ts:140](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L140)*
*Defined in [Queries.ts:140](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L140)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -379,13 +333,13 @@ ___
## fees
▸ **fees**(): `Observable`<[RxFees](../modules/_types_d_.md#rxfees)>
▸ **fees**(): `Observable`<`RxFees`>
*Inherited from [ApiQueries](_queries_.apiqueries.md).[fees](_queries_.apiqueries.md#fees)*
*Defined in [Queries.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L119)*
*Defined in [Queries.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L119)*
**Returns:** `Observable`<[RxFees](../modules/_types_d_.md#rxfees)>
**Returns:** `Observable`<`RxFees`>
___
<a id="getblock"></a>
@@ -396,7 +350,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[getBlock](_calls_.apicalls.md#getblock)*
*Defined in [Calls.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L29)*
*Defined in [Calls.ts:29](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L29)*
**Parameters:**
@@ -415,7 +369,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[isConnected](_base_.apibase.md#isconnected)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L89)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L89)*
**Returns:** `Observable`<`boolean`>
@@ -428,7 +382,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[newHead](_calls_.apicalls.md#newhead)*
*Defined in [Calls.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L33)*
*Defined in [Calls.ts:33](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L33)*
**Returns:** `Observable`< `Header` &#124; `undefined`>
@@ -441,7 +395,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[proposalDeposits](_queries_.apiqueries.md#proposaldeposits)*
*Defined in [Queries.ts:49](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L49)*
*Defined in [Queries.ts:49](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L49)*
**Parameters:**
@@ -458,7 +412,7 @@ ___
▸ **publicProposalCount**(): `Observable`<`number`>
*Defined in [Combined.ts:20](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L20)*
*Defined in [Combined.ts:20](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L20)*
**Returns:** `Observable`<`number`>
@@ -471,7 +425,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[publicProposals](_queries_.apiqueries.md#publicproposals)*
*Defined in [Queries.ts:62](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L62)*
*Defined in [Queries.ts:62](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L62)*
**Returns:** `Observable`<`Array`<[RxProposal](_classes_.rxproposal.md)>>
@@ -484,7 +438,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawCall](_base_.apibase.md#rawcall)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L93)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L93)*
**Type parameters:**
@@ -507,7 +461,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawStorage](_base_.apibase.md#rawstorage)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L106)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L106)*
**Type parameters:**
@@ -530,7 +484,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawStorageMulti](_base_.apibase.md#rawstoragemulti)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L119)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L119)*
**Type parameters:**
@@ -552,7 +506,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumCount](_queries_.apiqueries.md#referendumcount)*
*Defined in [Queries.ts:81](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L81)*
*Defined in [Queries.ts:81](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L81)*
**Returns:** `Observable`< `ReferendumIndex` &#124; `undefined`>
@@ -565,7 +519,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumInfo](_queries_.apiqueries.md#referenduminfo)*
*Defined in [Queries.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L85)*
*Defined in [Queries.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L85)*
**Parameters:**
@@ -584,7 +538,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumVote](_queries_.apiqueries.md#referendumvote)*
*Defined in [Queries.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L98)*
*Defined in [Queries.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L98)*
**Parameters:**
@@ -604,7 +558,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumVoters](_queries_.apiqueries.md#referendumvoters)*
*Defined in [Queries.ts:102](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L102)*
*Defined in [Queries.ts:102](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L102)*
**Parameters:**
@@ -621,7 +575,7 @@ ___
▸ **referendumVotes**(index: * `ReferendumIndex` &#124; `BN` &#124; `number`*, addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<`boolean`>
*Defined in [Combined.ts:79](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L79)*
*Defined in [Combined.ts:79](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L79)*
**Parameters:**
@@ -639,7 +593,7 @@ ___
▸ **referendums**(): `Observable`<`Array`<[RxReferendum](_classes_.rxreferendum.md)>>
*Defined in [Combined.ts:58](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L58)*
*Defined in [Combined.ts:58](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L58)*
**Returns:** `Observable`<`Array`<[RxReferendum](_classes_.rxreferendum.md)>>
@@ -650,7 +604,7 @@ ___
▸ **referendumsInfo**(referendumIds: *`Array`< `ReferendumIndex` &#124; `BN` &#124; `number`>*): `Observable`<`Array`<[RxReferendum](_classes_.rxreferendum.md)>>
*Defined in [Combined.ts:30](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L30)*
*Defined in [Combined.ts:30](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L30)*
**Parameters:**
@@ -667,7 +621,7 @@ ___
▸ **sessionBlockProgress**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Combined.ts:167](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L167)*
*Defined in [Combined.ts:167](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L167)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -678,7 +632,7 @@ ___
▸ **sessionBlockRemaining**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Combined.ts:187](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L187)*
*Defined in [Combined.ts:187](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L187)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -689,7 +643,7 @@ ___
▸ **sessionBrokenValue**(): `Observable`< `Moment` &#124; `undefined`>
*Defined in [Combined.ts:202](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L202)*
*Defined in [Combined.ts:202](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L202)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -702,7 +656,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionCurrentIndex](_queries_.apiqueries.md#sessioncurrentindex)*
*Defined in [Queries.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L152)*
*Defined in [Queries.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L152)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -715,7 +669,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionCurrentStart](_queries_.apiqueries.md#sessioncurrentstart)*
*Defined in [Queries.ts:156](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L156)*
*Defined in [Queries.ts:156](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L156)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -728,7 +682,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionLastLengthChange](_queries_.apiqueries.md#sessionlastlengthchange)*
*Defined in [Queries.ts:160](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L160)*
*Defined in [Queries.ts:160](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L160)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -741,7 +695,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionLength](_queries_.apiqueries.md#sessionlength)*
*Defined in [Queries.ts:164](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L164)*
*Defined in [Queries.ts:164](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L164)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -754,7 +708,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionReward](_queries_.apiqueries.md#sessionreward)*
*Defined in [Queries.ts:144](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L144)*
*Defined in [Queries.ts:144](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L144)*
**Returns:** `Observable`< `Perbill` &#124; `undefined`>
@@ -767,7 +721,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionRewardCurrent](_queries_.apiqueries.md#sessionrewardcurrent)*
*Defined in [Queries.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L148)*
*Defined in [Queries.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L148)*
**Returns:** `Observable`< `Balance` &#124; `undefined`>
@@ -778,7 +732,7 @@ ___
▸ **sessionTimeExpected**(): `Observable`< `Moment` &#124; `undefined`>
*Defined in [Combined.ts:221](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L221)*
*Defined in [Combined.ts:221](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L221)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -789,7 +743,7 @@ ___
▸ **sessionTimeRemaining**(): `Observable`< `Moment` &#124; `undefined`>
*Defined in [Combined.ts:236](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L236)*
*Defined in [Combined.ts:236](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L236)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -802,7 +756,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionValidators](_queries_.apiqueries.md#sessionvalidators)*
*Defined in [Queries.ts:172](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L172)*
*Defined in [Queries.ts:172](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L172)*
**Returns:** `Observable`<`Array`<`AccountId`>>
@@ -815,7 +769,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionsPerEra](_queries_.apiqueries.md#sessionsperera)*
*Defined in [Queries.ts:168](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L168)*
*Defined in [Queries.ts:168](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L168)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -828,7 +782,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingIntentions](_queries_.apiqueries.md#stakingintentions)*
*Defined in [Queries.ts:185](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L185)*
*Defined in [Queries.ts:185](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L185)*
**Returns:** `Observable`<`Array`<`AccountId`>>
@@ -841,7 +795,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingNominating](_queries_.apiqueries.md#stakingnominating)*
*Defined in [Queries.ts:211](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L211)*
*Defined in [Queries.ts:211](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L211)*
**Parameters:**
@@ -860,7 +814,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingNominatorsFor](_queries_.apiqueries.md#stakingnominatorsfor)*
*Defined in [Queries.ts:198](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L198)*
*Defined in [Queries.ts:198](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L198)*
**Parameters:**
@@ -879,7 +833,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[submitExtrinsic](_calls_.apicalls.md#submitextrinsic)*
*Defined in [Calls.ts:47](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L47)*
*Defined in [Calls.ts:47](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L47)*
**Parameters:**
@@ -898,7 +852,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[systemName](_calls_.apicalls.md#systemname)*
*Defined in [Calls.ts:39](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L39)*
*Defined in [Calls.ts:39](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L39)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
@@ -911,7 +865,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[systemVersion](_calls_.apicalls.md#systemversion)*
*Defined in [Calls.ts:43](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L43)*
*Defined in [Calls.ts:43](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L43)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
@@ -920,9 +874,9 @@ ___
## validatingBalance
▸ **validatingBalance**(address: * `AccountId` &#124; `string`*): `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)>
▸ **validatingBalance**(address: * `AccountId` &#124; `string`*): `Observable`<`RxBalance`>
*Defined in [Combined.ts:251](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L251)*
*Defined in [Combined.ts:251](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L251)*
**Parameters:**
@@ -930,16 +884,16 @@ ___
| ------ | ------ |
| address | `AccountId` &#124; `string`|
**Returns:** `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)>
**Returns:** `Observable`<`RxBalance`>
___
<a id="validatingbalances"></a>
## validatingBalances
▸ **validatingBalances**(...addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<[RxBalanceMap](../modules/_types_d_.md#rxbalancemap)>
▸ **validatingBalances**(...addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<`RxBalanceMap`>
*Defined in [Combined.ts:276](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L276)*
*Defined in [Combined.ts:276](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L276)*
**Parameters:**
@@ -947,7 +901,7 @@ ___
| ------ | ------ |
| `Rest` addresses | `Array`< `AccountId` &#124; `string`> |
**Returns:** `Observable`<[RxBalanceMap](../modules/_types_d_.md#rxbalancemap)>
**Returns:** `Observable`<`RxBalanceMap`>
___
<a id="validatorcount"></a>
@@ -958,7 +912,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[validatorCount](_queries_.apiqueries.md#validatorcount)*
*Defined in [Queries.ts:215](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L215)*
*Defined in [Queries.ts:215](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L215)*
**Returns:** `Observable`< `u32` &#124; `undefined`>
@@ -967,9 +921,9 @@ ___
## votingBalance
▸ **votingBalance**(_address: * `AccountId` &#124; `string`*): `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)>
▸ **votingBalance**(_address: * `AccountId` &#124; `string`*): `Observable`<`RxBalance`>
*Defined in [Combined.ts:290](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L290)*
*Defined in [Combined.ts:290](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L290)*
**Parameters:**
@@ -977,16 +931,16 @@ ___
| ------ | ------ |
| _address | `AccountId` &#124; `string`|
**Returns:** `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)>
**Returns:** `Observable`<`RxBalance`>
___
<a id="votingbalances"></a>
## votingBalances
▸ **votingBalances**(...addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)[]>
▸ **votingBalances**(...addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<`RxBalance`[]>
*Defined in [Combined.ts:324](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L324)*
*Defined in [Combined.ts:324](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L324)*
**Parameters:**
@@ -994,7 +948,7 @@ ___
| ------ | ------ |
| `Rest` addresses | `Array`< `AccountId` &#124; `string`> |
**Returns:** `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)[]>
**Returns:** `Observable`<`RxBalance`[]>
___
<a id="votingbalancesnominatorsfor"></a>
@@ -1003,7 +957,7 @@ ___
▸ **votingBalancesNominatorsFor**(address: * `AccountId` &#124; `string`*): `Observable`<`any`>
*Defined in [Combined.ts:313](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L313)*
*Defined in [Combined.ts:313](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L313)*
**Parameters:**
+76 -122
View File
@@ -16,7 +16,7 @@
*Inherited from [ApiBase](_base_.apibase.md).[constructor](_base_.apibase.md#constructor)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
**Parameters:**
@@ -30,28 +30,6 @@ ___
# Properties
<a id="_api"></a>
## `<Protected>` _api
**● _api**: *`RpcRxInterface`*
*Inherited from [ApiBase](_base_.apibase.md).[_api](_base_.apibase.md#_api)*
*Defined in [Base.ts:28](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L28)*
___
<a id="_genesishash"></a>
## `<Protected>` _genesisHash
**● _genesisHash**: *`Hash`*
*Inherited from [ApiBase](_base_.apibase.md).[_genesisHash](_base_.apibase.md#_genesishash)*
*Defined in [Base.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L29)*
___
<a id="whenready"></a>
## whenReady
@@ -60,7 +38,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[whenReady](_base_.apibase.md#whenready)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
___
<a id="extrinsics"></a>
@@ -71,7 +49,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[extrinsics](_base_.apibase.md#extrinsics)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L40)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L40)*
___
<a id="storage"></a>
@@ -82,7 +60,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[storage](_base_.apibase.md#storage)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L41)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L41)*
___
@@ -96,7 +74,7 @@ getgenesisHash(): `Hash`
*Inherited from [ApiBase](_base_.apibase.md).[genesisHash](_base_.apibase.md#genesishash)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L85)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L85)*
**Returns:** `Hash`
@@ -112,7 +90,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[accountNonce](_queries_.apiqueries.md#accountnonce)*
*Defined in [Queries.ts:21](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L21)*
*Defined in [Queries.ts:21](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L21)*
**Parameters:**
@@ -131,7 +109,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[balanceFree](_queries_.apiqueries.md#balancefree)*
*Defined in [Queries.ts:25](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L25)*
*Defined in [Queries.ts:25](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L25)*
**Parameters:**
@@ -150,7 +128,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[balanceReserved](_queries_.apiqueries.md#balancereserved)*
*Defined in [Queries.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L29)*
*Defined in [Queries.ts:29](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L29)*
**Parameters:**
@@ -169,7 +147,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[bestNumber](_calls_.apicalls.md#bestnumber)*
*Defined in [Calls.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L13)*
*Defined in [Calls.ts:13](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L13)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -182,7 +160,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[blockNow](_queries_.apiqueries.md#blocknow)*
*Defined in [Queries.ts:37](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L37)*
*Defined in [Queries.ts:37](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L37)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -195,7 +173,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[blockPeriod](_queries_.apiqueries.md#blockperiod)*
*Defined in [Queries.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L33)*
*Defined in [Queries.ts:33](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L33)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -208,34 +186,10 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[chain](_calls_.apicalls.md#chain)*
*Defined in [Calls.ts:25](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L25)*
*Defined in [Calls.ts:25](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L25)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
___
<a id="combine"></a>
## `<Protected>` combine
▸ **combine**<`T`,`R`>(observables: *`Array`<`Observable`<`any`>>*, mapfn?: *`MapFn`<`R`, `T`>*): `Observable`<`T`>
*Inherited from [ApiBase](_base_.apibase.md).[combine](_base_.apibase.md#combine)*
*Defined in [Base.ts:78](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L78)*
**Type parameters:**
#### T
#### R
**Parameters:**
| Param | Type | Default value |
| ------ | ------ | ------ |
| observables | `Array`<`Observable`<`any`>> | - |
| `Default value` mapfn | `MapFn`<`R`, `T`> | defaultMapFn |
**Returns:** `Observable`<`T`>
___
<a id="democracylaunchperiod"></a>
@@ -245,7 +199,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyLaunchPeriod](_queries_.apiqueries.md#democracylaunchperiod)*
*Defined in [Queries.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L41)*
*Defined in [Queries.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L41)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -258,7 +212,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyNextTally](_queries_.apiqueries.md#democracynexttally)*
*Defined in [Queries.ts:45](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L45)*
*Defined in [Queries.ts:45](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L45)*
**Returns:** `Observable`< `ReferendumIndex` &#124; `undefined`>
@@ -267,11 +221,11 @@ ___
## democracyReferendumVoters
▸ **democracyReferendumVoters**(referendumId: * `ReferendumIndex` &#124; `BN` &#124; `number`*): `Observable`<`Array`<[RxReferendumVote](../modules/_types_d_.md#rxreferendumvote)>>
▸ **democracyReferendumVoters**(referendumId: * `ReferendumIndex` &#124; `BN` &#124; `number`*): `Observable`<`Array`<`RxReferendumVote`>>
*Inherited from [ApiCombined](_combined_.apicombined.md).[democracyReferendumVoters](_combined_.apicombined.md#democracyreferendumvoters)*
*Defined in [Combined.ts:42](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L42)*
*Defined in [Combined.ts:42](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L42)*
**Parameters:**
@@ -279,7 +233,7 @@ ___
| ------ | ------ |
| referendumId | `ReferendumIndex` &#124; `BN` &#124; `number`|
**Returns:** `Observable`<`Array`<[RxReferendumVote](../modules/_types_d_.md#rxreferendumvote)>>
**Returns:** `Observable`<`Array`<`RxReferendumVote`>>
___
<a id="democracyvotersbalancesof"></a>
@@ -290,7 +244,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[democracyVotersBalancesOf](_combined_.apicombined.md#democracyvotersbalancesof)*
*Defined in [Combined.ts:87](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L87)*
*Defined in [Combined.ts:87](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L87)*
**Parameters:**
@@ -309,7 +263,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[democracyVotersVotesOf](_combined_.apicombined.md#democracyvotersvotesof)*
*Defined in [Combined.ts:103](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L103)*
*Defined in [Combined.ts:103](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L103)*
**Parameters:**
@@ -328,7 +282,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[democracyVotingPeriod](_queries_.apiqueries.md#democracyvotingperiod)*
*Defined in [Queries.ts:115](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L115)*
*Defined in [Queries.ts:115](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L115)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -341,7 +295,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[eraBlockLength](_combined_.apicombined.md#erablocklength)*
*Defined in [Combined.ts:114](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L114)*
*Defined in [Combined.ts:114](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L114)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -354,7 +308,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[eraBlockProgress](_combined_.apicombined.md#erablockprogress)*
*Defined in [Combined.ts:129](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L129)*
*Defined in [Combined.ts:129](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L129)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -367,7 +321,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[eraBlockRemaining](_combined_.apicombined.md#erablockremaining)*
*Defined in [Combined.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L152)*
*Defined in [Combined.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L152)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -380,7 +334,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[eraLastLengthChange](_queries_.apiqueries.md#eralastlengthchange)*
*Defined in [Queries.ts:140](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L140)*
*Defined in [Queries.ts:140](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L140)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -389,13 +343,13 @@ ___
## fees
▸ **fees**(): `Observable`<[RxFees](../modules/_types_d_.md#rxfees)>
▸ **fees**(): `Observable`<`RxFees`>
*Inherited from [ApiQueries](_queries_.apiqueries.md).[fees](_queries_.apiqueries.md#fees)*
*Defined in [Queries.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L119)*
*Defined in [Queries.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L119)*
**Returns:** `Observable`<[RxFees](../modules/_types_d_.md#rxfees)>
**Returns:** `Observable`<`RxFees`>
___
<a id="getblock"></a>
@@ -406,7 +360,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[getBlock](_calls_.apicalls.md#getblock)*
*Defined in [Calls.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L29)*
*Defined in [Calls.ts:29](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L29)*
**Parameters:**
@@ -425,7 +379,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[isConnected](_base_.apibase.md#isconnected)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L89)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L89)*
**Returns:** `Observable`<`boolean`>
@@ -438,7 +392,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[newHead](_calls_.apicalls.md#newhead)*
*Defined in [Calls.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L33)*
*Defined in [Calls.ts:33](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L33)*
**Returns:** `Observable`< `Header` &#124; `undefined`>
@@ -451,7 +405,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[proposalDeposits](_queries_.apiqueries.md#proposaldeposits)*
*Defined in [Queries.ts:49](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L49)*
*Defined in [Queries.ts:49](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L49)*
**Parameters:**
@@ -470,7 +424,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[publicProposalCount](_combined_.apicombined.md#publicproposalcount)*
*Defined in [Combined.ts:20](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L20)*
*Defined in [Combined.ts:20](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L20)*
**Returns:** `Observable`<`number`>
@@ -483,7 +437,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[publicProposals](_queries_.apiqueries.md#publicproposals)*
*Defined in [Queries.ts:62](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L62)*
*Defined in [Queries.ts:62](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L62)*
**Returns:** `Observable`<`Array`<[RxProposal](_classes_.rxproposal.md)>>
@@ -496,7 +450,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawCall](_base_.apibase.md#rawcall)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L93)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L93)*
**Type parameters:**
@@ -519,7 +473,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawStorage](_base_.apibase.md#rawstorage)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L106)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L106)*
**Type parameters:**
@@ -542,7 +496,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawStorageMulti](_base_.apibase.md#rawstoragemulti)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L119)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L119)*
**Type parameters:**
@@ -564,7 +518,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumCount](_queries_.apiqueries.md#referendumcount)*
*Defined in [Queries.ts:81](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L81)*
*Defined in [Queries.ts:81](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L81)*
**Returns:** `Observable`< `ReferendumIndex` &#124; `undefined`>
@@ -577,7 +531,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumInfo](_queries_.apiqueries.md#referenduminfo)*
*Defined in [Queries.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L85)*
*Defined in [Queries.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L85)*
**Parameters:**
@@ -596,7 +550,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumVote](_queries_.apiqueries.md#referendumvote)*
*Defined in [Queries.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L98)*
*Defined in [Queries.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L98)*
**Parameters:**
@@ -616,7 +570,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[referendumVoters](_queries_.apiqueries.md#referendumvoters)*
*Defined in [Queries.ts:102](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L102)*
*Defined in [Queries.ts:102](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L102)*
**Parameters:**
@@ -635,7 +589,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[referendumVotes](_combined_.apicombined.md#referendumvotes)*
*Defined in [Combined.ts:79](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L79)*
*Defined in [Combined.ts:79](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L79)*
**Parameters:**
@@ -655,7 +609,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[referendums](_combined_.apicombined.md#referendums)*
*Defined in [Combined.ts:58](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L58)*
*Defined in [Combined.ts:58](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L58)*
**Returns:** `Observable`<`Array`<[RxReferendum](_classes_.rxreferendum.md)>>
@@ -668,7 +622,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[referendumsInfo](_combined_.apicombined.md#referendumsinfo)*
*Defined in [Combined.ts:30](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L30)*
*Defined in [Combined.ts:30](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L30)*
**Parameters:**
@@ -687,7 +641,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[sessionBlockProgress](_combined_.apicombined.md#sessionblockprogress)*
*Defined in [Combined.ts:167](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L167)*
*Defined in [Combined.ts:167](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L167)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -700,7 +654,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[sessionBlockRemaining](_combined_.apicombined.md#sessionblockremaining)*
*Defined in [Combined.ts:187](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L187)*
*Defined in [Combined.ts:187](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L187)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -713,7 +667,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[sessionBrokenValue](_combined_.apicombined.md#sessionbrokenvalue)*
*Defined in [Combined.ts:202](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L202)*
*Defined in [Combined.ts:202](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L202)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -726,7 +680,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionCurrentIndex](_queries_.apiqueries.md#sessioncurrentindex)*
*Defined in [Queries.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L152)*
*Defined in [Queries.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L152)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -739,7 +693,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionCurrentStart](_queries_.apiqueries.md#sessioncurrentstart)*
*Defined in [Queries.ts:156](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L156)*
*Defined in [Queries.ts:156](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L156)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -752,7 +706,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionLastLengthChange](_queries_.apiqueries.md#sessionlastlengthchange)*
*Defined in [Queries.ts:160](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L160)*
*Defined in [Queries.ts:160](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L160)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -765,7 +719,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionLength](_queries_.apiqueries.md#sessionlength)*
*Defined in [Queries.ts:164](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L164)*
*Defined in [Queries.ts:164](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L164)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -778,7 +732,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionReward](_queries_.apiqueries.md#sessionreward)*
*Defined in [Queries.ts:144](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L144)*
*Defined in [Queries.ts:144](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L144)*
**Returns:** `Observable`< `Perbill` &#124; `undefined`>
@@ -791,7 +745,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionRewardCurrent](_queries_.apiqueries.md#sessionrewardcurrent)*
*Defined in [Queries.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L148)*
*Defined in [Queries.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L148)*
**Returns:** `Observable`< `Balance` &#124; `undefined`>
@@ -804,7 +758,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[sessionTimeExpected](_combined_.apicombined.md#sessiontimeexpected)*
*Defined in [Combined.ts:221](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L221)*
*Defined in [Combined.ts:221](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L221)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -817,7 +771,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[sessionTimeRemaining](_combined_.apicombined.md#sessiontimeremaining)*
*Defined in [Combined.ts:236](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L236)*
*Defined in [Combined.ts:236](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L236)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -830,7 +784,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionValidators](_queries_.apiqueries.md#sessionvalidators)*
*Defined in [Queries.ts:172](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L172)*
*Defined in [Queries.ts:172](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L172)*
**Returns:** `Observable`<`Array`<`AccountId`>>
@@ -843,7 +797,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[sessionsPerEra](_queries_.apiqueries.md#sessionsperera)*
*Defined in [Queries.ts:168](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L168)*
*Defined in [Queries.ts:168](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L168)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -856,7 +810,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingIntentions](_queries_.apiqueries.md#stakingintentions)*
*Defined in [Queries.ts:185](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L185)*
*Defined in [Queries.ts:185](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L185)*
**Returns:** `Observable`<`Array`<`AccountId`>>
@@ -869,7 +823,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingNominating](_queries_.apiqueries.md#stakingnominating)*
*Defined in [Queries.ts:211](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L211)*
*Defined in [Queries.ts:211](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L211)*
**Parameters:**
@@ -888,7 +842,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[stakingNominatorsFor](_queries_.apiqueries.md#stakingnominatorsfor)*
*Defined in [Queries.ts:198](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L198)*
*Defined in [Queries.ts:198](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L198)*
**Parameters:**
@@ -907,7 +861,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[submitExtrinsic](_calls_.apicalls.md#submitextrinsic)*
*Defined in [Calls.ts:47](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L47)*
*Defined in [Calls.ts:47](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L47)*
**Parameters:**
@@ -926,7 +880,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[systemName](_calls_.apicalls.md#systemname)*
*Defined in [Calls.ts:39](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L39)*
*Defined in [Calls.ts:39](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L39)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
@@ -939,7 +893,7 @@ ___
*Inherited from [ApiCalls](_calls_.apicalls.md).[systemVersion](_calls_.apicalls.md#systemversion)*
*Defined in [Calls.ts:43](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Calls.ts#L43)*
*Defined in [Calls.ts:43](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Calls.ts#L43)*
**Returns:** `Observable`< `Text` &#124; `undefined`>
@@ -948,11 +902,11 @@ ___
## validatingBalance
▸ **validatingBalance**(address: * `AccountId` &#124; `string`*): `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)>
▸ **validatingBalance**(address: * `AccountId` &#124; `string`*): `Observable`<`RxBalance`>
*Inherited from [ApiCombined](_combined_.apicombined.md).[validatingBalance](_combined_.apicombined.md#validatingbalance)*
*Defined in [Combined.ts:251](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L251)*
*Defined in [Combined.ts:251](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L251)*
**Parameters:**
@@ -960,18 +914,18 @@ ___
| ------ | ------ |
| address | `AccountId` &#124; `string`|
**Returns:** `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)>
**Returns:** `Observable`<`RxBalance`>
___
<a id="validatingbalances"></a>
## validatingBalances
▸ **validatingBalances**(...addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<[RxBalanceMap](../modules/_types_d_.md#rxbalancemap)>
▸ **validatingBalances**(...addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<`RxBalanceMap`>
*Inherited from [ApiCombined](_combined_.apicombined.md).[validatingBalances](_combined_.apicombined.md#validatingbalances)*
*Defined in [Combined.ts:276](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L276)*
*Defined in [Combined.ts:276](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L276)*
**Parameters:**
@@ -979,7 +933,7 @@ ___
| ------ | ------ |
| `Rest` addresses | `Array`< `AccountId` &#124; `string`> |
**Returns:** `Observable`<[RxBalanceMap](../modules/_types_d_.md#rxbalancemap)>
**Returns:** `Observable`<`RxBalanceMap`>
___
<a id="validatorcount"></a>
@@ -990,7 +944,7 @@ ___
*Inherited from [ApiQueries](_queries_.apiqueries.md).[validatorCount](_queries_.apiqueries.md#validatorcount)*
*Defined in [Queries.ts:215](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L215)*
*Defined in [Queries.ts:215](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L215)*
**Returns:** `Observable`< `u32` &#124; `undefined`>
@@ -999,11 +953,11 @@ ___
## votingBalance
▸ **votingBalance**(_address: * `AccountId` &#124; `string`*): `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)>
▸ **votingBalance**(_address: * `AccountId` &#124; `string`*): `Observable`<`RxBalance`>
*Inherited from [ApiCombined](_combined_.apicombined.md).[votingBalance](_combined_.apicombined.md#votingbalance)*
*Defined in [Combined.ts:290](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L290)*
*Defined in [Combined.ts:290](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L290)*
**Parameters:**
@@ -1011,18 +965,18 @@ ___
| ------ | ------ |
| _address | `AccountId` &#124; `string`|
**Returns:** `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)>
**Returns:** `Observable`<`RxBalance`>
___
<a id="votingbalances"></a>
## votingBalances
▸ **votingBalances**(...addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)[]>
▸ **votingBalances**(...addresses: *`Array`< `AccountId` &#124; `string`>*): `Observable`<`RxBalance`[]>
*Inherited from [ApiCombined](_combined_.apicombined.md).[votingBalances](_combined_.apicombined.md#votingbalances)*
*Defined in [Combined.ts:324](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L324)*
*Defined in [Combined.ts:324](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L324)*
**Parameters:**
@@ -1030,7 +984,7 @@ ___
| ------ | ------ |
| `Rest` addresses | `Array`< `AccountId` &#124; `string`> |
**Returns:** `Observable`<[RxBalance](../modules/_types_d_.md#rxbalance)[]>
**Returns:** `Observable`<`RxBalance`[]>
___
<a id="votingbalancesnominatorsfor"></a>
@@ -1041,7 +995,7 @@ ___
*Inherited from [ApiCombined](_combined_.apicombined.md).[votingBalancesNominatorsFor](_combined_.apicombined.md#votingbalancesnominatorsfor)*
*Defined in [Combined.ts:313](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Combined.ts#L313)*
*Defined in [Combined.ts:313](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Combined.ts#L313)*
**Parameters:**
@@ -18,7 +18,7 @@
*Inherited from [ApiBase](_base_.apibase.md).[constructor](_base_.apibase.md#constructor)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
**Parameters:**
@@ -32,28 +32,6 @@ ___
# Properties
<a id="_api"></a>
## `<Protected>` _api
**● _api**: *`RpcRxInterface`*
*Inherited from [ApiBase](_base_.apibase.md).[_api](_base_.apibase.md#_api)*
*Defined in [Base.ts:28](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L28)*
___
<a id="_genesishash"></a>
## `<Protected>` _genesisHash
**● _genesisHash**: *`Hash`*
*Inherited from [ApiBase](_base_.apibase.md).[_genesisHash](_base_.apibase.md#_genesishash)*
*Defined in [Base.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L29)*
___
<a id="whenready"></a>
## whenReady
@@ -62,7 +40,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[whenReady](_base_.apibase.md#whenready)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L32)*
*Defined in [Base.ts:32](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L32)*
___
<a id="extrinsics"></a>
@@ -73,7 +51,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[extrinsics](_base_.apibase.md#extrinsics)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L40)*
*Defined in [Base.ts:40](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L40)*
___
<a id="storage"></a>
@@ -84,7 +62,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[storage](_base_.apibase.md#storage)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L41)*
*Defined in [Base.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L41)*
___
@@ -98,7 +76,7 @@ getgenesisHash(): `Hash`
*Inherited from [ApiBase](_base_.apibase.md).[genesisHash](_base_.apibase.md#genesishash)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L85)*
*Defined in [Base.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L85)*
**Returns:** `Hash`
@@ -112,7 +90,7 @@ ___
▸ **accountNonce**(address: * `AccountId` &#124; `string`*): `Observable`< `Index` &#124; `undefined`>
*Defined in [Queries.ts:21](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L21)*
*Defined in [Queries.ts:21](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L21)*
**Parameters:**
@@ -129,7 +107,7 @@ ___
▸ **balanceFree**(address: * `AccountId` &#124; `string`*): `Observable`< `Balance` &#124; `undefined`>
*Defined in [Queries.ts:25](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L25)*
*Defined in [Queries.ts:25](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L25)*
**Parameters:**
@@ -146,7 +124,7 @@ ___
▸ **balanceReserved**(address: * `AccountId` &#124; `string`*): `Observable`< `Balance` &#124; `undefined`>
*Defined in [Queries.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L29)*
*Defined in [Queries.ts:29](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L29)*
**Parameters:**
@@ -163,7 +141,7 @@ ___
▸ **blockNow**(): `Observable`< `Moment` &#124; `undefined`>
*Defined in [Queries.ts:37](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L37)*
*Defined in [Queries.ts:37](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L37)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -174,34 +152,10 @@ ___
▸ **blockPeriod**(): `Observable`< `Moment` &#124; `undefined`>
*Defined in [Queries.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L33)*
*Defined in [Queries.ts:33](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L33)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
___
<a id="combine"></a>
## `<Protected>` combine
▸ **combine**<`T`,`R`>(observables: *`Array`<`Observable`<`any`>>*, mapfn?: *`MapFn`<`R`, `T`>*): `Observable`<`T`>
*Inherited from [ApiBase](_base_.apibase.md).[combine](_base_.apibase.md#combine)*
*Defined in [Base.ts:78](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L78)*
**Type parameters:**
#### T
#### R
**Parameters:**
| Param | Type | Default value |
| ------ | ------ | ------ |
| observables | `Array`<`Observable`<`any`>> | - |
| `Default value` mapfn | `MapFn`<`R`, `T`> | defaultMapFn |
**Returns:** `Observable`<`T`>
___
<a id="democracylaunchperiod"></a>
@@ -209,7 +163,7 @@ ___
▸ **democracyLaunchPeriod**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Queries.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L41)*
*Defined in [Queries.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L41)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -220,7 +174,7 @@ ___
▸ **democracyNextTally**(): `Observable`< `ReferendumIndex` &#124; `undefined`>
*Defined in [Queries.ts:45](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L45)*
*Defined in [Queries.ts:45](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L45)*
**Returns:** `Observable`< `ReferendumIndex` &#124; `undefined`>
@@ -231,7 +185,7 @@ ___
▸ **democracyVotingPeriod**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Queries.ts:115](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L115)*
*Defined in [Queries.ts:115](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L115)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -242,7 +196,7 @@ ___
▸ **eraLastLengthChange**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Queries.ts:140](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L140)*
*Defined in [Queries.ts:140](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L140)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -251,11 +205,11 @@ ___
## fees
▸ **fees**(): `Observable`<[RxFees](../modules/_types_d_.md#rxfees)>
▸ **fees**(): `Observable`<`RxFees`>
*Defined in [Queries.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L119)*
*Defined in [Queries.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L119)*
**Returns:** `Observable`<[RxFees](../modules/_types_d_.md#rxfees)>
**Returns:** `Observable`<`RxFees`>
___
<a id="isconnected"></a>
@@ -266,7 +220,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[isConnected](_base_.apibase.md#isconnected)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L89)*
*Defined in [Base.ts:89](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L89)*
**Returns:** `Observable`<`boolean`>
@@ -277,7 +231,7 @@ ___
▸ **proposalDeposits**(proposalId: * `PropIndex` &#124; `BN` &#124; `number`*): `Observable`< [RxProposalDeposits](_classes_.rxproposaldeposits.md) &#124; `undefined`>
*Defined in [Queries.ts:49](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L49)*
*Defined in [Queries.ts:49](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L49)*
**Parameters:**
@@ -294,7 +248,7 @@ ___
▸ **publicProposals**(): `Observable`<`Array`<[RxProposal](_classes_.rxproposal.md)>>
*Defined in [Queries.ts:62](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L62)*
*Defined in [Queries.ts:62](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L62)*
**Returns:** `Observable`<`Array`<[RxProposal](_classes_.rxproposal.md)>>
@@ -307,7 +261,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawCall](_base_.apibase.md#rawcall)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L93)*
*Defined in [Base.ts:93](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L93)*
**Type parameters:**
@@ -330,7 +284,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawStorage](_base_.apibase.md#rawstorage)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L106)*
*Defined in [Base.ts:106](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L106)*
**Type parameters:**
@@ -353,7 +307,7 @@ ___
*Inherited from [ApiBase](_base_.apibase.md).[rawStorageMulti](_base_.apibase.md#rawstoragemulti)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Base.ts#L119)*
*Defined in [Base.ts:119](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Base.ts#L119)*
**Type parameters:**
@@ -373,7 +327,7 @@ ___
▸ **referendumCount**(): `Observable`< `ReferendumIndex` &#124; `undefined`>
*Defined in [Queries.ts:81](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L81)*
*Defined in [Queries.ts:81](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L81)*
**Returns:** `Observable`< `ReferendumIndex` &#124; `undefined`>
@@ -384,7 +338,7 @@ ___
▸ **referendumInfo**(referendumId: * `ReferendumIndex` &#124; `BN` &#124; `number`*): `Observable`< [RxReferendum](_classes_.rxreferendum.md) &#124; `undefined`>
*Defined in [Queries.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L85)*
*Defined in [Queries.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L85)*
**Parameters:**
@@ -401,7 +355,7 @@ ___
▸ **referendumVote**(index: * `ReferendumIndex` &#124; `BN` &#124; `number`*, address: * `AccountId` &#124; `string`*): `Observable`< `Bool` &#124; `undefined`>
*Defined in [Queries.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L98)*
*Defined in [Queries.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L98)*
**Parameters:**
@@ -419,7 +373,7 @@ ___
▸ **referendumVoters**(index: * `ReferendumIndex` &#124; `BN` &#124; `number`*): `Observable`<`Array`<`AccountId`>>
*Defined in [Queries.ts:102](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L102)*
*Defined in [Queries.ts:102](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L102)*
**Parameters:**
@@ -436,7 +390,7 @@ ___
▸ **sessionCurrentIndex**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Queries.ts:152](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L152)*
*Defined in [Queries.ts:152](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L152)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -447,7 +401,7 @@ ___
▸ **sessionCurrentStart**(): `Observable`< `Moment` &#124; `undefined`>
*Defined in [Queries.ts:156](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L156)*
*Defined in [Queries.ts:156](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L156)*
**Returns:** `Observable`< `Moment` &#124; `undefined`>
@@ -458,7 +412,7 @@ ___
▸ **sessionLastLengthChange**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Queries.ts:160](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L160)*
*Defined in [Queries.ts:160](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L160)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -469,7 +423,7 @@ ___
▸ **sessionLength**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Queries.ts:164](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L164)*
*Defined in [Queries.ts:164](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L164)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -480,7 +434,7 @@ ___
▸ **sessionReward**(): `Observable`< `Perbill` &#124; `undefined`>
*Defined in [Queries.ts:144](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L144)*
*Defined in [Queries.ts:144](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L144)*
**Returns:** `Observable`< `Perbill` &#124; `undefined`>
@@ -491,7 +445,7 @@ ___
▸ **sessionRewardCurrent**(): `Observable`< `Balance` &#124; `undefined`>
*Defined in [Queries.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L148)*
*Defined in [Queries.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L148)*
**Returns:** `Observable`< `Balance` &#124; `undefined`>
@@ -502,7 +456,7 @@ ___
▸ **sessionValidators**(): `Observable`<`Array`<`AccountId`>>
*Defined in [Queries.ts:172](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L172)*
*Defined in [Queries.ts:172](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L172)*
**Returns:** `Observable`<`Array`<`AccountId`>>
@@ -513,7 +467,7 @@ ___
▸ **sessionsPerEra**(): `Observable`< `BlockNumber` &#124; `undefined`>
*Defined in [Queries.ts:168](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L168)*
*Defined in [Queries.ts:168](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L168)*
**Returns:** `Observable`< `BlockNumber` &#124; `undefined`>
@@ -524,7 +478,7 @@ ___
▸ **stakingIntentions**(): `Observable`<`Array`<`AccountId`>>
*Defined in [Queries.ts:185](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L185)*
*Defined in [Queries.ts:185](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L185)*
**Returns:** `Observable`<`Array`<`AccountId`>>
@@ -535,7 +489,7 @@ ___
▸ **stakingNominating**(address: * `AccountId` &#124; `string`*): `Observable`< `AccountId` &#124; `undefined`>
*Defined in [Queries.ts:211](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L211)*
*Defined in [Queries.ts:211](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L211)*
**Parameters:**
@@ -552,7 +506,7 @@ ___
▸ **stakingNominatorsFor**(address: * `AccountId` &#124; `string`*): `Observable`<`Array`<`AccountId`>>
*Defined in [Queries.ts:198](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L198)*
*Defined in [Queries.ts:198](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L198)*
**Parameters:**
@@ -569,7 +523,7 @@ ___
▸ **validatorCount**(): `Observable`< `u32` &#124; `undefined`>
*Defined in [Queries.ts:215](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/Queries.ts#L215)*
*Defined in [Queries.ts:215](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api-observable/src/Queries.ts#L215)*
**Returns:** `Observable`< `u32` &#124; `undefined`>
-61
View File
@@ -1,61 +0,0 @@
# Type aliases
<a id="apifunctions"></a>
## ApiFunctions
**Ƭ ApiFunctions**: * `keyof ApiBase` &#124; `keyof ApiCalls` &#124; `keyof ApiCombined` &#124; `keyof ApiQueries`
*
*Defined in [types.d.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/types.d.ts#L14)*
___
<a id="rxbalance"></a>
## RxBalance
**Ƭ RxBalance**: *`object`*
*Defined in [types.d.ts:16](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/types.d.ts#L16)*
#### Type declaration
___
<a id="rxbalancemap"></a>
## RxBalanceMap
**Ƭ RxBalanceMap**: *`object`*
*Defined in [types.d.ts:40](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/types.d.ts#L40)*
#### Type declaration
[index: `string`]: [RxBalance](_types_d_.md#rxbalance)
___
<a id="rxfees"></a>
## RxFees
**Ƭ RxFees**: *`object`*
*Defined in [types.d.ts:26](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/types.d.ts#L26)*
#### Type declaration
___
<a id="rxreferendumvote"></a>
## RxReferendumVote
**Ƭ RxReferendumVote**: *`object`*
*Defined in [types.d.ts:34](https://github.com/polkadot-js/api/blob/f5948fe/packages/api-observable/src/types.d.ts#L34)*
#### Type declaration
___
+41 -21
View File
@@ -1,13 +1,27 @@
[![polkadotjs](https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square)](https://polkadot.js.org) ![isc](https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square) [![style](https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square)](https://github.com/Flet/semistandard) [![npm](https://img.shields.io/npm/v/@polkadot/api.svg?style=flat-square)](https://www.npmjs.com/package/@polkadot/api) [![travis](https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square)](https://travis-ci.org/polkadot-js/api) [![maintainability](https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square)](https://codeclimate.com/github/polkadot-js/api/maintainability) [![coverage](https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square)](https://coveralls.io/github/polkadot-js/api?branch=master) [![dependency](https://david-dm.org/polkadot-js/api.svg?style=flat-square&path=packages/api)](https://david-dm.org/polkadot-js/api?path=packages/api) [![devDependency](https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&path=packages/api)](https://david-dm.org/polkadot-js/api?path=packages/api#info=devDependencies)
@polkadot/api
=============
An RxJs wrapper around [@polkadot/rpc-core](../rpc-core).
The Polkadot-JS API provides easy-to-use wrappers around JSONRPC calls that flow from an application to a node. It handles all the encoding and decoding or parameters, provides access to RPC functions and allows for the query of chain state and the submission of transactions.
Usage
=====
The API wrappers provide a standard interface for use -
* A static `.create(<optional WsProvider>)` that returns an API istance when connected, decorated and ready-to use
* The above is just a wrapper for `new Api(<optional WsProvider>)`, exposing the `isReady` getter
* `api.rpc.*` provides access to actual RPC calls, be it for queries, submission or retrieving chain information
* `api.st.*` provides access to chain state queries. These are dynamically populated based on what the runtime provides
* `api.tx.*` provides the ability to create transaction, like chain state, this list is populated from a runtime query
API Selection
-------------
There are two flavours of the API provided, one allowing a standard interface via JavaScript Promises and the second provides an Observable wrapper using [RxJS](https://github.com/ReactiveX/rxjs). Depending on your use-case and familiarity, you can choose either (or even both) for your application.
* [ApiPromise](promise/) All interface calls returns Promises, including the static `.create(...)`. Additionally any subscription method use standard JavaScript `(error, value) => {}` callbacks.
* [ApiRx](rx/) All interface calls return RxJS Observables, including the static `.create(...)`. In the same fashion and subscription-based methods return long-running Observables that update with the latest values.
Installation & import
---------------------
Installation -
@@ -15,14 +29,26 @@ Installation -
npm install --save @polkadot/api/rx
```
Making rpc calls -
Subscribing to blocks via Promise-based API -
```javascript
import ApiRx from '@polkadot/api/rx';
// alternatively
// import { ApiRx } from '@polkadot/api';
import { ApiPromise } from '@polkadot/api';
// initialise via Promise & static create
// initialise via static create
const api = await ApiPromise.create();
// make a call to retrieve the current network head
api.rpc.chain.newHead((error, header) => {
console.log(`Chain is at #${header.blockNumber}`);
});
```
Subscribing to blocks via RxJS-based API -
```javascript
import { ApiRx } from '@polkadot/api';
// initialise via static create
const api = await ApiRx.create().toPromise();
// make a call to retrieve the current network head
@@ -31,17 +57,11 @@ api.rpc.chain.newHead().subscribe((header) => {
});
```
Subscribing to chain state -
Users
-----
```javascript
import Api from '@polkadot/api';
Some of the users of the API (let us know if you are missing from the list), include -
// initialise via isReady & new
new Api().isReady.subscribe((api) => {
// make a call to retrieve the current network head
api.st.timestamp.now().subscribe((timestamp) => {
console.log(`Current block timestamp ${timestamp}`);
});
});
```
* [Polkadot-JS UI](https://github.com/polkadot-js/apps) A user-interface that allows you to make transactions, query the network or participate in actions on the network such as referendums and staking
* [Polkabot](https://gitlab.com/Polkabot) Polkabot is a Matrix chatbot that keeps an eye on the Polkadot network. You can see Polkabot in action in [https://matrix.to/#/#polkadot-network-status:matrix.org](https://matrix.to/#/#polkadot-network-status:matrix.org)
-18
View File
@@ -5,25 +5,7 @@
* [SubmittableExtrinsic](classes/_promise_submittableextrinsic_.submittableextrinsic.md)
* [&quot;promise/index&quot;](modules/_promise_index_.md)
* [ApiPromise](classes/_promise_index_.apipromise.md)
* [&quot;promise/types.d&quot;](modules/_promise_types_d_.md)
* [ApiPromiseInterface](interfaces/_promise_types_d_.apipromiseinterface.md)
* [QueryableModuleStorage](interfaces/_promise_types_d_.queryablemodulestorage.md)
* [QueryableStorage](interfaces/_promise_types_d_.queryablestorage.md)
* [QueryableStorageFunction](interfaces/_promise_types_d_.queryablestoragefunction.md)
* [SubmittableExtrinsicFunction](interfaces/_promise_types_d_.submittableextrinsicfunction.md)
* [SubmittableExtrinsics](interfaces/_promise_types_d_.submittableextrinsics.md)
* [SubmittableModuleExtrinsics](interfaces/_promise_types_d_.submittablemoduleextrinsics.md)
* [&quot;rx/SubmittableExtrinsic&quot;](modules/_rx_submittableextrinsic_.md)
* [SubmittableExtrinsic](classes/_rx_submittableextrinsic_.submittableextrinsic.md)
* [&quot;rx/index&quot;](modules/_rx_index_.md)
* [ApiRx](classes/_rx_index_.apirx.md)
* [&quot;rx/types.d&quot;](modules/_rx_types_d_.md)
* [ApiRxInterface](interfaces/_rx_types_d_.apirxinterface.md)
* [QueryableModuleStorage](interfaces/_rx_types_d_.queryablemodulestorage.md)
* [QueryableStorage](interfaces/_rx_types_d_.queryablestorage.md)
* [QueryableStorageFunction](interfaces/_rx_types_d_.queryablestoragefunction.md)
* [SubmittableExtrinsicFunction](interfaces/_rx_types_d_.submittableextrinsicfunction.md)
* [SubmittableExtrinsics](interfaces/_rx_types_d_.submittableextrinsics.md)
* [SubmittableModuleExtrinsics](interfaces/_rx_types_d_.submittablemoduleextrinsics.md)
* [&quot;types.d&quot;](modules/_types_d_.md)
* [ApiBaseInterface](interfaces/_types_d_.apibaseinterface.md)
+8 -140
View File
@@ -18,7 +18,7 @@
# Implements
* [ApiBaseInterface](../interfaces/_types_d_.apibaseinterface.md)<`R`, `S`, `E`>
* `ApiBaseInterface`<`R`, `S`, `E`>
# Constructors
@@ -28,7 +28,7 @@
⊕ **new ApiBase**(wsProvider?: *`WsProvider`*): [ApiBase](_base_.apibase.md)
*Defined in [Base.ts:39](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L39)*
*Defined in [Base.ts:39](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L39)*
*__example__*:
```javascript
@@ -53,69 +53,6 @@ ___
# Properties
<a id="_extrinsics"></a>
## `<Protected>``<Optional>` _extrinsics
**● _extrinsics**: *[E]()*
*Defined in [Base.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L33)*
___
<a id="_genesishash"></a>
## `<Protected>``<Optional>` _genesisHash
**● _genesisHash**: *`Hash`*
*Defined in [Base.ts:34](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L34)*
___
<a id="_rpc"></a>
## `<Protected>` _rpc
**● _rpc**: *`R`*
*Defined in [Base.ts:36](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L36)*
___
<a id="_rpcbase"></a>
## `<Protected>` _rpcBase
**● _rpcBase**: *`Rpc`*
*Defined in [Base.ts:37](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L37)*
___
<a id="_runtimemetadata"></a>
## `<Protected>``<Optional>` _runtimeMetadata
**● _runtimeMetadata**: *`RuntimeMetadata`*
*Defined in [Base.ts:38](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L38)*
___
<a id="_runtimeversion"></a>
## `<Protected>``<Optional>` _runtimeVersion
**● _runtimeVersion**: *`RuntimeVersion`*
*Defined in [Base.ts:39](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L39)*
___
<a id="_storage"></a>
## `<Protected>``<Optional>` _storage
**● _storage**: *[S]()*
*Defined in [Base.ts:35](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L35)*
___
<a id="prefixed"></a>
## `<Static>` prefixed
@@ -137,7 +74,7 @@ ___
getgenesisHash(): `Hash`
*Defined in [Base.ts:68](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L68)*
*Defined in [Base.ts:68](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L68)*
*__description__*: Contains the genesis Hash of the attached chain. Apart from being useful to determine the actual chain, it can also be used to sign immortal transactions.
@@ -150,7 +87,7 @@ ___
getrpc(): `R`
*Defined in [Base.ts:105](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L105)*
*Defined in [Base.ts:105](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L105)*
*__description__*: Contains all the raw rpc sections and their subsequent methods in the API as defined by the jsonrpc interface definitions.
@@ -172,7 +109,7 @@ ___
getruntimeMetadata(): `RuntimeMetadata`
*Defined in [Base.ts:77](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L77)*
*Defined in [Base.ts:77](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L77)*
*__description__*: Yields the current attached runtime metadata. Generally this is only used to construct extrinsics & storage, but is useful for current runtime inspection.
@@ -185,7 +122,7 @@ ___
getruntimeVersion(): `RuntimeVersion`
*Defined in [Base.ts:86](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L86)*
*Defined in [Base.ts:86](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L86)*
*__description__*: Contains the version information for the current runtime.
@@ -198,7 +135,7 @@ ___
getst(): `S`
*Defined in [Base.ts:122](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L122)*
*Defined in [Base.ts:122](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L122)*
*__description__*: Contains all the chain state modules and their subsequent methods in the API. These are attached dynamically from the runtime metadata.
@@ -220,7 +157,7 @@ ___
gettx(): `E`
*Defined in [Base.ts:143](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L143)*
*Defined in [Base.ts:143](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L143)*
*__description__*: Contains all the extrinsic modules and their subsequent methods in the API. It allows for the construction of transactions and the submission thereof. These are attached dynamically from the runtime metadata.
@@ -261,75 +198,6 @@ ___
**Returns:** `this`
___
<a id="decorateextrinsics"></a>
## `<Protected>``<Abstract>` decorateExtrinsics
▸ **decorateExtrinsics**(extrinsics: *`Extrinsics`*): `E`
*Defined in [Base.ts:214](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L214)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| extrinsics | `Extrinsics` |
**Returns:** `E`
___
<a id="decoratefunctionmeta"></a>
## `<Protected>` decorateFunctionMeta
▸ **decorateFunctionMeta**(input: *`MetaDecoration`*, output: *`MetaDecoration`*): `MetaDecoration`
*Defined in [Base.ts:200](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L200)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| input | `MetaDecoration` |
| output | `MetaDecoration` |
**Returns:** `MetaDecoration`
___
<a id="decoraterpc"></a>
## `<Protected>``<Abstract>` decorateRpc
▸ **decorateRpc**(rpc: *`Rpc`*): `R`
*Defined in [Base.ts:213](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L213)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| rpc | `Rpc` |
**Returns:** `R`
___
<a id="decoratestorage"></a>
## `<Protected>``<Abstract>` decorateStorage
▸ **decorateStorage**(storage: *`Storage`*): `S`
*Defined in [Base.ts:215](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L215)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| storage | `Storage` |
**Returns:** `S`
___
<a id="emit"></a>
+96 -170
View File
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../../examples/">
<li class="chapter " data-level="2.1" data-path="../../examples-rpc/">
<a href="../../examples/">
<a href="../../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../../examples-rpc/01_simple_connect/">
<a href="../../examples/01_simple_connect/">
<a href="../../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../../examples-rpc/02_listen_to_blocks/">
<a href="../../examples/02_listen_to_blocks/">
<a href="../../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../../examples-rpc/03_listen_to_balance_change/">
<a href="../../examples/03_listen_to_balance_change/">
<a href="../../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../../examples-rpc/04_generate_account/">
<a href="../../examples/04_generate_account/">
<a href="../../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../../examples-rpc/05_read_storage/">
<a href="../../examples/05_read_storage/">
<a href="../../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../../examples-rpc/06_craft_extrinsic/">
<a href="../../examples/06_craft_extrinsic/">
<a href="../../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../../examples-rpc/07_transfer_dots/">
<a href="../../examples/07_transfer_dots/">
<a href="../../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -422,22 +428,76 @@
<section class="normal markdown-section">
<h1 id="type-parameters">Type parameters</h1>
<p><em><strong>description</strong></em>: ApiPromise is a standard JavaScript wrapper around the RPC and interfaces on the Polkadot network. As a full Promise-based, all interface calls return Promises, including the static <code>.create(...)</code>. Subscription calls utilise standard JavaScript-convention <code>(error, value)</code> callbacks.</p>
<p>The API is well suited to real-time applications where either the single-shot state is needed or use is to be made of athe subscription-based features of Polkadot (and Substrate) clients.</p>
<p><em><strong>example</strong></em>: </p>
<p>Making rpc calls - </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">ApiPromise</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/promise&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;initialise&#xA0;via&#xA0;static&#xA0;create</span>
<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">api</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">await</span>&#xA0;<span class="sunlight-ident">ApiPromise</span><span class="sunlight-operator">.</span><span class="sunlight-ident">create</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;make&#xA0;a&#xA0;subscription&#xA0;to&#xA0;the&#xA0;network&#xA0;head</span>
<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">rpc</span><span class="sunlight-operator">.</span><span class="sunlight-ident">chain</span><span class="sunlight-operator">.</span><span class="sunlight-ident">newHead</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">error</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">header</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">Chain</span>&#xA0;<span class="sunlight-ident">is</span>&#xA0;<span class="sunlight-ident">at</span>&#xA0;<span class="sunlight-punctuation">#</span><span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">header</span><span class="sunlight-operator">.</span><span class="sunlight-ident">blockNumber</span><span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p>Subscribing to chain state - </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-punctuation">{</span>&#xA0;<span class="sunlight-ident">ApiPromise</span>&#xA0;<span class="sunlight-punctuation">}</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">WsProvider</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/rpc-provider/ws&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;initialise&#xA0;via&#xA0;isReady&#xA0;&amp;&#xA0;new&#xA0;with&#xA0;specific&#xA0;non-local&#xA0;endpoint</span>
<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">api</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">await</span>&#xA0;<span class="sunlight-keyword">new</span>&#xA0;<span class="sunlight-ident">ApiPromise</span><span class="sunlight-punctuation">(</span><span class="sunlight-keyword">new</span>&#xA0;<span class="sunlight-ident">WsProvider</span><span class="sunlight-punctuation">(</span><span class="sunlight-string">&apos;wss://example.com:9944&apos;</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">isReady</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;retrieve&#xA0;the&#xA0;block&#xA0;target&#xA0;time</span>
<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">blockPeriod</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">await</span>&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">blockPeriod</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">toNumber</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-ident">let</span>&#xA0;<span class="sunlight-ident">last</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-number">0</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;subscribe&#xA0;to&#xA0;the&#xA0;current&#xA0;block&#xA0;timestamp,&#xA0;updates&#xA0;automatically</span>
<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">now</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">error</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">elapsed</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">last</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">?</span>&#xA0;<span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">toNumber</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">-</span>&#xA0;<span class="sunlight-ident">last</span><span class="sunlight-punctuation">}</span><span class="sunlight-ident">s</span>&#xA0;<span class="sunlight-ident">since</span>&#xA0;<span class="sunlight-ident">last</span><span class="sunlight-punctuation">`</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">:</span>&#xA0;<span class="sunlight-string">&apos;&apos;</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-ident">last</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">toNumber</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">timestamp</span>&#xA0;<span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">}</span><span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">elapsed</span><span class="sunlight-punctuation">}</span>&#xA0;<span class="sunlight-punctuation">(</span><span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">blockPeriod</span><span class="sunlight-punctuation">}</span><span class="sunlight-ident">s</span>&#xA0;<span class="sunlight-ident">target</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p>Submitting a transaction - </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">ApiPromise</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/promise&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-ident">ApiPromise</span><span class="sunlight-operator">.</span><span class="sunlight-ident">create</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">then</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">api</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">nonce</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">await</span>&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">system</span><span class="sunlight-operator">.</span><span class="sunlight-ident">accountNonce</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">keyring</span><span class="sunlight-operator">.</span><span class="sunlight-ident">alice</span><span class="sunlight-operator">.</span><span class="sunlight-ident">address</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">tx</span><span class="sunlight-operator">.</span><span class="sunlight-ident">balances</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;create&#xA0;transfer</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">transfer</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">keyring</span><span class="sunlight-operator">.</span><span class="sunlight-ident">bob</span><span class="sunlight-operator">.</span><span class="sunlight-ident">address</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-number">12345</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;sign&#xA0;the&#xA0;transcation</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">sign</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">keyring</span><span class="sunlight-operator">.</span><span class="sunlight-ident">alice</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">nonce</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;send&#xA0;the&#xA0;transaction</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">send</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;retrieve&#xA0;the&#xA0;overall&#xA0;result</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">then</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">hash</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">submitted</span>&#xA0;<span class="sunlight-keyword">with</span>&#xA0;<span class="sunlight-ident">hash</span>&#xA0;<span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">hash</span><span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<h1 id="type-parameters">Type parameters</h1>
<h4 id="eventtypes----string--symbol">EventTypes : <code>string</code> | <code>symbol</code></h4>
<h1 id="hierarchy">Hierarchy</h1>
<p>&#x21B3; <a href="_base_.apibase.md">ApiBase</a>&lt;<code>Rpc</code>, <a href="../interfaces/_promise_types_d_.queryablestorage.md">QueryableStorage</a>, <a href="../interfaces/_promise_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a>&gt;</p>
<p>&#x21B3; <a href="_base_.apibase.md">ApiBase</a>&lt;<code>Rpc</code>, <code>QueryableStorage</code>, <code>SubmittableExtrinsics</code>&gt;</p>
<p><strong>&#x21B3; ApiPromise</strong></p>
<h1 id="implements">Implements</h1>
<ul>
<li><a href="../interfaces/_types_d_.apibaseinterface.md">ApiBaseInterface</a>&lt;<code>Rpc</code>, <a href="../interfaces/_promise_types_d_.queryablestorage.md">QueryableStorage</a>, <a href="../interfaces/_promise_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a>&gt;</li>
<li><a href="../interfaces/_promise_types_d_.apipromiseinterface.md">ApiPromiseInterface</a></li>
<li><code>ApiBaseInterface</code>&lt;<code>Rpc</code>, <code>QueryableStorage</code>, <code>SubmittableExtrinsics</code>&gt;</li>
<li><code>ApiPromiseInterface</code></li>
</ul>
<h1 id="constructors">Constructors</h1>
<p><a id="constructor"></a></p>
<h2 id="constructor">constructor</h2>
<p>&#x2295; <strong>new ApiPromise</strong>(wsProvider?: <em><code>WsProvider</code></em>): <a href="_promise_index_.apipromise.html">ApiPromise</a></p>
<p><em>Overrides <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#constructor">constructor</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L38" target="_blank">promise/index.ts:38</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/index.ts#L113" target="_blank">promise/index.ts:113</a></em></p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">Api</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/promise&apos;</span><span class="sunlight-punctuation">;</span>
@@ -467,48 +527,6 @@
<p><strong>Returns:</strong> <a href="_promise_index_.apipromise.html">ApiPromise</a></p>
<hr>
<h1 id="properties">Properties</h1>
<p><a id="_extrinsics"></a></p>
<h2 id="protectedoptional-extrinsics"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _extrinsics</h2>
<p><strong>&#x25CF; _extrinsics</strong>: <em><a href="">E</a></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_extrinsics">_extrinsics</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L33" target="_blank">Base.ts:33</a></em></p>
<hr>
<p><a id="_genesishash"></a></p>
<h2 id="protectedoptional-genesishash"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _genesisHash</h2>
<p><strong>&#x25CF; _genesisHash</strong>: <em><code>Hash</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_genesishash">_genesisHash</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L34" target="_blank">Base.ts:34</a></em></p>
<hr>
<p><a id="_rpc"></a></p>
<h2 id="protected-rpc"><code>&lt;Protected&gt;</code> _rpc</h2>
<p><strong>&#x25CF; _rpc</strong>: <em><code>Rpc</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_rpc">_rpc</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L36" target="_blank">Base.ts:36</a></em></p>
<hr>
<p><a id="_rpcbase"></a></p>
<h2 id="protected-rpcbase"><code>&lt;Protected&gt;</code> _rpcBase</h2>
<p><strong>&#x25CF; _rpcBase</strong>: <em><code>Rpc</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_rpcbase">_rpcBase</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L37" target="_blank">Base.ts:37</a></em></p>
<hr>
<p><a id="_runtimemetadata"></a></p>
<h2 id="protectedoptional-runtimemetadata"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _runtimeMetadata</h2>
<p><strong>&#x25CF; _runtimeMetadata</strong>: <em><code>RuntimeMetadata</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_runtimemetadata">_runtimeMetadata</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L38" target="_blank">Base.ts:38</a></em></p>
<hr>
<p><a id="_runtimeversion"></a></p>
<h2 id="protectedoptional-runtimeversion"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _runtimeVersion</h2>
<p><strong>&#x25CF; _runtimeVersion</strong>: <em><code>RuntimeVersion</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_runtimeversion">_runtimeVersion</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L39" target="_blank">Base.ts:39</a></em></p>
<hr>
<p><a id="_storage"></a></p>
<h2 id="protectedoptional-storage"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _storage</h2>
<p><strong>&#x25CF; _storage</strong>: <em><a href="">S</a></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_storage">_storage</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L35" target="_blank">Base.ts:35</a></em></p>
<hr>
<p><a id="prefixed"></a></p>
<h2 id="static-prefixed"><code>&lt;Static&gt;</code> prefixed</h2>
<p><strong>&#x25CF; prefixed</strong>: <em> <code>string</code> | <code>boolean</code>
@@ -521,14 +539,14 @@
<h2 id="genesishash">genesisHash</h2>
<p>getgenesisHash(): <code>Hash</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#genesishash">genesisHash</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L68" target="_blank">Base.ts:68</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L68" target="_blank">Base.ts:68</a></em></p>
<p><em><strong>description</strong></em>: Contains the genesis Hash of the attached chain. Apart from being useful to determine the actual chain, it can also be used to sign immortal transactions.</p>
<p><strong>Returns:</strong> <code>Hash</code></p>
<hr>
<p><a id="isready"></a></p>
<h2 id="isready">isReady</h2>
<p>getisReady(): <code>Promise</code>&lt;<a href="_promise_index_.apipromise.html">ApiPromise</a>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L68" target="_blank">promise/index.ts:68</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/index.ts#L143" target="_blank">promise/index.ts:143</a></em></p>
<p><em><strong>description</strong></em>: Promise that returns the first time we are connected and loaded</p>
<p><strong>Returns:</strong> <code>Promise</code>&lt;<a href="_promise_index_.apipromise.html">ApiPromise</a>&gt;</p>
<hr>
@@ -536,7 +554,7 @@
<h2 id="rpc">rpc</h2>
<p>getrpc(): <code>Rpc</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#rpc">rpc</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L105" target="_blank">Base.ts:105</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L105" target="_blank">Base.ts:105</a></em></p>
<p><em><strong>description</strong></em>: Contains all the raw rpc sections and their subsequent methods in the API as defined by the jsonrpc interface definitions.</p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">rpc</span><span class="sunlight-operator">.</span><span class="sunlight-ident">chain</span>
@@ -551,7 +569,7 @@
<h2 id="runtimemetadata">runtimeMetadata</h2>
<p>getruntimeMetadata(): <code>RuntimeMetadata</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#runtimemetadata">runtimeMetadata</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L77" target="_blank">Base.ts:77</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L77" target="_blank">Base.ts:77</a></em></p>
<p><em><strong>description</strong></em>: Yields the current attached runtime metadata. Generally this is only used to construct extrinsics &amp; storage, but is useful for current runtime inspection.</p>
<p><strong>Returns:</strong> <code>RuntimeMetadata</code></p>
<hr>
@@ -559,15 +577,15 @@
<h2 id="runtimeversion">runtimeVersion</h2>
<p>getruntimeVersion(): <code>RuntimeVersion</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#runtimeversion">runtimeVersion</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L86" target="_blank">Base.ts:86</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L86" target="_blank">Base.ts:86</a></em></p>
<p><em><strong>description</strong></em>: Contains the version information for the current runtime.</p>
<p><strong>Returns:</strong> <code>RuntimeVersion</code></p>
<hr>
<p><a id="st"></a></p>
<h2 id="st">st</h2>
<p>getst(): <a href="../interfaces/_promise_types_d_.queryablestorage.md">QueryableStorage</a></p>
<p>getst(): <code>QueryableStorage</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#st">st</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L122" target="_blank">Base.ts:122</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L122" target="_blank">Base.ts:122</a></em></p>
<p><em><strong>description</strong></em>: Contains all the chain state modules and their subsequent methods in the API. These are attached dynamically from the runtime metadata.</p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">balances</span>
@@ -576,13 +594,13 @@
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-string">&apos;new&#xA0;balance&apos;</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">balance</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p><strong>Returns:</strong> <a href="../interfaces/_promise_types_d_.queryablestorage.md">QueryableStorage</a></p>
<p><strong>Returns:</strong> <code>QueryableStorage</code></p>
<hr>
<p><a id="tx"></a></p>
<h2 id="tx">tx</h2>
<p>gettx(): <a href="../interfaces/_promise_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a></p>
<p>gettx(): <code>SubmittableExtrinsics</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#tx">tx</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L143" target="_blank">Base.ts:143</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L143" target="_blank">Base.ts:143</a></em></p>
<p><em><strong>description</strong></em>: Contains all the extrinsic modules and their subsequent methods in the API. It allows for the construction of transactions and the submission thereof. These are attached dynamically from the runtime metadata.</p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">tx</span><span class="sunlight-operator">.</span><span class="sunlight-ident">balances</span>
@@ -593,7 +611,7 @@
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-string">&apos;tx&#xA0;status&apos;</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">status</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p><strong>Returns:</strong> <a href="../interfaces/_promise_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a></p>
<p><strong>Returns:</strong> <code>SubmittableExtrinsics</code></p>
<hr>
<h1 id="methods">Methods</h1>
<p><a id="addlistener"></a></p>
@@ -626,98 +644,6 @@
</table>
<p><strong>Returns:</strong> <code>this</code></p>
<hr>
<p><a id="decorateextrinsics"></a></p>
<h2 id="protected-decorateextrinsics"><code>&lt;Protected&gt;</code> decorateExtrinsics</h2>
<p>&#x25B8; <strong>decorateExtrinsics</strong>(extrinsics: <em><code>Extrinsics</code></em>): <a href="../interfaces/_promise_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a></p>
<p><em>Overrides <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#decorateextrinsics">decorateExtrinsics</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L76" target="_blank">promise/index.ts:76</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
<tr>
<th>Param</th>
<th>Type</th>
</tr>
</thead>
<tbody>
<tr>
<td>extrinsics</td>
<td><code>Extrinsics</code></td>
</tr>
</tbody>
</table>
<p><strong>Returns:</strong> <a href="../interfaces/_promise_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a></p>
<hr>
<p><a id="decoratefunctionmeta"></a></p>
<h2 id="protected-decoratefunctionmeta"><code>&lt;Protected&gt;</code> decorateFunctionMeta</h2>
<p>&#x25B8; <strong>decorateFunctionMeta</strong>(input: <em><code>MetaDecoration</code></em>, output: <em><code>MetaDecoration</code></em>): <code>MetaDecoration</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#decoratefunctionmeta">decorateFunctionMeta</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L200" target="_blank">Base.ts:200</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
<tr>
<th>Param</th>
<th>Type</th>
</tr>
</thead>
<tbody>
<tr>
<td>input</td>
<td><code>MetaDecoration</code></td>
</tr>
<tr>
<td>output</td>
<td><code>MetaDecoration</code></td>
</tr>
</tbody>
</table>
<p><strong>Returns:</strong> <code>MetaDecoration</code></p>
<hr>
<p><a id="decoraterpc"></a></p>
<h2 id="protected-decoraterpc"><code>&lt;Protected&gt;</code> decorateRpc</h2>
<p>&#x25B8; <strong>decorateRpc</strong>(rpc: <em><code>Rpc</code></em>): <code>Rpc</code></p>
<p><em>Overrides <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#decoraterpc">decorateRpc</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L72" target="_blank">promise/index.ts:72</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
<tr>
<th>Param</th>
<th>Type</th>
</tr>
</thead>
<tbody>
<tr>
<td>rpc</td>
<td><code>Rpc</code></td>
</tr>
</tbody>
</table>
<p><strong>Returns:</strong> <code>Rpc</code></p>
<hr>
<p><a id="decoratestorage"></a></p>
<h2 id="protected-decoratestorage"><code>&lt;Protected&gt;</code> decorateStorage</h2>
<p>&#x25B8; <strong>decorateStorage</strong>(storage: <em><code>Storage</code></em>): <a href="../interfaces/_promise_types_d_.queryablestorage.md">QueryableStorage</a></p>
<p><em>Overrides <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#decoratestorage">decorateStorage</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L97" target="_blank">promise/index.ts:97</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
<tr>
<th>Param</th>
<th>Type</th>
</tr>
</thead>
<tbody>
<tr>
<td>storage</td>
<td><code>Storage</code></td>
</tr>
</tbody>
</table>
<p><strong>Returns:</strong> <a href="../interfaces/_promise_types_d_.queryablestorage.md">QueryableStorage</a></p>
<hr>
<p><a id="emit"></a></p>
<h2 id="emit">emit</h2>
<p>&#x25B8; <strong>emit</strong>(event: <em><code>EventTypes</code></em>, ...args: <em><code>Array</code>&lt;<code>any</code>&gt;</em>): <code>boolean</code></p>
@@ -956,7 +882,7 @@
<p><a id="create"></a></p>
<h2 id="static-create"><code>&lt;Static&gt;</code> create</h2>
<p>&#x25B8; <strong>create</strong>(wsProvider?: <em><code>WsProvider</code></em>): <code>Promise</code>&lt;<a href="_promise_index_.apipromise.html">ApiPromise</a>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L36" target="_blank">promise/index.ts:36</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/index.ts#L111" target="_blank">promise/index.ts:111</a></em></p>
<p><em><strong>description</strong></em>: Creates an ApiPromise instance using the supplied provider. Returns an Promise containing the actual Api instance.</p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">Api</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/promise&apos;</span><span class="sunlight-punctuation">;</span>
@@ -1029,7 +955,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"ApiPromise","level":"1.2.1","depth":2,"next":{"title":"ApiRx","level":"1.2.2","depth":2,"path":"api/classes/_rx_index_.apirx.md","ref":"api/classes/_rx_index_.apirx.md","articles":[]},"previous":{"title":"api","level":"1.2","depth":1,"path":"api/README.md","ref":"api/README.md","articles":[{"title":"ApiPromise","level":"1.2.1","depth":2,"path":"api/classes/_promise_index_.apipromise.md","ref":"api/classes/_promise_index_.apipromise.md","articles":[]},{"title":"ApiRx","level":"1.2.2","depth":2,"path":"api/classes/_rx_index_.apirx.md","ref":"api/classes/_rx_index_.apirx.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"api/classes/_promise_index_.apipromise.md","mtime":"2018-10-11T11:42:17.518Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"ApiPromise","level":"1.2.1","depth":2,"next":{"title":"ApiRx","level":"1.2.2","depth":2,"path":"api/classes/_rx_index_.apirx.md","ref":"api/classes/_rx_index_.apirx.md","articles":[]},"previous":{"title":"api","level":"1.2","depth":1,"path":"api/README.md","ref":"api/README.md","articles":[{"title":"ApiPromise","level":"1.2.1","depth":2,"path":"api/classes/_promise_index_.apipromise.md","ref":"api/classes/_promise_index_.apipromise.md","articles":[]},{"title":"ApiRx","level":"1.2.2","depth":2,"path":"api/classes/_rx_index_.apirx.md","ref":"api/classes/_rx_index_.apirx.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"api/classes/_promise_index_.apipromise.md","mtime":"2018-10-11T13:30:00.325Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
+84 -170
View File
@@ -1,18 +1,86 @@
*__description__*: ApiPromise is a standard JavaScript wrapper around the RPC and interfaces on the Polkadot network. As a full Promise-based, all interface calls return Promises, including the static `.create(...)`. Subscription calls utilise standard JavaScript-convention `(error, value)` callbacks.
The API is well suited to real-time applications where either the single-shot state is needed or use is to be made of athe subscription-based features of Polkadot (and Substrate) clients.
*__example__*:
Making rpc calls -
```javascript
import ApiPromise from '@polkadot/api/promise';
// initialise via static create
const api = await ApiPromise.create();
// make a subscription to the network head
api.rpc.chain.newHead((error, header) => {
console.log(`Chain is at #${header.blockNumber}`);
});
```
Subscribing to chain state -
```javascript
import { ApiPromise } from '@polkadot/api';
import WsProvider from '@polkadot/rpc-provider/ws';
// initialise via isReady & new with specific non-local endpoint
const api = await new ApiPromise(new WsProvider('wss://example.com:9944')).isReady;
// retrieve the block target time
const blockPeriod = await api.st.timestamp.blockPeriod().toNumber();
let last = 0;
// subscribe to the current block timestamp, updates automatically
api.st.timestamp.now((error, timestamp) => {
const elapsed = last
? `, ${timestamp.toNumber() - last}s since last`
: '';
last = timestamp.toNumber();
console.log(`timestamp ${timestamp}${elapsed} (${blockPeriod}s target)`);
});
```
Submitting a transaction -
```javascript
import ApiPromise from '@polkadot/api/promise';
ApiPromise.create().then((api) => {
const nonce = await api.st.system.accountNonce(keyring.alice.address());
api.tx.balances
// create transfer
transfer(keyring.bob.address(), 12345)
// sign the transcation
.sign(keyring.alice, nonce)
// send the transaction
.send()
// retrieve the overall result
.then((hash) => {
console.log(`submitted with hash ${hash}`);
});
});
```
# Type parameters
#### EventTypes : `string` &#124; `symbol`
# Hierarchy
↳ [ApiBase](_base_.apibase.md)<`Rpc`, [QueryableStorage](../interfaces/_promise_types_d_.queryablestorage.md), [SubmittableExtrinsics](../interfaces/_promise_types_d_.submittableextrinsics.md)>
↳ [ApiBase](_base_.apibase.md)<`Rpc`, `QueryableStorage`, `SubmittableExtrinsics`>
**↳ ApiPromise**
# Implements
* [ApiBaseInterface](../interfaces/_types_d_.apibaseinterface.md)<`Rpc`, [QueryableStorage](../interfaces/_promise_types_d_.queryablestorage.md), [SubmittableExtrinsics](../interfaces/_promise_types_d_.submittableextrinsics.md)>
* [ApiPromiseInterface](../interfaces/_promise_types_d_.apipromiseinterface.md)
* `ApiBaseInterface`<`Rpc`, `QueryableStorage`, `SubmittableExtrinsics`>
* `ApiPromiseInterface`
# Constructors
@@ -24,7 +92,7 @@
*Overrides [ApiBase](_base_.apibase.md).[constructor](_base_.apibase.md#constructor)*
*Defined in [promise/index.ts:38](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L38)*
*Defined in [promise/index.ts:113](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/index.ts#L113)*
*__example__*:
```javascript
@@ -49,83 +117,6 @@ ___
# Properties
<a id="_extrinsics"></a>
## `<Protected>``<Optional>` _extrinsics
**● _extrinsics**: *[E]()*
*Inherited from [ApiBase](_base_.apibase.md).[_extrinsics](_base_.apibase.md#_extrinsics)*
*Defined in [Base.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L33)*
___
<a id="_genesishash"></a>
## `<Protected>``<Optional>` _genesisHash
**● _genesisHash**: *`Hash`*
*Inherited from [ApiBase](_base_.apibase.md).[_genesisHash](_base_.apibase.md#_genesishash)*
*Defined in [Base.ts:34](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L34)*
___
<a id="_rpc"></a>
## `<Protected>` _rpc
**● _rpc**: *`Rpc`*
*Inherited from [ApiBase](_base_.apibase.md).[_rpc](_base_.apibase.md#_rpc)*
*Defined in [Base.ts:36](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L36)*
___
<a id="_rpcbase"></a>
## `<Protected>` _rpcBase
**● _rpcBase**: *`Rpc`*
*Inherited from [ApiBase](_base_.apibase.md).[_rpcBase](_base_.apibase.md#_rpcbase)*
*Defined in [Base.ts:37](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L37)*
___
<a id="_runtimemetadata"></a>
## `<Protected>``<Optional>` _runtimeMetadata
**● _runtimeMetadata**: *`RuntimeMetadata`*
*Inherited from [ApiBase](_base_.apibase.md).[_runtimeMetadata](_base_.apibase.md#_runtimemetadata)*
*Defined in [Base.ts:38](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L38)*
___
<a id="_runtimeversion"></a>
## `<Protected>``<Optional>` _runtimeVersion
**● _runtimeVersion**: *`RuntimeVersion`*
*Inherited from [ApiBase](_base_.apibase.md).[_runtimeVersion](_base_.apibase.md#_runtimeversion)*
*Defined in [Base.ts:39](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L39)*
___
<a id="_storage"></a>
## `<Protected>``<Optional>` _storage
**● _storage**: *[S]()*
*Inherited from [ApiBase](_base_.apibase.md).[_storage](_base_.apibase.md#_storage)*
*Defined in [Base.ts:35](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L35)*
___
<a id="prefixed"></a>
## `<Static>` prefixed
@@ -149,7 +140,7 @@ getgenesisHash(): `Hash`
*Inherited from [ApiBase](_base_.apibase.md).[genesisHash](_base_.apibase.md#genesishash)*
*Defined in [Base.ts:68](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L68)*
*Defined in [Base.ts:68](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L68)*
*__description__*: Contains the genesis Hash of the attached chain. Apart from being useful to determine the actual chain, it can also be used to sign immortal transactions.
@@ -162,7 +153,7 @@ ___
getisReady(): `Promise`<[ApiPromise](_promise_index_.apipromise.md)>
*Defined in [promise/index.ts:68](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L68)*
*Defined in [promise/index.ts:143](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/index.ts#L143)*
*__description__*: Promise that returns the first time we are connected and loaded
@@ -177,7 +168,7 @@ getrpc(): `Rpc`
*Inherited from [ApiBase](_base_.apibase.md).[rpc](_base_.apibase.md#rpc)*
*Defined in [Base.ts:105](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L105)*
*Defined in [Base.ts:105](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L105)*
*__description__*: Contains all the raw rpc sections and their subsequent methods in the API as defined by the jsonrpc interface definitions.
@@ -201,7 +192,7 @@ getruntimeMetadata(): `RuntimeMetadata`
*Inherited from [ApiBase](_base_.apibase.md).[runtimeMetadata](_base_.apibase.md#runtimemetadata)*
*Defined in [Base.ts:77](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L77)*
*Defined in [Base.ts:77](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L77)*
*__description__*: Yields the current attached runtime metadata. Generally this is only used to construct extrinsics & storage, but is useful for current runtime inspection.
@@ -216,7 +207,7 @@ getruntimeVersion(): `RuntimeVersion`
*Inherited from [ApiBase](_base_.apibase.md).[runtimeVersion](_base_.apibase.md#runtimeversion)*
*Defined in [Base.ts:86](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L86)*
*Defined in [Base.ts:86](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L86)*
*__description__*: Contains the version information for the current runtime.
@@ -227,11 +218,11 @@ ___
## st
getst(): [QueryableStorage](../interfaces/_promise_types_d_.queryablestorage.md)
getst(): `QueryableStorage`
*Inherited from [ApiBase](_base_.apibase.md).[st](_base_.apibase.md#st)*
*Defined in [Base.ts:122](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L122)*
*Defined in [Base.ts:122](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L122)*
*__description__*: Contains all the chain state modules and their subsequent methods in the API. These are attached dynamically from the runtime metadata.
@@ -244,18 +235,18 @@ api.st.balances
});
```
**Returns:** [QueryableStorage](../interfaces/_promise_types_d_.queryablestorage.md)
**Returns:** `QueryableStorage`
___
<a id="tx"></a>
## tx
gettx(): [SubmittableExtrinsics](../interfaces/_promise_types_d_.submittableextrinsics.md)
gettx(): `SubmittableExtrinsics`
*Inherited from [ApiBase](_base_.apibase.md).[tx](_base_.apibase.md#tx)*
*Defined in [Base.ts:143](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L143)*
*Defined in [Base.ts:143](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L143)*
*__description__*: Contains all the extrinsic modules and their subsequent methods in the API. It allows for the construction of transactions and the submission thereof. These are attached dynamically from the runtime metadata.
@@ -270,7 +261,7 @@ api.tx.balances
});
```
**Returns:** [SubmittableExtrinsics](../interfaces/_promise_types_d_.submittableextrinsics.md)
**Returns:** `SubmittableExtrinsics`
___
@@ -296,83 +287,6 @@ ___
**Returns:** `this`
___
<a id="decorateextrinsics"></a>
## `<Protected>` decorateExtrinsics
▸ **decorateExtrinsics**(extrinsics: *`Extrinsics`*): [SubmittableExtrinsics](../interfaces/_promise_types_d_.submittableextrinsics.md)
*Overrides [ApiBase](_base_.apibase.md).[decorateExtrinsics](_base_.apibase.md#decorateextrinsics)*
*Defined in [promise/index.ts:76](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L76)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| extrinsics | `Extrinsics` |
**Returns:** [SubmittableExtrinsics](../interfaces/_promise_types_d_.submittableextrinsics.md)
___
<a id="decoratefunctionmeta"></a>
## `<Protected>` decorateFunctionMeta
▸ **decorateFunctionMeta**(input: *`MetaDecoration`*, output: *`MetaDecoration`*): `MetaDecoration`
*Inherited from [ApiBase](_base_.apibase.md).[decorateFunctionMeta](_base_.apibase.md#decoratefunctionmeta)*
*Defined in [Base.ts:200](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L200)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| input | `MetaDecoration` |
| output | `MetaDecoration` |
**Returns:** `MetaDecoration`
___
<a id="decoraterpc"></a>
## `<Protected>` decorateRpc
▸ **decorateRpc**(rpc: *`Rpc`*): `Rpc`
*Overrides [ApiBase](_base_.apibase.md).[decorateRpc](_base_.apibase.md#decoraterpc)*
*Defined in [promise/index.ts:72](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L72)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| rpc | `Rpc` |
**Returns:** `Rpc`
___
<a id="decoratestorage"></a>
## `<Protected>` decorateStorage
▸ **decorateStorage**(storage: *`Storage`*): [QueryableStorage](../interfaces/_promise_types_d_.queryablestorage.md)
*Overrides [ApiBase](_base_.apibase.md).[decorateStorage](_base_.apibase.md#decoratestorage)*
*Defined in [promise/index.ts:97](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L97)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| storage | `Storage` |
**Returns:** [QueryableStorage](../interfaces/_promise_types_d_.queryablestorage.md)
___
<a id="emit"></a>
@@ -572,7 +486,7 @@ ___
▸ **create**(wsProvider?: *`WsProvider`*): `Promise`<[ApiPromise](_promise_index_.apipromise.md)>
*Defined in [promise/index.ts:36](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/index.ts#L36)*
*Defined in [promise/index.ts:111](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/index.ts#L111)*
*__description__*: Creates an ApiPromise instance using the supplied provider. Returns an Promise containing the actual Api instance.
@@ -17,17 +17,17 @@
## constructor
⊕ **new SubmittableExtrinsic**(api: *[ApiPromiseInterface](../interfaces/_promise_types_d_.apipromiseinterface.md)*, extrinsic: *`Extrinsic`*): [SubmittableExtrinsic](_promise_submittableextrinsic_.submittableextrinsic.md)
⊕ **new SubmittableExtrinsic**(api: *`ApiPromiseInterface`*, extrinsic: *`Extrinsic`*): [SubmittableExtrinsic](_promise_submittableextrinsic_.submittableextrinsic.md)
*Overrides Extrinsic.__constructor*
*Defined in [promise/SubmittableExtrinsic.ts:12](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/SubmittableExtrinsic.ts#L12)*
*Defined in [promise/SubmittableExtrinsic.ts:12](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/SubmittableExtrinsic.ts#L12)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| api | [ApiPromiseInterface](../interfaces/_promise_types_d_.apipromiseinterface.md) |
| api | `ApiPromiseInterface` |
| extrinsic | `Extrinsic` |
**Returns:** [SubmittableExtrinsic](_promise_submittableextrinsic_.submittableextrinsic.md)
@@ -36,28 +36,6 @@ ___
# Properties
<a id="_types"></a>
## `<Protected>` _Types
**● _Types**: *`E`*
*Inherited from Struct._Types*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:30](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L30)*
___
<a id="_jsonmap"></a>
## `<Protected>` _jsonMap
**● _jsonMap**: *`Map`<`keyof S`, `string`>*
*Inherited from Struct._jsonMap*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L29)*
___
<a id="raw"></a>
## raw
@@ -66,7 +44,7 @@ ___
*Inherited from Base.raw*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Base.ts#L19)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Base.ts#L19)*
___
@@ -80,7 +58,7 @@ getType(): `E`
*Inherited from Struct.Type*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L108)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L108)*
**Returns:** `E`
@@ -93,7 +71,7 @@ getcallIndex(): `Uint8Array`
*Inherited from Extrinsic.callIndex*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:70](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L70)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:70](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L70)*
**Returns:** `Uint8Array`
@@ -106,7 +84,7 @@ getdata(): `Uint8Array`
*Inherited from Extrinsic.data*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:74](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L74)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:74](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L74)*
**Returns:** `Uint8Array`
@@ -119,7 +97,7 @@ gethash(): `Hash`
*Inherited from Extrinsic.hash*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:79](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L79)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:79](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L79)*
**Returns:** `Hash`
@@ -132,7 +110,7 @@ getisSigned(): `boolean`
*Inherited from Extrinsic.isSigned*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L85)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L85)*
**Returns:** `boolean`
@@ -145,7 +123,7 @@ getlength(): `number`
*Inherited from Extrinsic.length*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:89](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L89)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:89](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L89)*
**Returns:** `number`
@@ -158,7 +136,7 @@ getmeta(): `FunctionMetadata`
*Inherited from Extrinsic.meta*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:93](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L93)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:93](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L93)*
**Returns:** `FunctionMetadata`
@@ -171,7 +149,7 @@ getmethod(): `Method`
*Inherited from Extrinsic.method*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:97](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L97)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:97](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L97)*
**Returns:** `Method`
@@ -184,7 +162,7 @@ getsignature(): `ExtrinsicSignature`
*Inherited from Extrinsic.signature*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:101](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L101)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:101](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L101)*
**Returns:** `ExtrinsicSignature`
@@ -202,7 +180,7 @@ ___
*Overrides Struct.byteLength*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:105](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L105)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:105](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L105)*
**Returns:** `number`
@@ -217,7 +195,7 @@ ___
*Overrides Struct.fromJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:111](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L111)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:111](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L111)*
**Parameters:**
@@ -238,7 +216,7 @@ ___
*Overrides Struct.fromU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:117](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L117)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:117](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L117)*
**Parameters:**
@@ -257,7 +235,7 @@ ___
*Inherited from Struct.get*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L148)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L148)*
**Parameters:**
@@ -276,7 +254,7 @@ ___
*Inherited from Struct.keys*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L163)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L163)*
**Returns:** `Array`<`string`>
@@ -287,7 +265,7 @@ ___
▸ **send**(): `Promise`<`Hash`>
*Defined in [promise/SubmittableExtrinsic.ts:22](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/SubmittableExtrinsic.ts#L22)*
*Defined in [promise/SubmittableExtrinsic.ts:22](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/SubmittableExtrinsic.ts#L22)*
**Returns:** `Promise`<`Hash`>
@@ -300,7 +278,7 @@ ___
*Overrides Extrinsic.sign*
*Defined in [promise/SubmittableExtrinsic.ts:26](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/SubmittableExtrinsic.ts#L26)*
*Defined in [promise/SubmittableExtrinsic.ts:26](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/promise/SubmittableExtrinsic.ts#L26)*
**Parameters:**
@@ -321,7 +299,7 @@ ___
*Inherited from Extrinsic.toHex*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:142](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L142)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:142](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L142)*
**Returns:** `string`
@@ -336,7 +314,7 @@ ___
*Overrides Struct.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:146](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L146)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:146](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L146)*
**Returns:** `any`
@@ -351,7 +329,7 @@ ___
*Overrides Base.toString*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L175)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L175)*
**Returns:** `string`
@@ -366,7 +344,7 @@ ___
*Overrides Struct.toU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:131](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L131)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:131](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L131)*
**Parameters:**
@@ -385,7 +363,7 @@ ___
*Inherited from Struct.values*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L184)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L184)*
**Returns:** `Array`<`Base`>
@@ -398,7 +376,7 @@ ___
*Inherited from Extrinsic.decodeExtrinsic*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:45](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L45)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:45](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L45)*
**Parameters:**
@@ -417,7 +395,7 @@ ___
*Inherited from Struct.decodeStruct*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L48)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L48)*
**Type parameters:**
@@ -442,7 +420,7 @@ ___
*Inherited from Struct.with*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L98)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L98)*
**Type parameters:**
+110 -172
View File
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../../examples/">
<li class="chapter " data-level="2.1" data-path="../../examples-rpc/">
<a href="../../examples/">
<a href="../../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../../examples-rpc/01_simple_connect/">
<a href="../../examples/01_simple_connect/">
<a href="../../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../../examples-rpc/02_listen_to_blocks/">
<a href="../../examples/02_listen_to_blocks/">
<a href="../../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../../examples-rpc/03_listen_to_balance_change/">
<a href="../../examples/03_listen_to_balance_change/">
<a href="../../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../../examples-rpc/04_generate_account/">
<a href="../../examples/04_generate_account/">
<a href="../../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../../examples-rpc/05_read_storage/">
<a href="../../examples/05_read_storage/">
<a href="../../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../../examples-rpc/06_craft_extrinsic/">
<a href="../../examples/06_craft_extrinsic/">
<a href="../../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../../examples-rpc/07_transfer_dots/">
<a href="../../examples/07_transfer_dots/">
<a href="../../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -422,22 +428,88 @@
<section class="normal markdown-section">
<h1 id="type-parameters">Type parameters</h1>
<p><em><strong>description</strong></em>: ApiRx is a powerfull RxJS Observable wrapper around the RPC and interfaces on the Polkadot network. As a full Observable API, all interface calls return RxJS Observables, including the static <code>.create(...)</code>. In the same fashion and subscription-based methods return long-running Observables that update with the latest values.</p>
<p>The API is well suited to real-time applications where the latest state is needed, unlocking the subscription-based features of Polkadot (and Substrate) clients. Some familiarity with RxJS is a requirement to use the API, however just understanding <code>.subscribe</code> and <code>.pipe</code> on Observables will unlock full-scale use thereof.</p>
<p><em><strong>example</strong></em>: </p>
<p>Making rpc calls - </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">ApiRx</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/rx&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;initialise&#xA0;via&#xA0;Promise&#xA0;&amp;&#xA0;static&#xA0;create</span>
<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">api</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">await</span>&#xA0;<span class="sunlight-ident">ApiRx</span><span class="sunlight-operator">.</span><span class="sunlight-ident">create</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">toPromise</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;make&#xA0;a&#xA0;call&#xA0;to&#xA0;retrieve&#xA0;the&#xA0;current&#xA0;network&#xA0;head</span>
<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">rpc</span><span class="sunlight-operator">.</span><span class="sunlight-ident">chain</span><span class="sunlight-operator">.</span><span class="sunlight-ident">newHead</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">subscribe</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">header</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">Chain</span>&#xA0;<span class="sunlight-ident">is</span>&#xA0;<span class="sunlight-ident">at</span>&#xA0;<span class="sunlight-punctuation">#</span><span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">header</span><span class="sunlight-operator">.</span><span class="sunlight-ident">blockNumber</span><span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p>Subscribing to chain state - </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-punctuation">{</span>&#xA0;<span class="sunlight-ident">ApiRx</span>&#xA0;<span class="sunlight-punctuation">}</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">WsProvider</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/rpc-provider/ws&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-punctuation">{</span>&#xA0;<span class="sunlight-ident">combineLatest</span>&#xA0;<span class="sunlight-punctuation">}</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;rxjs&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-ident">let</span>&#xA0;<span class="sunlight-ident">last</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-number">0</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;initialise&#xA0;via&#xA0;isReady&#xA0;&amp;&#xA0;new&#xA0;with&#xA0;specific&#xA0;non-local&#xA0;endpoint</span>
<span class="sunlight-keyword">new</span>&#xA0;<span class="sunlight-ident">ApiRx</span><span class="sunlight-punctuation">(</span><span class="sunlight-keyword">new</span>&#xA0;<span class="sunlight-ident">WsProvider</span><span class="sunlight-punctuation">(</span><span class="sunlight-string">&apos;wss://example.com:9944&apos;</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">isReady</span>
&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">pipe</span><span class="sunlight-punctuation">(</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">switchMap</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">api</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">combineLatest</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">[</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">blockPeriod</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">,</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">now</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-punctuation">]</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">subscribe</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">[</span><span class="sunlight-ident">blockPeriod</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">]</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">elapsed</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">last</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">?</span>&#xA0;<span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">toNumber</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">-</span>&#xA0;<span class="sunlight-ident">last</span><span class="sunlight-punctuation">}</span><span class="sunlight-ident">s</span>&#xA0;<span class="sunlight-ident">since</span>&#xA0;<span class="sunlight-ident">last</span><span class="sunlight-punctuation">`</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">:</span>&#xA0;<span class="sunlight-string">&apos;&apos;</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">last</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">toNumber</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">timestamp</span>&#xA0;<span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">}</span><span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">elapsed</span><span class="sunlight-punctuation">}</span>&#xA0;<span class="sunlight-punctuation">(</span><span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">blockPeriod</span><span class="sunlight-punctuation">}</span><span class="sunlight-ident">s</span>&#xA0;<span class="sunlight-ident">target</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p>Submitting a transaction - </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">ApiRx</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/rx&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;get&#xA0;api&#xA0;via&#xA0;Promise</span>
<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">api</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">await</span>&#xA0;<span class="sunlight-ident">ApiRx</span><span class="sunlight-operator">.</span><span class="sunlight-ident">create</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">toPromise</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;retrieve&#xA0;nonce&#xA0;for&#xA0;the&#xA0;account</span>
<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">system</span>
&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">accountNonce</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">keyring</span><span class="sunlight-operator">.</span><span class="sunlight-ident">alice</span><span class="sunlight-operator">.</span><span class="sunlight-ident">address</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">pipe</span><span class="sunlight-punctuation">(</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;pipe&#xA0;nonce&#xA0;into&#xA0;transfer</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">switchMap</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">nonce</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">tx</span><span class="sunlight-operator">.</span><span class="sunlight-ident">balances</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;create&#xA0;transfer</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">transfer</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">keyring</span><span class="sunlight-operator">.</span><span class="sunlight-ident">bob</span><span class="sunlight-operator">.</span><span class="sunlight-ident">address</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-number">12345</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;sign&#xA0;the&#xA0;transcation</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">sign</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">keyring</span><span class="sunlight-operator">.</span><span class="sunlight-ident">alice</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">nonce</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;send&#xA0;the&#xA0;transaction</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">send</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">)</span>
&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;subscribe&#xA0;to&#xA0;overall&#xA0;result</span>
&#xA0;&#xA0;<span class="sunlight-operator">.</span><span class="sunlight-ident">subscribe</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">hash</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">submitted</span>&#xA0;<span class="sunlight-keyword">with</span>&#xA0;<span class="sunlight-ident">hash</span>&#xA0;<span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">hash</span><span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<h1 id="type-parameters">Type parameters</h1>
<h4 id="eventtypes----string--symbol">EventTypes : <code>string</code> | <code>symbol</code></h4>
<h1 id="hierarchy">Hierarchy</h1>
<p>&#x21B3; <a href="_base_.apibase.md">ApiBase</a>&lt;<code>RpcRx</code>, <a href="../interfaces/_rx_types_d_.queryablestorage.md">QueryableStorage</a>, <a href="../interfaces/_rx_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a>&gt;</p>
<p>&#x21B3; <a href="_base_.apibase.md">ApiBase</a>&lt;<code>RpcRx</code>, <code>QueryableStorage</code>, <code>SubmittableExtrinsics</code>&gt;</p>
<p><strong>&#x21B3; ApiRx</strong></p>
<h1 id="implements">Implements</h1>
<ul>
<li><a href="../interfaces/_types_d_.apibaseinterface.md">ApiBaseInterface</a>&lt;<code>RpcRx</code>, <a href="../interfaces/_rx_types_d_.queryablestorage.md">QueryableStorage</a>, <a href="../interfaces/_rx_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a>&gt;</li>
<li><a href="../interfaces/_rx_types_d_.apirxinterface.md">ApiRxInterface</a></li>
<li><code>ApiBaseInterface</code>&lt;<code>RpcRx</code>, <code>QueryableStorage</code>, <code>SubmittableExtrinsics</code>&gt;</li>
<li><code>ApiRxInterface</code></li>
</ul>
<h1 id="constructors">Constructors</h1>
<p><a id="constructor"></a></p>
<h2 id="constructor">constructor</h2>
<p>&#x2295; <strong>new ApiRx</strong>(wsProvider?: <em><code>WsProvider</code></em>): <a href="_rx_index_.apirx.html">ApiRx</a></p>
<p><em>Overrides <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#constructor">constructor</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L44" target="_blank">rx/index.ts:44</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/index.ts#L130" target="_blank">rx/index.ts:130</a></em></p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">Api</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/rx&apos;</span><span class="sunlight-punctuation">;</span>
@@ -467,48 +539,6 @@
<p><strong>Returns:</strong> <a href="_rx_index_.apirx.html">ApiRx</a></p>
<hr>
<h1 id="properties">Properties</h1>
<p><a id="_extrinsics"></a></p>
<h2 id="protectedoptional-extrinsics"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _extrinsics</h2>
<p><strong>&#x25CF; _extrinsics</strong>: <em><a href="">E</a></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_extrinsics">_extrinsics</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L33" target="_blank">Base.ts:33</a></em></p>
<hr>
<p><a id="_genesishash"></a></p>
<h2 id="protectedoptional-genesishash"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _genesisHash</h2>
<p><strong>&#x25CF; _genesisHash</strong>: <em><code>Hash</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_genesishash">_genesisHash</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L34" target="_blank">Base.ts:34</a></em></p>
<hr>
<p><a id="_rpc"></a></p>
<h2 id="protected-rpc"><code>&lt;Protected&gt;</code> _rpc</h2>
<p><strong>&#x25CF; _rpc</strong>: <em><code>RpcRx</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_rpc">_rpc</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L36" target="_blank">Base.ts:36</a></em></p>
<hr>
<p><a id="_rpcbase"></a></p>
<h2 id="protected-rpcbase"><code>&lt;Protected&gt;</code> _rpcBase</h2>
<p><strong>&#x25CF; _rpcBase</strong>: <em><code>Rpc</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_rpcbase">_rpcBase</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L37" target="_blank">Base.ts:37</a></em></p>
<hr>
<p><a id="_runtimemetadata"></a></p>
<h2 id="protectedoptional-runtimemetadata"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _runtimeMetadata</h2>
<p><strong>&#x25CF; _runtimeMetadata</strong>: <em><code>RuntimeMetadata</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_runtimemetadata">_runtimeMetadata</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L38" target="_blank">Base.ts:38</a></em></p>
<hr>
<p><a id="_runtimeversion"></a></p>
<h2 id="protectedoptional-runtimeversion"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _runtimeVersion</h2>
<p><strong>&#x25CF; _runtimeVersion</strong>: <em><code>RuntimeVersion</code></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_runtimeversion">_runtimeVersion</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L39" target="_blank">Base.ts:39</a></em></p>
<hr>
<p><a id="_storage"></a></p>
<h2 id="protectedoptional-storage"><code>&lt;Protected&gt;``&lt;Optional&gt;</code> _storage</h2>
<p><strong>&#x25CF; _storage</strong>: <em><a href="">S</a></em></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#_storage">_storage</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L35" target="_blank">Base.ts:35</a></em></p>
<hr>
<p><a id="prefixed"></a></p>
<h2 id="static-prefixed"><code>&lt;Static&gt;</code> prefixed</h2>
<p><strong>&#x25CF; prefixed</strong>: <em> <code>string</code> | <code>boolean</code>
@@ -521,21 +551,21 @@
<h2 id="genesishash">genesisHash</h2>
<p>getgenesisHash(): <code>Hash</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#genesishash">genesisHash</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L68" target="_blank">Base.ts:68</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L68" target="_blank">Base.ts:68</a></em></p>
<p><em><strong>description</strong></em>: Contains the genesis Hash of the attached chain. Apart from being useful to determine the actual chain, it can also be used to sign immortal transactions.</p>
<p><strong>Returns:</strong> <code>Hash</code></p>
<hr>
<p><a id="isconnected"></a></p>
<h2 id="isconnected">isConnected</h2>
<p>getisConnected(): <code>Observable</code>&lt;<code>boolean</code>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L77" target="_blank">rx/index.ts:77</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/index.ts#L163" target="_blank">rx/index.ts:163</a></em></p>
<p><em><strong>description</strong></em>: Observable that carries the connected state for the provider. Results in a boolean flag that is true/false based on the connectivity.</p>
<p><strong>Returns:</strong> <code>Observable</code>&lt;<code>boolean</code>&gt;</p>
<hr>
<p><a id="isready"></a></p>
<h2 id="isready">isReady</h2>
<p>getisReady(): <code>Observable</code>&lt;<a href="_rx_index_.apirx.html">ApiRx</a>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L84" target="_blank">rx/index.ts:84</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/index.ts#L170" target="_blank">rx/index.ts:170</a></em></p>
<p><em><strong>description</strong></em>: Observable that returns the first time we are connected and loaded</p>
<p><strong>Returns:</strong> <code>Observable</code>&lt;<a href="_rx_index_.apirx.html">ApiRx</a>&gt;</p>
<hr>
@@ -543,7 +573,7 @@
<h2 id="rpc">rpc</h2>
<p>getrpc(): <code>RpcRx</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#rpc">rpc</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L105" target="_blank">Base.ts:105</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L105" target="_blank">Base.ts:105</a></em></p>
<p><em><strong>description</strong></em>: Contains all the raw rpc sections and their subsequent methods in the API as defined by the jsonrpc interface definitions.</p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">rpc</span><span class="sunlight-operator">.</span><span class="sunlight-ident">chain</span>
@@ -558,7 +588,7 @@
<h2 id="runtimemetadata">runtimeMetadata</h2>
<p>getruntimeMetadata(): <code>RuntimeMetadata</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#runtimemetadata">runtimeMetadata</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L77" target="_blank">Base.ts:77</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L77" target="_blank">Base.ts:77</a></em></p>
<p><em><strong>description</strong></em>: Yields the current attached runtime metadata. Generally this is only used to construct extrinsics &amp; storage, but is useful for current runtime inspection.</p>
<p><strong>Returns:</strong> <code>RuntimeMetadata</code></p>
<hr>
@@ -566,15 +596,15 @@
<h2 id="runtimeversion">runtimeVersion</h2>
<p>getruntimeVersion(): <code>RuntimeVersion</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#runtimeversion">runtimeVersion</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L86" target="_blank">Base.ts:86</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L86" target="_blank">Base.ts:86</a></em></p>
<p><em><strong>description</strong></em>: Contains the version information for the current runtime.</p>
<p><strong>Returns:</strong> <code>RuntimeVersion</code></p>
<hr>
<p><a id="st"></a></p>
<h2 id="st">st</h2>
<p>getst(): <a href="../interfaces/_rx_types_d_.queryablestorage.md">QueryableStorage</a></p>
<p>getst(): <code>QueryableStorage</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#st">st</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L122" target="_blank">Base.ts:122</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L122" target="_blank">Base.ts:122</a></em></p>
<p><em><strong>description</strong></em>: Contains all the chain state modules and their subsequent methods in the API. These are attached dynamically from the runtime metadata.</p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">balances</span>
@@ -583,13 +613,13 @@
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-string">&apos;new&#xA0;balance&apos;</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">balance</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p><strong>Returns:</strong> <a href="../interfaces/_rx_types_d_.queryablestorage.md">QueryableStorage</a></p>
<p><strong>Returns:</strong> <code>QueryableStorage</code></p>
<hr>
<p><a id="tx"></a></p>
<h2 id="tx">tx</h2>
<p>gettx(): <a href="../interfaces/_rx_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a></p>
<p>gettx(): <code>SubmittableExtrinsics</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#tx">tx</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L143" target="_blank">Base.ts:143</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L143" target="_blank">Base.ts:143</a></em></p>
<p><em><strong>description</strong></em>: Contains all the extrinsic modules and their subsequent methods in the API. It allows for the construction of transactions and the submission thereof. These are attached dynamically from the runtime metadata.</p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">tx</span><span class="sunlight-operator">.</span><span class="sunlight-ident">balances</span>
@@ -600,7 +630,7 @@
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-string">&apos;tx&#xA0;status&apos;</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">status</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p><strong>Returns:</strong> <a href="../interfaces/_rx_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a></p>
<p><strong>Returns:</strong> <code>SubmittableExtrinsics</code></p>
<hr>
<h1 id="methods">Methods</h1>
<p><a id="addlistener"></a></p>
@@ -633,98 +663,6 @@
</table>
<p><strong>Returns:</strong> <code>this</code></p>
<hr>
<p><a id="decorateextrinsics"></a></p>
<h2 id="protected-decorateextrinsics"><code>&lt;Protected&gt;</code> decorateExtrinsics</h2>
<p>&#x25B8; <strong>decorateExtrinsics</strong>(extrinsics: <em><code>Extrinsics</code></em>): <a href="../interfaces/_rx_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a></p>
<p><em>Overrides <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#decorateextrinsics">decorateExtrinsics</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L92" target="_blank">rx/index.ts:92</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
<tr>
<th>Param</th>
<th>Type</th>
</tr>
</thead>
<tbody>
<tr>
<td>extrinsics</td>
<td><code>Extrinsics</code></td>
</tr>
</tbody>
</table>
<p><strong>Returns:</strong> <a href="../interfaces/_rx_types_d_.submittableextrinsics.md">SubmittableExtrinsics</a></p>
<hr>
<p><a id="decoratefunctionmeta"></a></p>
<h2 id="protected-decoratefunctionmeta"><code>&lt;Protected&gt;</code> decorateFunctionMeta</h2>
<p>&#x25B8; <strong>decorateFunctionMeta</strong>(input: <em><code>MetaDecoration</code></em>, output: <em><code>MetaDecoration</code></em>): <code>MetaDecoration</code></p>
<p><em>Inherited from <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#decoratefunctionmeta">decorateFunctionMeta</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L200" target="_blank">Base.ts:200</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
<tr>
<th>Param</th>
<th>Type</th>
</tr>
</thead>
<tbody>
<tr>
<td>input</td>
<td><code>MetaDecoration</code></td>
</tr>
<tr>
<td>output</td>
<td><code>MetaDecoration</code></td>
</tr>
</tbody>
</table>
<p><strong>Returns:</strong> <code>MetaDecoration</code></p>
<hr>
<p><a id="decoraterpc"></a></p>
<h2 id="protected-decoraterpc"><code>&lt;Protected&gt;</code> decorateRpc</h2>
<p>&#x25B8; <strong>decorateRpc</strong>(rpc: <em><code>Rpc</code></em>): <code>RpcRx</code></p>
<p><em>Overrides <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#decoraterpc">decorateRpc</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L88" target="_blank">rx/index.ts:88</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
<tr>
<th>Param</th>
<th>Type</th>
</tr>
</thead>
<tbody>
<tr>
<td>rpc</td>
<td><code>Rpc</code></td>
</tr>
</tbody>
</table>
<p><strong>Returns:</strong> <code>RpcRx</code></p>
<hr>
<p><a id="decoratestorage"></a></p>
<h2 id="protected-decoratestorage"><code>&lt;Protected&gt;</code> decorateStorage</h2>
<p>&#x25B8; <strong>decorateStorage</strong>(storage: <em><code>Storage</code></em>): <a href="../interfaces/_rx_types_d_.queryablestorage.md">QueryableStorage</a></p>
<p><em>Overrides <a href="_base_.apibase.md">ApiBase</a>.<a href="_base_.apibase.md#decoratestorage">decorateStorage</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L113" target="_blank">rx/index.ts:113</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
<tr>
<th>Param</th>
<th>Type</th>
</tr>
</thead>
<tbody>
<tr>
<td>storage</td>
<td><code>Storage</code></td>
</tr>
</tbody>
</table>
<p><strong>Returns:</strong> <a href="../interfaces/_rx_types_d_.queryablestorage.md">QueryableStorage</a></p>
<hr>
<p><a id="emit"></a></p>
<h2 id="emit">emit</h2>
<p>&#x25B8; <strong>emit</strong>(event: <em><code>EventTypes</code></em>, ...args: <em><code>Array</code>&lt;<code>any</code>&gt;</em>): <code>boolean</code></p>
@@ -963,13 +901,13 @@
<p><a id="create"></a></p>
<h2 id="static-create"><code>&lt;Static&gt;</code> create</h2>
<p>&#x25B8; <strong>create</strong>(wsProvider?: <em><code>WsProvider</code></em>): <code>Observable</code>&lt;<a href="_rx_index_.apirx.html">ApiRx</a>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L42" target="_blank">rx/index.ts:42</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/index.ts#L128" target="_blank">rx/index.ts:128</a></em></p>
<p><em><strong>description</strong></em>: Creates an ApiRx instance using the supplied provider. Returns an Observable containing the actual Api instance.</p>
<p><em><strong>example</strong></em>: </p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">Api</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/rx&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-ident">Api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">create</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">subscribe</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">api</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">now</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">now</span><span class="sunlight-operator">.</span><span class="sunlight-ident">subscribe</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">lastest</span>&#xA0;<span class="sunlight-ident">block</span>&#xA0;<span class="sunlight-ident">timestamp</span>&#xA0;<span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
@@ -1036,7 +974,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"ApiRx","level":"1.2.2","depth":2,"next":{"title":"rpc-provider","level":"1.3","depth":1,"path":"rpc-provider/README.md","ref":"rpc-provider/README.md","articles":[{"title":"HttpProvider","level":"1.3.1","depth":2,"path":"rpc-provider/classes/_http_index_.httpprovider.md","ref":"rpc-provider/classes/_http_index_.httpprovider.md","articles":[]},{"title":"WsProvider","level":"1.3.2","depth":2,"path":"rpc-provider/classes/_ws_index_.wsprovider.md","ref":"rpc-provider/classes/_ws_index_.wsprovider.md","articles":[]}]},"previous":{"title":"ApiPromise","level":"1.2.1","depth":2,"path":"api/classes/_promise_index_.apipromise.md","ref":"api/classes/_promise_index_.apipromise.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"api/classes/_rx_index_.apirx.md","mtime":"2018-10-11T11:42:17.618Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"ApiRx","level":"1.2.2","depth":2,"next":{"title":"rpc-provider","level":"1.3","depth":1,"path":"rpc-provider/README.md","ref":"rpc-provider/README.md","articles":[{"title":"HttpProvider","level":"1.3.1","depth":2,"path":"rpc-provider/classes/_http_index_.httpprovider.md","ref":"rpc-provider/classes/_http_index_.httpprovider.md","articles":[]},{"title":"WsProvider","level":"1.3.2","depth":2,"path":"rpc-provider/classes/_ws_index_.wsprovider.md","ref":"rpc-provider/classes/_ws_index_.wsprovider.md","articles":[]}]},"previous":{"title":"ApiPromise","level":"1.2.1","depth":2,"path":"api/classes/_promise_index_.apipromise.md","ref":"api/classes/_promise_index_.apipromise.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"api/classes/_rx_index_.apirx.md","mtime":"2018-10-11T13:30:00.457Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
+98 -172
View File
@@ -1,18 +1,98 @@
*__description__*: ApiRx is a powerfull RxJS Observable wrapper around the RPC and interfaces on the Polkadot network. As a full Observable API, all interface calls return RxJS Observables, including the static `.create(...)`. In the same fashion and subscription-based methods return long-running Observables that update with the latest values.
The API is well suited to real-time applications where the latest state is needed, unlocking the subscription-based features of Polkadot (and Substrate) clients. Some familiarity with RxJS is a requirement to use the API, however just understanding `.subscribe` and `.pipe` on Observables will unlock full-scale use thereof.
*__example__*:
Making rpc calls -
```javascript
import ApiRx from '@polkadot/api/rx';
// initialise via Promise & static create
const api = await ApiRx.create().toPromise();
// make a call to retrieve the current network head
api.rpc.chain.newHead().subscribe((header) => {
console.log(`Chain is at #${header.blockNumber}`);
});
```
Subscribing to chain state -
```javascript
import { ApiRx } from '@polkadot/api';
import WsProvider from '@polkadot/rpc-provider/ws';
import { combineLatest } from 'rxjs';
let last = 0;
// initialise via isReady & new with specific non-local endpoint
new ApiRx(new WsProvider('wss://example.com:9944'))
.isReady
.pipe(
switchMap((api) =>
combineLatest([
api.st.timestamp.blockPeriod(),
api.st.timestamp.now()
])
)
.subscribe(([blockPeriod, timestamp]) => {
const elapsed = last
? `, ${timestamp.toNumber() - last}s since last`
: '';
last = timestamp.toNumber();
console.log(`timestamp ${timestamp}${elapsed} (${blockPeriod}s target)`);
});
```
Submitting a transaction -
```javascript
import ApiRx from '@polkadot/api/rx';
// get api via Promise
const api = await ApiRx.create().toPromise();
// retrieve nonce for the account
api.st.system
.accountNonce(keyring.alice.address())
.pipe(
// pipe nonce into transfer
switchMap((nonce) =>
api.tx.balances
// create transfer
.transfer(keyring.bob.address(), 12345)
// sign the transcation
.sign(keyring.alice, nonce)
// send the transaction
.send()
)
)
// subscribe to overall result
.subscribe((hash) => {
console.log(`submitted with hash ${hash}`);
});
```
# Type parameters
#### EventTypes : `string` &#124; `symbol`
# Hierarchy
↳ [ApiBase](_base_.apibase.md)<`RpcRx`, [QueryableStorage](../interfaces/_rx_types_d_.queryablestorage.md), [SubmittableExtrinsics](../interfaces/_rx_types_d_.submittableextrinsics.md)>
↳ [ApiBase](_base_.apibase.md)<`RpcRx`, `QueryableStorage`, `SubmittableExtrinsics`>
**↳ ApiRx**
# Implements
* [ApiBaseInterface](../interfaces/_types_d_.apibaseinterface.md)<`RpcRx`, [QueryableStorage](../interfaces/_rx_types_d_.queryablestorage.md), [SubmittableExtrinsics](../interfaces/_rx_types_d_.submittableextrinsics.md)>
* [ApiRxInterface](../interfaces/_rx_types_d_.apirxinterface.md)
* `ApiBaseInterface`<`RpcRx`, `QueryableStorage`, `SubmittableExtrinsics`>
* `ApiRxInterface`
# Constructors
@@ -24,7 +104,7 @@
*Overrides [ApiBase](_base_.apibase.md).[constructor](_base_.apibase.md#constructor)*
*Defined in [rx/index.ts:44](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L44)*
*Defined in [rx/index.ts:130](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/index.ts#L130)*
*__example__*:
```javascript
@@ -49,83 +129,6 @@ ___
# Properties
<a id="_extrinsics"></a>
## `<Protected>``<Optional>` _extrinsics
**● _extrinsics**: *[E]()*
*Inherited from [ApiBase](_base_.apibase.md).[_extrinsics](_base_.apibase.md#_extrinsics)*
*Defined in [Base.ts:33](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L33)*
___
<a id="_genesishash"></a>
## `<Protected>``<Optional>` _genesisHash
**● _genesisHash**: *`Hash`*
*Inherited from [ApiBase](_base_.apibase.md).[_genesisHash](_base_.apibase.md#_genesishash)*
*Defined in [Base.ts:34](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L34)*
___
<a id="_rpc"></a>
## `<Protected>` _rpc
**● _rpc**: *`RpcRx`*
*Inherited from [ApiBase](_base_.apibase.md).[_rpc](_base_.apibase.md#_rpc)*
*Defined in [Base.ts:36](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L36)*
___
<a id="_rpcbase"></a>
## `<Protected>` _rpcBase
**● _rpcBase**: *`Rpc`*
*Inherited from [ApiBase](_base_.apibase.md).[_rpcBase](_base_.apibase.md#_rpcbase)*
*Defined in [Base.ts:37](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L37)*
___
<a id="_runtimemetadata"></a>
## `<Protected>``<Optional>` _runtimeMetadata
**● _runtimeMetadata**: *`RuntimeMetadata`*
*Inherited from [ApiBase](_base_.apibase.md).[_runtimeMetadata](_base_.apibase.md#_runtimemetadata)*
*Defined in [Base.ts:38](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L38)*
___
<a id="_runtimeversion"></a>
## `<Protected>``<Optional>` _runtimeVersion
**● _runtimeVersion**: *`RuntimeVersion`*
*Inherited from [ApiBase](_base_.apibase.md).[_runtimeVersion](_base_.apibase.md#_runtimeversion)*
*Defined in [Base.ts:39](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L39)*
___
<a id="_storage"></a>
## `<Protected>``<Optional>` _storage
**● _storage**: *[S]()*
*Inherited from [ApiBase](_base_.apibase.md).[_storage](_base_.apibase.md#_storage)*
*Defined in [Base.ts:35](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L35)*
___
<a id="prefixed"></a>
## `<Static>` prefixed
@@ -149,7 +152,7 @@ getgenesisHash(): `Hash`
*Inherited from [ApiBase](_base_.apibase.md).[genesisHash](_base_.apibase.md#genesishash)*
*Defined in [Base.ts:68](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L68)*
*Defined in [Base.ts:68](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L68)*
*__description__*: Contains the genesis Hash of the attached chain. Apart from being useful to determine the actual chain, it can also be used to sign immortal transactions.
@@ -162,7 +165,7 @@ ___
getisConnected(): `Observable`<`boolean`>
*Defined in [rx/index.ts:77](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L77)*
*Defined in [rx/index.ts:163](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/index.ts#L163)*
*__description__*: Observable that carries the connected state for the provider. Results in a boolean flag that is true/false based on the connectivity.
@@ -175,7 +178,7 @@ ___
getisReady(): `Observable`<[ApiRx](_rx_index_.apirx.md)>
*Defined in [rx/index.ts:84](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L84)*
*Defined in [rx/index.ts:170](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/index.ts#L170)*
*__description__*: Observable that returns the first time we are connected and loaded
@@ -190,7 +193,7 @@ getrpc(): `RpcRx`
*Inherited from [ApiBase](_base_.apibase.md).[rpc](_base_.apibase.md#rpc)*
*Defined in [Base.ts:105](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L105)*
*Defined in [Base.ts:105](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L105)*
*__description__*: Contains all the raw rpc sections and their subsequent methods in the API as defined by the jsonrpc interface definitions.
@@ -214,7 +217,7 @@ getruntimeMetadata(): `RuntimeMetadata`
*Inherited from [ApiBase](_base_.apibase.md).[runtimeMetadata](_base_.apibase.md#runtimemetadata)*
*Defined in [Base.ts:77](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L77)*
*Defined in [Base.ts:77](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L77)*
*__description__*: Yields the current attached runtime metadata. Generally this is only used to construct extrinsics & storage, but is useful for current runtime inspection.
@@ -229,7 +232,7 @@ getruntimeVersion(): `RuntimeVersion`
*Inherited from [ApiBase](_base_.apibase.md).[runtimeVersion](_base_.apibase.md#runtimeversion)*
*Defined in [Base.ts:86](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L86)*
*Defined in [Base.ts:86](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L86)*
*__description__*: Contains the version information for the current runtime.
@@ -240,11 +243,11 @@ ___
## st
getst(): [QueryableStorage](../interfaces/_rx_types_d_.queryablestorage.md)
getst(): `QueryableStorage`
*Inherited from [ApiBase](_base_.apibase.md).[st](_base_.apibase.md#st)*
*Defined in [Base.ts:122](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L122)*
*Defined in [Base.ts:122](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L122)*
*__description__*: Contains all the chain state modules and their subsequent methods in the API. These are attached dynamically from the runtime metadata.
@@ -257,18 +260,18 @@ api.st.balances
});
```
**Returns:** [QueryableStorage](../interfaces/_rx_types_d_.queryablestorage.md)
**Returns:** `QueryableStorage`
___
<a id="tx"></a>
## tx
gettx(): [SubmittableExtrinsics](../interfaces/_rx_types_d_.submittableextrinsics.md)
gettx(): `SubmittableExtrinsics`
*Inherited from [ApiBase](_base_.apibase.md).[tx](_base_.apibase.md#tx)*
*Defined in [Base.ts:143](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L143)*
*Defined in [Base.ts:143](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/Base.ts#L143)*
*__description__*: Contains all the extrinsic modules and their subsequent methods in the API. It allows for the construction of transactions and the submission thereof. These are attached dynamically from the runtime metadata.
@@ -283,7 +286,7 @@ api.tx.balances
});
```
**Returns:** [SubmittableExtrinsics](../interfaces/_rx_types_d_.submittableextrinsics.md)
**Returns:** `SubmittableExtrinsics`
___
@@ -309,83 +312,6 @@ ___
**Returns:** `this`
___
<a id="decorateextrinsics"></a>
## `<Protected>` decorateExtrinsics
▸ **decorateExtrinsics**(extrinsics: *`Extrinsics`*): [SubmittableExtrinsics](../interfaces/_rx_types_d_.submittableextrinsics.md)
*Overrides [ApiBase](_base_.apibase.md).[decorateExtrinsics](_base_.apibase.md#decorateextrinsics)*
*Defined in [rx/index.ts:92](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L92)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| extrinsics | `Extrinsics` |
**Returns:** [SubmittableExtrinsics](../interfaces/_rx_types_d_.submittableextrinsics.md)
___
<a id="decoratefunctionmeta"></a>
## `<Protected>` decorateFunctionMeta
▸ **decorateFunctionMeta**(input: *`MetaDecoration`*, output: *`MetaDecoration`*): `MetaDecoration`
*Inherited from [ApiBase](_base_.apibase.md).[decorateFunctionMeta](_base_.apibase.md#decoratefunctionmeta)*
*Defined in [Base.ts:200](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/Base.ts#L200)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| input | `MetaDecoration` |
| output | `MetaDecoration` |
**Returns:** `MetaDecoration`
___
<a id="decoraterpc"></a>
## `<Protected>` decorateRpc
▸ **decorateRpc**(rpc: *`Rpc`*): `RpcRx`
*Overrides [ApiBase](_base_.apibase.md).[decorateRpc](_base_.apibase.md#decoraterpc)*
*Defined in [rx/index.ts:88](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L88)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| rpc | `Rpc` |
**Returns:** `RpcRx`
___
<a id="decoratestorage"></a>
## `<Protected>` decorateStorage
▸ **decorateStorage**(storage: *`Storage`*): [QueryableStorage](../interfaces/_rx_types_d_.queryablestorage.md)
*Overrides [ApiBase](_base_.apibase.md).[decorateStorage](_base_.apibase.md#decoratestorage)*
*Defined in [rx/index.ts:113](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L113)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| storage | `Storage` |
**Returns:** [QueryableStorage](../interfaces/_rx_types_d_.queryablestorage.md)
___
<a id="emit"></a>
@@ -585,7 +511,7 @@ ___
▸ **create**(wsProvider?: *`WsProvider`*): `Observable`<[ApiRx](_rx_index_.apirx.md)>
*Defined in [rx/index.ts:42](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/index.ts#L42)*
*Defined in [rx/index.ts:128](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/index.ts#L128)*
*__description__*: Creates an ApiRx instance using the supplied provider. Returns an Observable containing the actual Api instance.
@@ -594,7 +520,7 @@ ___
import Api from '@polkadot/api/rx';
Api.create().subscribe((api) => {
api.st.timestamp.now((timestamp) => {
api.st.timestamp.now.subscribe((timestamp) => {
console.log(`lastest block timestamp ${timestamp}`);
});
});
@@ -17,17 +17,17 @@
## constructor
⊕ **new SubmittableExtrinsic**(api: *[ApiRxInterface](../interfaces/_rx_types_d_.apirxinterface.md)*, extrinsic: *`Extrinsic`*): [SubmittableExtrinsic](_rx_submittableextrinsic_.submittableextrinsic.md)
⊕ **new SubmittableExtrinsic**(api: *`ApiRxInterface`*, extrinsic: *`Extrinsic`*): [SubmittableExtrinsic](_rx_submittableextrinsic_.submittableextrinsic.md)
*Overrides Extrinsic.__constructor*
*Defined in [rx/SubmittableExtrinsic.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/SubmittableExtrinsic.ts#L13)*
*Defined in [rx/SubmittableExtrinsic.ts:13](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/SubmittableExtrinsic.ts#L13)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| api | [ApiRxInterface](../interfaces/_rx_types_d_.apirxinterface.md) |
| api | `ApiRxInterface` |
| extrinsic | `Extrinsic` |
**Returns:** [SubmittableExtrinsic](_rx_submittableextrinsic_.submittableextrinsic.md)
@@ -36,28 +36,6 @@ ___
# Properties
<a id="_types"></a>
## `<Protected>` _Types
**● _Types**: *`E`*
*Inherited from Struct._Types*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:30](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L30)*
___
<a id="_jsonmap"></a>
## `<Protected>` _jsonMap
**● _jsonMap**: *`Map`<`keyof S`, `string`>*
*Inherited from Struct._jsonMap*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L29)*
___
<a id="raw"></a>
## raw
@@ -66,7 +44,7 @@ ___
*Inherited from Base.raw*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Base.ts#L19)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Base.ts:19](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Base.ts#L19)*
___
@@ -80,7 +58,7 @@ getType(): `E`
*Inherited from Struct.Type*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L108)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:108](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L108)*
**Returns:** `E`
@@ -93,7 +71,7 @@ getcallIndex(): `Uint8Array`
*Inherited from Extrinsic.callIndex*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:70](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L70)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:70](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L70)*
**Returns:** `Uint8Array`
@@ -106,7 +84,7 @@ getdata(): `Uint8Array`
*Inherited from Extrinsic.data*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:74](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L74)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:74](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L74)*
**Returns:** `Uint8Array`
@@ -119,7 +97,7 @@ gethash(): `Hash`
*Inherited from Extrinsic.hash*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:79](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L79)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:79](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L79)*
**Returns:** `Hash`
@@ -132,7 +110,7 @@ getisSigned(): `boolean`
*Inherited from Extrinsic.isSigned*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:85](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L85)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:85](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L85)*
**Returns:** `boolean`
@@ -145,7 +123,7 @@ getlength(): `number`
*Inherited from Extrinsic.length*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:89](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L89)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:89](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L89)*
**Returns:** `number`
@@ -158,7 +136,7 @@ getmeta(): `FunctionMetadata`
*Inherited from Extrinsic.meta*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:93](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L93)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:93](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L93)*
**Returns:** `FunctionMetadata`
@@ -171,7 +149,7 @@ getmethod(): `Method`
*Inherited from Extrinsic.method*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:97](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L97)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:97](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L97)*
**Returns:** `Method`
@@ -184,7 +162,7 @@ getsignature(): `ExtrinsicSignature`
*Inherited from Extrinsic.signature*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:101](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L101)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:101](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L101)*
**Returns:** `ExtrinsicSignature`
@@ -202,7 +180,7 @@ ___
*Overrides Struct.byteLength*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:105](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L105)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:105](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L105)*
**Returns:** `number`
@@ -217,7 +195,7 @@ ___
*Overrides Struct.fromJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:111](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L111)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:111](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L111)*
**Parameters:**
@@ -238,7 +216,7 @@ ___
*Overrides Struct.fromU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:117](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L117)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:117](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L117)*
**Parameters:**
@@ -257,7 +235,7 @@ ___
*Inherited from Struct.get*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L148)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:148](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L148)*
**Parameters:**
@@ -276,7 +254,7 @@ ___
*Inherited from Struct.keys*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L163)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:163](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L163)*
**Returns:** `Array`<`string`>
@@ -287,7 +265,7 @@ ___
▸ **send**(): `Observable`<`any`>
*Defined in [rx/SubmittableExtrinsic.ts:22](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/SubmittableExtrinsic.ts#L22)*
*Defined in [rx/SubmittableExtrinsic.ts:22](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/SubmittableExtrinsic.ts#L22)*
**Returns:** `Observable`<`any`>
@@ -300,7 +278,7 @@ ___
*Overrides Extrinsic.sign*
*Defined in [rx/SubmittableExtrinsic.ts:26](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/SubmittableExtrinsic.ts#L26)*
*Defined in [rx/SubmittableExtrinsic.ts:26](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/api/src/rx/SubmittableExtrinsic.ts#L26)*
**Parameters:**
@@ -321,7 +299,7 @@ ___
*Inherited from Extrinsic.toHex*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:142](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L142)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:142](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L142)*
**Returns:** `string`
@@ -336,7 +314,7 @@ ___
*Overrides Struct.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:146](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L146)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:146](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L146)*
**Returns:** `any`
@@ -351,7 +329,7 @@ ___
*Overrides Base.toString*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L175)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:175](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L175)*
**Returns:** `string`
@@ -366,7 +344,7 @@ ___
*Overrides Struct.toU8a*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:131](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L131)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:131](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L131)*
**Parameters:**
@@ -385,7 +363,7 @@ ___
*Inherited from Struct.values*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L184)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:184](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L184)*
**Returns:** `Array`<`Base`>
@@ -398,7 +376,7 @@ ___
*Inherited from Extrinsic.decodeExtrinsic*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:45](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/Extrinsic.ts#L45)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/Extrinsic.ts:45](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/Extrinsic.ts#L45)*
**Parameters:**
@@ -417,7 +395,7 @@ ___
*Inherited from Struct.decodeStruct*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L48)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:48](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L48)*
**Type parameters:**
@@ -442,7 +420,7 @@ ___
*Inherited from Struct.with*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/codec/Struct.ts#L98)*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/codec/Struct.ts:98](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/types/src/codec/Struct.ts#L98)*
**Type parameters:**
+62 -39
View File
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../examples/">
<li class="chapter " data-level="2.1" data-path="../examples-rpc/">
<a href="../examples/">
<a href="../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../examples-rpc/01_simple_connect/">
<a href="../examples/01_simple_connect/">
<a href="../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../examples-rpc/02_listen_to_blocks/">
<a href="../examples/02_listen_to_blocks/">
<a href="../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../examples-rpc/03_listen_to_balance_change/">
<a href="../examples/03_listen_to_balance_change/">
<a href="../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../examples-rpc/04_generate_account/">
<a href="../examples/04_generate_account/">
<a href="../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../examples-rpc/05_read_storage/">
<a href="../examples/05_read_storage/">
<a href="../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../examples-rpc/06_craft_extrinsic/">
<a href="../examples/06_craft_extrinsic/">
<a href="../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../examples-rpc/07_transfer_dots/">
<a href="../examples/07_transfer_dots/">
<a href="../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -422,18 +428,40 @@
<section class="normal markdown-section">
<p><a href="https://polkadot.js.org" target="_blank"><img src="https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square" alt="polkadotjs"></a> <img src="https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square" alt="isc"> <a href="https://github.com/Flet/semistandard" target="_blank"><img src="https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square" alt="style"></a> <a href="https://www.npmjs.com/package/@polkadot/api" target="_blank"><img src="https://img.shields.io/npm/v/@polkadot/api.svg?style=flat-square" alt="npm"></a> <a href="https://travis-ci.org/polkadot-js/api" target="_blank"><img src="https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square" alt="travis"></a> <a href="https://codeclimate.com/github/polkadot-js/api/maintainability" target="_blank"><img src="https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square" alt="maintainability"></a> <a href="https://coveralls.io/github/polkadot-js/api?branch=master" target="_blank"><img src="https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square" alt="coverage"></a> <a href="https://david-dm.org/polkadot-js/api?path=packages/api" target="_blank"><img src="https://david-dm.org/polkadot-js/api.svg?style=flat-square&amp;path=packages/api" alt="dependency"></a> <a href="https://david-dm.org/polkadot-js/api?path=packages/api#info=devDependencies" target="_blank"><img src="https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&amp;path=packages/api" alt="devDependency"></a></p>
<h1 id="polkadotapi">@polkadot/api</h1>
<p>An RxJs wrapper around <a href="../rpc-core">@polkadot/rpc-core</a>.</p>
<h1 id="usage">Usage</h1>
<h1 id="polkadotapi">@polkadot/api</h1>
<p>The Polkadot-JS API provides easy-to-use wrappers around JSONRPC calls that flow from an application to a node. It handles all the encoding and decoding or parameters, provides access to RPC functions and allows for the query of chain state and the submission of transactions.</p>
<p>The API wrappers provide a standard interface for use -</p>
<ul>
<li>A static <code>.create(&lt;optional WsProvider&gt;)</code> that returns an API istance when connected, decorated and ready-to use</li>
<li>The above is just a wrapper for <code>new Api(&lt;optional WsProvider&gt;)</code>, exposing the <code>isReady</code> getter</li>
<li><code>api.rpc.*</code> provides access to actual RPC calls, be it for queries, submission or retrieving chain information</li>
<li><code>api.st.*</code> provides access to chain state queries. These are dynamically populated based on what the runtime provides</li>
<li><code>api.tx.*</code> provides the ability to create transaction, like chain state, this list is populated from a runtime query</li>
</ul>
<h2 id="api-selection">API Selection</h2>
<p>There are two flavours of the API provided, one allowing a standard interface via JavaScript Promises and the second provides an Observable wrapper using <a href="https://github.com/ReactiveX/rxjs" target="_blank">RxJS</a>. Depending on your use-case and familiarity, you can choose either (or even both) for your application.</p>
<ul>
<li><a href="promise">ApiPromise</a> All interface calls returns Promises, including the static <code>.create(...)</code>. Additionally any subscription method use standard JavaScript <code>(error, value) =&gt; {}</code> callbacks.</li>
<li><a href="rx">ApiRx</a> All interface calls return RxJS Observables, including the static <code>.create(...)</code>. In the same fashion and subscription-based methods return long-running Observables that update with the latest values.</li>
</ul>
<h2 id="installation--import">Installation &amp; import</h2>
<p>Installation -</p>
<pre><code>npm install --save @polkadot/api/rx
</code></pre><p>Making rpc calls -</p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">ApiRx</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api/rx&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;alternatively</span>
<span class="sunlight-comment">//&#xA0;import&#xA0;{&#xA0;ApiRx&#xA0;}&#xA0;from&#xA0;&apos;@polkadot/api&apos;;</span>
</code></pre><p>Subscribing to blocks via Promise-based API -</p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-punctuation">{</span>&#xA0;<span class="sunlight-ident">ApiPromise</span>&#xA0;<span class="sunlight-punctuation">}</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;initialise&#xA0;via&#xA0;Promise&#xA0;&amp;&#xA0;static&#xA0;create</span>
<span class="sunlight-comment">//&#xA0;initialise&#xA0;via&#xA0;static&#xA0;create</span>
<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">api</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">await</span>&#xA0;<span class="sunlight-ident">ApiPromise</span><span class="sunlight-operator">.</span><span class="sunlight-ident">create</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;make&#xA0;a&#xA0;call&#xA0;to&#xA0;retrieve&#xA0;the&#xA0;current&#xA0;network&#xA0;head</span>
<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">rpc</span><span class="sunlight-operator">.</span><span class="sunlight-ident">chain</span><span class="sunlight-operator">.</span><span class="sunlight-ident">newHead</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">error</span><span class="sunlight-punctuation">,</span>&#xA0;<span class="sunlight-ident">header</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">Chain</span>&#xA0;<span class="sunlight-ident">is</span>&#xA0;<span class="sunlight-ident">at</span>&#xA0;<span class="sunlight-punctuation">#</span><span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">header</span><span class="sunlight-operator">.</span><span class="sunlight-ident">blockNumber</span><span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p>Subscribing to blocks via RxJS-based API -</p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-punctuation">{</span>&#xA0;<span class="sunlight-ident">ApiRx</span>&#xA0;<span class="sunlight-punctuation">}</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;initialise&#xA0;via&#xA0;static&#xA0;create</span>
<span class="sunlight-reservedWord">const</span>&#xA0;<span class="sunlight-ident">api</span>&#xA0;<span class="sunlight-operator">=</span>&#xA0;<span class="sunlight-ident">await</span>&#xA0;<span class="sunlight-ident">ApiRx</span><span class="sunlight-operator">.</span><span class="sunlight-ident">create</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">toPromise</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;make&#xA0;a&#xA0;call&#xA0;to&#xA0;retrieve&#xA0;the&#xA0;current&#xA0;network&#xA0;head</span>
@@ -441,17 +469,12 @@
&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">Chain</span>&#xA0;<span class="sunlight-ident">is</span>&#xA0;<span class="sunlight-ident">at</span>&#xA0;<span class="sunlight-punctuation">#</span><span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">header</span><span class="sunlight-operator">.</span><span class="sunlight-ident">blockNumber</span><span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<p>Subscribing to chain state -</p>
<pre><code class="lang-javascript"><div class="sunlight-container sunlight-theme-gitbook"><div class="sunlight-code-container"><pre class="sunlight-highlight-javascript sunlight-highlighted"><span class="sunlight-javascript"><span class="sunlight-reservedWord">import</span>&#xA0;<span class="sunlight-ident">Api</span>&#xA0;<span class="sunlight-ident">from</span>&#xA0;<span class="sunlight-string">&apos;@polkadot/api&apos;</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-comment">//&#xA0;initialise&#xA0;via&#xA0;isReady&#xA0;&amp;&#xA0;new</span>
<span class="sunlight-keyword">new</span>&#xA0;<span class="sunlight-ident">Api</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">isReady</span><span class="sunlight-operator">.</span><span class="sunlight-ident">subscribe</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">api</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;<span class="sunlight-comment">//&#xA0;make&#xA0;a&#xA0;call&#xA0;to&#xA0;retrieve&#xA0;the&#xA0;current&#xA0;network&#xA0;head</span>
&#xA0;&#xA0;<span class="sunlight-ident">api</span><span class="sunlight-operator">.</span><span class="sunlight-ident">st</span><span class="sunlight-operator">.</span><span class="sunlight-ident">timestamp</span><span class="sunlight-operator">.</span><span class="sunlight-ident">now</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">)</span><span class="sunlight-operator">.</span><span class="sunlight-ident">subscribe</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">(</span><span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">)</span>&#xA0;<span class="sunlight-operator">=</span><span class="sunlight-operator">&gt;</span>&#xA0;<span class="sunlight-punctuation">{</span>
&#xA0;&#xA0;&#xA0;&#xA0;<span class="sunlight-ident">console</span><span class="sunlight-operator">.</span><span class="sunlight-ident">log</span><span class="sunlight-punctuation">(</span><span class="sunlight-punctuation">`</span><span class="sunlight-ident">Current</span>&#xA0;<span class="sunlight-ident">block</span>&#xA0;<span class="sunlight-ident">timestamp</span>&#xA0;<span class="sunlight-ident">$</span><span class="sunlight-punctuation">{</span><span class="sunlight-ident">timestamp</span><span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">`</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
&#xA0;&#xA0;<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
<span class="sunlight-punctuation">}</span><span class="sunlight-punctuation">)</span><span class="sunlight-punctuation">;</span>
</span></pre></div></div></code></pre>
<h2 id="users">Users</h2>
<p>Some of the users of the API (let us know if you are missing from the list), include -</p>
<ul>
<li><a href="https://github.com/polkadot-js/apps" target="_blank">Polkadot-JS UI</a> A user-interface that allows you to make transactions, query the network or participate in actions on the network such as referendums and staking</li>
<li><a href="https://gitlab.com/Polkabot" target="_blank">Polkabot</a> Polkabot is a Matrix chatbot that keeps an eye on the Polkadot network. You can see Polkabot in action in <a href="https://matrix.to/#/#polkadot-network-status:matrix.org" target="_blank">https://matrix.to/#/#polkadot-network-status:matrix.org</a></li>
</ul>
</section>
@@ -495,7 +518,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"api","level":"1.2","depth":1,"next":{"title":"ApiPromise","level":"1.2.1","depth":2,"path":"api/classes/_promise_index_.apipromise.md","ref":"api/classes/_promise_index_.apipromise.md","articles":[]},"previous":{"title":"Introduction","level":"1.1","depth":1,"path":"README.md","ref":"README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"api/README.md","mtime":"2018-10-11T11:42:17.258Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"api","level":"1.2","depth":1,"next":{"title":"ApiPromise","level":"1.2.1","depth":2,"path":"api/classes/_promise_index_.apipromise.md","ref":"api/classes/_promise_index_.apipromise.md","articles":[]},"previous":{"title":"Introduction","level":"1.1","depth":1,"path":"README.md","ref":"README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"api/README.md","mtime":"2018-10-11T13:30:00.033Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"..","book":{"language":""}});
});
</script>
</div>
@@ -1,113 +0,0 @@
# Hierarchy
[ApiBaseInterface](_types_d_.apibaseinterface.md)<`Rpc`, [QueryableStorage](_promise_types_d_.queryablestorage.md), [SubmittableExtrinsics](_promise_types_d_.submittableextrinsics.md)>
**↳ ApiPromiseInterface**
# Implemented by
* [ApiPromise](../classes/_promise_index_.apipromise.md)
# Properties
<a id="genesishash"></a>
## genesisHash
**● genesisHash**: *`Hash`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[genesisHash](_types_d_.apibaseinterface.md#genesishash)*
*Defined in [types.d.ts:16](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L16)*
___
<a id="isready"></a>
## isReady
**● isReady**: *`Promise`<[ApiPromiseInterface](_promise_types_d_.apipromiseinterface.md)>*
*Defined in [promise/types.d.ts:42](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/types.d.ts#L42)*
___
<a id="on"></a>
## on
**● on**: *`function`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[on](_types_d_.apibaseinterface.md#on)*
*Defined in [types.d.ts:23](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L23)*
#### Type declaration
▸(type: *[ApiInterface$Events](../modules/_types_d_.md#apiinterface_events)*, handler: *`function`*): `void`
**Parameters:**
| Param | Type |
| ------ | ------ |
| type | [ApiInterface$Events](../modules/_types_d_.md#apiinterface_events) |
| handler | `function` |
**Returns:** `void`
___
<a id="rpc"></a>
## rpc
**● rpc**: *`Rpc`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[rpc](_types_d_.apibaseinterface.md#rpc)*
*Defined in [types.d.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L19)*
___
<a id="runtimemetadata"></a>
## runtimeMetadata
**● runtimeMetadata**: *`RuntimeMetadata`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[runtimeMetadata](_types_d_.apibaseinterface.md#runtimemetadata)*
*Defined in [types.d.ts:17](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L17)*
___
<a id="runtimeversion"></a>
## runtimeVersion
**● runtimeVersion**: *`RuntimeVersion`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[runtimeVersion](_types_d_.apibaseinterface.md#runtimeversion)*
*Defined in [types.d.ts:18](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L18)*
___
<a id="st"></a>
## st
**● st**: *[QueryableStorage](_promise_types_d_.queryablestorage.md)*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[st](_types_d_.apibaseinterface.md#st)*
*Defined in [types.d.ts:20](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L20)*
___
<a id="tx"></a>
## tx
**● tx**: *[SubmittableExtrinsics](_promise_types_d_.submittableextrinsics.md)*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[tx](_types_d_.apibaseinterface.md#tx)*
*Defined in [types.d.ts:21](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L21)*
___
@@ -1,9 +0,0 @@
# Hierarchy
**QueryableModuleStorage**
# Indexable
\[index: `string`\]:&nbsp;[QueryableStorageFunction](_promise_types_d_.queryablestoragefunction.md)
@@ -1,9 +0,0 @@
# Hierarchy
**QueryableStorage**
# Indexable
\[index: `string`\]:&nbsp;[QueryableModuleStorage](_promise_types_d_.queryablemodulestorage.md)
@@ -1,85 +0,0 @@
# Hierarchy
`StorageFunction`
**↳ QueryableStorageFunction**
# Callable
▸ **__call**(arg?: *`any`*): `Promise`< `Base` &#124; `null` &#124; `undefined`>
▸ **__call**(arg?: *`any`*): `Uint8Array`
*Defined in [promise/types.d.ts:17](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/types.d.ts#L17)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Optional` arg | `any` |
**Returns:** `Promise`< `Base` &#124; `null` &#124; `undefined`>
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:12](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L12)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Optional` arg | `any` |
**Returns:** `Uint8Array`
# Properties
<a id="meta"></a>
## meta
**● meta**: *`StorageFunctionMetadata`*
*Inherited from StorageFunction.meta*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L14)*
___
<a id="method"></a>
## method
**● method**: *`string`*
*Inherited from StorageFunction.method*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:15](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L15)*
___
<a id="section"></a>
## section
**● section**: *`string`*
*Inherited from StorageFunction.section*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:16](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L16)*
___
<a id="tojson"></a>
## toJSON
**● toJSON**: *`function`*
*Inherited from StorageFunction.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:17](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L17)*
#### Type declaration
▸(): `any`
**Returns:** `any`
___
@@ -1,96 +0,0 @@
# Hierarchy
`ExtrinsicFunction`
**↳ SubmittableExtrinsicFunction**
# Callable
▸ **__call**(...args: *`any`[]*): [SubmittableExtrinsic](../classes/_promise_submittableextrinsic_.submittableextrinsic.md)
▸ **__call**(...args: *`any`[]*): `Extrinsic`
*Defined in [promise/types.d.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/promise/types.d.ts#L29)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Rest` args | `any`[] |
**Returns:** [SubmittableExtrinsic](../classes/_promise_submittableextrinsic_.submittableextrinsic.md)
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:8](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L8)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Rest` args | `any`[] |
**Returns:** `Extrinsic`
# Properties
<a id="callindex"></a>
## callIndex
**● callIndex**: *`Uint8Array`*
*Inherited from ExtrinsicFunction.callIndex*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:10](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L10)*
___
<a id="meta"></a>
## meta
**● meta**: *`FunctionMetadata`*
*Inherited from ExtrinsicFunction.meta*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:11](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L11)*
___
<a id="method"></a>
## method
**● method**: *`string`*
*Inherited from ExtrinsicFunction.method*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:12](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L12)*
___
<a id="section"></a>
## section
**● section**: *`string`*
*Inherited from ExtrinsicFunction.section*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L13)*
___
<a id="tojson"></a>
## toJSON
**● toJSON**: *`function`*
*Inherited from ExtrinsicFunction.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L14)*
#### Type declaration
▸(): `any`
**Returns:** `any`
___
@@ -1,9 +0,0 @@
# Hierarchy
**SubmittableExtrinsics**
# Indexable
\[index: `string`\]:&nbsp;[SubmittableModuleExtrinsics](_promise_types_d_.submittablemoduleextrinsics.md)
@@ -1,9 +0,0 @@
# Hierarchy
**SubmittableModuleExtrinsics**
# Indexable
\[index: `string`\]:&nbsp;[SubmittableExtrinsicFunction](_promise_types_d_.submittableextrinsicfunction.md)
@@ -1,122 +0,0 @@
# Hierarchy
[ApiBaseInterface](_types_d_.apibaseinterface.md)<`RpcRx`, [QueryableStorage](_rx_types_d_.queryablestorage.md), [SubmittableExtrinsics](_rx_types_d_.submittableextrinsics.md)>
**↳ ApiRxInterface**
# Implemented by
* [ApiRx](../classes/_rx_index_.apirx.md)
# Properties
<a id="genesishash"></a>
## genesisHash
**● genesisHash**: *`Hash`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[genesisHash](_types_d_.apibaseinterface.md#genesishash)*
*Defined in [types.d.ts:16](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L16)*
___
<a id="isconnected"></a>
## isConnected
**● isConnected**: *`Observable`<`boolean`>*
*Defined in [rx/types.d.ts:42](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/types.d.ts#L42)*
___
<a id="isready"></a>
## isReady
**● isReady**: *`Observable`<[ApiRxInterface](_rx_types_d_.apirxinterface.md)>*
*Defined in [rx/types.d.ts:43](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/types.d.ts#L43)*
___
<a id="on"></a>
## on
**● on**: *`function`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[on](_types_d_.apibaseinterface.md#on)*
*Defined in [types.d.ts:23](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L23)*
#### Type declaration
▸(type: *[ApiInterface$Events](../modules/_types_d_.md#apiinterface_events)*, handler: *`function`*): `void`
**Parameters:**
| Param | Type |
| ------ | ------ |
| type | [ApiInterface$Events](../modules/_types_d_.md#apiinterface_events) |
| handler | `function` |
**Returns:** `void`
___
<a id="rpc"></a>
## rpc
**● rpc**: *`RpcRx`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[rpc](_types_d_.apibaseinterface.md#rpc)*
*Defined in [types.d.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L19)*
___
<a id="runtimemetadata"></a>
## runtimeMetadata
**● runtimeMetadata**: *`RuntimeMetadata`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[runtimeMetadata](_types_d_.apibaseinterface.md#runtimemetadata)*
*Defined in [types.d.ts:17](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L17)*
___
<a id="runtimeversion"></a>
## runtimeVersion
**● runtimeVersion**: *`RuntimeVersion`*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[runtimeVersion](_types_d_.apibaseinterface.md#runtimeversion)*
*Defined in [types.d.ts:18](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L18)*
___
<a id="st"></a>
## st
**● st**: *[QueryableStorage](_rx_types_d_.queryablestorage.md)*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[st](_types_d_.apibaseinterface.md#st)*
*Defined in [types.d.ts:20](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L20)*
___
<a id="tx"></a>
## tx
**● tx**: *[SubmittableExtrinsics](_rx_types_d_.submittableextrinsics.md)*
*Inherited from [ApiBaseInterface](_types_d_.apibaseinterface.md).[tx](_types_d_.apibaseinterface.md#tx)*
*Defined in [types.d.ts:21](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L21)*
___
@@ -1,9 +0,0 @@
# Hierarchy
**QueryableModuleStorage**
# Indexable
\[index: `string`\]:&nbsp;[QueryableStorageFunction](_rx_types_d_.queryablestoragefunction.md)
@@ -1,9 +0,0 @@
# Hierarchy
**QueryableStorage**
# Indexable
\[index: `string`\]:&nbsp;[QueryableModuleStorage](_rx_types_d_.queryablemodulestorage.md)
@@ -1,85 +0,0 @@
# Hierarchy
`StorageFunction`
**↳ QueryableStorageFunction**
# Callable
▸ **__call**(arg?: *`any`*): `Observable`< `Base` &#124; `null` &#124; `undefined`>
▸ **__call**(arg?: *`any`*): `Uint8Array`
*Defined in [rx/types.d.ts:17](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/types.d.ts#L17)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Optional` arg | `any` |
**Returns:** `Observable`< `Base` &#124; `null` &#124; `undefined`>
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:12](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L12)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Optional` arg | `any` |
**Returns:** `Uint8Array`
# Properties
<a id="meta"></a>
## meta
**● meta**: *`StorageFunctionMetadata`*
*Inherited from StorageFunction.meta*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L14)*
___
<a id="method"></a>
## method
**● method**: *`string`*
*Inherited from StorageFunction.method*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:15](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L15)*
___
<a id="section"></a>
## section
**● section**: *`string`*
*Inherited from StorageFunction.section*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:16](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L16)*
___
<a id="tojson"></a>
## toJSON
**● toJSON**: *`function`*
*Inherited from StorageFunction.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/types/src/StorageKey.ts:17](https://github.com/polkadot-js/api/blob/f5948fe/packages/types/src/StorageKey.ts#L17)*
#### Type declaration
▸(): `any`
**Returns:** `any`
___
@@ -1,96 +0,0 @@
# Hierarchy
`ExtrinsicFunction`
**↳ SubmittableExtrinsicFunction**
# Callable
▸ **__call**(...args: *`any`[]*): [SubmittableExtrinsic](../classes/_rx_submittableextrinsic_.submittableextrinsic.md)
▸ **__call**(...args: *`any`[]*): `Extrinsic`
*Defined in [rx/types.d.ts:29](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/rx/types.d.ts#L29)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Rest` args | `any`[] |
**Returns:** [SubmittableExtrinsic](../classes/_rx_submittableextrinsic_.submittableextrinsic.md)
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:8](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L8)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Rest` args | `any`[] |
**Returns:** `Extrinsic`
# Properties
<a id="callindex"></a>
## callIndex
**● callIndex**: *`Uint8Array`*
*Inherited from ExtrinsicFunction.callIndex*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:10](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L10)*
___
<a id="meta"></a>
## meta
**● meta**: *`FunctionMetadata`*
*Inherited from ExtrinsicFunction.meta*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:11](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L11)*
___
<a id="method"></a>
## method
**● method**: *`string`*
*Inherited from ExtrinsicFunction.method*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:12](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L12)*
___
<a id="section"></a>
## section
**● section**: *`string`*
*Inherited from ExtrinsicFunction.section*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L13)*
___
<a id="tojson"></a>
## toJSON
**● toJSON**: *`function`*
*Inherited from ExtrinsicFunction.toJSON*
*Defined in [/home/travis/build/polkadot-js/api/packages/type-extrinsics/src/types.d.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L14)*
#### Type declaration
▸(): `any`
**Returns:** `any`
___
@@ -1,9 +0,0 @@
# Hierarchy
**SubmittableExtrinsics**
# Indexable
\[index: `string`\]:&nbsp;[SubmittableModuleExtrinsics](_rx_types_d_.submittablemoduleextrinsics.md)
@@ -1,9 +0,0 @@
# Hierarchy
**SubmittableModuleExtrinsics**
# Indexable
\[index: `string`\]:&nbsp;[SubmittableExtrinsicFunction](_rx_types_d_.submittableextrinsicfunction.md)
@@ -1,98 +0,0 @@
# Type parameters
#### R
#### S
#### E
# Hierarchy
**ApiBaseInterface**
↳ [ApiPromiseInterface](_promise_types_d_.apipromiseinterface.md)
↳ [ApiRxInterface](_rx_types_d_.apirxinterface.md)
# Implemented by
* [ApiBase](../classes/_base_.apibase.md)
* [ApiPromise](../classes/_promise_index_.apipromise.md)
* [ApiRx](../classes/_rx_index_.apirx.md)
# Properties
<a id="genesishash"></a>
## genesisHash
**● genesisHash**: *`Hash`*
*Defined in [types.d.ts:16](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L16)*
___
<a id="on"></a>
## on
**● on**: *`function`*
*Defined in [types.d.ts:23](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L23)*
#### Type declaration
▸(type: *[ApiInterface$Events](../modules/_types_d_.md#apiinterface_events)*, handler: *`function`*): `void`
**Parameters:**
| Param | Type |
| ------ | ------ |
| type | [ApiInterface$Events](../modules/_types_d_.md#apiinterface_events) |
| handler | `function` |
**Returns:** `void`
___
<a id="rpc"></a>
## rpc
**● rpc**: *`R`*
*Defined in [types.d.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L19)*
___
<a id="runtimemetadata"></a>
## runtimeMetadata
**● runtimeMetadata**: *`RuntimeMetadata`*
*Defined in [types.d.ts:17](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L17)*
___
<a id="runtimeversion"></a>
## runtimeVersion
**● runtimeVersion**: *`RuntimeVersion`*
*Defined in [types.d.ts:18](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L18)*
___
<a id="st"></a>
## st
**● st**: *`S`*
*Defined in [types.d.ts:20](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L20)*
___
<a id="tx"></a>
## tx
**● tx**: *`E`*
*Defined in [types.d.ts:21](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L21)*
___
-2
View File
@@ -1,2 +0,0 @@
-2
View File
@@ -1,2 +0,0 @@
-15
View File
@@ -1,15 +0,0 @@
# Type aliases
<a id="apiinterface_events"></a>
## ApiInterface$Events
**Ƭ ApiInterface$Events**: * `RpcRxInterface$Events` &#124; "ready"
*
*Defined in [types.d.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/api/src/types.d.ts#L13)*
___
+17 -11
View File
@@ -278,15 +278,16 @@
<a href="../">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter active" data-level="2.2" data-path="./">
<li class="chapter active" data-level="2.1.1" data-path="./">
<a href="./">
@@ -299,7 +300,7 @@
</li>
<li class="chapter " data-level="2.3" data-path="../02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../02_listen_to_blocks/">
<a href="../02_listen_to_blocks/">
@@ -312,7 +313,7 @@
</li>
<li class="chapter " data-level="2.4" data-path="../03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../03_listen_to_balance_change/">
<a href="../03_listen_to_balance_change/">
@@ -325,7 +326,7 @@
</li>
<li class="chapter " data-level="2.5" data-path="../04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../04_generate_account/">
<a href="../04_generate_account/">
@@ -338,7 +339,7 @@
</li>
<li class="chapter " data-level="2.6" data-path="../05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../05_read_storage/">
<a href="../05_read_storage/">
@@ -351,7 +352,7 @@
</li>
<li class="chapter " data-level="2.7" data-path="../06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../06_craft_extrinsic/">
<a href="../06_craft_extrinsic/">
@@ -364,7 +365,7 @@
</li>
<li class="chapter " data-level="2.8" data-path="../07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../07_transfer_dots/">
<a href="../07_transfer_dots/">
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -468,7 +474,7 @@
<a href="../" class="navigation navigation-prev " aria-label="Previous page: Overview">
<a href="../" class="navigation navigation-prev " aria-label="Previous page: RPC">
<i class="fa fa-angle-left"></i>
</a>
@@ -484,7 +490,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Simple connect","level":"2.2","depth":1,"next":{"title":"Listen to blocks","level":"2.3","depth":1,"path":"examples/02_listen_to_blocks/README.md","ref":"examples/02_listen_to_blocks/README.md","articles":[]},"previous":{"title":"Overview","level":"2.1","depth":1,"path":"examples/README.md","ref":"examples/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples/01_simple_connect/README.md","mtime":"2018-10-11T11:40:21.743Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Simple connect","level":"2.1.1","depth":2,"next":{"title":"Listen to blocks","level":"2.1.2","depth":2,"path":"examples-rpc/02_listen_to_blocks/README.md","ref":"examples-rpc/02_listen_to_blocks/README.md","articles":[]},"previous":{"title":"RPC","level":"2.1","depth":1,"path":"examples-rpc/README.md","ref":"examples-rpc/README.md","articles":[{"title":"Simple connect","level":"2.1.1","depth":2,"path":"examples-rpc/01_simple_connect/README.md","ref":"examples-rpc/01_simple_connect/README.md","articles":[]},{"title":"Listen to blocks","level":"2.1.2","depth":2,"path":"examples-rpc/02_listen_to_blocks/README.md","ref":"examples-rpc/02_listen_to_blocks/README.md","articles":[]},{"title":"Listen to balance change","level":"2.1.3","depth":2,"path":"examples-rpc/03_listen_to_balance_change/README.md","ref":"examples-rpc/03_listen_to_balance_change/README.md","articles":[]},{"title":"Generate Accounts","level":"2.1.4","depth":2,"path":"examples-rpc/04_generate_account/README.md","ref":"examples-rpc/04_generate_account/README.md","articles":[]},{"title":"Read Storage","level":"2.1.5","depth":2,"path":"examples-rpc/05_read_storage/README.md","ref":"examples-rpc/05_read_storage/README.md","articles":[]},{"title":"Craft Extrinsic","level":"2.1.6","depth":2,"path":"examples-rpc/06_craft_extrinsic/README.md","ref":"examples-rpc/06_craft_extrinsic/README.md","articles":[]},{"title":"Transfer DOTs","level":"2.1.7","depth":2,"path":"examples-rpc/07_transfer_dots/README.md","ref":"examples-rpc/07_transfer_dots/README.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples-rpc/01_simple_connect/README.md","mtime":"2018-10-11T13:27:51.709Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
@@ -278,15 +278,16 @@
<a href="../">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../01_simple_connect/">
<a href="../01_simple_connect/">
@@ -299,7 +300,7 @@
</li>
<li class="chapter active" data-level="2.3" data-path="./">
<li class="chapter active" data-level="2.1.2" data-path="./">
<a href="./">
@@ -312,7 +313,7 @@
</li>
<li class="chapter " data-level="2.4" data-path="../03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../03_listen_to_balance_change/">
<a href="../03_listen_to_balance_change/">
@@ -325,7 +326,7 @@
</li>
<li class="chapter " data-level="2.5" data-path="../04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../04_generate_account/">
<a href="../04_generate_account/">
@@ -338,7 +339,7 @@
</li>
<li class="chapter " data-level="2.6" data-path="../05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../05_read_storage/">
<a href="../05_read_storage/">
@@ -351,7 +352,7 @@
</li>
<li class="chapter " data-level="2.7" data-path="../06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../06_craft_extrinsic/">
<a href="../06_craft_extrinsic/">
@@ -364,7 +365,7 @@
</li>
<li class="chapter " data-level="2.8" data-path="../07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../07_transfer_dots/">
<a href="../07_transfer_dots/">
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -491,7 +497,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Listen to blocks","level":"2.3","depth":1,"next":{"title":"Listen to balance change","level":"2.4","depth":1,"path":"examples/03_listen_to_balance_change/README.md","ref":"examples/03_listen_to_balance_change/README.md","articles":[]},"previous":{"title":"Simple connect","level":"2.2","depth":1,"path":"examples/01_simple_connect/README.md","ref":"examples/01_simple_connect/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples/02_listen_to_blocks/README.md","mtime":"2018-10-11T11:40:21.743Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Listen to blocks","level":"2.1.2","depth":2,"next":{"title":"Listen to balance change","level":"2.1.3","depth":2,"path":"examples-rpc/03_listen_to_balance_change/README.md","ref":"examples-rpc/03_listen_to_balance_change/README.md","articles":[]},"previous":{"title":"Simple connect","level":"2.1.1","depth":2,"path":"examples-rpc/01_simple_connect/README.md","ref":"examples-rpc/01_simple_connect/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples-rpc/02_listen_to_blocks/README.md","mtime":"2018-10-11T13:27:51.709Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
@@ -278,15 +278,16 @@
<a href="../">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../01_simple_connect/">
<a href="../01_simple_connect/">
@@ -299,7 +300,7 @@
</li>
<li class="chapter " data-level="2.3" data-path="../02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../02_listen_to_blocks/">
<a href="../02_listen_to_blocks/">
@@ -312,7 +313,7 @@
</li>
<li class="chapter active" data-level="2.4" data-path="./">
<li class="chapter active" data-level="2.1.3" data-path="./">
<a href="./">
@@ -325,7 +326,7 @@
</li>
<li class="chapter " data-level="2.5" data-path="../04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../04_generate_account/">
<a href="../04_generate_account/">
@@ -338,7 +339,7 @@
</li>
<li class="chapter " data-level="2.6" data-path="../05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../05_read_storage/">
<a href="../05_read_storage/">
@@ -351,7 +352,7 @@
</li>
<li class="chapter " data-level="2.7" data-path="../06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../06_craft_extrinsic/">
<a href="../06_craft_extrinsic/">
@@ -364,7 +365,7 @@
</li>
<li class="chapter " data-level="2.8" data-path="../07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../07_transfer_dots/">
<a href="../07_transfer_dots/">
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -486,7 +492,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Listen to balance change","level":"2.4","depth":1,"next":{"title":"Generate Accounts","level":"2.5","depth":1,"path":"examples/04_generate_account/README.md","ref":"examples/04_generate_account/README.md","articles":[]},"previous":{"title":"Listen to blocks","level":"2.3","depth":1,"path":"examples/02_listen_to_blocks/README.md","ref":"examples/02_listen_to_blocks/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples/03_listen_to_balance_change/README.md","mtime":"2018-10-11T11:40:21.743Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Listen to balance change","level":"2.1.3","depth":2,"next":{"title":"Generate Accounts","level":"2.1.4","depth":2,"path":"examples-rpc/04_generate_account/README.md","ref":"examples-rpc/04_generate_account/README.md","articles":[]},"previous":{"title":"Listen to blocks","level":"2.1.2","depth":2,"path":"examples-rpc/02_listen_to_blocks/README.md","ref":"examples-rpc/02_listen_to_blocks/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples-rpc/03_listen_to_balance_change/README.md","mtime":"2018-10-11T13:27:51.709Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
@@ -278,15 +278,16 @@
<a href="../">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../01_simple_connect/">
<a href="../01_simple_connect/">
@@ -299,7 +300,7 @@
</li>
<li class="chapter " data-level="2.3" data-path="../02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../02_listen_to_blocks/">
<a href="../02_listen_to_blocks/">
@@ -312,7 +313,7 @@
</li>
<li class="chapter " data-level="2.4" data-path="../03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../03_listen_to_balance_change/">
<a href="../03_listen_to_balance_change/">
@@ -325,7 +326,7 @@
</li>
<li class="chapter active" data-level="2.5" data-path="./">
<li class="chapter active" data-level="2.1.4" data-path="./">
<a href="./">
@@ -338,7 +339,7 @@
</li>
<li class="chapter " data-level="2.6" data-path="../05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../05_read_storage/">
<a href="../05_read_storage/">
@@ -351,7 +352,7 @@
</li>
<li class="chapter " data-level="2.7" data-path="../06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../06_craft_extrinsic/">
<a href="../06_craft_extrinsic/">
@@ -364,7 +365,7 @@
</li>
<li class="chapter " data-level="2.8" data-path="../07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../07_transfer_dots/">
<a href="../07_transfer_dots/">
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -500,7 +506,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Generate Accounts","level":"2.5","depth":1,"next":{"title":"Read Storage","level":"2.6","depth":1,"path":"examples/05_read_storage/README.md","ref":"examples/05_read_storage/README.md","articles":[]},"previous":{"title":"Listen to balance change","level":"2.4","depth":1,"path":"examples/03_listen_to_balance_change/README.md","ref":"examples/03_listen_to_balance_change/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples/04_generate_account/README.md","mtime":"2018-10-11T11:40:21.743Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Generate Accounts","level":"2.1.4","depth":2,"next":{"title":"Read Storage","level":"2.1.5","depth":2,"path":"examples-rpc/05_read_storage/README.md","ref":"examples-rpc/05_read_storage/README.md","articles":[]},"previous":{"title":"Listen to balance change","level":"2.1.3","depth":2,"path":"examples-rpc/03_listen_to_balance_change/README.md","ref":"examples-rpc/03_listen_to_balance_change/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples-rpc/04_generate_account/README.md","mtime":"2018-10-11T13:27:51.709Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
+16 -10
View File
@@ -278,15 +278,16 @@
<a href="../">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../01_simple_connect/">
<a href="../01_simple_connect/">
@@ -299,7 +300,7 @@
</li>
<li class="chapter " data-level="2.3" data-path="../02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../02_listen_to_blocks/">
<a href="../02_listen_to_blocks/">
@@ -312,7 +313,7 @@
</li>
<li class="chapter " data-level="2.4" data-path="../03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../03_listen_to_balance_change/">
<a href="../03_listen_to_balance_change/">
@@ -325,7 +326,7 @@
</li>
<li class="chapter " data-level="2.5" data-path="../04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../04_generate_account/">
<a href="../04_generate_account/">
@@ -338,7 +339,7 @@
</li>
<li class="chapter active" data-level="2.6" data-path="./">
<li class="chapter active" data-level="2.1.5" data-path="./">
<a href="./">
@@ -351,7 +352,7 @@
</li>
<li class="chapter " data-level="2.7" data-path="../06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../06_craft_extrinsic/">
<a href="../06_craft_extrinsic/">
@@ -364,7 +365,7 @@
</li>
<li class="chapter " data-level="2.8" data-path="../07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../07_transfer_dots/">
<a href="../07_transfer_dots/">
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -500,7 +506,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Read Storage","level":"2.6","depth":1,"next":{"title":"Craft Extrinsic","level":"2.7","depth":1,"path":"examples/06_craft_extrinsic/README.md","ref":"examples/06_craft_extrinsic/README.md","articles":[]},"previous":{"title":"Generate Accounts","level":"2.5","depth":1,"path":"examples/04_generate_account/README.md","ref":"examples/04_generate_account/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples/05_read_storage/README.md","mtime":"2018-10-11T11:40:21.743Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Read Storage","level":"2.1.5","depth":2,"next":{"title":"Craft Extrinsic","level":"2.1.6","depth":2,"path":"examples-rpc/06_craft_extrinsic/README.md","ref":"examples-rpc/06_craft_extrinsic/README.md","articles":[]},"previous":{"title":"Generate Accounts","level":"2.1.4","depth":2,"path":"examples-rpc/04_generate_account/README.md","ref":"examples-rpc/04_generate_account/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples-rpc/05_read_storage/README.md","mtime":"2018-10-11T13:27:51.713Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
+16 -10
View File
@@ -278,15 +278,16 @@
<a href="../">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../01_simple_connect/">
<a href="../01_simple_connect/">
@@ -299,7 +300,7 @@
</li>
<li class="chapter " data-level="2.3" data-path="../02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../02_listen_to_blocks/">
<a href="../02_listen_to_blocks/">
@@ -312,7 +313,7 @@
</li>
<li class="chapter " data-level="2.4" data-path="../03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../03_listen_to_balance_change/">
<a href="../03_listen_to_balance_change/">
@@ -325,7 +326,7 @@
</li>
<li class="chapter " data-level="2.5" data-path="../04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../04_generate_account/">
<a href="../04_generate_account/">
@@ -338,7 +339,7 @@
</li>
<li class="chapter " data-level="2.6" data-path="../05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../05_read_storage/">
<a href="../05_read_storage/">
@@ -351,7 +352,7 @@
</li>
<li class="chapter active" data-level="2.7" data-path="./">
<li class="chapter active" data-level="2.1.6" data-path="./">
<a href="./">
@@ -364,7 +365,7 @@
</li>
<li class="chapter " data-level="2.8" data-path="../07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../07_transfer_dots/">
<a href="../07_transfer_dots/">
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -524,7 +530,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Craft Extrinsic","level":"2.7","depth":1,"next":{"title":"Transfer DOTs","level":"2.8","depth":1,"path":"examples/07_transfer_dots/README.md","ref":"examples/07_transfer_dots/README.md","articles":[]},"previous":{"title":"Read Storage","level":"2.6","depth":1,"path":"examples/05_read_storage/README.md","ref":"examples/05_read_storage/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples/06_craft_extrinsic/README.md","mtime":"2018-10-11T11:40:21.747Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Craft Extrinsic","level":"2.1.6","depth":2,"next":{"title":"Transfer DOTs","level":"2.1.7","depth":2,"path":"examples-rpc/07_transfer_dots/README.md","ref":"examples-rpc/07_transfer_dots/README.md","articles":[]},"previous":{"title":"Read Storage","level":"2.1.5","depth":2,"path":"examples-rpc/05_read_storage/README.md","ref":"examples-rpc/05_read_storage/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples-rpc/06_craft_extrinsic/README.md","mtime":"2018-10-11T13:27:51.713Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
+16 -10
View File
@@ -276,15 +276,16 @@
<a href="../">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../01_simple_connect/">
<a href="../01_simple_connect/">
@@ -297,7 +298,7 @@
</li>
<li class="chapter " data-level="2.3" data-path="../02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../02_listen_to_blocks/">
<a href="../02_listen_to_blocks/">
@@ -310,7 +311,7 @@
</li>
<li class="chapter " data-level="2.4" data-path="../03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../03_listen_to_balance_change/">
<a href="../03_listen_to_balance_change/">
@@ -323,7 +324,7 @@
</li>
<li class="chapter " data-level="2.5" data-path="../04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../04_generate_account/">
<a href="../04_generate_account/">
@@ -336,7 +337,7 @@
</li>
<li class="chapter " data-level="2.6" data-path="../05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../05_read_storage/">
<a href="../05_read_storage/">
@@ -349,7 +350,7 @@
</li>
<li class="chapter " data-level="2.7" data-path="../06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../06_craft_extrinsic/">
<a href="../06_craft_extrinsic/">
@@ -362,7 +363,7 @@
</li>
<li class="chapter active" data-level="2.8" data-path="./">
<li class="chapter active" data-level="2.1.7" data-path="./">
<a href="./">
@@ -376,6 +377,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -504,7 +510,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Transfer DOTs","level":"2.8","depth":1,"previous":{"title":"Craft Extrinsic","level":"2.7","depth":1,"path":"examples/06_craft_extrinsic/README.md","ref":"examples/06_craft_extrinsic/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples/07_transfer_dots/README.md","mtime":"2018-10-11T11:40:21.747Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Transfer DOTs","level":"2.1.7","depth":2,"previous":{"title":"Craft Extrinsic","level":"2.1.6","depth":2,"path":"examples-rpc/06_craft_extrinsic/README.md","ref":"examples-rpc/06_craft_extrinsic/README.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples-rpc/07_transfer_dots/README.md","mtime":"2018-10-11T13:27:51.713Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
+18 -12
View File
@@ -4,7 +4,7 @@
<head>
<meta charset="UTF-8">
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<title>Overview · Polkadot API Book</title>
<title>RPC · Polkadot API Book</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="description" content="">
<meta name="generator" content="GitBook 3.2.3">
@@ -278,15 +278,16 @@
<a href="./">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="01_simple_connect/">
<a href="01_simple_connect/">
@@ -299,7 +300,7 @@
</li>
<li class="chapter " data-level="2.3" data-path="02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="02_listen_to_blocks/">
<a href="02_listen_to_blocks/">
@@ -312,7 +313,7 @@
</li>
<li class="chapter " data-level="2.4" data-path="03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="03_listen_to_balance_change/">
<a href="03_listen_to_balance_change/">
@@ -325,7 +326,7 @@
</li>
<li class="chapter " data-level="2.5" data-path="04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="04_generate_account/">
<a href="04_generate_account/">
@@ -338,7 +339,7 @@
</li>
<li class="chapter " data-level="2.6" data-path="05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="05_read_storage/">
<a href="05_read_storage/">
@@ -351,7 +352,7 @@
</li>
<li class="chapter " data-level="2.7" data-path="06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="06_craft_extrinsic/">
<a href="06_craft_extrinsic/">
@@ -364,7 +365,7 @@
</li>
<li class="chapter " data-level="2.8" data-path="07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="07_transfer_dots/">
<a href="07_transfer_dots/">
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -407,7 +413,7 @@
<!-- Title -->
<h1>
<i class="fa fa-circle-o-notch fa-spin"></i>
<a href=".." >Overview</a>
<a href=".." >RPC</a>
</h1>
</div>
@@ -480,7 +486,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Overview","level":"2.1","depth":1,"next":{"title":"Simple connect","level":"2.2","depth":1,"path":"examples/01_simple_connect/README.md","ref":"examples/01_simple_connect/README.md","articles":[]},"previous":{"title":"RpcRx","level":"1.5.1","depth":2,"path":"rpc-rx/classes/_index_.rpcrx.md","ref":"rpc-rx/classes/_index_.rpcrx.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples/README.md","mtime":"2018-10-11T11:40:21.747Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"RPC","level":"2.1","depth":1,"next":{"title":"Simple connect","level":"2.1.1","depth":2,"path":"examples-rpc/01_simple_connect/README.md","ref":"examples-rpc/01_simple_connect/README.md","articles":[]},"previous":{"title":"RpcRx","level":"1.5.1","depth":2,"path":"rpc-rx/classes/_index_.rpcrx.md","ref":"rpc-rx/classes/_index_.rpcrx.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"examples-rpc/README.md","mtime":"2018-10-11T13:27:51.713Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"..","book":{"language":""}});
});
</script>
</div>
+35 -27
View File
@@ -271,22 +271,23 @@
<li class="chapter " data-level="2.1" data-path="examples/">
<li class="chapter " data-level="2.1" data-path="examples-rpc/">
<a href="examples/">
<a href="examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="examples-rpc/01_simple_connect/">
<a href="examples/01_simple_connect/">
<a href="examples-rpc/01_simple_connect/">
Simple connect
@@ -297,9 +298,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="examples-rpc/02_listen_to_blocks/">
<a href="examples/02_listen_to_blocks/">
<a href="examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -310,9 +311,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="examples-rpc/03_listen_to_balance_change/">
<a href="examples/03_listen_to_balance_change/">
<a href="examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -323,9 +324,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="examples-rpc/04_generate_account/">
<a href="examples/04_generate_account/">
<a href="examples-rpc/04_generate_account/">
Generate Accounts
@@ -336,9 +337,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="examples-rpc/05_read_storage/">
<a href="examples/05_read_storage/">
<a href="examples-rpc/05_read_storage/">
Read Storage
@@ -349,9 +350,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="examples-rpc/06_craft_extrinsic/">
<a href="examples/06_craft_extrinsic/">
<a href="examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -362,9 +363,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="examples-rpc/07_transfer_dots/">
<a href="examples/07_transfer_dots/">
<a href="examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -376,6 +377,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -445,14 +451,16 @@
</ul>
<h2 id="examples">Examples</h2>
<ul>
<li><a href="examples/">Overview</a></li>
<li><a href="examples/01_simple_connect/">Simple connect</a></li>
<li><a href="examples/02_listen_to_blocks/">Listen to blocks</a></li>
<li><a href="examples/03_listen_to_balance_change/">Listen to balance change</a></li>
<li><a href="examples/04_generate_account/">Generate Accounts</a></li>
<li><a href="examples/05_read_storage/">Read Storage</a></li>
<li><a href="examples/06_craft_extrinsic/">Craft Extrinsic</a></li>
<li><a href="examples/07_transfer_dots/">Transfer DOTs</a></li>
<li><a href="examples-rpc/">RPC</a><ul>
<li><a href="examples-rpc/01_simple_connect/">Simple connect</a></li>
<li><a href="examples-rpc/02_listen_to_blocks/">Listen to blocks</a></li>
<li><a href="examples-rpc/03_listen_to_balance_change/">Listen to balance change</a></li>
<li><a href="examples-rpc/04_generate_account/">Generate Accounts</a></li>
<li><a href="examples-rpc/05_read_storage/">Read Storage</a></li>
<li><a href="examples-rpc/06_craft_extrinsic/">Craft Extrinsic</a></li>
<li><a href="examples-rpc/07_transfer_dots/">Transfer DOTs</a></li>
</ul>
</li>
</ul>
<h2 id="the-polkadot-project">The Polkadot Project</h2>
<p>You can read more about the Polkadot Network at <a href="https://polkadot.network/" target="_blank">https://polkadot.network/</a></p>
@@ -505,7 +513,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Introduction","level":"1.1","depth":1,"next":{"title":"api","level":"1.2","depth":1,"path":"api/README.md","ref":"api/README.md","articles":[{"title":"ApiPromise","level":"1.2.1","depth":2,"path":"api/classes/_promise_index_.apipromise.md","ref":"api/classes/_promise_index_.apipromise.md","articles":[]},{"title":"ApiRx","level":"1.2.2","depth":2,"path":"api/classes/_rx_index_.apirx.md","ref":"api/classes/_rx_index_.apirx.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"README.md","mtime":"2018-10-11T11:40:21.739Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":".","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Introduction","level":"1.1","depth":1,"next":{"title":"api","level":"1.2","depth":1,"path":"api/README.md","ref":"api/README.md","articles":[{"title":"ApiPromise","level":"1.2.1","depth":2,"path":"api/classes/_promise_index_.apipromise.md","ref":"api/classes/_promise_index_.apipromise.md","articles":[]},{"title":"ApiRx","level":"1.2.2","depth":2,"path":"api/classes/_rx_index_.apirx.md","ref":"api/classes/_rx_index_.apirx.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"README.md","mtime":"2018-10-11T13:27:51.705Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":".","book":{"language":""}});
});
</script>
</div>
-2
View File
@@ -1,6 +1,4 @@
[![polkadotjs](https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square)](https://polkadot.js.org) ![isc](https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square) [![style](https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square)](https://github.com/Flet/semistandard) [![npm](https://img.shields.io/npm/v/@polkadot/api.svg?style=flat-square)](https://www.npmjs.com/package/@polkadot/api) [![travis](https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square)](https://travis-ci.org/polkadot-js/api) [![maintainability](https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square)](https://codeclimate.com/github/polkadot-js/api/maintainability) [![coverage](https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square)](https://coveralls.io/github/polkadot-js/api?branch=master) [![dependency](https://david-dm.org/polkadot-js/api.svg?style=flat-square&path=package/rpc-core)](https://david-dm.org/polkadot-js/api?path=package/rpc-core) [![devDependency](https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&path=package/rpc-core)](https://david-dm.org/polkadot-js/api?path=package/rpc-core#info=devDependencies)
@polkadot/rpc-core
==================
-3
View File
@@ -1,6 +1,3 @@
* [&quot;defaults&quot;](modules/_defaults_.md)
* [&quot;index&quot;](modules/_index_.md)
* [Rpc](classes/_index_.rpc.md)
* [&quot;types.d&quot;](modules/_types_d_.md)
* [RpcInterface](interfaces/_types_d_.rpcinterface.md)
* [RpcInterface$Section$Method](interfaces/_types_d_.rpcinterface_section_method.md)
+37 -35
View File
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../../examples/">
<li class="chapter " data-level="2.1" data-path="../../examples-rpc/">
<a href="../../examples/">
<a href="../../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../../examples-rpc/01_simple_connect/">
<a href="../../examples/01_simple_connect/">
<a href="../../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../../examples-rpc/02_listen_to_blocks/">
<a href="../../examples/02_listen_to_blocks/">
<a href="../../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../../examples-rpc/03_listen_to_balance_change/">
<a href="../../examples/03_listen_to_balance_change/">
<a href="../../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../../examples-rpc/04_generate_account/">
<a href="../../examples/04_generate_account/">
<a href="../../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../../examples-rpc/05_read_storage/">
<a href="../../examples/05_read_storage/">
<a href="../../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../../examples-rpc/06_craft_extrinsic/">
<a href="../../examples/06_craft_extrinsic/">
<a href="../../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../../examples-rpc/07_transfer_dots/">
<a href="../../examples/07_transfer_dots/">
<a href="../../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -442,13 +448,13 @@ graph LR;
<p><strong>Rpc</strong></p>
<h1 id="implements">Implements</h1>
<ul>
<li><a href="../interfaces/_types_d_.rpcinterface.md">RpcInterface</a></li>
<li><code>RpcInterface</code></li>
</ul>
<h1 id="constructors">Constructors</h1>
<p><a id="constructor"></a></p>
<h2 id="constructor">constructor</h2>
<p>&#x2295; <strong>new Rpc</strong>(provider?: <em><code>ProviderInterface</code></em>): <a href="_index_.rpc.html">Rpc</a></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L47" target="_blank">index.ts:47</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L47" target="_blank">index.ts:47</a></em></p>
<p><em><strong>constructor</strong></em>: Default constructor for the Api Object</p>
<p><strong>Parameters:</strong></p>
<table>
@@ -475,37 +481,33 @@ graph LR;
<p><a id="_provider"></a></p>
<h2 id="provider">_provider</h2>
<p><strong>&#x25CF; _provider</strong>: <em><code>ProviderInterface</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L43" target="_blank">index.ts:43</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L43" target="_blank">index.ts:43</a></em></p>
<hr>
<p><a id="author"></a></p>
<h2 id="author">author</h2>
<p><strong>&#x25CF; author</strong>: <em><a href="../modules/_types_d_.md#rpcinterface_section">RpcInterface$Section</a></em></p>
<p><em>Implementation of <a href="../interfaces/_types_d_.rpcinterface.md">RpcInterface</a>.<a href="../interfaces/_types_d_.rpcinterface.md#author">author</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L44" target="_blank">index.ts:44</a></em></p>
<p><strong>&#x25CF; author</strong>: <em><code>RpcInterface$Section</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L44" target="_blank">index.ts:44</a></em></p>
<hr>
<p><a id="chain"></a></p>
<h2 id="chain">chain</h2>
<p><strong>&#x25CF; chain</strong>: <em><a href="../modules/_types_d_.md#rpcinterface_section">RpcInterface$Section</a></em></p>
<p><em>Implementation of <a href="../interfaces/_types_d_.rpcinterface.md">RpcInterface</a>.<a href="../interfaces/_types_d_.rpcinterface.md#chain">chain</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L45" target="_blank">index.ts:45</a></em></p>
<p><strong>&#x25CF; chain</strong>: <em><code>RpcInterface$Section</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L45" target="_blank">index.ts:45</a></em></p>
<hr>
<p><a id="state"></a></p>
<h2 id="state">state</h2>
<p><strong>&#x25CF; state</strong>: <em><a href="../modules/_types_d_.md#rpcinterface_section">RpcInterface$Section</a></em></p>
<p><em>Implementation of <a href="../interfaces/_types_d_.rpcinterface.md">RpcInterface</a>.<a href="../interfaces/_types_d_.rpcinterface.md#state">state</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L46" target="_blank">index.ts:46</a></em></p>
<p><strong>&#x25CF; state</strong>: <em><code>RpcInterface$Section</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L46" target="_blank">index.ts:46</a></em></p>
<hr>
<p><a id="system"></a></p>
<h2 id="system">system</h2>
<p><strong>&#x25CF; system</strong>: <em><a href="../modules/_types_d_.md#rpcinterface_section">RpcInterface$Section</a></em></p>
<p><em>Implementation of <a href="../interfaces/_types_d_.rpcinterface.md">RpcInterface</a>.<a href="../interfaces/_types_d_.rpcinterface.md#system">system</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L47" target="_blank">index.ts:47</a></em></p>
<p><strong>&#x25CF; system</strong>: <em><code>RpcInterface$Section</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L47" target="_blank">index.ts:47</a></em></p>
<hr>
<h1 id="methods">Methods</h1>
<p><a id="signature"></a></p>
<h2 id="static-signature"><code>&lt;Static&gt;</code> signature</h2>
<p>&#x25B8; <strong>signature</strong>(__namedParameters: <em><code>object</code></em>): <code>string</code></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L80" target="_blank">index.ts:80</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L80" target="_blank">index.ts:80</a></em></p>
<p><em><strong>name</strong></em>: signature</p>
<p><em><strong>summary</strong></em>: Returns a string representation of the method with inputs and outputs.</p>
<p><em><strong>description</strong></em>: Formats the name, inputs and outputs into a human-readable string. This contains the input parameter names input types and output type.</p>
@@ -574,7 +576,7 @@ graph LR;
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Rpc","level":"1.4.1","depth":2,"next":{"title":"rpc-rx","level":"1.5","depth":1,"path":"rpc-rx/README.md","ref":"rpc-rx/README.md","articles":[{"title":"RpcRx","level":"1.5.1","depth":2,"path":"rpc-rx/classes/_index_.rpcrx.md","ref":"rpc-rx/classes/_index_.rpcrx.md","articles":[]}]},"previous":{"title":"rpc-core","level":"1.4","depth":1,"path":"rpc-core/README.md","ref":"rpc-core/README.md","articles":[{"title":"Rpc","level":"1.4.1","depth":2,"path":"rpc-core/classes/_index_.rpc.md","ref":"rpc-core/classes/_index_.rpc.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-core/classes/_index_.rpc.md","mtime":"2018-10-11T11:42:33.522Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"Rpc","level":"1.4.1","depth":2,"next":{"title":"rpc-rx","level":"1.5","depth":1,"path":"rpc-rx/README.md","ref":"rpc-rx/README.md","articles":[{"title":"RpcRx","level":"1.5.1","depth":2,"path":"rpc-rx/classes/_index_.rpcrx.md","ref":"rpc-rx/classes/_index_.rpcrx.md","articles":[]}]},"previous":{"title":"rpc-core","level":"1.4","depth":1,"path":"rpc-core/README.md","ref":"rpc-core/README.md","articles":[{"title":"Rpc","level":"1.4.1","depth":2,"path":"rpc-core/classes/_index_.rpc.md","ref":"rpc-core/classes/_index_.rpc.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-core/classes/_index_.rpc.md","mtime":"2018-10-11T13:30:18.190Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
+12 -20
View File
@@ -27,7 +27,7 @@ const api = new Api(provider);
# Implements
* [RpcInterface](../interfaces/_types_d_.rpcinterface.md)
* `RpcInterface`
# Constructors
@@ -37,7 +37,7 @@ const api = new Api(provider);
⊕ **new Rpc**(provider?: *`ProviderInterface`*): [Rpc](_index_.rpc.md)
*Defined in [index.ts:47](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L47)*
*Defined in [index.ts:47](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L47)*
*__constructor__*: Default constructor for the Api Object
@@ -59,51 +59,43 @@ ___
**● _provider**: *`ProviderInterface`*
*Defined in [index.ts:43](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L43)*
*Defined in [index.ts:43](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L43)*
___
<a id="author"></a>
## author
**● author**: *[RpcInterface$Section](../modules/_types_d_.md#rpcinterface_section)*
**● author**: *`RpcInterface$Section`*
*Implementation of [RpcInterface](../interfaces/_types_d_.rpcinterface.md).[author](../interfaces/_types_d_.rpcinterface.md#author)*
*Defined in [index.ts:44](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L44)*
*Defined in [index.ts:44](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L44)*
___
<a id="chain"></a>
## chain
**● chain**: *[RpcInterface$Section](../modules/_types_d_.md#rpcinterface_section)*
**● chain**: *`RpcInterface$Section`*
*Implementation of [RpcInterface](../interfaces/_types_d_.rpcinterface.md).[chain](../interfaces/_types_d_.rpcinterface.md#chain)*
*Defined in [index.ts:45](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L45)*
*Defined in [index.ts:45](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L45)*
___
<a id="state"></a>
## state
**● state**: *[RpcInterface$Section](../modules/_types_d_.md#rpcinterface_section)*
**● state**: *`RpcInterface$Section`*
*Implementation of [RpcInterface](../interfaces/_types_d_.rpcinterface.md).[state](../interfaces/_types_d_.rpcinterface.md#state)*
*Defined in [index.ts:46](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L46)*
*Defined in [index.ts:46](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L46)*
___
<a id="system"></a>
## system
**● system**: *[RpcInterface$Section](../modules/_types_d_.md#rpcinterface_section)*
**● system**: *`RpcInterface$Section`*
*Implementation of [RpcInterface](../interfaces/_types_d_.rpcinterface.md).[system](../interfaces/_types_d_.rpcinterface.md#system)*
*Defined in [index.ts:47](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L47)*
*Defined in [index.ts:47](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L47)*
___
@@ -115,7 +107,7 @@ ___
▸ **signature**(__namedParameters: *`object`*): `string`
*Defined in [index.ts:80](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/index.ts#L80)*
*Defined in [index.ts:80](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-core/src/index.ts#L80)*
*__name__*: signature
+26 -21
View File
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../examples/">
<li class="chapter " data-level="2.1" data-path="../examples-rpc/">
<a href="../examples/">
<a href="../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../examples-rpc/01_simple_connect/">
<a href="../examples/01_simple_connect/">
<a href="../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../examples-rpc/02_listen_to_blocks/">
<a href="../examples/02_listen_to_blocks/">
<a href="../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../examples-rpc/03_listen_to_balance_change/">
<a href="../examples/03_listen_to_balance_change/">
<a href="../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../examples-rpc/04_generate_account/">
<a href="../examples/04_generate_account/">
<a href="../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../examples-rpc/05_read_storage/">
<a href="../examples/05_read_storage/">
<a href="../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../examples-rpc/06_craft_extrinsic/">
<a href="../examples/06_craft_extrinsic/">
<a href="../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../examples-rpc/07_transfer_dots/">
<a href="../examples/07_transfer_dots/">
<a href="../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -422,8 +428,7 @@
<section class="normal markdown-section">
<p><a href="https://polkadot.js.org" target="_blank"><img src="https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square" alt="polkadotjs"></a> <img src="https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square" alt="isc"> <a href="https://github.com/Flet/semistandard" target="_blank"><img src="https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square" alt="style"></a> <a href="https://www.npmjs.com/package/@polkadot/api" target="_blank"><img src="https://img.shields.io/npm/v/@polkadot/api.svg?style=flat-square" alt="npm"></a> <a href="https://travis-ci.org/polkadot-js/api" target="_blank"><img src="https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square" alt="travis"></a> <a href="https://codeclimate.com/github/polkadot-js/api/maintainability" target="_blank"><img src="https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square" alt="maintainability"></a> <a href="https://coveralls.io/github/polkadot-js/api?branch=master" target="_blank"><img src="https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square" alt="coverage"></a> <a href="https://david-dm.org/polkadot-js/api?path=package/rpc-core" target="_blank"><img src="https://david-dm.org/polkadot-js/api.svg?style=flat-square&amp;path=package/rpc-core" alt="dependency"></a> <a href="https://david-dm.org/polkadot-js/api?path=package/rpc-core#info=devDependencies" target="_blank"><img src="https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&amp;path=package/rpc-core" alt="devDependency"></a></p>
<h1 id="polkadotrpc-core">@polkadot/rpc-core</h1>
<h1 id="polkadotrpc-core">@polkadot/rpc-core</h1>
<p>This library provides a clean wrapper around all the methods exposed by a Polkadot network client.</p>
<h2 id="usage">Usage</h2>
<p>Installation -</p>
@@ -519,7 +524,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"rpc-core","level":"1.4","depth":1,"next":{"title":"Rpc","level":"1.4.1","depth":2,"path":"rpc-core/classes/_index_.rpc.md","ref":"rpc-core/classes/_index_.rpc.md","articles":[]},"previous":{"title":"WsProvider","level":"1.3.2","depth":2,"path":"rpc-provider/classes/_ws_index_.wsprovider.md","ref":"rpc-provider/classes/_ws_index_.wsprovider.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-core/README.md","mtime":"2018-10-11T11:42:33.374Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"rpc-core","level":"1.4","depth":1,"next":{"title":"Rpc","level":"1.4.1","depth":2,"path":"rpc-core/classes/_index_.rpc.md","ref":"rpc-core/classes/_index_.rpc.md","articles":[]},"previous":{"title":"WsProvider","level":"1.3.2","depth":2,"path":"rpc-provider/classes/_ws_index_.wsprovider.md","ref":"rpc-provider/classes/_ws_index_.wsprovider.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-core/README.md","mtime":"2018-10-11T13:30:18.050Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"..","book":{"language":""}});
});
</script>
</div>
@@ -1,49 +0,0 @@
# Hierarchy
**RpcInterface**
# Implemented by
* [Rpc](../classes/_index_.rpc.md)
# Properties
<a id="author"></a>
## author
**● author**: *[RpcInterface$Section](../modules/_types_d_.md#rpcinterface_section)*
*Defined in [types.d.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/types.d.ts#L19)*
___
<a id="chain"></a>
## chain
**● chain**: *[RpcInterface$Section](../modules/_types_d_.md#rpcinterface_section)*
*Defined in [types.d.ts:20](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/types.d.ts#L20)*
___
<a id="state"></a>
## state
**● state**: *[RpcInterface$Section](../modules/_types_d_.md#rpcinterface_section)*
*Defined in [types.d.ts:21](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/types.d.ts#L21)*
___
<a id="system"></a>
## system
**● system**: *[RpcInterface$Section](../modules/_types_d_.md#rpcinterface_section)*
*Defined in [types.d.ts:22](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/types.d.ts#L22)*
___
@@ -1,51 +0,0 @@
# Hierarchy
**RpcInterface$Section$Method**
# Callable
▸ **__call**(...params: *`Array`<`any`>*): `Promise`<`any`>
*Defined in [types.d.ts:7](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/types.d.ts#L7)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Rest` params | `Array`<`any`> |
**Returns:** `Promise`<`any`>
# Properties
<a id="subscription"></a>
## subscription
**● subscription**: *`string`*
*Defined in [types.d.ts:10](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/types.d.ts#L10)*
___
<a id="unsubscribe"></a>
## unsubscribe
**● unsubscribe**: *`function`*
*Defined in [types.d.ts:11](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/types.d.ts#L11)*
#### Type declaration
▸(id: *`number`*): `Promise`<`any`>
**Parameters:**
| Param | Type |
| ------ | ------ |
| id | `number` |
**Returns:** `Promise`<`any`>
___
-18
View File
@@ -1,18 +0,0 @@
# Type aliases
<a id="rpcinterface_section"></a>
## RpcInterface$Section
**Ƭ RpcInterface$Section**: *`object`*
*Defined in [types.d.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-core/src/types.d.ts#L14)*
#### Type declaration
[index: `string`]: [RpcInterface$Section$Method](../interfaces/_types_d_.rpcinterface_section_method.md)
___
-2
View File
@@ -1,6 +1,4 @@
[![polkadotjs](https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square)](https://polkadot.js.org) ![isc](https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square) [![style](https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square)](https://github.com/Flet/semistandard) [![npm](https://img.shields.io/npm/v/@polkadot/rpc-provider.svg?style=flat-square)](https://www.npmjs.com/package/@polkadot/rpc-provider) [![travis](https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square)](https://travis-ci.org/polkadot-js/api) [![maintainability](https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square)](https://codeclimate.com/github/polkadot-js/api/maintainability) [![coverage](https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square)](https://coveralls.io/github/polkadot-js/api?branch=master) [![dependency](https://david-dm.org/polkadot-js/api.svg?style=flat-square&path=packages/rpc-provider)](https://david-dm.org/polkadot-js/api?path=packages/rpc-provider) [![devDependency](https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&path=packages/rpc-provider)](https://david-dm.org/polkadot-js/api?path=packages/rpc-provider#info=devDependencies)
@polkadot/rpc-provider
======================
-5
View File
@@ -2,11 +2,9 @@
* [&quot;coder/json/encodeJson&quot;](modules/_coder_json_encodejson_.md)
* [&quot;coder/json/encodeObject&quot;](modules/_coder_json_encodeobject_.md)
* [&quot;coder/json/index&quot;](modules/_coder_json_index_.md)
* [&quot;coder/json/types.d&quot;](modules/_coder_json_types_d_.md)
* [&quot;http/index&quot;](modules/_http_index_.md)
* [HttpProvider](classes/_http_index_.httpprovider.md)
* [&quot;http/polyfill&quot;](modules/_http_polyfill_.md)
* [&quot;http/types.d&quot;](modules/_http_types_d_.md)
* [&quot;index&quot;](modules/_index_.md)
* [&quot;mock/index&quot;](modules/_mock_index_.md)
* [&quot;mock/mocks&quot;](modules/_mock_mocks_.md)
@@ -14,10 +12,7 @@
* [&quot;mock/send&quot;](modules/_mock_send_.md)
* [&quot;mock/state&quot;](modules/_mock_state_.md)
* [&quot;mock/subscribe&quot;](modules/_mock_subscribe_.md)
* [&quot;mock/types.d&quot;](modules/_mock_types_d_.md)
* [&quot;mock/unsubscribe&quot;](modules/_mock_unsubscribe_.md)
* [&quot;types.d&quot;](modules/_types_d_.md)
* [ProviderInterface](interfaces/_types_d_.providerinterface.md)
* [&quot;ws/index&quot;](modules/_ws_index_.md)
* [WsProvider](classes/_ws_index_.wsprovider.md)
* [&quot;ws/polyfill&quot;](modules/_ws_polyfill_.md)
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../../examples/">
<li class="chapter " data-level="2.1" data-path="../../examples-rpc/">
<a href="../../examples/">
<a href="../../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../../examples-rpc/01_simple_connect/">
<a href="../../examples/01_simple_connect/">
<a href="../../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../../examples-rpc/02_listen_to_blocks/">
<a href="../../examples/02_listen_to_blocks/">
<a href="../../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../../examples-rpc/03_listen_to_balance_change/">
<a href="../../examples/03_listen_to_balance_change/">
<a href="../../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../../examples-rpc/04_generate_account/">
<a href="../../examples/04_generate_account/">
<a href="../../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../../examples-rpc/05_read_storage/">
<a href="../../examples/05_read_storage/">
<a href="../../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../../examples-rpc/06_craft_extrinsic/">
<a href="../../examples/06_craft_extrinsic/">
<a href="../../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../../examples-rpc/07_transfer_dots/">
<a href="../../examples/07_transfer_dots/">
<a href="../../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -437,13 +443,13 @@
<p><strong>HttpProvider</strong></p>
<h1 id="implements">Implements</h1>
<ul>
<li><a href="../interfaces/_types_d_.providerinterface.md">ProviderInterface</a></li>
<li><code>ProviderInterface</code></li>
</ul>
<h1 id="constructors">Constructors</h1>
<p><a id="constructor"></a></p>
<h2 id="constructor">constructor</h2>
<p>&#x2295; <strong>new HttpProvider</strong>(endpoint: <em><code>string</code></em>): <a href="_http_index_.httpprovider.html">HttpProvider</a></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L40" target="_blank">http/index.ts:40</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L40" target="_blank">http/index.ts:40</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
@@ -467,17 +473,15 @@
<p><a id="isconnected"></a></p>
<h2 id="isconnected">isConnected</h2>
<p>&#x25B8; <strong>isConnected</strong>(): <code>boolean</code></p>
<p><em>Implementation of <a href="../interfaces/_types_d_.providerinterface.md">ProviderInterface</a>.<a href="../interfaces/_types_d_.providerinterface.md#isconnected">isConnected</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L57" target="_blank">http/index.ts:57</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L57" target="_blank">http/index.ts:57</a></em></p>
<p><em><strong>summary</strong></em>: Whether the node is connected or not.</p>
<p><strong>Returns:</strong> <code>boolean</code>
true if connected</p>
<hr>
<p><a id="on"></a></p>
<h2 id="on">on</h2>
<p>&#x25B8; <strong>on</strong>(type: <em><a href="../modules/_types_d_.md#providerinterface_emitted">ProviderInterface$Emitted</a></em>, sub: <em><a href="../modules/_types_d_.md#providerinterface_emitcb">ProviderInterface$EmitCb</a></em>): <code>void</code></p>
<p><em>Implementation of <a href="../interfaces/_types_d_.providerinterface.md">ProviderInterface</a>.<a href="../interfaces/_types_d_.providerinterface.md#on">on</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L65" target="_blank">http/index.ts:65</a></em></p>
<p>&#x25B8; <strong>on</strong>(type: <em><code>ProviderInterface$Emitted</code></em>, sub: <em><code>ProviderInterface$EmitCb</code></em>): <code>void</code></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L65" target="_blank">http/index.ts:65</a></em></p>
<p><em><strong>summary</strong></em>: Events are not supported with the HttpProvider, see <a href="_ws_index_.wsprovider.html">WsProvider</a>.</p>
<p><em><strong>description</strong></em>: HTTP Provider does not have &apos;on&apos; emitters. WebSockets should be used instead.</p>
<p><strong>Parameters:</strong></p>
@@ -491,11 +495,11 @@ true if connected</p>
<tbody>
<tr>
<td>type</td>
<td><a href="../modules/_types_d_.md#providerinterface_emitted">ProviderInterface$Emitted</a></td>
<td><code>ProviderInterface$Emitted</code></td>
</tr>
<tr>
<td>sub</td>
<td><a href="../modules/_types_d_.md#providerinterface_emitcb">ProviderInterface$EmitCb</a></td>
<td><code>ProviderInterface$EmitCb</code></td>
</tr>
</tbody>
</table>
@@ -504,8 +508,7 @@ true if connected</p>
<p><a id="send"></a></p>
<h2 id="send">send</h2>
<p>&#x25B8; <strong>send</strong>(method: <em><code>string</code></em>, params: <em><code>Array</code>&lt;<code>any</code>&gt;</em>): <code>Promise</code>&lt;<code>any</code>&gt;</p>
<p><em>Implementation of <a href="../interfaces/_types_d_.providerinterface.md">ProviderInterface</a>.<a href="../interfaces/_types_d_.providerinterface.md#send">send</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L72" target="_blank">http/index.ts:72</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L72" target="_blank">http/index.ts:72</a></em></p>
<p><em><strong>summary</strong></em>: Send HTTP POST Request with Body to configured HTTP Endpoint.</p>
<p><strong>Parameters:</strong></p>
<table>
@@ -530,9 +533,8 @@ true if connected</p>
<hr>
<p><a id="subscribe"></a></p>
<h2 id="subscribe">subscribe</h2>
<p>&#x25B8; <strong>subscribe</strong>(types: <em><code>string</code></em>, method: <em><code>string</code></em>, params: <em><code>Array</code>&lt;<code>any</code>&gt;</em>, cb: <em><a href="../modules/_types_d_.md#providerinterface_callback">ProviderInterface$Callback</a></em>): <code>Promise</code>&lt;<code>number</code>&gt;</p>
<p><em>Implementation of <a href="../interfaces/_types_d_.providerinterface.md">ProviderInterface</a>.<a href="../interfaces/_types_d_.providerinterface.md#subscribe">subscribe</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L94" target="_blank">http/index.ts:94</a></em></p>
<p>&#x25B8; <strong>subscribe</strong>(types: <em><code>string</code></em>, method: <em><code>string</code></em>, params: <em><code>Array</code>&lt;<code>any</code>&gt;</em>, cb: <em><code>ProviderInterface$Callback</code></em>): <code>Promise</code>&lt;<code>number</code>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L94" target="_blank">http/index.ts:94</a></em></p>
<p><em><strong>summary</strong></em>: Subscriptions are not supported with the HttpProvider, see <a href="_ws_index_.wsprovider.html">WsProvider</a>.</p>
<p><strong>Parameters:</strong></p>
<table>
@@ -557,7 +559,7 @@ true if connected</p>
</tr>
<tr>
<td>cb</td>
<td><a href="../modules/_types_d_.md#providerinterface_callback">ProviderInterface$Callback</a></td>
<td><code>ProviderInterface$Callback</code></td>
</tr>
</tbody>
</table>
@@ -566,8 +568,7 @@ true if connected</p>
<p><a id="unsubscribe"></a></p>
<h2 id="unsubscribe">unsubscribe</h2>
<p>&#x25B8; <strong>unsubscribe</strong>(type: <em><code>string</code></em>, method: <em><code>string</code></em>, id: <em><code>number</code></em>): <code>Promise</code>&lt;<code>boolean</code>&gt;</p>
<p><em>Implementation of <a href="../interfaces/_types_d_.providerinterface.md">ProviderInterface</a>.<a href="../interfaces/_types_d_.providerinterface.md#unsubscribe">unsubscribe</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L103" target="_blank">http/index.ts:103</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L103" target="_blank">http/index.ts:103</a></em></p>
<p><em><strong>summary</strong></em>: Subscriptions are not supported with the HttpProvider, see <a href="_ws_index_.wsprovider.html">WsProvider</a>.</p>
<p><strong>Parameters:</strong></p>
<table>
@@ -637,7 +638,7 @@ true if connected</p>
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"HttpProvider","level":"1.3.1","depth":2,"next":{"title":"WsProvider","level":"1.3.2","depth":2,"path":"rpc-provider/classes/_ws_index_.wsprovider.md","ref":"rpc-provider/classes/_ws_index_.wsprovider.md","articles":[]},"previous":{"title":"rpc-provider","level":"1.3","depth":1,"path":"rpc-provider/README.md","ref":"rpc-provider/README.md","articles":[{"title":"HttpProvider","level":"1.3.1","depth":2,"path":"rpc-provider/classes/_http_index_.httpprovider.md","ref":"rpc-provider/classes/_http_index_.httpprovider.md","articles":[]},{"title":"WsProvider","level":"1.3.2","depth":2,"path":"rpc-provider/classes/_ws_index_.wsprovider.md","ref":"rpc-provider/classes/_ws_index_.wsprovider.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-provider/classes/_http_index_.httpprovider.md","mtime":"2018-10-11T11:42:41.326Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"HttpProvider","level":"1.3.1","depth":2,"next":{"title":"WsProvider","level":"1.3.2","depth":2,"path":"rpc-provider/classes/_ws_index_.wsprovider.md","ref":"rpc-provider/classes/_ws_index_.wsprovider.md","articles":[]},"previous":{"title":"rpc-provider","level":"1.3","depth":1,"path":"rpc-provider/README.md","ref":"rpc-provider/README.md","articles":[{"title":"HttpProvider","level":"1.3.1","depth":2,"path":"rpc-provider/classes/_http_index_.httpprovider.md","ref":"rpc-provider/classes/_http_index_.httpprovider.md","articles":[]},{"title":"WsProvider","level":"1.3.2","depth":2,"path":"rpc-provider/classes/_ws_index_.wsprovider.md","ref":"rpc-provider/classes/_ws_index_.wsprovider.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-provider/classes/_http_index_.httpprovider.md","mtime":"2018-10-11T13:30:26.643Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
@@ -23,7 +23,7 @@ const api = new Rpc(provider);
# Implements
* [ProviderInterface](../interfaces/_types_d_.providerinterface.md)
* `ProviderInterface`
# Constructors
@@ -33,7 +33,7 @@ const api = new Rpc(provider);
⊕ **new HttpProvider**(endpoint: *`string`*): [HttpProvider](_http_index_.httpprovider.md)
*Defined in [http/index.ts:40](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L40)*
*Defined in [http/index.ts:40](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L40)*
**Parameters:**
@@ -53,9 +53,7 @@ ___
▸ **isConnected**(): `boolean`
*Implementation of [ProviderInterface](../interfaces/_types_d_.providerinterface.md).[isConnected](../interfaces/_types_d_.providerinterface.md#isconnected)*
*Defined in [http/index.ts:57](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L57)*
*Defined in [http/index.ts:57](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L57)*
*__summary__*: Whether the node is connected or not.
@@ -67,11 +65,9 @@ ___
## on
▸ **on**(type: *[ProviderInterface$Emitted](../modules/_types_d_.md#providerinterface_emitted)*, sub: *[ProviderInterface$EmitCb](../modules/_types_d_.md#providerinterface_emitcb)*): `void`
▸ **on**(type: *`ProviderInterface$Emitted`*, sub: *`ProviderInterface$EmitCb`*): `void`
*Implementation of [ProviderInterface](../interfaces/_types_d_.providerinterface.md).[on](../interfaces/_types_d_.providerinterface.md#on)*
*Defined in [http/index.ts:65](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L65)*
*Defined in [http/index.ts:65](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L65)*
*__summary__*: Events are not supported with the HttpProvider, see [WsProvider](_ws_index_.wsprovider.md).
@@ -81,8 +77,8 @@ ___
| Param | Type |
| ------ | ------ |
| type | [ProviderInterface$Emitted](../modules/_types_d_.md#providerinterface_emitted) |
| sub | [ProviderInterface$EmitCb](../modules/_types_d_.md#providerinterface_emitcb) |
| type | `ProviderInterface$Emitted` |
| sub | `ProviderInterface$EmitCb` |
**Returns:** `void`
@@ -93,9 +89,7 @@ ___
▸ **send**(method: *`string`*, params: *`Array`<`any`>*): `Promise`<`any`>
*Implementation of [ProviderInterface](../interfaces/_types_d_.providerinterface.md).[send](../interfaces/_types_d_.providerinterface.md#send)*
*Defined in [http/index.ts:72](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L72)*
*Defined in [http/index.ts:72](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L72)*
*__summary__*: Send HTTP POST Request with Body to configured HTTP Endpoint.
@@ -113,11 +107,9 @@ ___
## subscribe
▸ **subscribe**(types: *`string`*, method: *`string`*, params: *`Array`<`any`>*, cb: *[ProviderInterface$Callback](../modules/_types_d_.md#providerinterface_callback)*): `Promise`<`number`>
▸ **subscribe**(types: *`string`*, method: *`string`*, params: *`Array`<`any`>*, cb: *`ProviderInterface$Callback`*): `Promise`<`number`>
*Implementation of [ProviderInterface](../interfaces/_types_d_.providerinterface.md).[subscribe](../interfaces/_types_d_.providerinterface.md#subscribe)*
*Defined in [http/index.ts:94](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L94)*
*Defined in [http/index.ts:94](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L94)*
*__summary__*: Subscriptions are not supported with the HttpProvider, see [WsProvider](_ws_index_.wsprovider.md).
@@ -128,7 +120,7 @@ ___
| types | `string` |
| method | `string` |
| params | `Array`<`any`> |
| cb | [ProviderInterface$Callback](../modules/_types_d_.md#providerinterface_callback) |
| cb | `ProviderInterface$Callback` |
**Returns:** `Promise`<`number`>
@@ -139,9 +131,7 @@ ___
▸ **unsubscribe**(type: *`string`*, method: *`string`*, id: *`number`*): `Promise`<`boolean`>
*Implementation of [ProviderInterface](../interfaces/_types_d_.providerinterface.md).[unsubscribe](../interfaces/_types_d_.providerinterface.md#unsubscribe)*
*Defined in [http/index.ts:103](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/index.ts#L103)*
*Defined in [http/index.ts:103](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/http/index.ts#L103)*
*__summary__*: Subscriptions are not supported with the HttpProvider, see [WsProvider](_ws_index_.wsprovider.md).
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../../examples/">
<li class="chapter " data-level="2.1" data-path="../../examples-rpc/">
<a href="../../examples/">
<a href="../../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../../examples-rpc/01_simple_connect/">
<a href="../../examples/01_simple_connect/">
<a href="../../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../../examples-rpc/02_listen_to_blocks/">
<a href="../../examples/02_listen_to_blocks/">
<a href="../../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../../examples-rpc/03_listen_to_balance_change/">
<a href="../../examples/03_listen_to_balance_change/">
<a href="../../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../../examples-rpc/04_generate_account/">
<a href="../../examples/04_generate_account/">
<a href="../../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../../examples-rpc/05_read_storage/">
<a href="../../examples/05_read_storage/">
<a href="../../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../../examples-rpc/06_craft_extrinsic/">
<a href="../../examples/06_craft_extrinsic/">
<a href="../../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../../examples-rpc/07_transfer_dots/">
<a href="../../examples/07_transfer_dots/">
<a href="../../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -446,7 +452,7 @@
<p><a id="constructor"></a></p>
<h2 id="constructor">constructor</h2>
<p>&#x2295; <strong>new WsProvider</strong>(endpoint: <em><code>string</code></em>, autoConnect?: <em><code>boolean</code></em>): <a href="_ws_index_.wsprovider.html">WsProvider</a></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L73" target="_blank">ws/index.ts:73</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L73" target="_blank">ws/index.ts:73</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
@@ -516,7 +522,7 @@
<p><a id="connect"></a></p>
<h2 id="connect">connect</h2>
<p>&#x25B8; <strong>connect</strong>(): <code>void</code></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L104" target="_blank">ws/index.ts:104</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L104" target="_blank">ws/index.ts:104</a></em></p>
<p><em><strong>summary</strong></em>: Manually connect</p>
<p><em><strong>description</strong></em>: The <a href="_ws_index_.wsprovider.html">WsProvider</a> connects automatically by default, however if you decided otherwise, you may connect manually using this method.</p>
<p><strong>Returns:</strong> <code>void</code></p>
@@ -559,7 +565,7 @@
<p><a id="isconnected"></a></p>
<h2 id="isconnected">isConnected</h2>
<p>&#x25B8; <strong>isConnected</strong>(): <code>boolean</code></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L121" target="_blank">ws/index.ts:121</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L121" target="_blank">ws/index.ts:121</a></em></p>
<p><em><strong>summary</strong></em>: Whether the node is connected or not.</p>
<p><strong>Returns:</strong> <code>boolean</code>
true if connected</p>
@@ -646,9 +652,9 @@ true if connected</p>
<hr>
<p><a id="on"></a></p>
<h2 id="on">on</h2>
<p>&#x25B8; <strong>on</strong>(type: <em><a href="../modules/_types_d_.md#providerinterface_emitted">ProviderInterface$Emitted</a></em>, sub: <em><a href="../modules/_types_d_.md#providerinterface_emitcb">ProviderInterface$EmitCb</a></em>): <code>this</code></p>
<p>&#x25B8; <strong>on</strong>(type: <em><code>ProviderInterface$Emitted</code></em>, sub: <em><code>ProviderInterface$EmitCb</code></em>): <code>this</code></p>
<p><em>Overrides EventEmitter.on</em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L131" target="_blank">ws/index.ts:131</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L131" target="_blank">ws/index.ts:131</a></em></p>
<p><em><strong>summary</strong></em>: Listens on events after having subscribed using the <a href="_ws_index_.wsprovider.html#subscribe">subscribe</a> function.</p>
<p><strong>Parameters:</strong></p>
<table>
@@ -662,12 +668,12 @@ true if connected</p>
<tbody>
<tr>
<td>type</td>
<td><a href="../modules/_types_d_.md#providerinterface_emitted">ProviderInterface$Emitted</a></td>
<td><code>ProviderInterface$Emitted</code></td>
<td>Event</td>
</tr>
<tr>
<td>sub</td>
<td><a href="../modules/_types_d_.md#providerinterface_emitcb">ProviderInterface$EmitCb</a></td>
<td><code>ProviderInterface$EmitCb</code></td>
<td>Callback</td>
</tr>
</tbody>
@@ -767,7 +773,7 @@ true if connected</p>
<p><a id="send"></a></p>
<h2 id="send">send</h2>
<p>&#x25B8; <strong>send</strong>(method: <em><code>string</code></em>, params: <em><code>Array</code>&lt;<code>any</code>&gt;</em>, subscription?: <em><code>SubscriptionHandler</code></em>): <code>Promise</code>&lt;<code>any</code>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L138" target="_blank">ws/index.ts:138</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L138" target="_blank">ws/index.ts:138</a></em></p>
<p><em><strong>summary</strong></em>: Send JSON data using WebSockets to configured HTTP Endpoint or queue.</p>
<p><strong>Parameters:</strong></p>
<table>
@@ -796,8 +802,8 @@ true if connected</p>
<hr>
<p><a id="subscribe"></a></p>
<h2 id="subscribe">subscribe</h2>
<p>&#x25B8; <strong>subscribe</strong>(type: <em><code>string</code></em>, method: <em><code>string</code></em>, params: <em><code>Array</code>&lt;<code>any</code>&gt;</em>, callback: <em><a href="../modules/_types_d_.md#providerinterface_callback">ProviderInterface$Callback</a></em>): <code>Promise</code>&lt;<code>number</code>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L194" target="_blank">ws/index.ts:194</a></em></p>
<p>&#x25B8; <strong>subscribe</strong>(type: <em><code>string</code></em>, method: <em><code>string</code></em>, params: <em><code>Array</code>&lt;<code>any</code>&gt;</em>, callback: <em><code>ProviderInterface$Callback</code></em>): <code>Promise</code>&lt;<code>number</code>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L194" target="_blank">ws/index.ts:194</a></em></p>
<p><em><strong>name</strong></em>: subscribe</p>
<p><em><strong>summary</strong></em>: Allows subscribing to a specific event.</p>
<p><em><strong>example</strong></em>: </p>
@@ -837,7 +843,7 @@ true if connected</p>
</tr>
<tr>
<td>callback</td>
<td><a href="../modules/_types_d_.md#providerinterface_callback">ProviderInterface$Callback</a></td>
<td><code>ProviderInterface$Callback</code></td>
<td>Callback</td>
</tr>
</tbody>
@@ -848,7 +854,7 @@ Promise resolving to the dd of the subscription you can use with [[unsubscribe]]
<p><a id="unsubscribe"></a></p>
<h2 id="unsubscribe">unsubscribe</h2>
<p>&#x25B8; <strong>unsubscribe</strong>(type: <em><code>string</code></em>, method: <em><code>string</code></em>, id: <em><code>number</code></em>): <code>Promise</code>&lt;<code>boolean</code>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L203" target="_blank">ws/index.ts:203</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L203" target="_blank">ws/index.ts:203</a></em></p>
<p><em><strong>summary</strong></em>: Allows unsubscribing to subscriptions made with <a href="_ws_index_.wsprovider.html#subscribe">subscribe</a>.</p>
<p><strong>Parameters:</strong></p>
<table>
@@ -918,7 +924,7 @@ Promise resolving to the dd of the subscription you can use with [[unsubscribe]]
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"WsProvider","level":"1.3.2","depth":2,"next":{"title":"rpc-core","level":"1.4","depth":1,"path":"rpc-core/README.md","ref":"rpc-core/README.md","articles":[{"title":"Rpc","level":"1.4.1","depth":2,"path":"rpc-core/classes/_index_.rpc.md","ref":"rpc-core/classes/_index_.rpc.md","articles":[]}]},"previous":{"title":"HttpProvider","level":"1.3.1","depth":2,"path":"rpc-provider/classes/_http_index_.httpprovider.md","ref":"rpc-provider/classes/_http_index_.httpprovider.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-provider/classes/_ws_index_.wsprovider.md","mtime":"2018-10-11T11:42:41.422Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"WsProvider","level":"1.3.2","depth":2,"next":{"title":"rpc-core","level":"1.4","depth":1,"path":"rpc-core/README.md","ref":"rpc-core/README.md","articles":[{"title":"Rpc","level":"1.4.1","depth":2,"path":"rpc-core/classes/_index_.rpc.md","ref":"rpc-core/classes/_index_.rpc.md","articles":[]}]},"previous":{"title":"HttpProvider","level":"1.3.1","depth":2,"path":"rpc-provider/classes/_http_index_.httpprovider.md","ref":"rpc-provider/classes/_http_index_.httpprovider.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-provider/classes/_ws_index_.wsprovider.md","mtime":"2018-10-11T13:30:26.759Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
@@ -38,7 +38,7 @@ const api = new Rpc(provider);
⊕ **new WsProvider**(endpoint: *`string`*, autoConnect?: *`boolean`*): [WsProvider](_ws_index_.wsprovider.md)
*Defined in [ws/index.ts:73](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L73)*
*Defined in [ws/index.ts:73](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L73)*
**Parameters:**
@@ -95,7 +95,7 @@ ___
▸ **connect**(): `void`
*Defined in [ws/index.ts:104](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L104)*
*Defined in [ws/index.ts:104](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L104)*
*__summary__*: Manually connect
@@ -147,7 +147,7 @@ ___
▸ **isConnected**(): `boolean`
*Defined in [ws/index.ts:121](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L121)*
*Defined in [ws/index.ts:121](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L121)*
*__summary__*: Whether the node is connected or not.
@@ -223,11 +223,11 @@ ___
## on
▸ **on**(type: *[ProviderInterface$Emitted](../modules/_types_d_.md#providerinterface_emitted)*, sub: *[ProviderInterface$EmitCb](../modules/_types_d_.md#providerinterface_emitcb)*): `this`
▸ **on**(type: *`ProviderInterface$Emitted`*, sub: *`ProviderInterface$EmitCb`*): `this`
*Overrides EventEmitter.on*
*Defined in [ws/index.ts:131](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L131)*
*Defined in [ws/index.ts:131](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L131)*
*__summary__*: Listens on events after having subscribed using the [subscribe](_ws_index_.wsprovider.md#subscribe) function.
@@ -235,8 +235,8 @@ ___
| Param | Type | Description |
| ------ | ------ | ------ |
| type | [ProviderInterface$Emitted](../modules/_types_d_.md#providerinterface_emitted) | Event |
| sub | [ProviderInterface$EmitCb](../modules/_types_d_.md#providerinterface_emitcb) | Callback |
| type | `ProviderInterface$Emitted` | Event |
| sub | `ProviderInterface$EmitCb` | Callback |
**Returns:** `this`
[description]
@@ -316,7 +316,7 @@ ___
▸ **send**(method: *`string`*, params: *`Array`<`any`>*, subscription?: *`SubscriptionHandler`*): `Promise`<`any`>
*Defined in [ws/index.ts:138](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L138)*
*Defined in [ws/index.ts:138](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L138)*
*__summary__*: Send JSON data using WebSockets to configured HTTP Endpoint or queue.
@@ -335,9 +335,9 @@ ___
## subscribe
▸ **subscribe**(type: *`string`*, method: *`string`*, params: *`Array`<`any`>*, callback: *[ProviderInterface$Callback](../modules/_types_d_.md#providerinterface_callback)*): `Promise`<`number`>
▸ **subscribe**(type: *`string`*, method: *`string`*, params: *`Array`<`any`>*, callback: *`ProviderInterface$Callback`*): `Promise`<`number`>
*Defined in [ws/index.ts:194](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L194)*
*Defined in [ws/index.ts:194](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L194)*
*__name__*: subscribe
@@ -362,7 +362,7 @@ api.state.storage([[storage.balances.freeBalance, <Address>]], (_, values) => {
| type | `string` | Subscription type |
| method | `string` | Subscription method |
| params | `Array`<`any`> | Parameters |
| callback | [ProviderInterface$Callback](../modules/_types_d_.md#providerinterface_callback) | Callback |
| callback | `ProviderInterface$Callback` | Callback |
**Returns:** `Promise`<`number`>
Promise resolving to the dd of the subscription you can use with [[unsubscribe]].
@@ -374,7 +374,7 @@ ___
▸ **unsubscribe**(type: *`string`*, method: *`string`*, id: *`number`*): `Promise`<`boolean`>
*Defined in [ws/index.ts:203](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/ws/index.ts#L203)*
*Defined in [ws/index.ts:203](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/ws/index.ts#L203)*
*__summary__*: Allows unsubscribing to subscriptions made with [subscribe](_ws_index_.wsprovider.md#subscribe).
+26 -21
View File
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../examples/">
<li class="chapter " data-level="2.1" data-path="../examples-rpc/">
<a href="../examples/">
<a href="../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../examples-rpc/01_simple_connect/">
<a href="../examples/01_simple_connect/">
<a href="../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../examples-rpc/02_listen_to_blocks/">
<a href="../examples/02_listen_to_blocks/">
<a href="../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../examples-rpc/03_listen_to_balance_change/">
<a href="../examples/03_listen_to_balance_change/">
<a href="../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../examples-rpc/04_generate_account/">
<a href="../examples/04_generate_account/">
<a href="../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../examples-rpc/05_read_storage/">
<a href="../examples/05_read_storage/">
<a href="../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../examples-rpc/06_craft_extrinsic/">
<a href="../examples/06_craft_extrinsic/">
<a href="../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../examples-rpc/07_transfer_dots/">
<a href="../examples/07_transfer_dots/">
<a href="../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -422,8 +428,7 @@
<section class="normal markdown-section">
<p><a href="https://polkadot.js.org" target="_blank"><img src="https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square" alt="polkadotjs"></a> <img src="https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square" alt="isc"> <a href="https://github.com/Flet/semistandard" target="_blank"><img src="https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square" alt="style"></a> <a href="https://www.npmjs.com/package/@polkadot/rpc-provider" target="_blank"><img src="https://img.shields.io/npm/v/@polkadot/rpc-provider.svg?style=flat-square" alt="npm"></a> <a href="https://travis-ci.org/polkadot-js/api" target="_blank"><img src="https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square" alt="travis"></a> <a href="https://codeclimate.com/github/polkadot-js/api/maintainability" target="_blank"><img src="https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square" alt="maintainability"></a> <a href="https://coveralls.io/github/polkadot-js/api?branch=master" target="_blank"><img src="https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square" alt="coverage"></a> <a href="https://david-dm.org/polkadot-js/api?path=packages/rpc-provider" target="_blank"><img src="https://david-dm.org/polkadot-js/api.svg?style=flat-square&amp;path=packages/rpc-provider" alt="dependency"></a> <a href="https://david-dm.org/polkadot-js/api?path=packages/rpc-provider#info=devDependencies" target="_blank"><img src="https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&amp;path=packages/rpc-provider" alt="devDependency"></a></p>
<h1 id="polkadotrpc-provider">@polkadot/rpc-provider</h1>
<h1 id="polkadotrpc-provider">@polkadot/rpc-provider</h1>
<p>Generic transport providers to handle the transport of method calls to and from Polkadot clients from applications interacting with it. Generally, unless you are operating at a low-level and taking care of encoding and decoding of parameters/results, it won&apos;t be directly used. API interfaces building on top these providers can support various transports with the same underlying interfaces.</p>
<h2 id="usage">Usage</h2>
<p>Installation -</p>
@@ -479,7 +484,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"rpc-provider","level":"1.3","depth":1,"next":{"title":"HttpProvider","level":"1.3.1","depth":2,"path":"rpc-provider/classes/_http_index_.httpprovider.md","ref":"rpc-provider/classes/_http_index_.httpprovider.md","articles":[]},"previous":{"title":"ApiRx","level":"1.2.2","depth":2,"path":"api/classes/_rx_index_.apirx.md","ref":"api/classes/_rx_index_.apirx.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-provider/README.md","mtime":"2018-10-11T11:42:41.170Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"rpc-provider","level":"1.3","depth":1,"next":{"title":"HttpProvider","level":"1.3.1","depth":2,"path":"rpc-provider/classes/_http_index_.httpprovider.md","ref":"rpc-provider/classes/_http_index_.httpprovider.md","articles":[]},"previous":{"title":"ApiRx","level":"1.2.2","depth":2,"path":"api/classes/_rx_index_.apirx.md","ref":"api/classes/_rx_index_.apirx.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-provider/README.md","mtime":"2018-10-11T13:30:26.487Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"..","book":{"language":""}});
});
</script>
</div>
@@ -1,99 +0,0 @@
# Hierarchy
**ProviderInterface**
# Implemented by
* [HttpProvider](../classes/_http_index_.httpprovider.md)
# Methods
<a id="isconnected"></a>
## isConnected
▸ **isConnected**(): `boolean`
*Defined in [types.d.ts:45](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L45)*
**Returns:** `boolean`
___
<a id="on"></a>
## on
▸ **on**(type: *[ProviderInterface$Emitted](../modules/_types_d_.md#providerinterface_emitted)*, sub: *[ProviderInterface$EmitCb](../modules/_types_d_.md#providerinterface_emitcb)*): `void`
*Defined in [types.d.ts:46](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L46)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| type | [ProviderInterface$Emitted](../modules/_types_d_.md#providerinterface_emitted) |
| sub | [ProviderInterface$EmitCb](../modules/_types_d_.md#providerinterface_emitcb) |
**Returns:** `void`
___
<a id="send"></a>
## send
▸ **send**(method: *`string`*, params: *`Array`<`any`>*): `Promise`<`any`>
*Defined in [types.d.ts:47](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L47)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| method | `string` |
| params | `Array`<`any`> |
**Returns:** `Promise`<`any`>
___
<a id="subscribe"></a>
## subscribe
▸ **subscribe**(type: *`string`*, method: *`string`*, params: *`Array`<`any`>*, cb: *[ProviderInterface$Callback](../modules/_types_d_.md#providerinterface_callback)*): `Promise`<`number`>
*Defined in [types.d.ts:48](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L48)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| type | `string` |
| method | `string` |
| params | `Array`<`any`> |
| cb | [ProviderInterface$Callback](../modules/_types_d_.md#providerinterface_callback) |
**Returns:** `Promise`<`number`>
___
<a id="unsubscribe"></a>
## unsubscribe
▸ **unsubscribe**(type: *`string`*, method: *`string`*, id: *`number`*): `Promise`<`boolean`>
*Defined in [types.d.ts:49](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L49)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| type | `string` |
| method | `string` |
| id | `number` |
**Returns:** `Promise`<`boolean`>
___
@@ -6,16 +6,16 @@
## decodeResponse
▸ **decodeResponse**(self: *[RpcCoderState](_coder_json_types_d_.md#rpccoderstate)*, response: *[JsonRpcResponse](_types_d_.md#jsonrpcresponse)*): `any`
▸ **decodeResponse**(self: *`RpcCoderState`*, response: *`JsonRpcResponse`*): `any`
*Defined in [coder/json/decodeResponse.ts:22](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/coder/json/decodeResponse.ts#L22)*
*Defined in [coder/json/decodeResponse.ts:22](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/coder/json/decodeResponse.ts#L22)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| self | [RpcCoderState](_coder_json_types_d_.md#rpccoderstate) |
| response | [JsonRpcResponse](_types_d_.md#jsonrpcresponse) |
| self | `RpcCoderState` |
| response | `JsonRpcResponse` |
**Returns:** `any`
@@ -6,15 +6,15 @@
## encodeJson
▸ **encodeJson**(self: *[RpcCoderState](_coder_json_types_d_.md#rpccoderstate)*, method: *`string`*, params: *`Array`<`any`>*): `string`
▸ **encodeJson**(self: *`RpcCoderState`*, method: *`string`*, params: *`Array`<`any`>*): `string`
*Defined in [coder/json/encodeJson.ts:9](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/coder/json/encodeJson.ts#L9)*
*Defined in [coder/json/encodeJson.ts:9](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/coder/json/encodeJson.ts#L9)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| self | [RpcCoderState](_coder_json_types_d_.md#rpccoderstate) |
| self | `RpcCoderState` |
| method | `string` |
| params | `Array`<`any`> |
@@ -6,19 +6,19 @@
## encodeObject
▸ **encodeObject**(self: *[RpcCoderState](_coder_json_types_d_.md#rpccoderstate)*, method: *`string`*, params: *`Array`<`any`>*): [JsonRpcRequest](_types_d_.md#jsonrpcrequest)
▸ **encodeObject**(self: *`RpcCoderState`*, method: *`string`*, params: *`Array`<`any`>*): `JsonRpcRequest`
*Defined in [coder/json/encodeObject.ts:8](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/coder/json/encodeObject.ts#L8)*
*Defined in [coder/json/encodeObject.ts:8](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/coder/json/encodeObject.ts#L8)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| self | [RpcCoderState](_coder_json_types_d_.md#rpccoderstate) |
| self | `RpcCoderState` |
| method | `string` |
| params | `Array`<`any`> |
**Returns:** [JsonRpcRequest](_types_d_.md#jsonrpcrequest)
**Returns:** `JsonRpcRequest`
___
@@ -6,11 +6,11 @@
## rpcCoder
▸ **rpcCoder**(): [RpcCoder](_coder_json_types_d_.md#rpccoder)
▸ **rpcCoder**(): `RpcCoder`
*Defined in [coder/json/index.ts:12](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/coder/json/index.ts#L12)*
*Defined in [coder/json/index.ts:12](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/coder/json/index.ts#L12)*
**Returns:** [RpcCoder](_coder_json_types_d_.md#rpccoder)
**Returns:** `RpcCoder`
___
@@ -1,27 +0,0 @@
# Type aliases
<a id="rpccoder"></a>
## RpcCoder
**Ƭ RpcCoder**: *`object`*
*Defined in [coder/json/types.d.ts:7](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/coder/json/types.d.ts#L7)*
#### Type declaration
___
<a id="rpccoderstate"></a>
## RpcCoderState
**Ƭ RpcCoderState**: *`object`*
*Defined in [coder/json/types.d.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/coder/json/types.d.ts#L14)*
#### Type declaration
___
@@ -1,16 +0,0 @@
# Type aliases
<a id="httpstate"></a>
## HttpState
**Ƭ HttpState**: *`object`*
*Defined in [http/types.d.ts:8](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/http/types.d.ts#L8)*
#### Type declaration
___
+3 -3
View File
@@ -6,13 +6,13 @@
## mockProvider
▸ **mockProvider**(): [ProviderInterface](../interfaces/_types_d_.providerinterface.md)
▸ **mockProvider**(): `ProviderInterface`
*Defined in [mock/index.ts:18](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/index.ts#L18)*
*Defined in [mock/index.ts:18](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/mock/index.ts#L18)*
A mock provider mainly used for testing.
**Returns:** [ProviderInterface](../interfaces/_types_d_.providerinterface.md)
**Returns:** `ProviderInterface`
The mock provider
___
+1 -1
View File
@@ -8,7 +8,7 @@
▸ **mocks**(__namedParameters: *`object`*): `void`
*Defined in [mock/mocks.ts:63](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/mocks.ts#L63)*
*Defined in [mock/mocks.ts:63](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/mock/mocks.ts#L63)*
**Parameters:**
+5 -5
View File
@@ -6,17 +6,17 @@
## on
▸ **on**(self: *[MockState](_mock_types_d_.md#mockstate)*, type: *[ProviderInterface$Emitted](_types_d_.md#providerinterface_emitted)*, sub: *[ProviderInterface$EmitCb](_types_d_.md#providerinterface_emitcb)*): `void`
▸ **on**(self: *`MockState`*, type: *`ProviderInterface$Emitted`*, sub: *`ProviderInterface$EmitCb`*): `void`
*Defined in [mock/on.ts:8](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/on.ts#L8)*
*Defined in [mock/on.ts:8](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/mock/on.ts#L8)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| self | [MockState](_mock_types_d_.md#mockstate) |
| type | [ProviderInterface$Emitted](_types_d_.md#providerinterface_emitted) |
| sub | [ProviderInterface$EmitCb](_types_d_.md#providerinterface_emitcb) |
| self | `MockState` |
| type | `ProviderInterface$Emitted` |
| sub | `ProviderInterface$EmitCb` |
**Returns:** `void`
+1 -1
View File
@@ -8,7 +8,7 @@
▸ **send**(__namedParameters: *`object`*, method: *`string`*, params: *`Array`<`any`>*): `Promise`<`any`>
*Defined in [mock/send.ts:7](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/send.ts#L7)*
*Defined in [mock/send.ts:7](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/mock/send.ts#L7)*
**Parameters:**
+3 -3
View File
@@ -6,11 +6,11 @@
## state
▸ **state**(): [MockState](_mock_types_d_.md#mockstate)
▸ **state**(): `MockState`
*Defined in [mock/state.ts:38](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/state.ts#L38)*
*Defined in [mock/state.ts:38](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/mock/state.ts#L38)*
**Returns:** [MockState](_mock_types_d_.md#mockstate)
**Returns:** `MockState`
___
@@ -6,15 +6,15 @@
## subscribe
▸ **subscribe**(self: *[MockState](_mock_types_d_.md#mockstate)*, type: *`string`*, method: *`string`*, params: *`Array`<`any`>*): `Promise`<`number`>
▸ **subscribe**(self: *`MockState`*, type: *`string`*, method: *`string`*, params: *`Array`<`any`>*): `Promise`<`number`>
*Defined in [mock/subscribe.ts:7](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/subscribe.ts#L7)*
*Defined in [mock/subscribe.ts:7](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/mock/subscribe.ts#L7)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| self | [MockState](_mock_types_d_.md#mockstate) |
| self | `MockState` |
| type | `string` |
| method | `string` |
| params | `Array`<`any`> |
@@ -1,87 +0,0 @@
# Type aliases
<a id="mockstate"></a>
## MockState
**Ƭ MockState**: *`object`*
*Defined in [mock/types.d.ts:27](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/types.d.ts#L27)*
#### Type declaration
___
<a id="mockstate_db"></a>
## MockState$Db
**Ƭ MockState$Db**: *`object`*
*Defined in [mock/types.d.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/types.d.ts#L19)*
#### Type declaration
[index: `string`]: `Uint8Array`
___
<a id="mockstate_requests"></a>
## MockState$Requests
**Ƭ MockState$Requests**: *`object`*
*Defined in [mock/types.d.ts:23](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/types.d.ts#L23)*
#### Type declaration
[index: `string`]: `function`
▸(db: *[MockState$Db](_mock_types_d_.md#mockstate_db)*, params: *`Array`<`any`>*): `string`
**Parameters:**
| Param | Type |
| ------ | ------ |
| db | [MockState$Db](_mock_types_d_.md#mockstate_db) |
| params | `Array`<`any`> |
**Returns:** `string`
___
<a id="mockstate_subscription_callback"></a>
## MockState$Subscription$Callback
**Ƭ MockState$Subscription$Callback**: *`function`*
*Defined in [mock/types.d.ts:8](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/types.d.ts#L8)*
#### Type declaration
▸(error: * `Error` &#124; `null`*, value: *`any`*): `void`
**Parameters:**
| Param | Type |
| ------ | ------ |
| error | `Error` &#124; `null`|
| value | `any` |
**Returns:** `void`
___
<a id="mockstate_subscriptions"></a>
## MockState$Subscriptions
**Ƭ MockState$Subscriptions**: *`object`*
*Defined in [mock/types.d.ts:10](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/types.d.ts#L10)*
#### Type declaration
[index: `string`]: `object`
___
@@ -6,15 +6,15 @@
## unsubscribe
▸ **unsubscribe**(self: *[MockState](_mock_types_d_.md#mockstate)*, type: *`string`*, name: *`string`*, id: *`number`*): `Promise`<`boolean`>
▸ **unsubscribe**(self: *`MockState`*, type: *`string`*, name: *`string`*, id: *`number`*): `Promise`<`boolean`>
*Defined in [mock/unsubscribe.ts:7](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/mock/unsubscribe.ts#L7)*
*Defined in [mock/unsubscribe.ts:7](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-provider/src/mock/unsubscribe.ts#L7)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| self | [MockState](_mock_types_d_.md#mockstate) |
| self | `MockState` |
| type | `string` |
| name | `string` |
| id | `number` |
-108
View File
@@ -1,108 +0,0 @@
# Type aliases
<a id="jsonrpcobject"></a>
## JsonRpcObject
**Ƭ JsonRpcObject**: *`object`*
*Defined in [types.d.ts:5](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L5)*
#### Type declaration
___
<a id="jsonrpcrequest"></a>
## JsonRpcRequest
**Ƭ JsonRpcRequest**: * [JsonRpcObject](_types_d_.md#jsonrpcobject) & `object`
*
*Defined in [types.d.ts:10](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L10)*
___
<a id="jsonrpcresponse"></a>
## JsonRpcResponse
**Ƭ JsonRpcResponse**: * [JsonRpcObject](_types_d_.md#jsonrpcobject) & [JsonRpcResponseBase](_types_d_.md#jsonrpcresponsebase)
*
*Defined in [types.d.ts:36](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L36)*
___
<a id="jsonrpcresponsebase"></a>
## JsonRpcResponseBase
**Ƭ JsonRpcResponseBase**: * `JsonRpcResponse$Single` & `JsonRpcResponse$Subscription`
*
*Defined in [types.d.ts:34](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L34)*
___
<a id="jsonrpcresponsebase_error"></a>
## JsonRpcResponseBase$Error
**Ƭ JsonRpcResponseBase$Error**: *`object`*
*Defined in [types.d.ts:15](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L15)*
#### Type declaration
___
<a id="providerinterface_callback"></a>
## ProviderInterface$Callback
**Ƭ ProviderInterface$Callback**: *`function`*
*Defined in [types.d.ts:38](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L38)*
#### Type declaration
▸(error: * `Error` &#124; `null`*, result: *`any`*): `void`
**Parameters:**
| Param | Type |
| ------ | ------ |
| error | `Error` &#124; `null`|
| result | `any` |
**Returns:** `void`
___
<a id="providerinterface_emitcb"></a>
## ProviderInterface$EmitCb
**Ƭ ProviderInterface$EmitCb**: *`function`*
*Defined in [types.d.ts:42](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L42)*
#### Type declaration
▸(value?: *`any`*): `any`
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Optional` value | `any` |
**Returns:** `any`
___
<a id="providerinterface_emitted"></a>
## ProviderInterface$Emitted
**Ƭ ProviderInterface$Emitted**: * "connected" &#124; "disconnected"
*
*Defined in [types.d.ts:40](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-provider/src/types.d.ts#L40)*
___
-2
View File
@@ -1,6 +1,4 @@
[![polkadotjs](https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square)](https://polkadot.js.org) ![isc](https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square) [![style](https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square)](https://github.com/Flet/semistandard) [![npm](https://img.shields.io/npm/v/@polkadot/rpc-rx.svg?style=flat-square)](https://www.npmjs.com/package/@polkadot/rpc-rx) [![travis](https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square)](https://travis-ci.org/polkadot-js/api) [![maintainability](https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square)](https://codeclimate.com/github/polkadot-js/api/maintainability) [![coverage](https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square)](https://coveralls.io/github/polkadot-js/api?branch=master) [![dependency](https://david-dm.org/polkadot-js/api.svg?style=flat-square&path=packages/rpc-rx)](https://david-dm.org/polkadot-js/api?path=packages/rpc-rx) [![devDependency](https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&path=packages/rpc-rx)](https://david-dm.org/polkadot-js/api?path=packages/rpc-rx#info=devDependencies)
@polkadot/rpc-rx
================
-1
View File
@@ -1,3 +1,2 @@
* [&quot;index&quot;](modules/_index_.md)
* [RpcRx](classes/_index_.rpcrx.md)
* [&quot;types.d&quot;](modules/_types_d_.md)
+37 -31
View File
@@ -65,7 +65,7 @@
<link rel="shortcut icon" href="../../gitbook/images/favicon.ico" type="image/x-icon">
<link rel="next" href="../../examples/" />
<link rel="next" href="../../examples-rpc/" />
<link rel="prev" href="../" />
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../../examples/">
<li class="chapter " data-level="2.1" data-path="../../examples-rpc/">
<a href="../../examples/">
<a href="../../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../../examples-rpc/01_simple_connect/">
<a href="../../examples/01_simple_connect/">
<a href="../../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../../examples-rpc/02_listen_to_blocks/">
<a href="../../examples/02_listen_to_blocks/">
<a href="../../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../../examples-rpc/03_listen_to_balance_change/">
<a href="../../examples/03_listen_to_balance_change/">
<a href="../../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../../examples-rpc/04_generate_account/">
<a href="../../examples/04_generate_account/">
<a href="../../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../../examples-rpc/05_read_storage/">
<a href="../../examples/05_read_storage/">
<a href="../../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../../examples-rpc/06_craft_extrinsic/">
<a href="../../examples/06_craft_extrinsic/">
<a href="../../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../../examples-rpc/07_transfer_dots/">
<a href="../../examples/07_transfer_dots/">
<a href="../../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -445,7 +451,7 @@
<p><a id="constructor"></a></p>
<h2 id="constructor">constructor</h2>
<p>&#x2295; <strong>new RpcRx</strong>(providerOrRpc?: <em> <code>Rpc</code> | <code>ProviderInterface</code></em>): <a href="_index_.rpcrx.html">RpcRx</a></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L44" target="_blank">index.ts:44</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L44" target="_blank">index.ts:44</a></em></p>
<p><strong>Parameters:</strong></p>
<table>
<thead>
@@ -466,23 +472,23 @@
<h1 id="properties">Properties</h1>
<p><a id="author"></a></p>
<h2 id="author">author</h2>
<p><strong>&#x25CF; author</strong>: <em><a href="../modules/_types_d_.md#rpcrxinterface_section">RpcRxInterface$Section</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L41" target="_blank">index.ts:41</a></em></p>
<p><strong>&#x25CF; author</strong>: <em><code>RpcRxInterface$Section</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L41" target="_blank">index.ts:41</a></em></p>
<hr>
<p><a id="chain"></a></p>
<h2 id="chain">chain</h2>
<p><strong>&#x25CF; chain</strong>: <em><a href="../modules/_types_d_.md#rpcrxinterface_section">RpcRxInterface$Section</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L42" target="_blank">index.ts:42</a></em></p>
<p><strong>&#x25CF; chain</strong>: <em><code>RpcRxInterface$Section</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L42" target="_blank">index.ts:42</a></em></p>
<hr>
<p><a id="state"></a></p>
<h2 id="state">state</h2>
<p><strong>&#x25CF; state</strong>: <em><a href="../modules/_types_d_.md#rpcrxinterface_section">RpcRxInterface$Section</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L43" target="_blank">index.ts:43</a></em></p>
<p><strong>&#x25CF; state</strong>: <em><code>RpcRxInterface$Section</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L43" target="_blank">index.ts:43</a></em></p>
<hr>
<p><a id="system"></a></p>
<h2 id="system">system</h2>
<p><strong>&#x25CF; system</strong>: <em><a href="../modules/_types_d_.md#rpcrxinterface_section">RpcRxInterface$Section</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L44" target="_blank">index.ts:44</a></em></p>
<p><strong>&#x25CF; system</strong>: <em><code>RpcRxInterface$Section</code></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L44" target="_blank">index.ts:44</a></em></p>
<hr>
<p><a id="prefixed"></a></p>
<h2 id="static-prefixed"><code>&lt;Static&gt;</code> prefixed</h2>
@@ -560,7 +566,7 @@
<p><a id="isconnected"></a></p>
<h2 id="isconnected">isConnected</h2>
<p>&#x25B8; <strong>isConnected</strong>(): <code>BehaviorSubject</code>&lt;<code>boolean</code>&gt;</p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L66" target="_blank">index.ts:66</a></em></p>
<p><em>Defined in <a href="https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L66" target="_blank">index.ts:66</a></em></p>
<p><strong>Returns:</strong> <code>BehaviorSubject</code>&lt;<code>boolean</code>&gt;</p>
<hr>
<p><a id="listenercount"></a></p>
@@ -795,7 +801,7 @@
</a>
<a href="../../examples/" class="navigation navigation-next " aria-label="Next page: Overview">
<a href="../../examples-rpc/" class="navigation navigation-next " aria-label="Next page: RPC">
<i class="fa fa-angle-right"></i>
</a>
@@ -806,7 +812,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"RpcRx","level":"1.5.1","depth":2,"next":{"title":"Overview","level":"2.1","depth":1,"path":"examples/README.md","ref":"examples/README.md","articles":[]},"previous":{"title":"rpc-rx","level":"1.5","depth":1,"path":"rpc-rx/README.md","ref":"rpc-rx/README.md","articles":[{"title":"RpcRx","level":"1.5.1","depth":2,"path":"rpc-rx/classes/_index_.rpcrx.md","ref":"rpc-rx/classes/_index_.rpcrx.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-rx/classes/_index_.rpcrx.md","mtime":"2018-10-11T11:42:49.182Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"../..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"RpcRx","level":"1.5.1","depth":2,"next":{"title":"RPC","level":"2.1","depth":1,"path":"examples-rpc/README.md","ref":"examples-rpc/README.md","articles":[{"title":"Simple connect","level":"2.1.1","depth":2,"path":"examples-rpc/01_simple_connect/README.md","ref":"examples-rpc/01_simple_connect/README.md","articles":[]},{"title":"Listen to blocks","level":"2.1.2","depth":2,"path":"examples-rpc/02_listen_to_blocks/README.md","ref":"examples-rpc/02_listen_to_blocks/README.md","articles":[]},{"title":"Listen to balance change","level":"2.1.3","depth":2,"path":"examples-rpc/03_listen_to_balance_change/README.md","ref":"examples-rpc/03_listen_to_balance_change/README.md","articles":[]},{"title":"Generate Accounts","level":"2.1.4","depth":2,"path":"examples-rpc/04_generate_account/README.md","ref":"examples-rpc/04_generate_account/README.md","articles":[]},{"title":"Read Storage","level":"2.1.5","depth":2,"path":"examples-rpc/05_read_storage/README.md","ref":"examples-rpc/05_read_storage/README.md","articles":[]},{"title":"Craft Extrinsic","level":"2.1.6","depth":2,"path":"examples-rpc/06_craft_extrinsic/README.md","ref":"examples-rpc/06_craft_extrinsic/README.md","articles":[]},{"title":"Transfer DOTs","level":"2.1.7","depth":2,"path":"examples-rpc/07_transfer_dots/README.md","ref":"examples-rpc/07_transfer_dots/README.md","articles":[]}]},"previous":{"title":"rpc-rx","level":"1.5","depth":1,"path":"rpc-rx/README.md","ref":"rpc-rx/README.md","articles":[{"title":"RpcRx","level":"1.5.1","depth":2,"path":"rpc-rx/classes/_index_.rpcrx.md","ref":"rpc-rx/classes/_index_.rpcrx.md","articles":[]}]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-rx/classes/_index_.rpcrx.md","mtime":"2018-10-11T13:30:35.531Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
+10 -10
View File
@@ -36,7 +36,7 @@ const api = new RpcRx(provider);
⊕ **new RpcRx**(providerOrRpc?: * `Rpc` &#124; `ProviderInterface`*): [RpcRx](_index_.rpcrx.md)
*Defined in [index.ts:44](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L44)*
*Defined in [index.ts:44](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L44)*
**Parameters:**
@@ -54,36 +54,36 @@ ___
## author
**● author**: *[RpcRxInterface$Section](../modules/_types_d_.md#rpcrxinterface_section)*
**● author**: *`RpcRxInterface$Section`*
*Defined in [index.ts:41](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L41)*
*Defined in [index.ts:41](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L41)*
___
<a id="chain"></a>
## chain
**● chain**: *[RpcRxInterface$Section](../modules/_types_d_.md#rpcrxinterface_section)*
**● chain**: *`RpcRxInterface$Section`*
*Defined in [index.ts:42](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L42)*
*Defined in [index.ts:42](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L42)*
___
<a id="state"></a>
## state
**● state**: *[RpcRxInterface$Section](../modules/_types_d_.md#rpcrxinterface_section)*
**● state**: *`RpcRxInterface$Section`*
*Defined in [index.ts:43](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L43)*
*Defined in [index.ts:43](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L43)*
___
<a id="system"></a>
## system
**● system**: *[RpcRxInterface$Section](../modules/_types_d_.md#rpcrxinterface_section)*
**● system**: *`RpcRxInterface$Section`*
*Defined in [index.ts:44](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L44)*
*Defined in [index.ts:44](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L44)*
___
<a id="prefixed"></a>
@@ -165,7 +165,7 @@ ___
▸ **isConnected**(): `BehaviorSubject`<`boolean`>
*Defined in [index.ts:66](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/index.ts#L66)*
*Defined in [index.ts:66](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/rpc-rx/src/index.ts#L66)*
**Returns:** `BehaviorSubject`<`boolean`>
+26 -21
View File
@@ -273,22 +273,23 @@
<li class="chapter " data-level="2.1" data-path="../examples/">
<li class="chapter " data-level="2.1" data-path="../examples-rpc/">
<a href="../examples/">
<a href="../examples-rpc/">
Overview
RPC
</a>
</li>
<ul class="articles">
<li class="chapter " data-level="2.2" data-path="../examples/01_simple_connect/">
<li class="chapter " data-level="2.1.1" data-path="../examples-rpc/01_simple_connect/">
<a href="../examples/01_simple_connect/">
<a href="../examples-rpc/01_simple_connect/">
Simple connect
@@ -299,9 +300,9 @@
</li>
<li class="chapter " data-level="2.3" data-path="../examples/02_listen_to_blocks/">
<li class="chapter " data-level="2.1.2" data-path="../examples-rpc/02_listen_to_blocks/">
<a href="../examples/02_listen_to_blocks/">
<a href="../examples-rpc/02_listen_to_blocks/">
Listen to blocks
@@ -312,9 +313,9 @@
</li>
<li class="chapter " data-level="2.4" data-path="../examples/03_listen_to_balance_change/">
<li class="chapter " data-level="2.1.3" data-path="../examples-rpc/03_listen_to_balance_change/">
<a href="../examples/03_listen_to_balance_change/">
<a href="../examples-rpc/03_listen_to_balance_change/">
Listen to balance change
@@ -325,9 +326,9 @@
</li>
<li class="chapter " data-level="2.5" data-path="../examples/04_generate_account/">
<li class="chapter " data-level="2.1.4" data-path="../examples-rpc/04_generate_account/">
<a href="../examples/04_generate_account/">
<a href="../examples-rpc/04_generate_account/">
Generate Accounts
@@ -338,9 +339,9 @@
</li>
<li class="chapter " data-level="2.6" data-path="../examples/05_read_storage/">
<li class="chapter " data-level="2.1.5" data-path="../examples-rpc/05_read_storage/">
<a href="../examples/05_read_storage/">
<a href="../examples-rpc/05_read_storage/">
Read Storage
@@ -351,9 +352,9 @@
</li>
<li class="chapter " data-level="2.7" data-path="../examples/06_craft_extrinsic/">
<li class="chapter " data-level="2.1.6" data-path="../examples-rpc/06_craft_extrinsic/">
<a href="../examples/06_craft_extrinsic/">
<a href="../examples-rpc/06_craft_extrinsic/">
Craft Extrinsic
@@ -364,9 +365,9 @@
</li>
<li class="chapter " data-level="2.8" data-path="../examples/07_transfer_dots/">
<li class="chapter " data-level="2.1.7" data-path="../examples-rpc/07_transfer_dots/">
<a href="../examples/07_transfer_dots/">
<a href="../examples-rpc/07_transfer_dots/">
Transfer DOTs
@@ -378,6 +379,11 @@
</li>
</ul>
</li>
<li class="divider"></li>
@@ -422,8 +428,7 @@
<section class="normal markdown-section">
<p><a href="https://polkadot.js.org" target="_blank"><img src="https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square" alt="polkadotjs"></a> <img src="https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square" alt="isc"> <a href="https://github.com/Flet/semistandard" target="_blank"><img src="https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square" alt="style"></a> <a href="https://www.npmjs.com/package/@polkadot/rpc-rx" target="_blank"><img src="https://img.shields.io/npm/v/@polkadot/rpc-rx.svg?style=flat-square" alt="npm"></a> <a href="https://travis-ci.org/polkadot-js/api" target="_blank"><img src="https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square" alt="travis"></a> <a href="https://codeclimate.com/github/polkadot-js/api/maintainability" target="_blank"><img src="https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square" alt="maintainability"></a> <a href="https://coveralls.io/github/polkadot-js/api?branch=master" target="_blank"><img src="https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square" alt="coverage"></a> <a href="https://david-dm.org/polkadot-js/api?path=packages/rpc-rx" target="_blank"><img src="https://david-dm.org/polkadot-js/api.svg?style=flat-square&amp;path=packages/rpc-rx" alt="dependency"></a> <a href="https://david-dm.org/polkadot-js/api?path=packages/rpc-rx#info=devDependencies" target="_blank"><img src="https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&amp;path=packages/rpc-rx" alt="devDependency"></a></p>
<h1 id="polkadotrpc-rx">@polkadot/rpc-rx</h1>
<h1 id="polkadotrpc-rx">@polkadot/rpc-rx</h1>
<p>An RxJs wrapper around the <a href="../rpc-core">@polkadot/rpc-core</a>.</p>
@@ -468,7 +473,7 @@
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"rpc-rx","level":"1.5","depth":1,"next":{"title":"RpcRx","level":"1.5.1","depth":2,"path":"rpc-rx/classes/_index_.rpcrx.md","ref":"rpc-rx/classes/_index_.rpcrx.md","articles":[]},"previous":{"title":"Rpc","level":"1.4.1","depth":2,"path":"rpc-core/classes/_index_.rpc.md","ref":"rpc-core/classes/_index_.rpc.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-rx/README.md","mtime":"2018-10-11T11:42:49.042Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T11:43:46.267Z"},"basePath":"..","book":{"language":""}});
gitbook.page.hasChanged({"page":{"title":"rpc-rx","level":"1.5","depth":1,"next":{"title":"RpcRx","level":"1.5.1","depth":2,"path":"rpc-rx/classes/_index_.rpcrx.md","ref":"rpc-rx/classes/_index_.rpcrx.md","articles":[]},"previous":{"title":"Rpc","level":"1.4.1","depth":2,"path":"rpc-core/classes/_index_.rpc.md","ref":"rpc-core/classes/_index_.rpc.md","articles":[]},"dir":"ltr"},"config":{"plugins":["include-codeblock","mermaid-gb3","-highlight","sunlight-highlighter"],"root":"docs","styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"sunlight-highlighter":{"theme":"gitbook","lineNumbers":false},"include-codeblock":{"check":false,"edit":false,"lang":"","fixlang":false,"template":"default","theme":"chrome","unindent":false},"mermaid-gb3":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Polkadot API Book","gitbook":">=2.4.0"},"file":{"path":"rpc-rx/README.md","mtime":"2018-10-11T13:30:35.371Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-10-11T13:31:41.446Z"},"basePath":"..","book":{"language":""}});
});
</script>
</div>
-59
View File
@@ -1,59 +0,0 @@
# Type aliases
<a id="rpcrxinterface"></a>
## RpcRxInterface
**Ƭ RpcRxInterface**: *`object`*
*Defined in [types.d.ts:16](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/types.d.ts#L16)*
#### Type declaration
___
<a id="rpcrxinterface_events"></a>
## RpcRxInterface$Events
**Ƭ RpcRxInterface$Events**: * "connected" &#124; "disconnected"
*
*Defined in [types.d.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/types.d.ts#L14)*
___
<a id="rpcrxinterface_method"></a>
## RpcRxInterface$Method
**Ƭ RpcRxInterface$Method**: *`function`*
*Defined in [types.d.ts:8](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/types.d.ts#L8)*
#### Type declaration
▸(...params: *`Array`<`any`>*): `Observable`<`any`> &#124; `ReplaySubject`<`any`>
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Rest` params | `Array`<`any`> |
**Returns:** `Observable`<`any`> &#124; `ReplaySubject`<`any`>
___
<a id="rpcrxinterface_section"></a>
## RpcRxInterface$Section
**Ƭ RpcRxInterface$Section**: *`object`*
*Defined in [types.d.ts:10](https://github.com/polkadot-js/api/blob/f5948fe/packages/rpc-rx/src/types.d.ts#L10)*
#### Type declaration
[index: `string`]: [RpcRxInterface$Method](_types_d_.md#rpcrxinterface_method)
___
File diff suppressed because one or more lines are too long
-4
View File
@@ -1,8 +1,4 @@
* [&quot;fromMetadata&quot;](modules/_frommetadata_.md)
* [&quot;index&quot;](modules/_index_.md)
* [&quot;static&quot;](modules/_static_.md)
* [&quot;types.d&quot;](modules/_types_d_.md)
* [ExtrinsicFunction](interfaces/_types_d_.extrinsicfunction.md)
* [Extrinsics](interfaces/_types_d_.extrinsics.md)
* [ModuleExtrinsics](interfaces/_types_d_.moduleextrinsics.md)
* [&quot;utils/createUnchecked&quot;](modules/_utils_createunchecked_.md)
@@ -1,72 +0,0 @@
# Hierarchy
**ExtrinsicFunction**
# Callable
▸ **__call**(...args: *`any`[]*): `Extrinsic`
*Defined in [types.d.ts:8](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L8)*
**Parameters:**
| Param | Type |
| ------ | ------ |
| `Rest` args | `any`[] |
**Returns:** `Extrinsic`
# Properties
<a id="callindex"></a>
## callIndex
**● callIndex**: *`Uint8Array`*
*Defined in [types.d.ts:10](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L10)*
___
<a id="meta"></a>
## meta
**● meta**: *`FunctionMetadata`*
*Defined in [types.d.ts:11](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L11)*
___
<a id="method"></a>
## method
**● method**: *`string`*
*Defined in [types.d.ts:12](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L12)*
___
<a id="section"></a>
## section
**● section**: *`string`*
*Defined in [types.d.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L13)*
___
<a id="tojson"></a>
## toJSON
**● toJSON**: *`function`*
*Defined in [types.d.ts:14](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/types.d.ts#L14)*
#### Type declaration
▸(): `any`
**Returns:** `any`
___
@@ -1,9 +0,0 @@
# Hierarchy
**Extrinsics**
# Indexable
\[key: `string`\]:&nbsp;[ModuleExtrinsics](_types_d_.moduleextrinsics.md)
@@ -1,9 +0,0 @@
# Hierarchy
**ModuleExtrinsics**
# Indexable
\[key: `string`\]:&nbsp;[ExtrinsicFunction](_types_d_.extrinsicfunction.md)
@@ -6,9 +6,9 @@
## fromMetadata
▸ **fromMetadata**(metadata: *`Metadata`*): [Extrinsics](../interfaces/_types_d_.extrinsics.md)
▸ **fromMetadata**(metadata: *`Metadata`*): `Extrinsics`
*Defined in [fromMetadata.ts:19](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/fromMetadata.ts#L19)*
*Defined in [fromMetadata.ts:19](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/type-extrinsics/src/fromMetadata.ts#L19)*
Extend a storage object with the storage modules & module functions present in the metadata.
@@ -18,7 +18,7 @@ Extend a storage object with the storage modules & module functions present in t
| ------ | ------ | ------ |
| metadata | `Metadata` | The metadata to extend the storage object against. |
**Returns:** [Extrinsics](../interfaces/_types_d_.extrinsics.md)
**Returns:** `Extrinsics`
___
@@ -1,2 +0,0 @@
@@ -6,9 +6,9 @@
## createDescriptor
▸ **createDescriptor**(section: *`string`*, method: *`string`*, index: *`number`*, meta: *`FunctionMetadata`*): [ExtrinsicFunction](../interfaces/_types_d_.extrinsicfunction.md)
▸ **createDescriptor**(section: *`string`*, method: *`string`*, index: *`number`*, meta: *`FunctionMetadata`*): `ExtrinsicFunction`
*Defined in [utils/createUnchecked.ts:16](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-extrinsics/src/utils/createUnchecked.ts#L16)*
*Defined in [utils/createUnchecked.ts:16](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/type-extrinsics/src/utils/createUnchecked.ts#L16)*
From the metadata of a function in the module's storage, generate the function that will return the an UncheckExtrinsic.
@@ -21,7 +21,7 @@ From the metadata of a function in the module's storage, generate the function t
| index | `number` | Index of the module section in the modules array. |
| meta | `FunctionMetadata` |
**Returns:** [ExtrinsicFunction](../interfaces/_types_d_.extrinsicfunction.md)
**Returns:** `ExtrinsicFunction`
___
-2
View File
@@ -1,6 +1,4 @@
[![polkadotjs](https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square)](https://polkadot.js.org) ![isc](https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square) [![style](https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square)](https://github.com/Flet/semistandard) [![npm](https://img.shields.io/npm/v/@polkadot/jsonrpc.svg?style=flat-square)](https://www.npmjs.com/package/@polkadot/jsonrpc) [![travis](https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square)](https://travis-ci.org/polkadot-js/api) [![maintainability](https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square)](https://codeclimate.com/github/polkadot-js/api/maintainability) [![coverage](https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square)](https://coveralls.io/github/polkadot-js/api?branch=master) [![dependency](https://david-dm.org/polkadot-js/api.svg?style=flat-square&path=packages/type-jsonrpc)](https://david-dm.org/polkadot-js/api?path=packages/type-jsonrpc) [![devDependency](https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&path=packages/type-jsonrpc)](https://david-dm.org/polkadot-js/api?path=packages/type-jsonrpc#info=devDependencies)
@polkadot/jsonrpc
=================
-1
View File
@@ -5,4 +5,3 @@
* [&quot;index&quot;](modules/_index_.md)
* [&quot;state&quot;](modules/_state_.md)
* [&quot;system&quot;](modules/_system_.md)
* [&quot;types.d&quot;](modules/_types_d_.md)
+3 -3
View File
@@ -6,9 +6,9 @@
## createMethod
▸ **createMethod**(section: *`string`*, method: *`string`*, __namedParameters: *`object`*): [RpcMethod](_types_d_.md#rpcmethod)
▸ **createMethod**(section: *`string`*, method: *`string`*, __namedParameters: *`object`*): `RpcMethod`
*Defined in [create/method.ts:9](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-jsonrpc/src/create/method.ts#L9)*
*Defined in [create/method.ts:9](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/type-jsonrpc/src/create/method.ts#L9)*
**Parameters:**
@@ -18,7 +18,7 @@
| method | `string` |
| __namedParameters | `object` |
**Returns:** [RpcMethod](_types_d_.md#rpcmethod)
**Returns:** `RpcMethod`
___
+3 -3
View File
@@ -6,9 +6,9 @@
## createParam
▸ **createParam**(name: *`string`*, type: *`CodecTypes`*, __namedParameters?: *`object`*): [RpcParam](_types_d_.md#rpcparam)
▸ **createParam**(name: *`string`*, type: *`CodecTypes`*, __namedParameters?: *`object`*): `RpcParam`
*Defined in [create/param.ts:12](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-jsonrpc/src/create/param.ts#L12)*
*Defined in [create/param.ts:12](https://github.com/polkadot-js/api/blob/a4fc2c5/packages/type-jsonrpc/src/create/param.ts#L12)*
**Parameters:**
@@ -18,7 +18,7 @@
| type | `CodecTypes` | - |
| `Default value` __namedParameters | `object` | { isOptional: false } |
**Returns:** [RpcParam](_types_d_.md#rpcparam)
**Returns:** `RpcParam`
___
-49
View File
@@ -1,49 +0,0 @@
# Type aliases
<a id="rpcmethod"></a>
## RpcMethod
**Ƭ RpcMethod**: *`object`*
*Defined in [types.d.ts:24](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-jsonrpc/src/types.d.ts#L24)*
#### Type declaration
___
<a id="rpcmethodopt"></a>
## RpcMethodOpt
**Ƭ RpcMethodOpt**: *`object`*
*Defined in [types.d.ts:13](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-jsonrpc/src/types.d.ts#L13)*
#### Type declaration
___
<a id="rpcparam"></a>
## RpcParam
**Ƭ RpcParam**: *`object`*
*Defined in [types.d.ts:7](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-jsonrpc/src/types.d.ts#L7)*
#### Type declaration
___
<a id="rpcsection"></a>
## RpcSection
**Ƭ RpcSection**: *`object`*
*Defined in [types.d.ts:38](https://github.com/polkadot-js/api/blob/f5948fe/packages/type-jsonrpc/src/types.d.ts#L38)*
#### Type declaration
___
-2
View File
@@ -1,6 +1,4 @@
[![polkadotjs](https://img.shields.io/badge/polkadot-js-orange.svg?style=flat-square)](https://polkadot.js.org) ![isc](https://img.shields.io/badge/license-ISC-lightgrey.svg?style=flat-square) [![style](https://img.shields.io/badge/code%20style-semistandard-lightgrey.svg?style=flat-square)](https://github.com/Flet/semistandard) [![npm](https://img.shields.io/npm/v/@polkadot/storage.svg?style=flat-square)](https://www.npmjs.com/package/@polkadot/storage) [![travis](https://img.shields.io/travis/polkadot-js/api.svg?style=flat-square)](https://travis-ci.org/polkadot-js/api) [![maintainability](https://img.shields.io/codeclimate/maintainability/polkadot-js/api.svg?style=flat-square)](https://codeclimate.com/github/polkadot-js/api/maintainability) [![coverage](https://img.shields.io/coveralls/polkadot-js/api.svg?style=flat-square)](https://coveralls.io/github/polkadot-js/api?branch=master) [![dependency](https://david-dm.org/polkadot-js/api.svg?style=flat-square&path=packages/type-storage)](https://david-dm.org/polkadot-js/api?path=packages/type-storage) [![devDependency](https://david-dm.org/polkadot-js/api/dev-status.svg?style=flat-square&path=packages/type-storage)](https://david-dm.org/polkadot-js/api?path=packages/type-storage#info=devDependencies)
@polkadot/storage
=================

Some files were not shown because too many files have changed in this diff Show More