Uncaught ReferenceError: serverUrl is not defined but i notice on the same page when you guys are giving out the intial code snippets to add to the html document there was no reference to Moralis.start({ serverUrl, appId });

  1. I was trying the 5 minute dapp tutorial and after Build a Simple dApp in 3 Mins - Historical Transactions (Part 3) i keep getting this error referenced on this line Moralis.start({ serverUrl, appId }); that says
    Uncaught ReferenceError: serverUrl is not defined but i notice on the same page when you guys are giving out the intial code snippets to add to the html document there was no reference to
    Moralis.start({ serverUrl, appId }); but in the last section when you guys show how the completed document should look that snippet is added when i remove the snippet the code works but when added i get an error.

  2. i also thought once i logged in i would show up in the dashboard but i didnt see my info anywhere im really new to coding and crypto i downloaded the metamask wallet and installed it i know theres a public address and private key but when using the metamask i cant really tell which is which

Moralis.start is a new syntax that was introduced more recently, https://docs.moralis.io/moralis-server/getting-started/connect-the-sdk#main.js-1
with latest Moralis SDK version you will need to use Moralis.start syntax.

When using metamask you usually see only an address that it is extracted from the public key, you donโ€™t see neither the public key or private key, but you could export the private key if you wanted

it may be something in the code that didnโ€™t make the dashboard appear after login, you can look in your browser console to see if there are any errors

the moralis start syntax is the error when i remove it everything works when added it keeps throwing and errors for some strange reason i removed it and logged in to metamask and the user showed up

What version of Moralis sdk are you using?

im not quite sure i just logged in and started doing a 5 min project to test a few thing out i didnt notice any version specifications


i also had another question in regards to the coin price api moralis just added can you point in the direction of how to just get a 100 or so coins including metadata instead of manually entering a coin at a time

Moralis SDK version will be specified in you html header, for example you may have something like this for latest version: <script src="https://unpkg.com/moralis/dist/moralis.js"></script>

I think that youโ€™ll have to query one coin at a time for now in order to get its price.

this is my html document i litraly just copied and paste the html document then created the main.js file and did the same thing.

so the nft queries is the same procedure as the coins then 1 at a time?

you can also get all owners for a specific NFT contract if you are interested only in a specific contract.

from that html it looks like you are using latest Moralis SDK version, that syntax with Moralis.start should work for you.

or you can get all NFTs for an address: https://docs.moralis.io/moralis-server/web3-sdk/account#getnfts

man sorry if im asking a lot of questions im a big fan of this moralis thing im just trying to learn as much possible about it so to implement the coins or nft data i would have to create a search bar for users to to type in specific information to get a response its not able to display multiple nfts or coins in ui