RESTful API 엔드포인트
인증 관련
POST /api/auth/register # 회원가입
POST /api/auth/login # 로그인
POST /api/auth/logout # 로그아웃
POST /api/auth/withdraw # 회원탈퇴
GET /api/auth/me # 내 정보 보기
할일 관리
GET /api/**todos** # 할일 목록 조회
POST /api/**todos** # 새 할일 생성
GET /api/**todos**/{id} # 특정 할일 조회
PUT /api/**todos**/{id} # 할일 수정
DELETE /api/**todos**/{id} # 할일 삭제
PATCH /api/**todos**/{id}/toggle # 완료 상태 토글
간단한 회원 관리 API 명세서
기본 설정
- 서버 주소:
http://localhost:3000
- 데이터 형식: JSON
응답 형식
성공했을 때 (Response Body)
{
"success": true,
"message": "성공 메시지",
"data": {}
}
실패했을 때 (Response Body)
{
"success": false,
"message": "에러 메시지"
}
API 명세서 (3)
API 명세서