throw new Error('bot.startConversationWithUser(): missing serviceUrl.');

40 Views Asked by At
controller.hears('dm me', 'message', async(bot, message) => {
        await bot.startConversationWithUser(message.reference);
        await bot.say('Hello! (in private)');
    });

I'm using botkit to send message on Slack but I'm getting this error

throw new Error('bot.startConversationWithUser(): missing serviceUrl.');
                      ^

Error: bot.startConversationWithUser(): missing serviceUrl.
    at SlackBotWorker

I tried console.log(message.reference), its showing me serviceUrl: undefined

0

There are 0 best solutions below