def create_account(self, account_name, creator=None, owner_key=None, active_key=None, memo_key=None, posting_key=None, password=None, additional_owner_keys=[], additional_active_keys=[], additional_posting_keys=[], additional_owner_accounts=[], additional_active_accounts=[], additional_posting_accounts=[], storekeys=True, store_owner_key=False, json_meta=None, **kwargs):
    " Create new account on Crea\n\n            The brainkey/password can be used to recover all generated keys\n            (see :class:`creagraphenebase.account` for more details.\n\n            By default, this call will use ``default_account`` to\n            register a new name ``account_name`` with all keys being\n            derived from a new brain key that will be returned. The\n            corresponding keys will automatically be installed in the\n            wallet.\n\n            .. warning:: Don't call this method unless you know what\n                          you are doing! Be sure to understand what this\n                          method does and where to find the private keys\n                          for your account.\n\n            .. note:: Please note that this imports private keys\n                      (if password is present) into the wallet by\n                      default when nobroadcast is set to False.\n                      However, it **does not import the owner\n                      key** for security reasons by default.\n                      If you set store_owner_key to True, the\n                      owner key is stored.\n                      Do NOT expect to be able to recover it from\n                      the wallet if you lose your password!\n\n            .. note:: Account creations cost a fee that is defined by\n                       the network. If you create an account, you will\n                       need to pay for that fee!\n\n            :param str account_name: (**required**) new account name\n            :param str json_meta: Optional meta data for the account\n            :param str owner_key: Main owner key\n            :param str active_key: Main active key\n            :param str posting_key: Main posting key\n            :param str memo_key: Main memo_key\n            :param str password: Alternatively to providing keys, one\n                                 can provide a password from which the\n                                 keys will be derived\n            :param array additional_owner_keys:  Additional owner public keys\n            :param array additional_active_keys: Additional active public keys\n            :param array additional_posting_keys: Additional posting public keys\n            :param array additional_owner_accounts: Additional owner account\n                names\n            :param array additional_active_accounts: Additional acctive account\n                names\n            :param bool storekeys: Store new keys in the wallet (default:\n                ``True``)\n\n            :param str creator: which account should pay the registration fee\n                                (defaults to ``default_account``)\n            :raises AccountExistsException: if the account already exists on\n                the blockchain\n\n        "
    if ((not creator) and config['default_account']):
        creator = config['default_account']
    if (not creator):
        raise ValueError(('Not creator account given. Define it with ' + 'creator=x, or set the default_account using creapy'))
    if (password and (owner_key or active_key or memo_key)):
        raise ValueError("You cannot use 'password' AND provide keys!")
    try:
        Account(account_name, crea_instance=self)
        raise AccountExistsException
    except AccountDoesNotExistsException:
        pass
    creator = Account(creator, crea_instance=self)
    ' Generate new keys from password'
    from creagraphenebase.account import PasswordKey
    if password:
        active_key = PasswordKey(account_name, password, role='active', prefix=self.prefix)
        owner_key = PasswordKey(account_name, password, role='owner', prefix=self.prefix)
        posting_key = PasswordKey(account_name, password, role='posting', prefix=self.prefix)
        memo_key = PasswordKey(account_name, password, role='memo', prefix=self.prefix)
        active_pubkey = active_key.get_public_key()
        owner_pubkey = owner_key.get_public_key()
        posting_pubkey = posting_key.get_public_key()
        memo_pubkey = memo_key.get_public_key()
        active_privkey = active_key.get_private_key()
        posting_privkey = posting_key.get_private_key()
        owner_privkey = owner_key.get_private_key()
        memo_privkey = memo_key.get_private_key()
        try:
            if (storekeys and (not self.nobroadcast)):
                if store_owner_key:
                    self.wallet.addPrivateKey(str(owner_privkey))
                self.wallet.addPrivateKey(str(active_privkey))
                self.wallet.addPrivateKey(str(memo_privkey))
                self.wallet.addPrivateKey(str(posting_privkey))
        except ValueError as e:
            log.info(str(e))
    elif (owner_key and active_key and memo_key and posting_key):
        active_pubkey = PublicKey(active_key, prefix=self.prefix)
        owner_pubkey = PublicKey(owner_key, prefix=self.prefix)
        posting_pubkey = PublicKey(posting_key, prefix=self.prefix)
        memo_pubkey = PublicKey(memo_key, prefix=self.prefix)
    else:
        raise ValueError('Call incomplete! Provide either a password or public keys!')
    owner = format(owner_pubkey, self.prefix)
    active = format(active_pubkey, self.prefix)
    posting = format(posting_pubkey, self.prefix)
    memo = format(memo_pubkey, self.prefix)
    owner_key_authority = [[owner, 1]]
    active_key_authority = [[active, 1]]
    posting_key_authority = [[posting, 1]]
    owner_accounts_authority = []
    active_accounts_authority = []
    posting_accounts_authority = []
    for k in additional_owner_keys:
        owner_key_authority.append([k, 1])
    for k in additional_active_keys:
        active_key_authority.append([k, 1])
    for k in additional_posting_keys:
        posting_key_authority.append([k, 1])
    for k in additional_owner_accounts:
        addaccount = Account(k, crea_instance=self)
        owner_accounts_authority.append([addaccount['name'], 1])
    for k in additional_active_accounts:
        addaccount = Account(k, crea_instance=self)
        active_accounts_authority.append([addaccount['name'], 1])
    for k in additional_posting_accounts:
        addaccount = Account(k, crea_instance=self)
        posting_accounts_authority.append([addaccount['name'], 1])
    props = self.get_chain_properties()
    if (self.hardfork >= 20):
        required_fee_crea = Amount(props['account_creation_fee'], crea_instance=self)
    else:
        required_fee_crea = (Amount(props['account_creation_fee'], crea_instance=self) * 30)
    op = {'fee': required_fee_crea, 'creator': creator['name'], 'new_account_name': account_name, 'owner': {'account_auths': owner_accounts_authority, 'key_auths': owner_key_authority, 'address_auths': [], 'weight_threshold': 1}, 'active': {'account_auths': active_accounts_authority, 'key_auths': active_key_authority, 'address_auths': [], 'weight_threshold': 1}, 'posting': {'account_auths': posting_accounts_authority, 'key_auths': posting_key_authority, 'address_auths': [], 'weight_threshold': 1}, 'memo_key': memo, 'json_metadata': (json_meta or {}), 'prefix': self.prefix}
    op = operations.Account_create(**op)
    return self.finalizeOp(op, creator, 'active', **kwargs)
