No EthTransactions in dashboard

Hello, could someone help me, please? I looked at the video Connecting Hardhat to Moralis, and I did everything like in the video, but I still can’t get the “EthTransactions” in the dashboard. Is it maybe a bug or do I need to do something more to make “EthTransactions” appear?

Server domain:
https://pyrvtjppbg7i.usemoralis.com:2053/server

2 Likes

Hi @Markus-55

Nice to see you again :slight_smile:

You can check docs for getting started : https://docs.moralis.io/moralis-server/connect-the-sdk

If you are using vanilla JS or react js code snippet exist for both

Also let me know what you are using.

And in which file you are importing moralis lib

1 Like

Hi Taha, Thanks nice to see you too!
I’m using vanilla js on mac, importing the SDK code in html and connecting to Moralis server in js.

<script src="https://cdn.jsdelivr.net/npm/web3@latest/dist/web3.min.js"></script>
<script src="https://unpkg.com/moralis/dist/moralis.js"></script>

I authenticate the user and then I query for the EthTransactions

async function listenForUpdates() {
  let query = new Moralis.Query("EthTransactions")
  let subscription = await query.subscribe();

  subscription.on("create", (object) => {
    console.log("object created");
    console.log(object);
  });
}
listenForUpdates();

I’m connecting with the npx hardhat node and also connecting to the Devchain proxy server.

if you look in your admin dashboard you see your server as being connected with the proxy?

Yes, it is connected, I also refreshed and still connected

and you have transactions with that address that you authenticated?

can you also try with ganache?

1 Like

Yes, I mean I can authenticate without any problem and send eth from the authenticated address to another address, is that what you meant?

Yes sure, I will try that too

You can also try to delete this server and create another one, that is indicated if you start again from block 0 with the local dev chain

Yes I did that a few times, but there was no difference.

I tried with ganache now and I got a transaction when sending from one address to other

But I still can’t get anything with hardhat

And also the EthTransactions is still not there in dashboard
22afe0ac248207ddfd69ab3a3f442b2f

You can see the transaction on the server too?

Do you mean, if I output it in the console like this?

const transactions = await Moralis.Web3API.account.getTransactions();
console.log(transactions);

Then I get 0 transactions using ganache address, that I also authenticated with
7d5a9436b0186b0afe4d2655ebef6c2e

Web3api doesn’t work with local dev chain.
I mean in the dashboard on the server if that transaction was present.

1 Like

I cannot see any transaction in the dashboard, if it is what you mean

What is the server url where ganache was connected?

I’m using the same server url:
https://pyrvtjppbg7i.usemoralis.com:2053/server

Can you try with a new server then and with ganache?

1 Like

It works now, Thanks a lot @cryptokid! The EthTransactions appeared in the Dashboard and I have the transactions from both Ganache and Hardhat in server.

I made 2 or 3 servers before, tried to use hardhat as proxy server and there was still no EthTransactions in the dashboard, but now when I used ganache in a new server, It works perfectly.

2 Likes