fix: Remove Niami API requirement for searching for domains
All checks were successful
Build Docker / Build Image (push) Successful in 2m36s

This commit is contained in:
2025-07-07 12:20:16 +10:00
parent 075e432900
commit 0164a9c3f2
3 changed files with 25 additions and 35 deletions

View File

@@ -472,6 +472,24 @@ def getDomain(domain: str):
}
return response['result']
def getAddressFromCoin(coinhash: str, coinindex = 0):
# Get the address from the hash
response = requests.get(f"http://x:{HSD_API}@{HSD_IP}:{HSD_NODE_PORT}/coin/{coinhash}/{coinindex}")
if response.status_code != 200:
return {
"error": {
"message": "Error getting address from coin"
}
}
data = response.json()
if 'address' not in data:
return {
"error": {
"message": "Error getting address from coin"
}
}
return data['address']
def renewDomain(account, domain):
account_name = check_account(account)