Create new account on Crea

The brainkey/password can be used to recover all generated keys
(see :class:`creagraphenebase.account` for more details.

By default, this call will use ``default_account`` to
register a new name ``account_name`` with all keys being
derived from a new brain key that will be returned. The
corresponding keys will automatically be installed in the
wallet.

.. warning:: Don't call this method unless you know what
              you are doing! Be sure to understand what this
              method does and where to find the private keys
              for your account.

.. note:: Please note that this imports private keys
          (if password is present) into the wallet by
          default when nobroadcast is set to False.
          However, it **does not import the owner
          key** for security reasons by default.
          If you set store_owner_key to True, the
          owner key is stored.
          Do NOT expect to be able to recover it from
          the wallet if you lose your password!

.. note:: Account creations cost a fee that is defined by
           the network. If you create an account, you will
           need to pay for that fee!

:param str account_name: (**required**) new account name
:param str json_meta: Optional meta data for the account
:param str owner_key: Main owner key
:param str active_key: Main active key
:param str posting_key: Main posting key
:param str memo_key: Main memo_key
:param str password: Alternatively to providing keys, one
                     can provide a password from which the
                     keys will be derived
:param array additional_owner_keys:  Additional owner public keys
:param array additional_active_keys: Additional active public keys
:param array additional_posting_keys: Additional posting public keys
:param array additional_owner_accounts: Additional owner account
    names
:param array additional_active_accounts: Additional acctive account
    names
:param bool storekeys: Store new keys in the wallet (default:
    ``True``)

:param str creator: which account should pay the registration fee
                    (defaults to ``default_account``)
:raises AccountExistsException: if the account already exists on
    the blockchain
def create_account(self, account_name, creator=None, owner_key=None, active_key=None, memo_key=None, posting_key=None, password=None, additional_owner_keys=[], additional_active_keys=[], additional_posting_keys=[], additional_owner_accounts=[], additional_active_accounts=[], additional_posting_accounts=[], storekeys=True, store_owner_key=False, json_meta=None, **kwargs):
    " Create new account on Crea\n\n            The brainkey/password can be used to recover all generated keys\n            (see :class:`creagraphenebase.account` for more details.\n\n            By default, this call will use ``default_account`` to\n            register a new name ``account_name`` with all keys being\n            derived from a new brain key that will be returned. The\n            corresponding keys will automatically be installed in the\n            wallet.\n\n            .. warning:: Don't call this method unless you know what\n                          you are doing! Be sure to understand what this\n                          method does and where to find the private keys\n                          for your account.\n\n            .. note:: Please note that this imports private keys\n                      (if password is present) into the wallet by\n                      default when nobroadcast is set to False.\n                      However, it **does not import the owner\n                      key** for security reasons by default.\n                      If you set store_owner_key to True, the\n                      owner key is stored.\n                      Do NOT expect to be able to recover it from\n                      the wallet if you lose your password!\n\n            .. note:: Account creations cost a fee that is defined by\n                       the network. If you create an account, you will\n                       need to pay for that fee!\n\n            :param str account_name: (**required**) new account name\n            :param str json_meta: Optional meta data for the account\n            :param str owner_key: Main owner key\n            :param str active_key: Main active key\n            :param str posting_key: Main posting key\n            :param str memo_key: Main memo_key\n            :param str password: Alternatively to providing keys, one\n                                 can provide a password from which the\n                                 keys will be derived\n            :param array additional_owner_keys:  Additional owner public keys\n            :param array additional_active_keys: Additional active public keys\n            :param array additional_posting_keys: Additional posting public keys\n            :param array additional_owner_accounts: Additional owner account\n                names\n            :param array additional_active_accounts: Additional acctive account\n                names\n            :param bool storekeys: Store new keys in the wallet (default:\n                ``True``)\n\n            :param str creator: which account should pay the registration fee\n                                (defaults to ``default_account``)\n            :raises AccountExistsException: if the account already exists on\n                the blockchain\n\n        "
    if ((not creator) and config['default_account']):
        creator = config['default_account']
    if (not creator):
        raise ValueError(('Not creator account given. Define it with ' + 'creator=x, or set the default_account using creapy'))
    if (password and (owner_key or active_key or memo_key)):
        raise ValueError("You cannot use 'password' AND provide keys!")
    try:
        Account(account_name, crea_instance=self)
        raise AccountExistsException
    except AccountDoesNotExistsException:
        pass
    creator = Account(creator, crea_instance=self)
    ' Generate new keys from password'
    from creagraphenebase.account import PasswordKey
    if password:
        active_key = PasswordKey(account_name, password, role='active', prefix=self.prefix)
        owner_key = PasswordKey(account_name, password, role='owner', prefix=self.prefix)
        posting_key = PasswordKey(account_name, password, role='posting', prefix=self.prefix)
        memo_key = PasswordKey(account_name, password, role='memo', prefix=self.prefix)
        active_pubkey = active_key.get_public_key()
        owner_pubkey = owner_key.get_public_key()
        posting_pubkey = posting_key.get_public_key()
        memo_pubkey = memo_key.get_public_key()
        active_privkey = active_key.get_private_key()
        posting_privkey = posting_key.get_private_key()
        owner_privkey = owner_key.get_private_key()
        memo_privkey = memo_key.get_private_key()
        try:
            if (storekeys and (not self.nobroadcast)):
                if store_owner_key:
                    self.wallet.addPrivateKey(str(owner_privkey))
                self.wallet.addPrivateKey(str(active_privkey))
                self.wallet.addPrivateKey(str(memo_privkey))
                self.wallet.addPrivateKey(str(posting_privkey))
        except ValueError as e:
            log.info(str(e))
    elif (owner_key and active_key and memo_key and posting_key):
        active_pubkey = PublicKey(active_key, prefix=self.prefix)
        owner_pubkey = PublicKey(owner_key, prefix=self.prefix)
        posting_pubkey = PublicKey(posting_key, prefix=self.prefix)
        memo_pubkey = PublicKey(memo_key, prefix=self.prefix)
    else:
        raise ValueError('Call incomplete! Provide either a password or public keys!')
    owner = format(owner_pubkey, self.prefix)
    active = format(active_pubkey, self.prefix)
    posting = format(posting_pubkey, self.prefix)
    memo = format(memo_pubkey, self.prefix)
    owner_key_authority = [[owner, 1]]
    active_key_authority = [[active, 1]]
    posting_key_authority = [[posting, 1]]
    owner_accounts_authority = []
    active_accounts_authority = []
    posting_accounts_authority = []
    for k in additional_owner_keys:
        owner_key_authority.append([k, 1])
    for k in additional_active_keys:
        active_key_authority.append([k, 1])
    for k in additional_posting_keys:
        posting_key_authority.append([k, 1])
    for k in additional_owner_accounts:
        addaccount = Account(k, crea_instance=self)
        owner_accounts_authority.append([addaccount['name'], 1])
    for k in additional_active_accounts:
        addaccount = Account(k, crea_instance=self)
        active_accounts_authority.append([addaccount['name'], 1])
    for k in additional_posting_accounts:
        addaccount = Account(k, crea_instance=self)
        posting_accounts_authority.append([addaccount['name'], 1])
    props = self.get_chain_properties()
    if (self.hardfork >= 20):
        required_fee_crea = Amount(props['account_creation_fee'], crea_instance=self)
    else:
        required_fee_crea = (Amount(props['account_creation_fee'], crea_instance=self) * 30)
    op = {'fee': required_fee_crea, 'creator': creator['name'], 'new_account_name': account_name, 'owner': {'account_auths': owner_accounts_authority, 'key_auths': owner_key_authority, 'address_auths': [], 'weight_threshold': 1}, 'active': {'account_auths': active_accounts_authority, 'key_auths': active_key_authority, 'address_auths': [], 'weight_threshold': 1}, 'posting': {'account_auths': posting_accounts_authority, 'key_auths': posting_key_authority, 'address_auths': [], 'weight_threshold': 1}, 'memo_key': memo, 'json_metadata': (json_meta or {}), 'prefix': self.prefix}
    op = operations.Account_create(**op)
    return self.finalizeOp(op, creator, 'active', **kwargs)