Interact with Contracts through JS

Hello, new to Moralis. I followed the tutorial, creating my basic html file and moralis js file with functions. Trying to interact with the mint function from my token contract. I can login and out of Metamask but when I hit the send button I get this error message.

js code:
`// connect to Moralis server
const serverUrl = “https://pbblhhajgpzo.usemoralis.com:2053/server”;
const appId = “Wbj56pqggKjgxMscXtwspYjJpO1JBBdLznoacFvO”;
Moralis.start({ serverUrl, appId });

// LOG IN WITH METAMASK
async function login() {
let user = Moralis.User.current();
if (!user) {
try {
user = await Moralis.authenticate({ signingMessage: “Authenticate” })
await Moralis.enableWeb3();
console.log(user)
console.log(user.get(‘ethAddress’))
} catch (error) {
console.log(error)
}
}
}

async function logOut() {
await Moralis.User.logOut();
console.log(“logged out”);
}

async function mint() {
const web3 = await Moralis.enable();
let options = {
contractAddress: ‘0x0x6634c175D94696ff0067B57551A87A1a3419449fdb7fAB4d8114a439Ccc0c4eCE68bf1DaED3B7b04’,
functionName: ‘mint’,
abi:[
{
“constant”: false,
“inputs”: [
{
“internalType”: “uint256”,
“name”: “amount”,
“type”: “uint256”
}
],
“name”: “mint”,
“outputs”: [
{
“internalType”: “bool”,
“name”: “”,
“type”: “bool”
}
],
“payable”: false,
“stateMutability”: “nonpayable”,
“type”: “function”
},
],

    params: {
        amount:""
    },

};

await Moralis.executeFunction(options);

}
// bind button click handlers
document.getElementById(“btn-login”).onclick = login;
document.getElementById(“btn-logout”).onclick = logOut;
document.getElementById(“btn-mint”).onclick = mint;
``

Send BNB

Mint Tokens

<button type ="button" class="btn btn-primary" id="btn-login">Connect Wallet</button>
<button type ="button" class="btn btn-danger" id="btn-logout">Logout</button>
<br>
<br>
<button type ="button" class="btn btn-success" id=”btn-send”>Mint</button>
<script type="text/javascript" src="./main.js"></script>
```

In your html code, you have your mint button <button type ="button" class="btn btn-success" id=”btn-send”>Mint</button> with an Id of btn-send, but in your javascript file, you’re calling another element document.getElementById(“btn-mint”).onclick = mint; with Id btn-mint which does not exist.

So you’ll have to make sure both Ids are the same.

Oh my goodness how did I miss that! Thank you! I made the correction but still receiving the same error. Am I missing some code or something? I’m new to this so any help is appreciated.

Seems you’re using an Invalid contract address