Reinstate ability to register an endpoint
At one point it was possible to register an endpoint (route) to handle incoming requests. One common usage for this is to register a callback URL for payment systems like Paypal that use a token. Another would be when creating webhooks. It's possible this capability exists and I have not been able to find it but I believe it was removed during DeMeteorization.
@zenweasel This is still available and for example in use here:
https://github.com/reactioncommerce/api-plugin-sitemap-generator/blob/88c9e71d62c096ab182bf7a101ff4bae315d7e44/src/startup.js#L19
However, similar to the considerations in https://github.com/reactioncommerce/reaction/issues/6279 defining these routes during runtime, while very flexible, is not optimal for a more distributed architecture - I would favor having them defined as part of the plug-in registration.
Thanks for the info @janus-reith but it's not quite what I am talking about as that is just utilizing the underlying express app. (also a legitimate thing to do)
At one point you could actually register an endpoint via plugin registration like here so that's more what I was talking about
Thanks for the info @janus-reith but it's not quite what I am talking about as that is just utilizing the underlying express app. (also a legitimate thing to do)
At one point you could actually register an endpoint via plugin registration like here so that's more what I was talking about
@zenweasel link goes to 404 error, I really need the example=)
@zenweasel This is still available and for example in use here:
https://github.com/reactioncommerce/api-plugin-sitemap-generator/blob/88c9e71d62c096ab182bf7a101ff4bae315d7e44/src/startup.js#L19
However, similar to the considerations in #6279 defining these routes during runtime, while very flexible, is not optimal for a more distributed architecture - I would favor having them defined as part of the plug-in registration.
@janus-reith This one works, thanks.