Sync and watch address with event

I have been following this tutorial.


Main bridge smart contract is emitting the event. Refer the transaction.

I have configured Sync and Watch Contract Events in moralis admin page.

But the sync is not happening in dashboard as well as the code after the event, is not executing because of this. how to solve

You have to use uint256 instead of uint in topic

Changed it, not solved.
thanks for swift support.

you can use the topic in the form of topic0 hash that you find in the block explorer

you can also paste the server url

This is the topic hash.

  • 0 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef
  • 1 0x0000000000000000000000007a717e1b64a6a3069fdadba4ccf5f9d0933f73da
  • 2 0x0000000000000000000000007e327cadc2857ff300538d93bfab0584ee569bf0

this is the server url

Can you format it and where do i paste? in topic field?

You paste directly that hash for topic0 for the entire topic field, it has to be only that sting that is a hash

I can look a little later at the server.
You can try to update it in case that it isn’t latest version.

hash of topic 0 Pasted in entire topic field,

not solved.

server is updated one 0.0.359.

I tried to fix that event, didn’t manage to do it, it looks like the transaction that you pasted is from a different smart contract, after changing the address to the one from that event it looks like the abi is not the correct one

Hi cryptokid.
It solved. I have started the process from zero. and the event sync is working now. I think the problem was with ABI.

I have a new issue. the process should be started in after save function in cloud. even though the transfer happens in dapp, control never reach aftersave function. Note i am logging it but the message did not come. What could be the reason?
Thank you

Moralis.Cloud.afterSave(“ETHTokenTransfers”, (request) => {“inside cloud.aftersave”);
const data = JSON.parse(JSON.stringify(request.object, [“token_address”, “to_address”, “from_address”,“transaction_hash”,“value”, “confirmed”]));;
if (data[“token_address”] == mainToken_address.toLocaleLowerCase() && data[“to_address”] == MainBridge_address.toLocaleLowerCase() && !data[“confirmed”]) {
const txlock = processBridgeRequestLock(data);
const txbridge = processBridgeRequestBridge(data);
else{“transaction not related to bridge”);

Same here. Seems like the object property is inaccessible"EthTokenTransfers");`Request: ${JSON.stringify(request)}`);`Request object: ${JSON.stringify(request.object)}`);`Token Address: ${request.object.token_address}`);`To Address: ${request.object.to_address}`);

Cant seems to access request.object.

Request.object seems to work.

You may need to use a different syntax to access its keys/values. You can try .get and [] also

I tried request.object[“token_address”] and it is still undefined. Let me try with .get