Skip to content

Custom middleware

szymonkorytnicki edited this page Jul 18, 2018 · 1 revision

By default, chatblocks sends your requests directly to Facebook using request-promise. If you want to handle them on your own, we provide middleware option in Bot constructor.

Middleware is a function receiving blocks, page acccess token, facebook API version and sender id.

Clone this wiki locally