ACE addon.authenticateInstall() is not working

Hello,
While developing with ACE, I was looking at the JWT status because the install/uninstall lifecycles were not working properly.
understanding-jwt-for-connect-apps
I was proceeding as shown in the green area here and a readme file for nodejs was shared here.
atlassian-bitbucket
How to secure an installation callback route with JWT
Install/Uninstall hooks are authenticated through asymmetric JWT. You can simply add an ACE authenticateInstall middleware to your custom install or uninstall lifecycle route:

module.exports = function(app, addon) {
app.post(
'/uninstalled',

// Protect this install callback resource with asymmetric JWT
addon.authenticateInstall(),

function(req, res) {
res.status(204).send();
}
);
};

Here, when I try to use this in my own code, I get the
TypeError: addon.authenticateInstall is not a function error.
What could be the reason for this?
My Node version is v18.20.4