[英]How to solve 'The parameter subscribed_fields is required ' curl -x post command error, for creating a facebook chatbot using node.js and heroku?
Heroku worked successfully , facebook page and app was created, webhook setup. Heroku工作成功,创建了Facebook页面和应用程序,并安装了Webhook。 But to allow chatbot to send / receive messages , curl command -x POST was used on terminal prompt - graph.api v3.2 , But throws an error stating It requires subscribed fields.
但是,为了允许chatbot发送/接收消息,在终端提示符-graph.api v3.2上使用了curl命令-x POST,但是抛出错误,指出它需要订阅的字段。
v3.2 is current, do I use some other version perhaps where sub fields are not required? v3.2是最新版本,是否在不需要子字段的地方使用其他版本? I tried 2.6-2.11 till 3.2 .
我尝试了2.6-2.11到3.2。 None of it works, throws undefined errors to sub field require errors.
它们都不起作用,将未定义的错误抛出到需要错误的子字段。
curl -X POST " https://graph.facebook.com/v3.2/me/subscribed_apps?access_token=(here I put my page token id)" curl -X POST“ https://graph.facebook.com/v3.2/me/subscribed_apps?access_token=(在这里放入页面令牌ID)”
Expecting an output saying - Successful True 期待输出说-成功True
subscribed_fields
just is a required parameter, so you can not subscribe an app for updates from a page without specifying which fields you want updates for. subscribed_fields
只是必填参数,因此,如果不指定要更新的字段,则无法从页面订阅应用程序以进行更新。
Documentation says type is an array of predefined keywords, so you should be able to subscribe to multiple fields in one request using subscribed_fields={field1,field2,...}
文档说类型是一组预定义的关键字,因此您应该能够使用
subscribed_fields={field1,field2,...}
在一个请求中subscribed_fields={field1,field2,...}
多个字段
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.