API Reference
The Shamwari Network API provides comprehensive access to blockchain data and operations. All endpoints return JSON and are accessible via HTTP GET or POST.
Quick Navigation
Use the sidebar to browse endpoints by category, or use the search bar to find specific endpoints.
Base URL
http://localhost:6876/nxt
HTTPS (if enabled):
https://localhost:6877/nxt
Authentication
Most endpoints are public. The following require authentication:
- Secret Phrase:
secretPhraseparameter for transaction signing - Admin Password:
adminPasswordfor administrative operations
Response Format
{
"requestType": "endpointName",
"...response fields...": "...",
"errorCode": 0,
"errorDescription": ""
}
Error Codes
| Code | Description |
|---|---|
| 1 | Incorrect request |
| 2 | Unknown request type |
| 3 | Unknown account |
| 4 | Unknown block |
| 5 | Insufficient balance |
| 6 | Not enough funds |
| 7 | Invalid parameter |
| 8 | Already have |
| 9 | Deadline already passed |
| 10 | Phasing only |
Common Parameters
| Parameter | Description |
|---|---|
requestType | API endpoint name |
chain | Chain ID |
requireBlock | Block ID for response |
requireLastBlock | Last block ID for response |
secretPhrase | Account passphrase |
publicKey | Account public key |
account | Account ID or NXT-format address |
adminPassword | Admin password |
firstIndex | Pagination start |
lastIndex | Pagination end |
includeLessors | Include lessor information |
includeCurrencies | Include currency holdings |
includeEffectiveBalance | Include effective balance |