2017-05-27 25 views
0

提交我特林我的演示机器人连接到冰通道,通过我得到一个错误:冰通道进行审核错误

Your bot did not respond to our Ping request with a success code. Please verify your bot is running and responsive before Publishing your bot. The error received from your bot was: InternalServerError(500), Internal Server Error

我所有的其他通道工作的罚款:(Skype公司,脸谱,电报,直达专线)。

回答

0

机器人应该以http状态200响应Ping。如果机器人用消息响应Ping或不响应状态200,某些通道将记录异常。

C#例如:

public async Task<HttpResponseMessage> Post([FromBody]Activity activity) 
{ 
    if (activity.GetActivityType() == ActivityTypes.Message) 
    { 
     await Conversation.SendAsync(activity,() => new Dialogs.RootDialog()); 
    } 
    else if (activity.GetActivityType() == ActivityTypes.Ping) 
    { 
     //Do nothin with Ping. Return .OK status below 
    } 

    return Request.CreateResponse(HttpStatusCode.OK); 
}