Article API

Get Article Count

GET https://localhost:3030/api/article/count

Get a article count

{
    "success": true,
    "count": ...
}

Get Article List per Page

GET https://localhost:3030/api/article/list?page=

Return 15 article per page in descending order.

Query Parameters

Name
Type
Description

page

number

Page number

[
    {
        "article_no": 1,
        "title": "title",
        "writer": "writer",
        "content": "content",
        "reg_date": "2020-10-29T05:56:37.000Z",
        "view_cnt": 0
    },
    ...
]

Read a Article

GET https://localhost:3030/api/article/read/:id

Path Parameters

Name
Type
Description

id

number

Article number

Write a Article

POST https://localhost:3030/api/article/write

Headers

Name
Type
Description

x-access-token

string

Access token

Request Body

Name
Type
Description

title

string

Article title

content

string

Article content

Modify a Article

PUT https://localhost:3030/api/article/modify/:id

Path Parameters

Name
Type
Description

id

number

Article number

Request Body

Name
Type
Description

title

string

Article title

content

string

Article content

Delete a Article

DELETE https://localhost:3030/api/article/delete?id=

Query Parameters

Name
Type
Description

id

number

Article number

Headers

Name
Type
Description

x-access-token

string

Access token

Search a Article

GET https://localhost:3030/api/article/search?type=&keyword=

Query Parameters

Name
Type
Description

type

string

Search type (everything, title, writer, content)

keyword

string

Search keyword

Last updated