AnsweredAssumed Answered

How can I prevent subject from getting overridden when creating Favorite (bookmark) via REST API?

Question asked by cgum on Jun 25, 2014
Latest reply on Jul 28, 2014 by Ryan Rutan

In a Cloud add-on app, I'm trying to leverage Jive's bookmarks to deep link into content within my app.

 

Here's an example of the JSON object I'm posting to /api/core/v3/contents:

 

{

  "type": "favorite",

  "status" : "published",

  "subject" : "fishing stuff",

  "content" : {

    "type" : "text/html",

    "text" : "This is all about fishing and stuff",

    "editable": true

  },

  "favoriteObject": {

     "type": "url",

     "url": "https://myjiveinstance.jiveon.com/apps/my-app#canvas:{\"path\":\"content/view/fishing_stuff\"}",

  },

  "tags": ["app_content_ec1e86ac-07a4-4b0b-a995-a40351527466"],

  "private": true

}


My problem is that after I POST this to /api/core/v3/contents, the result shows that the subject has been changed to "Login | <Jive Instance Name>"

 

In order to set the subject to what I want it to be, I have to get the newly created content URI, and do a second PUT with the same request body to /api/core/v3/contents/<contentID>.

 

Is there any way to get around this?

Outcomes