Genres

Genre merupakan tipe dari book genre itu sendiri untuk mengklasifikasikan genre berdasarkan buku-buku.

Get All Genres

Get All

GET https://openapi.omdo.site/api/genres

{
  "success": true,
  "message": "Genres retrieved successfully",
  "data": [
    {
      "id": 1,
      "name": "Genre Name",
      "description": "Genre Description",
      "genre_id": 1,
      "category": {
        "id": 1,
        "name": "Category Name",
        "description": "Category Description"
      }
    }
  ]
}

Get Genres by ID

GET https://openapi.omdo.site/api/genres/{id}

Path Parameters

Name
Type
Description

id*

integer

Genre ID for get specify data books

Create Genre

POST https://openapi.omdo.site/api/genres

application/json

Headers

Name
Type
Description

Authorization*

String

Token JWT with Bearer type

Request Body

Name
Type
Description

name*

String

Genre name

description

String

Genre description

category_id*

String

Category ID

Update Genre

PUT https://openapi.omdo.site/api/genres/{id}

application/json

Path Parameters

Name
Type
Description

id*

Integer

Genre id

Headers

Name
Type
Description

Authorization*

String

Token JWT with Bearer type

Request Body

Name
Type
Description

name*

String

Genre name

description

String

Genre description

category_id

String

Category ID

Delete Genre

DELETE https://openapi.omdo.site/api/genres/{id}

Path Parameters

Name
Type
Description

id*

integer

Genre ID for get specify data books

Last updated