API /content/{contentId}/update

ThoughtFarmer REST API Method: /content/{contentId}/update

Updates content in ThoughtFarmer. Returns the updated content when successful. Will only updated the optional parameters supplied, not all parameters need to be a part of the call.


Response Formats:

HTTP Method(s):

Requires Authentication:
true, user making call must pass a valid token parameter and must have edit permissions


Parameter Type Description
contentId int Required. The content id of the content to update
title string(255) The title of the content
body string The body text of the content
culture string(5) The culture of the content. If not supplied or not valid, defaults to the culture of the user adding the content.
pageType string Page, Section, Calendar, PhotoGallery, NewsBlog, Forum, Group, Post, CalendarEvent, Document, ForumTopic
layout string
Required if the pageType is changed.
LeftNavigation - For pageType Page
CompactDirectory, NavigationTwoColumn, NavigationOneColumn, Thumbnail - For pageType Section or Group
Day, Week, Month - For pageType CalendarEvent
News, Blog - For pageType NewsBlog
None - For all other pageType values
isPublished bool true, false. False will set the page to be Private.
token string Required. A valid token authentication parameter

Optional parameters for just CalendarEvent 
Parameter Type Description
startDate string
Required. ISO 8601 date string representing the desired start date. If a valid date format not in ISO 8601 is used (with no timezone), then the logged in user's timezone will be used instead.
endDate string ISO 8601 date string representing the desired end date. If a valid date format not in ISO 8601 is used (with no timezone),
then the logged in user's timezone will be used instead. If not supplied then the default event length of 1 hour will be used.
isAllDay bool true, false. True to set the event to an all day event.
eventType int Integer representing the eventType for the event. Can be taken from the column CustomEventTypeID  in the ThoughtFarmer table CustomEventTypeLocalized 

Response Status Codes:
200 - Update successful
401 - Token parameter is invalid
403 - No permissions to make update
404 - Content not found
500 - Any parameter validation error.

Example request
POST Data title={title}&body={body}&culture={culture}&pageType={pageType}&layout={layout}&isPublished={isPublished}&token={token}
         "Value":"Page Title"
   "TreePathText":"Directory  People  David Root, Product Marketing  Page Title",
   "Body":"Page Body"