Update a Content Library Media File

post

/rest/api/v1.3/clItems/{itemPath}

Request

Path Parameters
Body ()
Request Body
Root Schema : Content Library Media Files
Type: object
Title: Content Library Media Files
Show Source
Back to Top

Response

Supported Media Types

Default Response

Body ()
Root Schema : Content Library Media Files
Type: object
Title: Content Library Media Files
Show Source
Back to Top

Examples

This interface is used to update the contents of a content library media file.

A successful request requires the following headers:

FIELDS DESCRIPTION
Authorization <AUTH_TOKEN>
Content-Type application/json

Sample Request Body:

NOTES:
  • Since the payload accepts binary content, the entire content of the existing media file will be replaced with the content provided in the request payload.
  • Ensure that the itemData value is a base64-encoded binary string with no extraneous hidden characters. When the itemData value contains hidden characters, such as such as carriage returns or line feeds, the response returns an HTTP code of 500 and the error details return only an ID number.
	{
       "itemPath" : "/contentlibrary/abn/testcreate.png",
       "itemData": "<base64 encoded binary string>"
    }

Sample Response :Success

Note: The "itemData" attribute in the response is returned as null always. This is done to avoid returning large binary content in the response.

 {
   "itemPath": "/contentlibrary/abn/testcreate_50.png",
   "itemData": null,
   "links":    [
            {
         "rel": "self",
         "href": "/rest/api/v1.3/clItems/contentlibrary/abn/testcreate_50.png",
         "method": "POST"
      },
            {
         "rel": "getContentLibraryItem",
         "href": "/rest/api/v1.3/clItems/contentlibrary/abn/testcreate_50.png",
         "method": "GET"
      },
            {
         "rel": "deleteContentLibraryItem",
         "href": "/rest/api/v1.3/clItems/contentlibrary/abn/testcreate_50.png",
         "method": "DELETE"
      },
            {
         "rel": "createContentLibraryItem",
         "href": "/rest/api/v1.3/clItems",
         "method": "POST"
      }
   ]
}


	

Sample Response: Failure

   {
   "type": "",
   "title": "Invalid request parameters",
   "errorCode": "INVALID_PARAMETER",
   "detail": "Item Path in the URI does not match Item Path in the request payload",
   "errorDetails": []
}

	
Back to Top