Deskhero Developer Hub
Back to deskhero.com
Knowledge bases

List_ only aggregates

Returns only the distinct values (with counts) of the requested field_keys across the knowledge base articles the calling User can reach, so the data array comes back empty; unknown keys give 404. The same filters as the list endpoint apply, and each field returns at most its 1000 most common values.

GET /api/{tenant:minlength(2)}/v{version:apiVersion}/knowledge_bases/aggregate
Authorisation
Minimum role: USER

Request arguments

Name Type Source
field_keysString[]Query
filterDTO_standard_filterQuery
Request body example

Response

Status
200 (OK)
Type
DTO_knowledge_base[]
Wrapper
DTO_response_wrap_get_many
Other statuses
400 (BadRequest), 403 (Forbidden)
Response body example
DTO_standard_filter
NameTypeReadOnlyDescription
sort_by_keyStringSort by key
response_field_keysString[]Only return the fields specified
filtersString[]Each string needs to be structured: filters=field_key:operator:value1|value2|value3 Only used to store filters for passing along as querystring
include_aggregationsBooleanInclude aggregations
include_importedBooleanInclude imported
searchStringSearch
sort_orderENUM sort_orderSort order
takeInt32Take
pageInt32Page
DTO_knowledge_base
NameTypeReadOnlyDescription
created_byDTO_reference_userReadOnlyNull when the article was not created by a User in the workspace
last_updated_byDTO_reference_userReadOnlyNull until the article has been updated at least once after it was created
categoryDTO_referenceCategory the article belongs to, where the default category of the workspace is used when no category is sent
group_accessDTO_group_access[]Groups that may read or edit the article, where at least one entry with EDIT permission is required
sys_tagsDTO_reference[]Label can be used on POST/PUT to create new tags
sys_attachmentsDTO_reference_attachment[]Files attached to the article, referenced by the ids of files already uploaded to the workspace
idInt32ReadOnlyAssigned by the server, and must be left empty when creating an article
unique_keyStringLowercase url safe key identifying the article inside the workspace, between 2 and 30 characters, built from sys_subject when left empty
createdDateTimeReadOnlySet by the server in UTC when the article is first stored
last_updatedDateTimeReadOnlySet by the server in UTC every time the article is changed
sys_subjectStringTitle of the article, required on both create and update
sys_content_richDTO_rich_textBody of the article as rich text, where either this or sys_content_rich_draft must have content unless the article is created from a file
sys_content_rich_draftDTO_rich_textWork in progress copy of the body, stored and returned as sent and never merged into sys_content_rich by the server
publishedBooleanPublished
view_countInt32Raised by the server the first time a User opens the article (at most once per User and article every 12 hours), and overwritten by any value sent on create or update
rate_up_countInt32Number of positive ratings, maintained by the rate endpoint where each User counts once and changing an existing rating moves the count to rate_down_count
rate_down_countInt32Number of negative ratings, maintained by the rate endpoint in the same way as rate_up_count
privacyENUM privacyRequired on create and update, since the server rejects an article where privacy is left unset
highest_group_permissionENUM group_permissionReadOnlyCurrent users highest group permission
DTO_reference_user
NameTypeReadOnlyDescription
profile_picStringReadOnlyProfile pic
emailStringReadOnlyEmail
idInt32Id
labelObjectReadOnlyLabel
DTO_reference
NameTypeReadOnlyDescription
idInt32The id of the reference
labelObjectReadOnlyName/Label from referenced object.
DTO_group_access
NameTypeReadOnlyDescription
permissionENUM group_permissionPermission
idInt32Id
labelObjectReadOnlyLabel
DTO_reference_attachment
NameTypeReadOnlyDescription
size_kbInt32ReadOnlySize kb
statusENUM attachment_statusReadOnlyStatus
status_messageStringReadOnlyStatus message
download_urlStringReadOnlyDownload url
idInt32Id
labelObjectReadOnlyLabel
DTO_rich_text
NameTypeReadOnlyDescription
plain_previewStringReadOnlyPlain preview
htmlStringHtml
editorjsDTO_editorjsEditorjs
tiptapDTO_tiptapTiptap
read_minutesInt32Read minutes
DTO_editorjs
NameTypeReadOnlyDescription
timeInt64Time
versionStringVersion
blocksDTO_editorjs_block[]Blocks
DTO_editorjs_block
NameTypeReadOnlyDescription
idStringId
typeStringType
dataObjectData
DTO_tiptap
NameTypeReadOnlyDescription
typeStringType
contentDTO_tiptap_node[]Content
DTO_tiptap_node
NameTypeReadOnlyDescription
typeStringType
attrsDTO_tiptap_attrsAttrs
contentDTO_tiptap_node[]Content
textStringText
marksDTO_tiptap_mark[]Marks
DTO_tiptap_attrs
NameTypeReadOnlyDescription
textAlignStringTextalign
levelInt32 (nullable)Level
checkedBoolean (nullable)Checked
idInt32 (nullable)Id
altStringAlt
titleStringTitle
widthStringWidth
wrapperStyleStringWrapperstyle
filesDTO_tiptap_file_ref[]Files
hrefStringHref
targetStringTarget
colspanInt32 (nullable)Colspan
rowspanInt32 (nullable)Rowspan
colorStringColor
textStringText
nameStringFor emoji
nativeStringFor emoji
DTO_tiptap_file_ref
NameTypeReadOnlyDescription
idInt32Id
labelStringLabel
DTO_tiptap_mark
NameTypeReadOnlyDescription
typeStringType
attrsDTO_tiptap_attrsAttrs
ENUM group_permission
ValueNameDescription
0UNKNOWNUNKNOWN
1READRead only
2EDITEdit
3FULLFull
ENUM attachment_status
ValueNameDescription
0UNKNOWNUNKNOWN
1UNAVAILABLEUNAVAILABLE, processing in progress
2OKOK
3WARNINGWARNING
4ERRORERROR
ENUM sort_order
ValueNameDescription
0ASCASC
1DESCDESC
ENUM privacy
ValueNameDescription
0UNKNOWNUNKNOWN
1PRIVATEPRIVATE
2PUBLICPUBLIC

Generated Aug 4, 2026 18:37