-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
138 additions
and
26 deletions.
There are no files selected for viewing
65 changes: 65 additions & 0 deletions
65
smeem-api/src/main/java/com/smeem/api/diary/api/DiaryApi.java
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
package com.smeem.api.diary.api; | ||
|
||
import com.smeem.api.common.BaseResponse; | ||
import com.smeem.api.diary.api.dto.request.DiaryCreateRequest; | ||
import com.smeem.api.diary.api.dto.request.DiaryModifyRequest; | ||
import io.swagger.v3.oas.annotations.Operation; | ||
import io.swagger.v3.oas.annotations.responses.ApiResponse; | ||
import org.springframework.http.ResponseEntity; | ||
import org.springframework.web.bind.annotation.PathVariable; | ||
import org.springframework.web.bind.annotation.RequestBody; | ||
import org.springframework.web.bind.annotation.RequestParam; | ||
|
||
import java.security.Principal; | ||
|
||
public interface DiaryApi { | ||
|
||
@Operation( | ||
summary = "일기 생성", | ||
responses = { | ||
@ApiResponse(responseCode = "201", description = "성공"), | ||
@ApiResponse(responseCode = "500", description = "서버 내부 오류") | ||
} | ||
) | ||
ResponseEntity<BaseResponse<?>> createDiary(Principal principal, @RequestBody DiaryCreateRequest request); | ||
|
||
@Operation( | ||
summary = "일기 상세 조회", | ||
responses = { | ||
@ApiResponse(responseCode = "200", description = "성공"), | ||
@ApiResponse(responseCode = "500", description = "서버 내부 오류") | ||
} | ||
) | ||
ResponseEntity<BaseResponse<?>> getDiaryDetail(@PathVariable long diaryId); | ||
|
||
@Operation( | ||
summary = "일기 수정", | ||
responses = { | ||
@ApiResponse(responseCode = "200", description = "성공"), | ||
@ApiResponse(responseCode = "500", description = "서버 내부 오류") | ||
} | ||
) | ||
ResponseEntity<BaseResponse<?>> modifyDiary(@PathVariable long diaryId, @RequestBody DiaryModifyRequest request); | ||
|
||
@Operation( | ||
summary = "일기 삭제", | ||
responses = { | ||
@ApiResponse(responseCode = "200", description = "성공"), | ||
@ApiResponse(responseCode = "500", description = "서버 내부 오류") | ||
} | ||
) | ||
ResponseEntity<BaseResponse<?>> deleteDiary(@PathVariable long diaryId); | ||
|
||
@Operation( | ||
summary = "기간 내 일기 목록 조회", | ||
responses = { | ||
@ApiResponse(responseCode = "200", description = "성공"), | ||
@ApiResponse(responseCode = "500", description = "서버 내부 오류") | ||
} | ||
) | ||
ResponseEntity<BaseResponse<?>> getDiaries( | ||
Principal principal, | ||
@RequestParam String start, | ||
@RequestParam String end | ||
); | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
...oller/dto/request/DiaryCreateRequest.java → ...y/api/dto/request/DiaryCreateRequest.java
This file contains 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
2 changes: 1 addition & 1 deletion
2
...oller/dto/request/DiaryModifyRequest.java → ...y/api/dto/request/DiaryModifyRequest.java
This file contains 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
2 changes: 1 addition & 1 deletion
2
...ler/dto/response/DiaryCreateResponse.java → ...api/dto/response/DiaryCreateResponse.java
This file contains 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
2 changes: 1 addition & 1 deletion
2
...roller/dto/response/DiaryGetResponse.java → ...ry/api/dto/response/DiaryGetResponse.java
This file contains 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
2 changes: 1 addition & 1 deletion
2
...er/dto/response/DiaryListGetResponse.java → ...pi/dto/response/DiaryListGetResponse.java
This file contains 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
2 changes: 1 addition & 1 deletion
2
...-api/src/main/java/com/smeem/api/diary/service/dto/request/DiaryCreateServiceRequest.java
This file contains 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
2 changes: 1 addition & 1 deletion
2
...-api/src/main/java/com/smeem/api/diary/service/dto/request/DiaryModifyServiceRequest.java
This file contains 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
29 changes: 29 additions & 0 deletions
29
smeem-api/src/main/java/com/smeem/api/goal/api/GoalApi.java
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package com.smeem.api.goal.api; | ||
|
||
import com.smeem.api.common.BaseResponse; | ||
import com.smeem.domain.goal.model.GoalType; | ||
import io.swagger.v3.oas.annotations.Operation; | ||
import io.swagger.v3.oas.annotations.responses.ApiResponse; | ||
import org.springframework.http.ResponseEntity; | ||
import org.springframework.web.bind.annotation.PathVariable; | ||
|
||
public interface GoalApi { | ||
|
||
@Operation( | ||
summary = "목표 전체 목록 조회", | ||
responses = { | ||
@ApiResponse(responseCode = "200", description = "성공"), | ||
@ApiResponse(responseCode = "500", description = "서버 내부 오류") | ||
} | ||
) | ||
ResponseEntity<BaseResponse<?>> getAllGoals(); | ||
|
||
@Operation( | ||
summary = "목표 상세 조회", | ||
responses = { | ||
@ApiResponse(responseCode = "200", description = "성공"), | ||
@ApiResponse(responseCode = "500", description = "서버 내부 오류") | ||
} | ||
) | ||
ResponseEntity<BaseResponse<?>> getGoalByType(@PathVariable GoalType type); | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
...troller/dto/response/GoalGetResponse.java → ...oal/api/dto/response/GoalGetResponse.java
This file contains 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
2 changes: 1 addition & 1 deletion
2
...ler/dto/response/GoalListGetResponse.java → ...api/dto/response/GoalListGetResponse.java
This file contains 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
18 changes: 18 additions & 0 deletions
18
smeem-api/src/main/java/com/smeem/api/topic/api/TopicApi.java
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package com.smeem.api.topic.api; | ||
|
||
import com.smeem.api.common.BaseResponse; | ||
import io.swagger.v3.oas.annotations.Operation; | ||
import io.swagger.v3.oas.annotations.responses.ApiResponse; | ||
import org.springframework.http.ResponseEntity; | ||
|
||
public interface TopicApi { | ||
|
||
@Operation( | ||
summary = "랜덤 주제 조회", | ||
responses = { | ||
@ApiResponse(responseCode = "200", description = "성공"), | ||
@ApiResponse(responseCode = "500", description = "서버 내부 오류") | ||
} | ||
) | ||
ResponseEntity<BaseResponse<?>> getTopicByRandom(); | ||
} |
This file contains 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
2 changes: 1 addition & 1 deletion
2
.../dto/response/RandomTopicGetResponse.java → .../dto/response/RandomTopicGetResponse.java
This file contains 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
This file contains 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