feathersjs-ecosystem/feathers-authentication-management

how to pass hook data to the notifier

Closed this issue · 2 comments

I have a unique situation where I am managing authentication for several subdomains from a single codebase. In my notifier.js code I call an external API that handles the transactional communications.

I want to be able to pass this external service the subdomain and / or anything else I inject with a hook.

Is there a way I can get access to the hook or pass in the subdomain data to the notifier?

The notifier is called with

notifier(options.notifier, 'resendVerifySignup', user, notifierOptions)

The notifierOptions is passed from the call to the service

authManagement.create({ notifierOptions: ... }

That would be the way to pass custom values to the notifier.

Brilliant, that solves that.
Cheers