I tried the Hooks API docs but it’s not working:
// app/plugins/payu/server/register.js
module.exports = ({ strapi }) => {
strapi.createHook('payu/transaction-success');
};
Which failed with
[2022-04-20 17:31:49.870] error: strapi.createHook is not a function
I assume this is an old doc. How to do it in v4?
EDIT:
I’m now reading this - https://strapi.io/blog/understanding-the-different-types-categories-of-strapi-hooks but I’m not really getting it…