Create a new draft version
post
/content/management/api/v1.1/taxonomies/{id}/createDraft
Create a new draft taxonomy from an existing taxonomy.
Request
Path Parameters
-
id: string
id of the taxonomy.
Query Parameters
-
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
Header Parameters
-
X-Requested-With: string
A custom header to mitigate CSRF attacks.Allowed Values:
[ "XMLHttpRequest" ]
Taxonomy create draft request payload. The status and version will be used to determine the source taxonomy. Currently, the version is not used.
When a new draft is created, in case the shortName of the promoted taxonomy has any conflicts with other taxonomies, a new shortName will be generated. Followed by any changes to the shortName, any category without apiName will have one automatically generated.
This is an asynchronous operation. Asynchronous request is responded with 202 status with a status link in the location header.
When a new draft is created, in case the shortName of the promoted taxonomy has any conflicts with other taxonomies, a new shortName will be generated. Followed by any changes to the shortName, any category without apiName will have one automatically generated.
This is an asynchronous operation. Asynchronous request is responded with 202 status with a status link in the location header.
Root Schema : TaxonomyOperationCreateDraftRequest
Type:
object
Taxonomy Operation Create Draft Request
Show Source
-
status(optional):
string
Status of the Taxonomy (draft/promoted). Currently, only promoted taxonomies can be used to create a new draft.
-
version(optional):
integer(int32)
Version of a Taxonomy. The version field is currently ignored.
Response
Supported Media Types
- application/json
202 Response
Accepted.
400 Response
Bad request.
403 Response
Forbidden.
404 Response
Taxonomy not found. The requested resource not found.
409 Response
The requested resource operation is temporarily unavailable
500 Response
Internal server error.
Examples
The following example shows how to create a draft taxonomy from an exiting promoted taxonomy by submitting a POST request on the REST resource using cURL:
curl -X POST -H 'Content-Type: application/json' -H 'X-Requested-With: XMLHttpRequest' 'https://host:port/content/management/api/v1.1/taxonomies/{id}/createDraft'
Example:
Creates a draft taxonomy from an existing promoted taxonomy.
/content/management/api/v1.1/taxonomies/D7969D6CA0D144AEA9CCA88BA6D2CF81/createDraft
Request Body
{ "status": "promoted" }