KMD wallet list

I created a wallet/account on my own node using goal. When I query my kmd endpoint to get a list of wallets, it returns the array as undefined. I was expecting to see the wallet I created using goal, but now I am not sure how to access that wallet from my js code?

Can you provide the code snippet you use in Javascript, the error returned if any, as well as the output of goal wallet list?
Are you sure you are connected to the correct kmd?
Do you see the wallets using https://developer.algorand.org/solutions/algorand-wallet-manager-manage-your-own-wallets-graphic-interface/?

const algosdk = require('algosdk');

// kmd endpoint + api key
const kmdToken = "<api-key>";
const kmdServer = algodServer;
const kmdPort = 7833;

const kmdClient = new algosdk.Kmd(kmdToken, kmdServer, kmdPort);

(async () => {

    try {

        let wallets = (await kmdClient.listWallets().wallets);

        console.log ("wallets => %s", wallets);

    } catch(e) {
        console.error(e);
    }

})(); // output is 'wallets => undefinded'

The output of ‘goal wallet list’ is

##################################################
Wallet: main (default)
ID:     2e7e23602ec6df454958...
##################################################

Your issue is that await is misplaced. It should be:

let wallets = (await kmdClient.listWallets()).wallets;