현장 확인 > 처리 가능 수량 관리 api 및 수정

This commit is contained in:
2026-02-20 13:49:43 +09:00
parent c129362724
commit d91738c667
4 changed files with 85 additions and 34 deletions

View File

@@ -518,11 +518,19 @@ class NaverApiClient
$response = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
$curlError = curl_error($ch);
$curlErrno = curl_errno($ch);
curl_close($ch);
// CURL 오류 체크
if ($curlErrno !== 0) {
log_message('error', "[Naver API $method CURL ERROR] URL: $url | Error ($curlErrno): $curlError");
return null;
}
// 결과 로그 기록 (성공/실패 모두 기록하여 추적 가능하게 함)
if ($httpCode === 200 || $httpCode === 202) {
log_message('info', "[Naver API $method SUCCESS] URL: $url | Response: $response");
log_message('info', "[Naver API $method SUCCESS] URL: $url | Code: $httpCode | Response: $response");
} else {
log_message('error', "[Naver API $method FAIL] URL: $url | Code: $httpCode | Response: $response");
return null;