Create Editorial Role

post

/content/management/api/v1.1/editorialRoles

Create a custom editorial role with the given payload.

Request

Supported Media Types
Query Parameters
Header Parameters
Body ()
bean of the request payload to create a custom editorial role.
Root Schema : EditorialRole
Type: object
EditorialRole
Show Source
Nested Schema : contentPrivileges
Type: array
The privileges of asset type defined by a custom editorial role.
Show Source
Nested Schema : date
Type: object
date
Show Source
Nested Schema : taxonomyPrivileges
Type: array
The privileges of taxonomy defined by a custom editorial role.
Show Source
Nested Schema : ContentPrivilege
Type: object
ContentPrivilege
Show Source
Nested Schema : operations
Type: array
Operations.
Show Source
Nested Schema : TaxonomyPrivilege
Type: object
TaxonomyPrivilege
Show Source
Nested Schema : nodes
Type: array
The path of the category.
Show Source
Nested Schema : operations
Type: array
Operations.
Show Source
Nested Schema : CategoryNodeBean
Type: object
Show Source
Back to Top

Response

Supported Media Types

201 Response

Created.
Body ()
Root Schema : EditorialRole
Type: object
EditorialRole
Show Source
Nested Schema : contentPrivileges
Type: array
The privileges of asset type defined by a custom editorial role.
Show Source
Nested Schema : date
Type: object
date
Show Source
Nested Schema : taxonomyPrivileges
Type: array
The privileges of taxonomy defined by a custom editorial role.
Show Source
Nested Schema : ContentPrivilege
Type: object
ContentPrivilege
Show Source
Nested Schema : operations
Type: array
Operations.
Show Source
Nested Schema : TaxonomyPrivilege
Type: object
TaxonomyPrivilege
Show Source
Nested Schema : nodes
Type: array
The path of the category.
Show Source
Nested Schema : operations
Type: array
Operations.
Show Source
Nested Schema : CategoryNodeBean
Type: object
Show Source

400 Response

Bad request.

403 Response

Forbidden.

500 Response

Internal server error.
Back to Top

Examples

The following example shows how to create a editorial role by submitting a POST request using cURL.

curl -X POST -H 'Content-Type: application/json' -H 'X-Requested-With: XMLHttpRequest' 'https://host:port/content/management/api/v1.1/editorialRoles'

Example 1

/content/management/api/v1.1/editorialRoles
This creates a custom editorial role. Replace payload with your own data.

Note:

Any type rule is defined by an empty typeId; and the any category rule is defined by an empty categoryId.

Request Payload

{
  "name": "Custom Editor Role",
  "description": "role description",
  "contentPrivileges": [
    {
      "typeId": "",
      "typeName": "",
      "operations": [
        "view"
      ]
    },
    {
      "typeId": "EF4C64E6BF81419F9743A8A4348A69EB",
      "typeName": "Image",
      "operations": [
        "view",
        "update",
        "create"
      ]
    }
  ],
  "taxonomyPrivileges": [
    {
      "taxonomyId": "",
      "categoryId": "",
      "operations": [
        "view"
      ]
    }
  ]
}

Request Headers

{
   "Content-Type": "application/json",
   "X-Requested-With": "XMLHttpRequest"
}

Response Body

{
  "id": "8788B03F236340A8A2B7ADB825ED11A9",
  "name": "Custom Editor Role",
  "description": "role description",
  "createdBy": "cecuser1",
  "createdDate": {
    "value": "2021-09-13T19:02:39.947Z",
    "timezone": "UTC"
  },
  "updatedBy": "cecuser1",
  "updatedDate": {
    "value": "2021-09-13T19:02:39.947Z",
    "timezone": "UTC"
  },
  "roleName": "manager",
  "contentPrivileges": [
    {
      "typeId": "",
      "typeName": null,
      "isValid": true,
      "operations": [
        "view"
      ]
    },
    {
      "typeId": "EF4C64E6BF81419F9743A8A4348A69EB",
      "typeName": "Image",
      "isValid": true,
      "operations": [
        "view",
        "update",
        "create"
      ]
    }
  ],
  "taxonomyPrivileges": [
    {
      "taxonomyId": null,
      "taxonomyShortName": null,
      "isForSiteManagement": false,
      "categoryId": "",
      "nodes": null,
      "isSiteCategory": false,
      "isValid": true,
      "operations": [
        "view"
      ]
    }
  ],
  "links": [
    {
      "href": "http://<hostname>/content/management/api/v1.1/editorialRoles",
      "rel": "self",
      "method": "POST",
      "mediaType": "application/json"
    },
    {
      "href": "http://<hostname>/content/management/api/v1.1/editorialRoles",
      "rel": "canonical",
      "method": "POST",
      "mediaType": "application/json"
    },
    {
      "href": "http://<hostname>/content/management/api/v1.1/metadata-catalog/editorialRoles",
      "rel": "describedby",
      "method": "GET",
      "mediaType": "application/schema+json"
    }
  ]
}
 

