알림
알림 목록 조회
현재 로그인한 사용자의 알림 목록을 최신순으로 조회합니다. cursor와 limit을 사용해 다음 페이지를 조회할 수 있습니다. 삭제된 알림은 조회되지 않습니다.
GET
/
api
/
v1
/
notifications
알림 목록 조회
curl --request GET \
--url https://k-polaris.life/api/v1/notifications \
--header 'Authorization: Bearer <token>'import requests
url = "https://k-polaris.life/api/v1/notifications"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://k-polaris.life/api/v1/notifications', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://k-polaris.life/api/v1/notifications",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://k-polaris.life/api/v1/notifications"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://k-polaris.life/api/v1/notifications")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://k-polaris.life/api/v1/notifications")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"hasNext": true,
"nextCursor": 98,
"items": [
{
"notificationId": 123,
"notificationType": "BOOK_AVAILABLE",
"isbn": 9791191111111,
"bookTitle": "테스트 도서",
"libraryId": 10,
"libraryName": "구미시립양포도서관",
"title": "대출 가능 알림",
"message": "알림 받기 한 도서가 구미시립양포도서관에서 대출 가능합니다.",
"notificationDate": "2026-05-07",
"createdAt": "2026-05-07T09:00:01"
}
]
}{
"hasNext": true,
"nextCursor": 98,
"items": [
{
"notificationId": 123,
"notificationType": "BOOK_AVAILABLE",
"isbn": 9791191111111,
"bookTitle": "테스트 도서",
"libraryId": 10,
"libraryName": "구미시립양포도서관",
"title": "대출 가능 알림",
"message": "알림 받기 한 도서가 구미시립양포도서관에서 대출 가능합니다.",
"notificationDate": "2026-05-07",
"createdAt": "2026-05-07T09:00:01"
}
]
}{
"hasNext": true,
"nextCursor": 98,
"items": [
{
"notificationId": 123,
"notificationType": "BOOK_AVAILABLE",
"isbn": 9791191111111,
"bookTitle": "테스트 도서",
"libraryId": 10,
"libraryName": "구미시립양포도서관",
"title": "대출 가능 알림",
"message": "알림 받기 한 도서가 구미시립양포도서관에서 대출 가능합니다.",
"notificationDate": "2026-05-07",
"createdAt": "2026-05-07T09:00:01"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
커서 이후의 알림만 조회하려면 이전 응답의 nextCursor 값을 입력하세요. 없으면 첫 페이지를 조회합니다.
한 번에 조회할 알림 개수입니다. 1부터 100까지 입력할 수 있으며 기본값은 20입니다.
⌘I
알림 목록 조회
curl --request GET \
--url https://k-polaris.life/api/v1/notifications \
--header 'Authorization: Bearer <token>'import requests
url = "https://k-polaris.life/api/v1/notifications"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://k-polaris.life/api/v1/notifications', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://k-polaris.life/api/v1/notifications",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://k-polaris.life/api/v1/notifications"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://k-polaris.life/api/v1/notifications")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://k-polaris.life/api/v1/notifications")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"hasNext": true,
"nextCursor": 98,
"items": [
{
"notificationId": 123,
"notificationType": "BOOK_AVAILABLE",
"isbn": 9791191111111,
"bookTitle": "테스트 도서",
"libraryId": 10,
"libraryName": "구미시립양포도서관",
"title": "대출 가능 알림",
"message": "알림 받기 한 도서가 구미시립양포도서관에서 대출 가능합니다.",
"notificationDate": "2026-05-07",
"createdAt": "2026-05-07T09:00:01"
}
]
}{
"hasNext": true,
"nextCursor": 98,
"items": [
{
"notificationId": 123,
"notificationType": "BOOK_AVAILABLE",
"isbn": 9791191111111,
"bookTitle": "테스트 도서",
"libraryId": 10,
"libraryName": "구미시립양포도서관",
"title": "대출 가능 알림",
"message": "알림 받기 한 도서가 구미시립양포도서관에서 대출 가능합니다.",
"notificationDate": "2026-05-07",
"createdAt": "2026-05-07T09:00:01"
}
]
}{
"hasNext": true,
"nextCursor": 98,
"items": [
{
"notificationId": 123,
"notificationType": "BOOK_AVAILABLE",
"isbn": 9791191111111,
"bookTitle": "테스트 도서",
"libraryId": 10,
"libraryName": "구미시립양포도서관",
"title": "대출 가능 알림",
"message": "알림 받기 한 도서가 구미시립양포도서관에서 대출 가능합니다.",
"notificationDate": "2026-05-07",
"createdAt": "2026-05-07T09:00:01"
}
]
}