同时调用API surveymonkey意外的JSON结果 [英] Unexpected json result while calling the surveymonkey api
问题描述
在调用API surveymonkey我使用
{\survey_id\:\47625442\,+\域[] \ :\[网址] \}
作为服务器需要完成我的要求,同时它返回它需要的数据它不是JSON数据。 ?返回额外的URL我相信,我请求没有人知道为什么这不会给我这个后面
When calling the surveymonkey api I'm using
{\"survey_id\":\"47625442\"," +"\"fields[]\":\"['url']\"}"
as the json data the server needs to complete my request. while it is returning the data it is required it is not returning the additional URL i believe i am requesting. Does anyone know why this wouldn't give me this back?
修改的 https://developer.surveymonkey.com/mashery/get_collector_list 这是调用我尝试做,如果这有助于
EDIT https://developer.surveymonkey.com/mashery/get_collector_list this is the call im trying to make if this helps
推荐答案
正如指出了评论:您的JSON格式是关闭的,因此API不明白,你问。对网址
As was pointed out in the comments: Your JSON formatting is off, so the API doesn't understand that you're asking for the URL.
有关发生了什么事情的理解,看看您所提供的链接,例如请求;注意在字段的格式< 。/ strong>部分
For an understanding of what's going on, take a look at the example request in the link you provided; note the format of the fields section.
再试一次,这次使用:
{"survey_id": "47625442", "fields": ["url"]}
。与逃逸..这看起来就像这样......
...which with the escapes will look like this....
{\"survey_id\": \"47625442\", \"fields\":[ \"url\" ]}"
这篇关于同时调用API surveymonkey意外的JSON结果的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!