How to create a hook from a plugin

I tried the Hooks API docs but it’s not working:

// app/plugins/payu/server/register.js
module.exports = ({ strapi }) => {

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?

I’m now reading this - but I’m not really getting it…

I hoped there is a way to create a custom event (like in the link to the docs above), but I couldn’t find anything. Hooking to the update content type lifecycle is enough for my case, It just feels like a workaround