Read Repository Assigned Taxonomy's category
get
/content/management/api/v1.1/repositories/{id}/assignedTaxonomies/{taxonomyId}/categories/{categoryId}
Read a category of an assigned taxonomy under a repository.
Request
Path Parameters
-
categoryId: string
Id of an assigned taxonomy's category
-
id: string
id of the repository.
-
taxonomyId: string
Id of an assigned taxonomy
Query Parameters
-
fields(optional): string
This parameter is used to control the returned fields of the assigned category. This parameter accepts a comma-separated list of field names. These fields will be returned for the assigned category. All the field names are case-sensitive. Each assigned category can have these fields: id, name, description, apiName, position, isSiteCategory, parent, ancestors, allowedActions, descendantsAllowedActions. This parameter is optional. If it is not present, the default fields would be returned in the response: id, name, description, apiName, position, isSiteCategory.
Example: ?fields=id,name,apiName,ancestors,allowedActions,descendantsAllowedActions
This returns id, name, apiName, ancestors, allowedActions, and descendantsAllowedActions fields for the assigned category.
-
links(optional): string
This parameter accepts a comma-separated list of link names. By default, this parameter gives all the links applicable. Possible values are: self, canonical, describedby
Response
Supported Media Types
- application/json
200 Response
OK.
Root Schema : AssignedCategory
Type:
object
AssignedCategory
Show Source
-
allowedActions(optional):
array allowedActions
The allowed actions of an assigned category. The actions can be "ASSET_CATEGORIZE" and "SITE_CREATE".
-
ancestors(optional):
array ancestors
The ancestors of an assigned category, listing in a top-down order from the root category to the immediate parent category.
-
apiName(optional):
string
The API name of an assigned category.
-
descendantsAllowedActions(optional):
array descendantsAllowedActions
The aggregated allowed actions of the descendants of an assigned category. The actions can be "ASSET_CATEGORIZE" and "SITE_CREATE". If the category has no child, the actions would be an empty array.
-
description(optional):
string
The description of an assigned category.
-
id(optional):
string
The id of an assigned category.
-
isSiteCategory(optional):
boolean
Whether an assigned category is a site category.
-
links(optional):
array links
The links of an assigned taxonomy resource.
-
name(optional):
string
The name of an assigned category.
-
parent(optional):
object CategoryAncestorBean
-
position(optional):
integer(int32)
The position of an assigned category among its siblings.
Nested Schema : allowedActions
Type:
array
The allowed actions of an assigned category. The actions can be "ASSET_CATEGORIZE" and "SITE_CREATE".
Show Source
Nested Schema : ancestors
Type:
array
The ancestors of an assigned category, listing in a top-down order from the root category to the immediate parent category.
Show Source
Nested Schema : descendantsAllowedActions
Type:
array
The aggregated allowed actions of the descendants of an assigned category. The actions can be "ASSET_CATEGORIZE" and "SITE_CREATE". If the category has no child, the actions would be an empty array.
Show Source
Nested Schema : links
Type:
array
The links of an assigned taxonomy resource.
Show Source
-
Array of:
object Link
Link of the resource.
Nested Schema : CategoryAncestorBean
Type:
Show Source
object
-
apiName(optional):
string
The apiName of the Category ancestor
-
id(optional):
string
The id of the Category ancestor.
-
name(optional):
string
The name of the Category ancestor.
Nested Schema : Link
Type:
object
Link of the resource.
Show Source
-
href(optional):
string
The target resource's URI. It could be template URI. It is a required property in the get response.
-
mediaType(optional):
string
Media type.
-
method(optional):
string
What HTTP method can be used to access the target resource.
-
profile(optional):
string
Link to the metadata that describes the target resource.
-
rel(optional):
string
Relation type. It is a required property in the get response.
-
templated(optional):
boolean
Whether the URI is a template.
304 Response
Not modified.
400 Response
Bad request.
403 Response
Forbidden.
404 Response
Not found.
500 Response
Internal server error.
Examples
The following example shows how to read a category of an assigned taxonomy under a repository by submitting a GET request using cURL.
curl -X GET -H 'Accept: application/json' 'https://host:port/content/management/api/v1.1/repositories/{id}/assignedTaxonomies/{taxonomyId}/categories/{categoryId}'
Example 1:
This reads category 8A34CF67453E4BDE94505476C03B1066 of taxonomy FB8240D6DC70407F87ED111325D06F89 that is assigned to the repository 720E2B7391E64FB9A1EB5FA6DEA8F4C7.
/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories/8A34CF67453E4BDE94505476C03B1066?fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions
Response Body
{ "id": "8A34CF67453E4BDE94505476C03B1066", "name": "IT East", "description": "", "apiName": "org-r-i", "position": 2, "isSiteCategory": false, "parent": { "id": "03C2AB780DDD442CAC90328A0CA6687E", "name": "Region East", "apiName": "org-r" }, "ancestors": [ { "id": "03C2AB780DDD442CAC90328A0CA6687E", "name": "Region East", "apiName": "org-r" } ], "allowedActions": [ "ASSET_CATEGORIZE", "SITE_CREATE" ], "descendantsAllowedActions": [], "links": [ { "href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories/8A34CF67453E4BDE94505476C03B1066?fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions", "rel": "self", "method": "GET", "mediaType": "application/json" }, { "href": "http://{hostname}/content/management/api/v1.1/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories/8A34CF67453E4BDE94505476C03B1066?fields=id,name,description,apiName,position,isSiteCategory,parent,ancestors,allowedActions,descendantsAllowedActions", "rel": "canonical", "method": "GET", "mediaType": "application/json" }, { "href": "http://{hostname}/content/management/api/v1.1/metadata-catalog/repositories/720E2B7391E64FB9A1EB5FA6DEA8F4C7/assignedTaxonomies/FB8240D6DC70407F87ED111325D06F89/categories/8A34CF67453E4BDE94505476C03B1066", "rel": "describedby", "method": "GET", "mediaType": "application/json" } ] }