ArticleController

@Validated
@RestController
@RequestMapping(value = ["/api/v1/articles"], produces = ["application/json"])
class ArticleController(readArticleUseCase: ReadArticleUseCase, browseArticlesUseCase: BrowseArticlesUseCase, readArticleByEmailUseCase: ReadArticleByEmailUseCase)

Constructors

Link copied to clipboard
constructor(readArticleUseCase: ReadArticleUseCase, browseArticlesUseCase: BrowseArticlesUseCase, readArticleByEmailUseCase: ReadArticleByEmailUseCase)

Functions

Link copied to clipboard
@GetMapping(value = ["/categories"])
fun browseArticleCategories(): ApiResponse<ApiResponse.SuccessBody<Any>>
Link copied to clipboard
@GetMapping(value = ["/{articleId}"])
fun readArticle(userArgumentDetails: UserArgumentDetails, @PathVariable(value = "articleId") @Min(value = 1, message = "{min.id}") articleId: Long): ApiResponse<ApiResponse.SuccessBody<ReadArticleResponse>>
Link copied to clipboard
@PostMapping(value = ["/views"])
fun readArticleByEmail(@RequestParam(value = "type") type: SendType, @RequestBody request: ReadArticleByEmailRequest): ApiResponse<ApiResponse.Success>
Link copied to clipboard
@GetMapping
fun readArticles(@RequestParam(required = false, defaultValue = "0") prevArticleId: Long, @RequestParam(required = false, defaultValue = "-1") categoryCd: Byte): ApiResponse<ApiResponse.SuccessBody<ReadArticlesResponse>>