summaryrefslogtreecommitdiff
path: root/lib/swp/api-client.ts
diff options
context:
space:
mode:
Diffstat (limited to 'lib/swp/api-client.ts')
-rw-r--r--lib/swp/api-client.ts40
1 files changed, 40 insertions, 0 deletions
diff --git a/lib/swp/api-client.ts b/lib/swp/api-client.ts
index 4943a42a..1befa217 100644
--- a/lib/swp/api-client.ts
+++ b/lib/swp/api-client.ts
@@ -1,5 +1,45 @@
"use server";
+/**
+ * SWP API Client
+ *
+ * ## 목적
+ * 외부 SWP 시스템의 REST API를 호출하는 저수준 클라이언트입니다.
+ *
+ * ## 설계 원칙
+ * 1. **단순 API 호출만 담당** - 비즈니스 로직은 document-service.ts에서 처리
+ * 2. **타입 안전성** - API 응답 타입을 명확히 정의
+ * 3. **에러 핸들링** - API 실패 시 명확한 에러 메시지 제공
+ * 4. **디버깅 지원** - 모든 API 호출을 debugLog로 추적
+ *
+ * ## 주요 API
+ * - `fetchGetVDRDocumentList`: 문서 마스터 조회 (필터링 지원)
+ * - `fetchGetExternalInboxList`: 파일 정보 조회 (업로드된 파일 포함)
+ * - `fetchGetActivityFileList`: Rev-Activity-File 계층 구조 조회
+ * - `callSaveInBoxList`: 파일 업로드 메타데이터 등록
+ * - `callSaveInBoxListCancelStatus`: Standby 파일 취소
+ *
+ * ## 사용 예시
+ * ```typescript
+ * // 문서 목록 조회
+ * const documents = await fetchGetVDRDocumentList({
+ * proj_no: "SN2190",
+ * doc_gb: "V",
+ * vndrCd: "SE00100"
+ * });
+ *
+ * // 파일 목록 조회
+ * const files = await fetchGetExternalInboxList({
+ * projNo: "SN2190",
+ * vndrCd: "SE00100"
+ * });
+ * ```
+ *
+ * @see lib/swp/document-service.ts - 비즈니스 로직 레이어
+ * @see lib/swp/vendor-actions.ts - 서버 액션 (권한 체크)
+ * @see lib/swp/README.md - 전체 시스템 문서
+ */
+
// ============================================================================
// SWP API 클라이언트
// ============================================================================