Hi there,
here a simple python code I wrote recently to help me in creating new accounts from claimed account tokens both in the steem
blockchain and in the hive
one.
It works with beem library, and you just need to insert the new account name, and the script will check its availability on the blockchain, than a solid password and the account will be created.
It is important that you understand that the script uses the account creation ticket you should already have created to claim the new account.
#!/usr/bin/python
from beem import Steem
from beem.account import Account
from beem.rc import RC
from beem.vote import Vote
from beem.instance import set_shared_steem_instance
from beem.exceptions import ContentDoesNotExistsException
from beem.comment import Comment
import time
def name():
new_account=input('Enter the new account name:')
try:
acc=Account(str.lower(new_account),steem_instance=stm)
print (acc.name+' is UNAVAILABLE!')
name()
except Exception as e:
print (new_account+' is AVAILABLE!')
return new_account
def password_():
password = input('Enter the new password for the new account:')
password2= input('Re-Enter the new password for the new account:')
if password==password2:
print(stm.create_claimed_account(new_account_name, creator='[account creator]', password=password))
time.sleep(4)
new_account = Account(new_account_name)
new_account.print_info()
print('CREATED')
else:
print ('Passwords are different please re-try')
password_()
stm = Steem("https://anyx.io",keys='')#insert hive private active key
set_shared_steem_instance(stm)
account=Account("[YOUR ACCOUNT NAME]",steem_instance=stm)
new_account_name=name()
password_()
stm=0
stm = Steem("https://api.steemit.com",keys='')#insert steem private active key
set_shared_steem_instance(stm)
account=Account("[YOUR ACCOUNT NAME]",steem_instance=stm)
new_account_name=name()
password_()
This is the repo on github: https://github.com/digital-mine/steem-and-hive-account-creator
Amazing way to create an account. Easy and effortless. Thanks for sharing the code. We are looking for people like you in our platform
Your post has been curated with @gitplait community account because this is the kind of publications we like to see in our community.
Join our Community on Hive and Chat with us on
Thank you