validateaddress

Back to util

Summary

Return information about the given qbit address.

Description

Return information about the given qbit address.

Arguments

  • address (STR, required): The qbit address to validate

Results

  • value (OBJ): No description.
  • isvalid (BOOL): If the address is valid or not
  • address (STR, optional): The qbit address validated
  • scriptPubKey (STR_HEX, optional): The hex-encoded output script generated by the address
  • isscript (BOOL, optional): If the key is a script
  • iswitness (BOOL, optional): If the address is a witness address
  • witness_version (NUM, optional): The version number of the witness program
  • witness_program (STR_HEX, optional): The hex value of the witness program
  • error (STR, optional): Error message, if any
  • error_locations (ARR, optional): Indices of likely error locations in address, if known (e.g. Bech32 errors)
    • index (NUM): index of a potential error

Examples

qbit-cli validateaddress "qb1zqqqsyqcyq5rqwzqfpg9scrgwpugpzysnzs23v9ccrydpk8qarc0sjq57mw"
curl --user myusername --data-binary '{"jsonrpc": "2.0", "id": "curltest", "method": "validateaddress", "params": ["qb1zqqqsyqcyq5rqwzqfpg9scrgwpugpzysnzs23v9ccrydpk8qarc0sjq57mw"]}' -H 'content-type: application/json' http://127.0.0.1:8352/