Example 2

/content/management/api/v1.1/editorialRoles
This creates a custom editorial role including a taxonomy rule with createSite permission. Replace payload with your own data.

Note:

The any type rule is defined by an empty typeId; and the any category rule is defined by an empty categoryId.

Request Payload

{
  "name": "Site Security Custom Editorial Role",
  "description": "role description",
  "contentPrivileges": [
    {
      "typeId": "",
      "typeName": "",
      "isValid": true,
      "operations": [
        "view",
        "update",
        "create",
        "delete"
      ]
    }
  ],
  "taxonomyPrivileges": [
    {
      "taxonomyId": "",
      "categoryId": "",
      "isValid": true,
      "operations": [
        "view",
        "categorize"
      ]
    },
    {
      "taxonomyId": "AF6B75DBBCA244FC93166610EA2BA62A",
      "categoryId": "F54C934D081B4768B3A93A45C0E6955C",
      "isValid": true,
      "operations": [
        "view",
        "categorize",
        "createSite"
      ]
    }
  ]
}

Request Headers

{
  "Content-Type": "application/json",
  "X-Requested-With": "XMLHttpRequest"
}

Response Body

{
  "id": "0FCCDAB83A6D41819C15B61445F9E686",
  "name": "Site Security Custom Editorial Role",
  "description": "role description",
  "createdBy": "cecuser1",
  "createdDate": {
    "value": "2023-01-11T02:31:04.992Z",
    "timezone": "UTC"
  },
  "updatedBy": "cecuser1",
  "updatedDate": {
    "value": "2023-01-11T02:31:04.992Z",
    "timezone": "UTC"
  },
  "roleName": "manager",
  "contentPrivileges": [
    {
      "typeId": "",
      "typeName": null,
      "typeDisplayName": null,
      "isValid": true,
      "operations": [
        "view",
        "update",
        "create",
        "delete"
      ]
    }
  ],
  "taxonomyPrivileges": [
    {
      "taxonomyId": null,
      "taxonomyShortName": null,
      "isForSiteManagement": false,
      "categoryId": "",
      "nodes": null,
      "isSiteCategory": false,
      "isValid": true,
      "operations": [
        "view",
        "categorize"
      ]
    },
    {
      "taxonomyId": "AF6B75DBBCA244FC93166610EA2BA62A",
      "taxonomyShortName": "SST",
      "isForSiteManagement": true,
      "categoryId": "F54C934D081B4768B3A93A45C0E6955C",
      "nodes": [
        {
          "id": "BE58B209A968480480AA2AFBCE9C2D64",
          "name": "org1",
          "apiName": "sst-o"
        },
        {
          "id": "F54C934D081B4768B3A93A45C0E6955C",
          "name": "team1",
          "apiName": "sst-o-d"
        }
      ],
      "isSiteCategory": false,
      "isValid": true,
      "operations": [
        "view",
        "categorize",
        "createSite"
      ]
    }
  ],
  "links": [
    {
      "href": "http://<hostname>/content/management/api/v1.1/editorialRoles",
      "rel": "self",
      "method": "POST",
      "mediaType": "application/json"
    },
    {
      "href": "http://<hostname>/content/management/api/v1.1/editorialRoles",
      "rel": "canonical",
      "method": "POST",
      "mediaType": "application/json"
    },
    {
      "href": "http://<hostname>/content/management/api/v1.1/metadata-catalog/editorialRoles",
      "rel": "describedby",
      "method": "GET",
      "mediaType": "application/json"
    }
  ]
}
 
Back to Top