$corpid, 'user_id' => $userid,'start_time'=>$start_time,'end_time'=>$end_time]), ['errmsg' => '令牌获取失败'], 'qyWechat'); return false; } $postData = [ 'userid' => [$userid], 'start_time' => strtotime($start_time), 'end_time' => strtotime($end_time), ]; $requestUri = config('qyWechat.user_conversation_report'); $requestUri .= $accessToken; $response = HttpService::httpPost($requestUri, json_encode($postData)); if(false === $response && $retry < 5) { sleep(1); $retry++; return self::customer_conversation_report($corpid, $userid, $start_time, $end_time, $retry); } $responseData = json_decode($response, true); Log::logInfo('获取联系客户统计数据', [ 'params' => ['corpid' => $corpid, 'user_id' => $userid,'start_time'=>$start_time,'end_time'=>$end_time], 'response' => $responseData ], 'qyWechat'); if(isset($responseData['errcode']) && -1 == $responseData['errcode'] && $retry<5) { sleep(1); $retry++; return self::customer_conversation_report($corpid, $userid, $start_time, $end_time, $retry); } return $responseData; } }