diff --git a/src/main/java/com/nainga/nainga/domain/report/api/ReportApi.java b/src/main/java/com/nainga/nainga/domain/report/api/ReportApi.java index 7e5c4c3..d2cc173 100644 --- a/src/main/java/com/nainga/nainga/domain/report/api/ReportApi.java +++ b/src/main/java/com/nainga/nainga/domain/report/api/ReportApi.java @@ -27,7 +27,12 @@ public class ReportApi { "formattedAddress: 등록 요청하는 가게 주소
" + "certifications: 가게가 가지고 있는 인증제들의 이름을 담은 리스트. 착한가격업소, 모범음식점, 안심식당이 아닌 경우 예외 발생
" + "[Response Body]
" + - "등록된 reportId
") + "등록된 reportId
" + + "[Exceptions]
" + + "- 잘못된 인증제 이름이 들어온 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_CERTIFICATION
" + + "message: There is a wrong certification. You can only use certifications such as 착한가격업소, 모범음식점, 안심식당.
") @PostMapping("api/report/newStore/v1") public Result saveNewStoreReport(@Valid @RequestBody SaveNewStoreReportRequest saveNewStoreReportRequest) { Long reportId = reportService.saveNewStoreReport(saveNewStoreReportRequest); @@ -42,7 +47,12 @@ public Result saveNewStoreReport(@Valid @RequestBody SaveNewStoreReportReq "storeId: 수정 혹은 삭제를 요청하는 가게 id
" + "contents: 제보 내용
" + "[Response Body]
" + - "등록된 reportId
") + "등록된 reportId
" + + "[Exceptions]
" + + "- 잘못된 dtype이 들어온 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_DTYPE
" + + "message: There is a wrong dtype. You can only use a dtype such as fix or del.
") @PostMapping("api/report/specificStore/v1") public Result saveSpecificStoreReport(@Valid @RequestBody SaveSpecificStoreReportRequest saveSpecificStoreReportRequest) { Long reportId = reportService.saveSpecificStoreReport(saveSpecificStoreReportRequest); @@ -55,7 +65,12 @@ public Result saveSpecificStoreReport(@Valid @RequestBody SaveSpecificStor "[Request Body]
" + "reportId: 검색할 사용자 제보의 reportId. 유효하지 않은 reportId의 경우 예외 발생
" + "[Response Body]
" + - "해당 reportId로 검색된 사용자 제보 내용
") + "해당 reportId로 검색된 사용자 제보 내용
" + + "[Exceptions]
" + + "- 잘못된 reportId가 들어온 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_REPORT_ID
" + + "message: There is a wrong reportId.
") @GetMapping("api/report/byId/v1") public Result findById(@NotNull @RequestParam(value = "reportId") Long reportId) { Report report = reportService.findById(reportId); diff --git a/src/main/java/com/nainga/nainga/domain/store/api/StoreApi.java b/src/main/java/com/nainga/nainga/domain/store/api/StoreApi.java index dc5177f..098236e 100644 --- a/src/main/java/com/nainga/nainga/domain/store/api/StoreApi.java +++ b/src/main/java/com/nainga/nainga/domain/store/api/StoreApi.java @@ -27,18 +27,46 @@ public class StoreApi { private final GoodPriceGoogleMapStoreService goodPriceGoogleMapStoreService; private final StoreService storeService; - @Hidden +// @Hidden @Tag(name = "초기 Data 생성") - @Operation(summary = "모범음식점 데이터 생성", description = "[WARNING] DB에 처음으로 모든 모범음식점 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!") + @Operation(summary = "모범음식점 데이터 생성", description = "[WARNING] DB에 처음으로 모든 모범음식점 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!

" + + "[Request Param]
" + + "fileName: 파싱할 모범음식점 데이터 엑셀 파일명
" + + "[Response Body]
" + + "성공했다면, 200 http status value
" + + "[Exceptions]
" + + "- Excel 파일 이외의 확장자가 들어왔을 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_FILE_EXTENSION
" + + "message: There are incorrect files. Only the extension of Excel file is allowed.
" + + "- Google Map API 연동 과정 중 오류가 발생했을 경우
" + + "httpStatusValue: 500
" + + "httpStatusCode: GOOGLE_MAP_SERVER_ERROR
" + + "message: There are internal server errors related to Google Map API.
") @GetMapping("api/store/mobeom/v1") public Result createAllMobeomStores(@RequestParam(value = "fileName") String fileName) { mobeomGoogleMapStoreService.createAllMobeomStores(fileName); return new Result<>(Result.CODE_SUCCESS, Result.MESSAGE_OK, null); } - @Hidden +// @Hidden @Tag(name = "초기 Data 생성") - @Operation(summary = "지정한 Credit까지만 사용하여 모범음식점 데이터 생성", description = "[WARNING] 지정한 Credit까지만 사용하여 그동안 DB에 모범음식점 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!") + @Operation(summary = "지정한 Credit까지만 사용하여 모범음식점 데이터 생성", description = "[WARNING] 지정한 Credit까지만 사용하여 그동안 DB에 모범음식점 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!

" + + "[Request Param]
" + + "fileName: 파싱할 모범음식점 데이터 엑셀 파일명
" + + "dollars: 현재 API 호출에 사용할 수 있는 남은 달러
" + + "startIndex: 엑셀 데이터로부터 추출한 가게 리스트 Index number를 기준으로 조회를 시작할 Index number
" + + "[Response Body]
" + + "성공했다면, 200 http status value
" + + "[Exceptions]
" + + "- Excel 파일 이외의 확장자가 들어왔을 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_FILE_EXTENSION
" + + "message: There are incorrect files. Only the extension of Excel file is allowed.
" + + "- Google Map API 연동 과정 중 오류가 발생했을 경우
" + + "httpStatusValue: 500
" + + "httpStatusCode: GOOGLE_MAP_SERVER_ERROR
" + + "message: There are internal server errors related to Google Map API.
") @GetMapping("api/store/dividedMobeom/v1") public Result createDividedMobeomStores(@RequestParam(value = "fileName") String fileName, @RequestParam(value = "dollars") double dollars, @RequestParam(value = "startIndex") int startIndex) { CreateDividedMobeomStoresResponse response = mobeomGoogleMapStoreService.createDividedMobeomStores(fileName, dollars, startIndex); @@ -48,7 +76,20 @@ public Result createDividedMobeomStores(@Requ @Hidden @Tag(name = "초기 Data 생성") - @Operation(summary = "안심식당 데이터 생성", description = "[WARNING] DB에 처음으로 모든 안심식당 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!") + @Operation(summary = "안심식당 데이터 생성", description = "[WARNING] DB에 처음으로 모든 안심식당 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!

" + + "[Request Param]
" + + "fileName: 파싱할 안심식당 데이터 엑셀 파일명
" + + "[Response Body]
" + + "성공했다면, 200 http status value
" + + "[Exceptions]
" + + "- Excel 파일 이외의 확장자가 들어왔을 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_FILE_EXTENSION
" + + "message: There are incorrect files. Only the extension of Excel file is allowed.
" + + "- Google Map API 연동 과정 중 오류가 발생했을 경우
" + + "httpStatusValue: 500
" + + "httpStatusCode: GOOGLE_MAP_SERVER_ERROR
" + + "message: There are internal server errors related to Google Map API.
") @GetMapping("api/store/safe/v1") public Result createAllSafeStores(@RequestParam(value = "fileName") String fileName) { safeGoogleMapStoreService.createAllSafeStores(fileName); @@ -57,7 +98,22 @@ public Result createAllSafeStores(@RequestParam(value = "fileName") Stri @Hidden @Tag(name = "초기 Data 생성") - @Operation(summary = "지정한 Credit까지만 사용하여 안심식당 데이터 생성", description = "[WARNING] 지정한 Credit까지만 사용하여 그동안 DB에 안심식당 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!") + @Operation(summary = "지정한 Credit까지만 사용하여 안심식당 데이터 생성", description = "[WARNING] 지정한 Credit까지만 사용하여 그동안 DB에 안심식당 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!

" + + "[Request Param]
" + + "fileName: 파싱할 안심식당 데이터 엑셀 파일명
" + + "dollars: 현재 API 호출에 사용할 수 있는 남은 달러
" + + "startIndex: 엑셀 데이터로부터 추출한 가게 리스트 Index number를 기준으로 조회를 시작할 Index number
" + + "[Response Body]
" + + "성공했다면, 200 http status value
" + + "[Exceptions]
" + + "- Excel 파일 이외의 확장자가 들어왔을 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_FILE_EXTENSION
" + + "message: There are incorrect files. Only the extension of Excel file is allowed.
" + + "- Google Map API 연동 과정 중 오류가 발생했을 경우
" + + "httpStatusValue: 500
" + + "httpStatusCode: GOOGLE_MAP_SERVER_ERROR
" + + "message: There are internal server errors related to Google Map API.
") @GetMapping("api/store/dividedSafe/v1") public Result createDividedSafeStores(@RequestParam(value = "fileName") String fileName, @RequestParam(value = "dollars") double dollars, @RequestParam(value = "startIndex") int startIndex) { CreateDividedSafeStoresResponse response = safeGoogleMapStoreService.createDividedSafeStores(fileName, dollars, startIndex); @@ -67,7 +123,20 @@ public Result createDividedSafeStores(@RequestP @Hidden @Tag(name = "초기 Data 생성") - @Operation(summary = "착한가격업소 데이터 생성", description = "[WARNING] DB에 처음으로 모든 착한가격업소 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!") + @Operation(summary = "착한가격업소 데이터 생성", description = "[WARNING] DB에 처음으로 모든 착한가격업소 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!

" + + "[Request Param]
" + + "fileName: 파싱할 착한가격업소 데이터 엑셀 파일명
" + + "[Response Body]
" + + "성공했다면, 200 http status value
" + + "[Exceptions]
" + + "- Excel 파일 이외의 확장자가 들어왔을 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_FILE_EXTENSION
" + + "message: There are incorrect files. Only the extension of Excel file is allowed.
" + + "- Google Map API 연동 과정 중 오류가 발생했을 경우
" + + "httpStatusValue: 500
" + + "httpStatusCode: GOOGLE_MAP_SERVER_ERROR
" + + "message: There are internal server errors related to Google Map API.
") @GetMapping("api/store/goodPrice/v1") public Result createAllGoodPriceStores(@RequestParam(value = "fileName") String fileName) { goodPriceGoogleMapStoreService.createAllGoodPriceStores(fileName); @@ -76,7 +145,22 @@ public Result createAllGoodPriceStores(@RequestParam(value = "fileName") @Hidden @Tag(name = "초기 Data 생성") - @Operation(summary = "지정한 Credit까지만 사용하여 착한가격업소 데이터 생성", description = "[WARNING] 지정한 Credit까지만 사용하여 그동안 DB에 착한가격업소 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!") + @Operation(summary = "지정한 Credit까지만 사용하여 착한가격업소 데이터 생성", description = "[WARNING] 지정한 Credit까지만 사용하여 그동안 DB에 착한가격업소 데이터를 주입해주는 API입니다. DB에 엄청난 부하가 가는 작업으로, 합의 없이 실행시켜선 안됩니다!

" + + "[Request Param]
" + + "fileName: 파싱할 착한가격업소 데이터 엑셀 파일명
" + + "dollars: 현재 API 호출에 사용할 수 있는 남은 달러
" + + "startIndex: 엑셀 데이터로부터 추출한 가게 리스트 Index number를 기준으로 조회를 시작할 Index number
" + + "[Response Body]
" + + "성공했다면, 200 http status value
" + + "[Exceptions]
" + + "- Excel 파일 이외의 확장자가 들어왔을 경우
" + + "httpStatusValue: 404
" + + "httpStatusCode: INVALID_FILE_EXTENSION
" + + "message: There are incorrect files. Only the extension of Excel file is allowed.
" + + "- Google Map API 연동 과정 중 오류가 발생했을 경우
" + + "httpStatusValue: 500
" + + "httpStatusCode: GOOGLE_MAP_SERVER_ERROR
" + + "message: There are internal server errors related to Google Map API.
") @GetMapping("api/store/dividedGoodPrice/v1") public Result createDividedGoodPriceStores(@RequestParam(value = "fileName") String fileName, @RequestParam(value = "dollars") double dollars, @RequestParam(value = "startIndex") int startIndex) { CreateDividedGoodPriceStoresResponse response = goodPriceGoogleMapStoreService.createDividedGoodPriceStores(fileName, dollars, startIndex);