Repository navigation
[BE-declaration] 자기선언 질문지 발송·조회·제출 API - #25
Merged
Merged
Conversation
- POST /employees/:employeeId/declarations: 템플릿 스냅샷 저장 + 1회성 링크 발급, 커밋 후 메일 발송(linkSent) - GET /declarations/forms/:token: 링크 토큰으로 질문지 조회 (링크 소비 안 함) - POST /declarations/forms/:token/submit: 답변·필수 동의 제출, 링크 소비 - GET /declarations/:employeeId: 대표의 제출된 자기선언 이력 조회 - 답변 유형 불일치 400 INVALID_ANSWER_TYPE, 조건 위반 422 ANSWER_VALIDATION_FAILED, 동의 누락 403 CONSENT_NOT_GIVEN - 동시 발송·동시 제출은 조건부 갱신으로 한 번만 성공 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
💡 개요
대표가 직원에게 자기선언 질문지를 보내고, 직원이 메일 링크로 답변·동의를 제출하는 API 4개를 추가합니다.
Closes #11
📌 변경 사항
POST /employees/:employeeId/declarations(대표): 템플릿 할당·발송linkSentGET /declarations/forms/:token(직원): 질문지 조회, 조회만으로는 링크 소비 안 함POST /declarations/forms/:token/submit(직원): 답변·필수 동의 제출, 성공 시 링크 소비GET /declarations/:employeeId(대표): 제출된 자기선언 이력 (질문·답변·동의, 최신순)📖 프론트 참고
/verification/self-declare/:token[{ optionId, label }], 제출 시answerOptionId로 전달answerScore, SINGLE_CHOICE →answerOptionId, TEXT →answerTextconsentVersion은 조회 응답 값을 그대로 전송INVALID_ANSWER_TYPEANSWER_VALIDATION_FAILED(details.errors에 질문별 사유)CONSENT_NOT_GIVENALREADY_SUBMITTEDLINK_EXPIRED✅ 검증
👀 리뷰 포인트
2026-10-01(법무 확정 후 변경 필요, TODO)