Outlook通知订阅续订PATCH

I am trying to renew notification subscription using below code.

        $token = json_decode($account->token, true);
        $newToken = json_decode($sync->refreshToken($token['refresh_token']), true);

        $headers = array(
            "Content-Type: application/json",
            "Authorization: Bearer " . $newToken['access_token']
        );

        $url = "https://outlook.office.com/api/v2.0/me/subscriptions/" . $token['events_hookId'];
        $res = $emailSync->runCurl($url, null, $headers, "PATCH");
        print_r($res);
    }

but its returning below error.

{"error":{"code":"RequestBodyRead","message":"An unexpected 'EndOfInput' node was found when reading from the JSON reader. A 'StartObject' node was expected."}}

doubangzhang6992
doubangzhang6992 我错过了我的请求$data='{“@odata.type”:“#Microsoft.OutlookServices.PushSubscription”,“SubscriptionExpirationDateTime”:“2019-04-06T17:17:45.9028722Z”}';问题解决了
一年多之前 回复
dongwei1921
dongwei1921 我的卷曲功能gist.github.com/huzoorbux/25bb30c414fa6c7652dfba12f013524f
一年多之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问