2 Replies Latest reply on Nov 18, 2015 3:44 PM by joel.gralton

    Mark documents in a specific category as Official?

    joel.gralton Novice

      I'm trying to use the cloud API to mark all documents in a specific category as official. I am trying with a single file first to make sure the API call and JSON body is correct but am having issues.

      The problem I run into is once the call is run, it sometimes marks the doc as official but it then removed the category. When adding the category field into the json call it succeeds, the document edited time is updated but the document is not marked as official.


      It seems that the order of operations may be adding the category back to the document as the last part of the call which would remove the 'Official' mark as there has been a change?


      I am using a PUT request to {jive URL}/api/core/v3/contents/{contentID}


      with the following payload:


          "subject" : "File title here",

          "parent" : "https://jivesite.jiveon.com/api/core/v3/places/{PlaceID}",

          "outcomeCounts" : {

            "official" : 1


          "outcomeTypeNames" : [ "official" ],

           "visibility" : "place",

          "outcomeTypes" : [ {

            "id" : "7",

            "name" : "outdated",

            "shareable" : false,

            "noteRequired" : false,

            "urlAllowed" : true,

            "generalNote" : false,

            "confirmExclusion" : false,

            "confirmUnmark" : false,

            "type" : "outcomeType"

          } ]



      it succeeds (200 OK), but doesn't change the mark.

      I have even tried manually marking the doc as official, using a GET request to pull all of the JSON payload, copy the payload, remove the official mark manually on the doc then using a PUT request and send the whole copied JSON payload back. And still nothing.


      Is it possible to mark an existing document that is already set up with tags, categories etc using the API? As the plan is to loop through all of the documents in this specific category to mass mark them all using a script once If I can get this to work.