I want to send an onboarding flow to the user when they add the app to their slack. And, I am using slack bolt.
I tried using callbackOptions, but I get this error:
res is not a function
Here is the code that I tried:
callbackOptions: {
success: (installation, installOptions, req, res) => {
// Do custom success logic here
res.send('successful!');
},
failure: (error, installOptions , req, res) => {
// Do custom failure logic here
res.send('failure');
}
}
How can I make it work, or is there any other option to achieve this?