Categories
Get Categories
Returns records of news categories created by client
Get News Categories
GET /news/categories
Query Parameters
is_parent
Boolean
Filter categories by showing parent only
Headers
Client-Key*
String
Your client Key
{
"data": [
{
"id": 178,
"name": "Hiburan & Olahraga",
"slug": "hiburan-olahraga",
"description": null,
"parent": {
"data": []
},
"children": {
"data": [
{
"id": 177,
"name": "Hiburan",
"slug": "hiburan",
"description": ""
}
]
}
},
{
"id": 177,
"name": "Hiburan",
"slug": "hiburan",
"description": "",
"parent": {
"data": {
"id": 178,
"name": "Hiburan & Olahraga",
"slug": "hiburan-olahraga",
"description": null
}
},
"children": {
"data": []
}
}
]
}Create Category
Create a news category and return it value
Create Catogery
POST /news/categories
Headers
Client-Key*
String
Your client Key
Authorization*
String
Bearer access_token
Request Body
name*
String
The name of the category
slug
String
description
String
Get Category Detail
Returns news category by id
Detail Category
GET /news/categories/detail/{slug}
Path Parameters
slug*
String
Headers
Client-Key*
String
Your client Key
Update Category
Update news category by id and return its value
Update Category
PUT /news/categories/{id}
Path Parameters
id*
Integer
Headers
Client-Key*
String
Your client Key
Authorization*
String
Bearer access_token
Request Body
name*
String
The name of the category
slug
String
description
String
Delete Category
Delete news category by id
Delete Category
DELETE /news/categories/{id}
Path Parameters
*
Integer
Headers
Client-Key*
String
Your client Key
Authorization*
String
Bearer access_token
Example Request
Last updated