Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/ajax/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript Google联系人API未返回输出_Javascript_Ajax_Contacts_Google Contacts Api - Fatal编程技术网

Javascript Google联系人API未返回输出

Javascript Google联系人API未返回输出,javascript,ajax,contacts,google-contacts-api,Javascript,Ajax,Contacts,Google Contacts Api,它工作正常,但昨天它开始给出401。我试过了 我认为数据类型不正确。JSONP URL必须具有 JS函数的“回调”参数 看看: 在URL参数中还有一个“access_token”,有时 某些服务只能使用一次。这取决于端点 您正在与他们交谈,以及他们如何处理其身份验证过程 // handles the click event, sends the query function getSuccessOutput() { $.ajax({ url:'https://www

它工作正常,但昨天它开始给出401。我试过了

  • 我认为数据类型不正确。JSONP URL必须具有 JS函数的“回调”参数

    看看:

  • 在URL参数中还有一个“access_token”,有时 某些服务只能使用一次。这取决于端点 您正在与他们交谈,以及他们如何处理其身份验证过程

// handles the click event, sends the query
function getSuccessOutput() {
    $.ajax({
        url:'https://www.google.com/m8/feeds/contacts/default/full?access_token=ya29.XXXXXXXWLNLPslUUOifL1pu63cGG_DAkEHeh-VjjOGBYzgJAp65-RRrIYmIbGnHiZ5VwC6KpBPYstaSEoBgXOaf0kmuPqIL_-RllkGJKPh1uqTCJoN4k1YZl7Jdp-A&alt=json&max-results=9999',
    dataType: "jsonp",
    cache: true,        
        complete: function (response) {
            $('#output').html(response.responseText);

        },
error: function(xhr, status, error) {
  //var err = eval("(" + xhr.responseText + ")");
  alert(error.Message);
}
    });
    return false;
}