Replace the settings of one content type
/org-content/settings/{id}Sets how the organisation sorts one type of content, from the values in the schema; null goes back to the default. Lists then follow it unless the request names a sort. Needs permission to manage the organisation's content. It has no dry run, and no webhook, email or notification is sent. Sending the earlier value undoes it.
Path parameters
- One of:
The content type: news, event or resource.
news,event,resource
Request body
application/json, required · OrgContentSettingReplace
- One of:
How the type is ordered after the featured item: title, date_modified, date_created, oldest_to_newest, newest_to_oldest, publish_date_oldest_to_newest or publish_date_newest_to_oldest. null restores the default, newest_to_oldest.
title,date_modified,date_created,oldest_to_newest,newest_to_oldest,publish_date_oldest_to_newest,publish_date_newest_to_oldest
{
"sort": "title"
}Responses
{
"data": {
"type": "news",
"sort": "title"
}
}Authorization failed. error.code is one of org_disabled,
ip_blocked, missing_scope, scope_disabled, user_disabled.
The request can't be processed (HTTP 422): validation_failed with one ErrorDetail per
problem, or a code documented on the operation.
Examples
curl -X PUT https://your-org-domain/kong/core/api/v2/org-content/settings/{id}\
-H "Authorization: Bearer $HELM_API_KEY"\
-H "Content-Type: application/json"\
-d '{
"sort": "title"
}'