Knowledge Base items
List
Get a paginated list of knowledge base items
GET https://api.deskero.com/knowledgeItem/list
Headers
Header |
Value |
Authorization |
Bearer {{bearer}} |
Accept |
application/json |
clientId |
{{clientId}} |
URL parameters
Field name |
Value |
Required |
Default |
page |
int value for page to show |
false |
1 |
Example request
$ curl https://api.deskero.com/knowledgeItem/list \
-v \
-H "Accept: application/json" \
-H "Authorization: Bearer 58cfg61g-1585-5c72-g35f-7fe76893ed2f" \
-H "clientId: 51f01687e4b094c81d7b8bcdellef"
Example response
{
"knowledge base": {
"totalRecords": 50,
"recordsPerPage": 25,
"previousQuery": null,
"nextQuery": "https://api.deskero.com/knowledgeItem/list?page=2",
"records": [
See knowledge base item detail
]
}
}
Search
Search a knowledge base item
GET https://api.deskero.com/knowledgeItem/list
Headers
Header |
Value |
Authorization |
Bearer {{bearer}} |
Accept |
application/json |
clientId |
{{clientId}} |
URL parameters
Field name |
Value |
Required |
Default |
page |
int value for page to show |
false |
1 |
{{fieldName}} |
a value to search |
false |
|
Example request
$ curl https://api.deskero.com/knowledgeItem/list?item=Sign in\
-v \
-H "Accept: application/json" \
-H "Authorization: Bearer 58cfg61g-1585-5c72-g35f-7fe76893ed2f" \
-H "clientId: 51f01687e4b094c81d7b8bcdellef"
Example response
{
"knowledge base": {
"totalRecords": 1,
"recordsPerPage": 25,
"previousQuery": null,
"nextQuery": null,
"records": [
See knowledge base item detail
]
}
}
Detail
Show a single knowledge base item
GET https://api.deskero.com/knowledgeItem/{{knowledgeBaseItemId}}
Headers
Header |
Value |
Authorization |
Bearer {{bearer}} |
Accept |
application/json |
clientId |
{{clientId}} |
Example request
$ curl https://api.deskero.com/knowledgeItem/51cd8af3e4b0e90b324ab778 \
-v \
-H "Accept: application/json" \
-H "Authorization: Bearer 58cfg61g-1585-5c72-g35f-7fe76893ed2f" \
-H "clientId: 51f01687e4b094c81d7b8bcdellef"
Example response
{
"id": "51b9d6b8e4b0d7cf068b9749",
"title": "How do I log in?",
"text": "To sign in all you have to do is inserting your email and your password, and that’s it!",
"insertDate": 1372425039129,
"views": 9,
"insertBy": {
See agent detail
},
"approved": true,
"featured": true,
"contributeBy": {
See customer detail
},
"area": {
See knowledge base area detail
},
"tags": [
See tag detail
],
"attachedDocuments": [
See attached document detail
],
"votesNumber": 5,
"votesSum": 25,
"score": 5
}
Create
Create a new knowledge base item
POST https://api.deskero.com/knowledgeItem/insert
Headers
Header |
Value |
Authorization |
Bearer {{bearer}} |
Content-Type |
application/json |
clientId |
{{clientId}} |
Example request
$ curl https://api.deskero.com/knowledgeItem/insert \
-v \
-H "Content-item: application/json" \
-H "Authorization: Bearer 58cfg61g-1585-5c72-g35f-7fe76893ed2f" \
-H "clientId: 51f01687e4b094c81d7b8bcdellef" \
-X POST \
-d '{
"title":"How do I log in?",
"text":"To sign in all you have to do is inserting your email and your password, and that’s it!",
"area":{
"id":"51cd8af3e4b0e90b324ab778"
}
}'
Example response
Created knowledge base item id
{
"id": "51b9d6b8e4b0d7cf068b9749"
}
Update
Update a knowledge base item
PUT https://api.deskero.com/knowledgeItem/update/{{knowledgeItemId}}
Headers
Header |
Value |
Authorization |
Bearer {{bearer}} |
Content-Type |
application/json |
clientId |
{{clientId}} |
Example request
$ curl https://api.deskero.com/knowledgeItem/update/51b9d6b8e4b0d7cf068b9749 \
-v \
-H "Content-item: application/json" \
-H "Authorization: Bearer 58cfg61g-1585-5c72-g35f-7fe76893ed2f" \
-H "clientId: 51f01687e4b094c81d7b8bcdellef" \
-X PUT \
-d '{
"title":"How do I log in?",
"text":"To sign in all you have to do is inserting your email and your password, and that’s it!",
"area":{
"id":"51cd8af3e4b0e90b324ab778"
}
}'
Example response
Updated knowledge base item id
{
"id": "51b9d6b8e4b0d7cf068b9749"
}
Delete
Delete a knowledge base item
DELETE https://api.deskero.com/knowledgeItem/delete/{{knowledgeItemId}}
Headers
Header |
Value |
Authorization |
Bearer {{bearer}} |
Content-Type |
application/json |
clientId |
{{clientId}} |
Example request
$ curl https://api.deskero.com/knowledgeItem/delete/51b9d6b8e4b0d7cf068b9749 \
-v \
-H "Content-item: application/json" \
-H "Authorization: Bearer 58cfg61g-1585-5c72-g35f-7fe76893ed2f" \
-H "clientId: 51f01687e4b094c81d7b8bcdellef" \
-X DELETE
Example response
Deleted knowledge base item id
{
"id": "51b9d6b8e4b0d7cf068b9749"
}
Fields
Field name |
Description |
id |
auto-generated id |
title |
title |
text |
full text |
insertDate |
full text |
text |
insert date timestamp |
views |
views counter |
insertBy |
agent who insert or approve the item, see agent detail |
approved |
approval status, true/false |
featured |
featured item, true/false |
contributeBy |
customer who propose the item, see customer detail |
area |
item's area, see knowledge base area detail |
tags |
list of tags, see tag detail |
attachedDocuments |
list of attached documents, see attached document detail |
votesNumber |
number of votes received |
votesSum |
sum of all votes received |
score |
calculated score, votesSum divided by votesNumber |
visibility |
item visibility |
agentGroups |
list of agents group who can view this item, see agent group detail |
customerCompanies |
list of customer company who can view this item, see customer company detail |