neblio_rest_api_suite
NeblioRestApiSuite - JavaScript client for neblio_rest_api_suite APIs for Interacting with NTP1 Tokens & The Neblio Blockchain This SDK is automatically generated by the Swagger Codegen project:
- API version: 1.0.0
- Package version: 1.0.0
- Build package: io.swagger.codegen.languages.JavascriptClientCodegen
Installation
Node.js
Fornpm
To publish the library as a npm, please follow the procedure in "Publishing npm packages".
Then install it via:
npm install neblio_rest_api_suite --save
Local development
To use the library locally without publishing to a remote npm registry, first install the dependencies by changing
into the directory containing package.json
(and this README). Let's call this JAVASCRIPT_CLIENT_DIR
. Then run:
npm install
Next, link it globally in npm with the following, also from JAVASCRIPT_CLIENT_DIR
:
npm link
Finally, switch to the directory you want to use your neblio_rest_api_suite from, and run:
npm link /path/to/<JAVASCRIPT_CLIENT_DIR>
You should now be able to require('neblio_rest_api_suite')
in javascript files from the directory you ran the last
command above from.
git
If the library is hosted at a git repository, e.g. https://github.com/YOUR_USERNAME/neblio_rest_api_suite then install it via:
npm install YOUR_USERNAME/neblio_rest_api_suite --save
For browser
The library also works in the browser environment via npm and browserify. After following
the above steps with Node.js and installing browserify with npm install -g browserify
,
perform the following (assuming main.js is your entry file, that's to say your javascript file where you actually
use this library):
browserify main.js > bundle.js
Then include bundle.js in the HTML pages.
Webpack Configuration
Using Webpack you may encounter the following error: "Module not found: Error: Cannot resolve module", most certainly you should disable AMD loader. Add/merge the following section to your webpack config:
module: rules: parser: amd: false
Getting Started
Please follow the installation instruction and execute the following JS code:
var NeblioRestApiSuite = ; var api = var body = ; // {BroadcastTxRequest} Object representing a transaction to broadcast var { if error console; else console; };api;
Documentation for API Endpoints
All URIs are relative to https://ntp1node.nebl.io:1443
Class | Method | HTTP request | Description |
---|---|---|---|
NeblioRestApiSuite.NTP1Api | broadcastTx | POST /ntp1/broadcast | Broadcasts a signed raw transaction to the network |
NeblioRestApiSuite.NTP1Api | burnToken | POST /ntp1/burntoken | Builds a transaction that burns an NTP1 Token |
NeblioRestApiSuite.NTP1Api | getAddressInfo | GET /ntp1/addressinfo/{address} | Information On a Neblio Address |
NeblioRestApiSuite.NTP1Api | getTokenHolders | GET /ntp1/stakeholders/{tokenid} | Get Addresses Holding a Token |
NeblioRestApiSuite.NTP1Api | getTokenId | GET /ntp1/tokenid/{tokensymbol} | Returns the tokenId representing a token |
NeblioRestApiSuite.NTP1Api | getTokenMetadataOfIssuance | GET /ntp1/tokenmetadata/{tokenid} | Get Issuance Metadata of Token |
NeblioRestApiSuite.NTP1Api | getTokenMetadataOfUtxo | GET /ntp1/tokenmetadata/{tokenid}/{utxo} | Get UTXO Metadata of Token |
NeblioRestApiSuite.NTP1Api | issueToken | POST /ntp1/issue | Builds a transaction that issues a new NTP1 Token |
NeblioRestApiSuite.NTP1Api | sendToken | POST /ntp1/sendtoken | Builds a transaction that sends an NTP1 Token |
Documentation for Models
- NeblioRestApiSuite.BroadcastTxRequest
- NeblioRestApiSuite.BroadcastTxResponse
- NeblioRestApiSuite.BurnTokenRequest
- NeblioRestApiSuite.BurnTokenRequestBurn
- NeblioRestApiSuite.BurnTokenResponse
- NeblioRestApiSuite.Error
- NeblioRestApiSuite.GetAddressInfoResponse
- NeblioRestApiSuite.GetAddressInfoResponseTokens
- NeblioRestApiSuite.GetAddressInfoResponseUtxos
- NeblioRestApiSuite.GetTokenHoldersResponse
- NeblioRestApiSuite.GetTokenHoldersResponseHolders
- NeblioRestApiSuite.GetTokenIdResponse
- NeblioRestApiSuite.GetTokenMetadataResponse
- NeblioRestApiSuite.GetTokenMetadataResponseMetadataOfIssuance
- NeblioRestApiSuite.GetTokenMetadataResponseMetadataOfIssuanceData
- NeblioRestApiSuite.GetTokenMetadataResponseMetadataOfIssuanceDataUserData
- NeblioRestApiSuite.GetTokenMetadataResponseMetadataOfIssuanceDataUserDataMeta
- NeblioRestApiSuite.IssueTokenRequest
- NeblioRestApiSuite.IssueTokenRequestMetadata
- NeblioRestApiSuite.IssueTokenRequestMetadataEncryptions
- NeblioRestApiSuite.IssueTokenRequestMetadataRules
- NeblioRestApiSuite.IssueTokenRequestMetadataRulesExpiration
- NeblioRestApiSuite.IssueTokenRequestMetadataRulesFees
- NeblioRestApiSuite.IssueTokenRequestMetadataRulesFeesItems
- NeblioRestApiSuite.IssueTokenRequestMetadataRulesHolders
- NeblioRestApiSuite.IssueTokenRequestMetadataUrls
- NeblioRestApiSuite.IssueTokenResponse
- NeblioRestApiSuite.SendTokenRequest
- NeblioRestApiSuite.SendTokenRequestTo
- NeblioRestApiSuite.SendTokenResponse
Documentation for Authorization
All endpoints do not require authorization.