For all Zilliqa protocol and tools related topics. For more information, visit https://zilliqa.com/for-developers.html
Hi, In the python api scripts for zilliqa to create transaction what do I set the chain to in "set _active _chain" if I am running a local network .
from pyzil.crypto import zilkey
from pyzil.zilliqa import chain
chain.set_active_chain(chain.MainNet)
my_key = zilkey.ZilKey(private_key="**")
payload = {
"to_addr": "4baf5fada8e5db92c3d3242618c5b47133ae003c",
"amount": "1000000000000",
"gas_price": "1000000000",
"gas_limit": 1,
"code": "",
"data": "",
"priority": False,
}
params = chain.active_chain.build_transaction_params(my_key, **payload)
txn_info = chain.active_chain.api.CreateTransaction(params)
print(txn_info)
MainNet
here:gas
in Ethereum is gasLimit
*gasPrice
end
. Then I'd be much happier