0

I want to change the public key to email and the private key to password with javascript, Does anyone have an idea of how it works, please?

`

const fs = require ('fs')
const stellar = require('stellar-sdk')


const fileName= "accounts.json"

fs.writeFileSync(
    fileName,
    JSON.stringify(
        ["Alice","Bob"].map(name =>{
            const pair=stellar.Keypair.random();

            return{
                name,
                secret: pair.secret(),
                publicKey: pair.publicKey()
            }

            
        })
    )
)

`

Sophia
  • 11
  • 2

0 Answers0