Actions25
- Account Actions
- Token/Asset Actions
- Transaction Actions
- Utility Actions
Overview
This node interacts with the DecentralChain (DCC) blockchain to retrieve account-related information, specifically focusing on asset balances for a given account address. The "Get Asset Balance" operation under the "Account" resource fetches the balance of a specific asset held by an account.
Common scenarios where this node is beneficial include:
- Monitoring the balance of a particular token or asset in a user's wallet.
- Integrating blockchain asset balance checks into workflows for financial reporting or automated trading.
- Verifying asset holdings before executing further blockchain transactions.
For example, you can use this node to query how many units of a specific token an address owns, which is useful in decentralized finance (DeFi) applications or portfolio management tools.
Properties
| Name | Meaning |
|---|---|
| Base URL | The base URL of the DecentralChain node API endpoint to use if no credential is supplied. |
Output
The output JSON contains the balance information of the specified asset for the given account address. The structure typically includes fields such as:
balance: The amount of the asset held by the account (usually in smallest units).assetId: The identifier of the asset queried.- Other metadata related to the asset balance as returned by the DecentralChain API.
Example output JSON snippet:
{
"balance": 123456789,
"assetId": "some-asset-id",
// additional fields depending on API response
}
No binary data output is produced by this operation.
Dependencies
- Requires access to a DecentralChain node API endpoint, either via a user-supplied Base URL or configured credentials that provide the API URL.
- Uses HTTP requests to communicate with the blockchain node's REST API.
- No external libraries beyond standard n8n workflow helpers and optional waves-transactions library for other operations.
Troubleshooting
Common issues:
- Incorrect or unreachable Base URL: Ensure the Base URL points to a valid DecentralChain node API endpoint.
- Invalid or missing asset ID or account address parameters: Verify these inputs are correct and properly formatted.
- Network connectivity problems: Confirm network access to the DecentralChain node.
Error messages:
"Failed to create transaction"or"Library loading failed"errors do not apply directly to this operation but may appear if other operations are attempted without proper setup.- HTTP request failures will return error messages from the API; check the message for details like "Not Found" or "Unauthorized".
Resolution tips:
- Double-check input parameters for correctness.
- Test the Base URL separately using tools like curl or Postman.
- Enable "Continue On Fail" in the node settings to handle intermittent API errors gracefully.
Links and References
- DecentralChain official documentation (for API endpoints and asset management):
https://docs.decentralchain.io/ - Waves Transactions Library (used internally for transaction operations):
https://github.com/wavesplatform/waves-transactions - n8n Documentation on creating custom nodes:
https://docs.n8n.io/integrations/creating-nodes/