Iota Asked on August 21, 2021
I have created a one command tangle from this link: https://docs.iota.org/docs/utils/0.1/community/one-command-tangle/overview
And using API given here: https://docs.iota.org/docs/node-software/0.1/iri/references/api-reference#broadcasttransactions.
EDIT: I forgot to mention that sudo docker-compose up
was giving error, so I pulled coordinator-1264e19 from this link: https://hub.docker.com/r/iotacafe/compass/tags and the command sudo docker-compose up
started working after this.
I’m trying to broadcast transaction from this node using Python Library, but I’m getting this error:
“urlopen error [WinError 10061] No connection could be made because the target machine actively refused it”
My code is:
import urllib.request
import urllib.parse
import json
command = {
"command": "broadcastTransactions",
"trytes": ["P9KFSJVGSPLXAEBJSHWFZLGP ..."]
}
stringified = json.dumps(command)
headers = {
'content-type': 'application/json',
'X-IOTA-API-Version': '1'
}
url="http://localhost:14265"
fo = urllib.parse.urlencode(command)
#fo = urllib2.urlunparse(command)
fo = fo.encode('utf-8')
request = urllib.request.Request(url, fo)
returnData = urllib.request.urlopen(request).read()
jsonData = json.loads(returnData)
print (jsonData)
My node is running on ubuntu machine: ]1)
This is very important work for me. If I can get any guidance regarding this error and how to resolve it, I would be very thankful.
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP