Creating off chain calculation trigger

does solidity support hook ?

like every block or every day

1 Like

Hook? maybe not, but for some tokens, it supports, such as ERC777

1 Like

Hi @wade-liwei,

Other than ERC777 hooks (:pray: @Skyge), the only other hook I can think of is in OpenZeppelin Contracts:

Such as beforeTokenTransfer.

Is that what you meant?

no,

I hope trigger the calculation everyday.

1 Like

Hi @wade-liwei,

If you want to call a function every day you could use Defender Autotasks: https://docs.openzeppelin.com/defender/autotasks

got it.

right now, I want to implement auto task from off chain by myself.

1 Like

Hi @wade-liwei,

I would suggest trying out Defender Autotasks on a public testnet before building it out yourself.