SSE 연결
HTTP request
GET /notification/connect HTTP/1.1
Authorization: "access token"
Last-Event-ID: lastEventIdValue
Accept: text/event-stream
Host: localhost:8080
HTTP response
HTTP/1.1 200 OK
X-Accel-Buffering: no
Connection: keep-alive
전체 알림 조회
HTTP request
GET /notification/all HTTP/1.1
Authorization: "access token"
Accept: application/json
Host: localhost:8080
HTTP response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 202
[ {
"id" : 1,
"type" : "comment",
"content" : "알림 내용",
"url" : "/board/1",
"publishedAt" : [ 2023, 6, 19, 17, 21, 44 ],
"name" : "닉네임",
"checked" : false,
"del" : false
} ]
Response fields
| Path | Type | Description |
|---|---|---|
|
|
알림 고유번호 |
|
|
알림 분류 |
|
|
알림 내용 |
|
|
알림 redirect URL |
|
|
알림 생성 일시 |
|
|
알림 발신지에 해당하는 회원의 닉네임 |
|
|
알림 읽음 상태 구분 |
|
|
알림 삭제 상태 |
알림 삭제
HTTP request
POST /notification HTTP/1.1
Content-Type: application/json;charset=UTF-8
Authorization: "access token"
Accept: application/json
Content-Length: 31
Host: localhost:8080
{
"idList" : [ 1, 2, 3, 4 ]
}
HTTP response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 20
{
"status" : 200
}
Response fields
| Path | Type | Description |
|---|---|---|
|
|
응답 상태코드 |
알림 읽음 처리
HTTP request
PATCH /notification/checked/1 HTTP/1.1
Authorization: "access token"
Host: localhost:8080
HTTP response
HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 20
{
"status" : 200
}
Response fields
| Path | Type | Description |
|---|---|---|
|
|
응답 상태코드 |