description: 카테고리 목록 반환
홈페이지 요청 시 카테고리 정보를 호출하여 프론트에서 보여줄 수 있습니다.
Attribute Definition
attribute |
data type |
description |
id |
Long |
category 고유의 id |
name |
String |
category 이름 |
postNum |
Long |
해당 category에 써진 글 수 (logic 구현 O) |
Response example
// http://localhost:8080/category
[
{
"id": 1,
"name": "all",
"postNum": 0
},
{
"id": 2,
"name": "to-do-list",
"postNum": 0
},
{
"id": 3,
"name": "html_css",
"postNum": 4
},
{
"id": 4,
"name": "javascript",
"postNum": 0
},
{
"id": 5,
"name": "bla-bla",
"postNum": 1
},
{
"id": 6,
"name": "python",
"postNum": 0
},
{
"id": 7,
"name": "side_projects",
"postNum": 0
},
{
"id": 8,
"name": "hello",
"postNum": 0
},
{
"id": 9,
"name": "dev_resources",
"postNum": 0
},
{
"id": 10,
"name": "jobs",
"postNum": 0
},
{
"id": 11,
"name": "react",
"postNum": 0
},
{
"id": 12,
"name": "uber_eats",
"postNum": 0
},
{
"id": 13,
"name": "announcement",
"postNum": 0
},
{
"id": 14,
"name": "instaclone",
"postNum": 0
},
{
"id": 15,
"name": "type_test",
"postNum": 3
}
]