zahmis 5 years ago
parent
commit
fafb9f7f4e
1 changed files with 2 additions and 1 deletions
  1. 2 1
      packages/slackbot-proxy/src/controllers/slack.ts

+ 2 - 1
packages/slackbot-proxy/src/controllers/slack.ts

@@ -1,3 +1,4 @@
+import { SlashCommand } from '@slack/bolt';
 import {
   BodyParams, Controller, Get, Inject, Post, Req, Res,
 } from '@tsed/common';
@@ -58,7 +59,7 @@ export class SlackCtrl {
   }
 
   @Post('/events')
-  handleEvent(@BodyParams() body:{[key:string]:string}, @Res() res: Res): string {
+  handleEvent(@BodyParams() body:SlashCommand, @Res() res: Res): string {
     // Send response immediately to avoid opelation_timeout error
     // See https://api.slack.com/apis/connections/events-api#the-events-api__responding-to-events