1 | <h1 align="center">
|
2 | node-wallet-api
|
3 | <br>
|
4 | </h1>
|
5 |
|
6 | <h4 align="center">
|
7 | Node.js Wallet API for the <a href="https://tron.network">Tron Protocol</a>
|
8 | </h4>
|
9 |
|
10 | <p align="center">
|
11 | <a href="#how-to-use">How to Use</a> •
|
12 | <a href="#links">Links</a> •
|
13 | <a href="http://wiki.tron.network">Wiki</a> •
|
14 | <a href="#community">Community</a>
|
15 | </p>
|
16 |
|
17 | # How to use
|
18 |
|
19 | ## Requirements
|
20 |
|
21 | * Node v9.8.0
|
22 |
|
23 | ## Running tests
|
24 |
|
25 | Running the tests requires an active `wallet-cli` application.
|
26 | Check out to the [readme](https://github.com/tronprotocol/wallet-cli) to get it up and running.
|
27 |
|
28 | When there is a running `wallet-cli` application use `npm` to run the tests
|
29 |
|
30 | ```bash
|
31 | > npm test
|
32 | ```
|
33 |
|
34 | ## Usage
|
35 |
|
36 | Install the package
|
37 |
|
38 | ```bash
|
39 | > npm install @tronprotocol/wallet-api
|
40 | ```
|
41 |
|
42 | Use the HTTP Client
|
43 |
|
44 | ```javascript
|
45 | import {HttpClient} from "@tronprotocol/wallet-api";
|
46 |
|
47 | const Client = new HttpClient();
|
48 |
|
49 | let latestBlock = await Client.getLatestBlock();
|
50 | ```
|
51 |
|
52 | # Community
|
53 |
|
54 | * [Slack](https://join.slack.com/t/tronfoundation/shared_invite/enQtMzAzNzg4NTI4NDM3LTAyZGQzMzEzMjNkNDU0ZjNkNTA4OTYyNTA5YWZmYjE3MTEyOWZhNzljNzQwODM3NDQ0OWRiMTIyMDhlYzgyOGQ)
|
55 | * [Telegram](https://t.me/tronnetworkEN)
|
56 |
|
57 | # Links
|
58 |
|
59 | * [Website](https://tron.network/)
|
60 | * [Documentation](https://github.com/tronprotocol/java-tron)
|
61 | * [Blog](https://tronprotocol.github.io/tron-blog/)
|
62 | * [TRON Wiki](http://wiki.tron.network/en/latest/)
|
63 |
|
64 | # Projects
|
65 |
|
66 | * [TRON Protocol](https://github.com/tronprotocol/protocol)
|
67 | * [Wallet Client](https://github.com/tronprotocol/wallet-cli)
|
68 | * [Wallet Web](https://github.com/tronprotocol/Wallet_Web)
|