Search
내 도서 검색 API
Request (요청)
URL
https://soobook.devlim.net/api/book/mybook/search/?
Method
GET
Params
URL Params
name | value | type |
---|---|---|
keyword | 검색어 (책 제목) | string |
Data Params
None
Header
name | value | type |
---|---|---|
Authorization | Token <발급받은 토큰 key> | string |
Response (응답)
Success Response
- Code: 200
- Content:
{
"count": 13,
"next": "https://soobook.devlim.net/api/book/mybook/search/?keyword=%ED%8C%8C%EC%9D%B4%EC%8D%AC&page=2",
"previous": null,
"results": [
{
"book" {
"id": 425,
"title": "뇌를 자극하는 파이썬 3",
"author": "박상현",
"cover_thumbnail": "http://books.google.com/books/content?id=1WqFDQAAQBAJ&printsec=frontcover&img=1&zoom=1&edge=curl&source=파이썬",
"publisher": "한빛미디어",
}
},
{ ... },
{ ... },
{ ... },
{ ... },
{ ... },
{ ... },
{ ... },
{ ... },
{ ... },
{ ... },
{ ... }
]
}
- results 배열안에 12개의 딕셔너리를 반환합니다.
Error Response
- Code: 401
- Reason: 헤더에
Authorization: Token
이 없는 경우 - Content:
{
"detail": "Incorrect authentication credentials."
}
- Code: 401
- Reason: 유효하지 않은 토큰 키를 입력하는 경우
- Content:
{
"detail": "Invalid token."
}
- Code: 400
- Reason: 키(keyword)가 없는 경우
- Content:
{
"ios_error_code": "4002",
"keyword": [
"This field is required."
]
}
- Code: 400
- Reason: 키의 값이 없는 경우
- Content:
{
"ios_error_code": "4003",
"keyword": [
"This field may not be blank."
]
}