passport-facebook: how to dynamically set callbackURL?

I'm following this example to setup a FacebookStrategy - https://github.com/jaredhanson/passport-facebook/blob/master/examples/login/app.js

I want to set the callbackURL dynamically, ie: the user access /posts/34 so the callback will be /posts/34/callback

how can I achieve something like this ?

I found the solution, both the auth redirect route and the callback route should wrap passport.authenticate() with function(req, res, next).

I followed the example in http://passportjs.org/guide/authenticate/ for custom callback

and the comments in https://github.com/jaredhanson/passport-facebook/issues/2 for custom callbackURL