[Python] 12 words tonkeeper wallet

Discussão em 'Python' iniciado por Stack, Abril 9, 2025.

  1. Stack

    Stack Membro Participativo

    Why can't the script generate an address from a 12-word mnemonic as in tonKeeper? I take into account the type and format of the address. The code itself

    import tonutils.wallet.data

    from tonutils.client import TonapiClient
    from tonutils.wallet import WalletV3R1

    API_KEY = ""
    IS_TESTNET = False

    def tonkeeper():
    client = TonapiClient(api_key=API_KEY, is_testnet=IS_TESTNET)
    wallet, public_key, private_key, mnemonic = WalletV3R1.from_mnemonic(client=client,mnemonic='all all all all all all all all all all all all')
    print("Wallet has been successfully created!")
    print(f"Address: {wallet.address.to_str()}")
    print(f"Mnemonic: {mnemonic}")
    tonkeeper()


    The expected address is EQDo1-d2nIWaZ-BCKqC47PzMu3MZzAKYN_7RZDEYPv04WaJm
    The address I get is EQA3Wx97dYZC7mKa8J2kYC8r_tb6Ze0CIuuVUjXMyyyyvp04G
    Version - V3R1
    Although this code correctly generates addresses from mnemonic phrases of 24 words
    Also I will be grateful for any working examples in js, as the situation is similar there

    Continue reading...

Compartilhe esta Página