Detail

저장한 도서 중 1권에 대한 정보를 반환하는 API

Request (요청)

URL

https://soobook.devlim.net/api/book/mybook/detail/?

Method

GET

Params

URL Params

name value type
bookid Book PK integer

Data Params

None

name value type
Authorization Token <발급받은 토큰 key> string

Response (응답)

Success Response

  • Code: 200
  • Content:
[
  {
    "mybook_id": 30,
    "updated_date": "2017-04-13T06:01:53.572051Z",
    "book": {
      "id": 2001,
      "title": "파이썬 인 프랙티스(위키북스 프로그래밍 & 프랙티스 시리즈 8)",
      "author": "마크서머필드",
      "cover_thumbnail": "",
      "publisher": "위키북스",
      "description": ""
    },
    "comment": [
      {
        "id": 7,
        "content": "테스트입니다",
        "updated_date": "2017-04-15T02:46:45.693551Z"
      }
    ],
    "star": [
      {
        "id": 1,
        "content": 4.5,
        "created_date": "2017-04-14T13:20:31.134370Z"
      }
    ],
    "mark": [
      {
        "id": 2,
        "content": "파이썬은 인터프리터 언어입니다. ",
        "update_date": "2017-04-18T08:54:48.127344Z"
      },
      {
        "id": 5,
        "content": "파이썬은 간결합니다. ",
        "update_date": "2017-04-18T08:55:36.340169Z"
      },
      {
        "id": 7,
        "content": "파이썬은 강력합니다. ",
        "update_date": "2017-04-18T08:56:23.637250Z"
      }
    ]
  }
]

Error Response

  • Code: 401
  • Reason: 헤더에 Authorization: Token이 없는 경우
  • Content:
{
  "detail": "Authentication credentials were not provided."
}
  • Code: 401
  • Reason: 유효하지 않은 토큰 키를 입력하는 경우
  • Content:
{
  "detail": "Invalid token."
}
  • Code: 400
  • Reason: 키(bookid)가 없는 경우
  • Content:
{
  "ios_error_code": "4002",
  "bookid": [
    "This field is required."
  ]
}
  • Code: 400
  • Reason: 키의 값이 없는 경우
  • Content:
{
  "ios_error_code": "4003",
  "bookid": [
    "This field may not be blank."
  ]
}
  • Code: 400
  • Reason: 유효하지 않은 bookid를 입력하는 경우
  • Content:
{
  "ios_error_code": "4004",
  "detail": "Invalid bookid."
}

results matching ""

    No results matching ""