从postman里面可以看到结果,返回的结果如下所示:
{"data":"{\"err_msg\":\"正确\",\"err_code\":0}","lifespan":86400,"query":"{\"type\":1000015,\"items\":[{\"city\":\"济南市\",\"district\":\"历下区\",\"houses\":\"名悦山庄\"},{\"city\":\"郑州市\",\"district\":\"郑州高新技术产业开发区\",\"houses\":\"金地名悦\"}]}","scene":1}
微信公众号:appid:wxd0002dae3cf14818
小程序的appid:wxa0e19ee2500465ac
接口:http://api.fyouyou.com/newhouse/uufdForWx/listByTtile?title=%E5%90%8D%E6%82%A6
请教大佬,我哪里出问题了?为什么在微信-->发现里面搜不到?
返回给微信的结果数据格式应该类似这样的,你可以参考下
{ "Content": "{\"data\":\"{\\\"err_code\\\":0,\\\"err_msg\\\":\\\"成功\\\",\\\"flight_airline\\\":\\\"山东航空\\\",\\\"flight_land_time\\\":\\\"00:50\\\",\\\"flight_line\\\":\\\"杭州-厦门\\\",\\\"flight_state\\\":\\\"计划\\\",\\\"flight_stop_over_information\\\":\\\"\\\",\\\"flight_take_off_time\\\":\\\"23:00\\\",\\\"flight_update_time\\\":\\\"1月6日 11:58 更新\\\",\\\"jump_url\\\":\\\"pages/flight_dynamics/info/detail?fnum=SC8838&date=2020-01-06&fnumsearch=1&arr=&dep=\\\"}\",\"lifespan\":60,\"query\":\"{\\\"type\\\":3,\\\"slot_list\\\":[{\\\"key\\\":\\\"flight_number\\\",\\\"value\\\":\\\"SC8838\\\"},{\\\"key\\\":\\\"search_date\\\",\\\"value\\\":\\\"2020-01-06\\\"}],\\\"search_id\\\":\\\"4749435768867564086\\\"}\",\"scene\":1}", "CreateTime": 1578283085, "FromUserName": "gh_7e6a41181ab7", "MsgType": "widget_data", "ToUserName": "o1DsJ0YKvmAAeABK3VrFyPx91TXc" }
我的是配置的 json 格式,如果是配置的 xml ,最外层请按照 xml 格式返回
具体可以看下文档中的描述:
https://wsad.weixin.qq.com/wsad/zh_CN/htmledition/widget-docs-v3/html/custom/quickstart/implement/server/sync.html