<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>Content Script API Type</title><link>https://community.telligent.com/community/11/w/api-documentation/66297/content-script-api-type</link><description /><dc:language>en-US</dc:language><generator>14.0.0.586 14</generator><item><title>Content Script API Type</title><link>https://community.telligent.com/community/11/w/api-documentation/66297/content-script-api-type</link><pubDate>Wed, 20 Nov 2019 15:04:54 GMT</pubDate><guid isPermaLink="false">f6ce87da-d4af-41d3-a830-cf8f0b27fea5</guid><dc:creator>Ben Tiedt</dc:creator><comments>https://community.telligent.com/community/11/w/api-documentation/66297/content-script-api-type#comments</comments><description>Current Revision posted to API Documentation by Ben Tiedt on 11/20/2019 15:04:54&lt;br /&gt;
&lt;hr class="generated-documentation-start" style="border-width:0;" /&gt;&lt;div class="documentation"&gt;&lt;p&gt;Content created on the site must implement this interface for the social services to support it.&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="#Properties"&gt;Properties&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="#HasErrors"&gt;HasErrors&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="#HasWarnings"&gt;HasWarnings&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="#HasWarningsOrErrors"&gt;HasWarningsOrErrors&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="#HtmlDescription"&gt;HtmlDescription&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="#HtmlName"&gt;HtmlName&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="#ThrowErrors"&gt;ThrowErrors&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="#ViewHtml"&gt;ViewHtml&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;a name="Properties"&gt;&lt;/a&gt;&lt;div class="documentation-members properties"&gt;&lt;h3&gt;&lt;a id="Properties" name="Properties"&gt;&lt;/a&gt;Properties&lt;/h3&gt;&lt;table cellspacing="0" cellpadding="2" width="99%" class="WikiTable"&gt;&lt;thead&gt;&lt;tr class="WikiTableBgBlue"&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Access&lt;/th&gt;&lt;th&gt;Type&lt;/th&gt;&lt;th&gt;Description&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;Application&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;[[Application Script API Type|Application]]&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;The application in which the IContent is located.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;AvatarUrl&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;String&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;Url to an image particular to the content or content type.  If none, return null.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;ContentId&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;Guid&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;A Guid uniquely identifying the content.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;ContentTypeId&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;Guid&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;A Guid identifying the type of content.  All content of the same type (i.e. wiki page) will have the same value here.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;CreatedByUserId&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;Nullable of Int32&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;The Id of the user who originated the content.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;CreatedDate&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;DateTime&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;The date the content was created.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;DataTypeId&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;Guid&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;Data Type Id&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;Errors&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;IList of [[Error Script API Type|Error]]&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;Errors&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;IsEnabled&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;Boolean&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;A flag representing whether the content is enabled.  This can be a wrapper for approval states, etc.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;Url&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;String&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;A Url to the content on the site.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;Warnings&lt;/td&gt;&lt;td rowspan="1"&gt;Read&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;IList of [[Warning Script API Type|Warning]]&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;Warnings&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;div class="documentation-members methods"&gt;&lt;h3&gt;&lt;a id="Methods" name="Methods"&gt;&lt;/a&gt;Methods&lt;/h3&gt;&lt;a name="HasErrors"&gt;&lt;/a&gt;&lt;h2&gt;&lt;a id="HasErrors" name="HasErrors"&gt;&lt;/a&gt;HasErrors&lt;/h2&gt;&lt;h4&gt;&lt;a id="Velocity" name="Velocity"&gt;&lt;/a&gt;&lt;em&gt;Velocity&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: velocity"&gt;#set($booleanResponse = $content.HasErrors())&lt;/pre&gt;&lt;h4&gt;&lt;a id="JavaScript" name="JavaScript"&gt;&lt;/a&gt;&lt;em&gt;JavaScript&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: javascript"&gt;var booleanResponse = content.HasErrors();&lt;/pre&gt;&lt;h4&gt;&lt;a id="Returns" name="Returns"&gt;&lt;/a&gt;&lt;em&gt;Returns&lt;/em&gt;&lt;/h4&gt;&lt;p&gt;&lt;div&gt;&lt;code&gt;Boolean&lt;/code&gt;&lt;/div&gt;&lt;/p&gt;&lt;a name="HasWarnings"&gt;&lt;/a&gt;&lt;h2&gt;&lt;a id="HasWarnings" name="HasWarnings"&gt;&lt;/a&gt;HasWarnings&lt;/h2&gt;&lt;h4&gt;&lt;a id="Velocity" name="Velocity"&gt;&lt;/a&gt;&lt;em&gt;Velocity&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: velocity"&gt;#set($booleanResponse = $content.HasWarnings())&lt;/pre&gt;&lt;h4&gt;&lt;a id="JavaScript" name="JavaScript"&gt;&lt;/a&gt;&lt;em&gt;JavaScript&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: javascript"&gt;var booleanResponse = content.HasWarnings();&lt;/pre&gt;&lt;h4&gt;&lt;a id="Returns" name="Returns"&gt;&lt;/a&gt;&lt;em&gt;Returns&lt;/em&gt;&lt;/h4&gt;&lt;p&gt;&lt;div&gt;&lt;code&gt;Boolean&lt;/code&gt;&lt;/div&gt;&lt;/p&gt;&lt;a name="HasWarningsOrErrors"&gt;&lt;/a&gt;&lt;h2&gt;&lt;a id="HasWarningsOrErrors" name="HasWarningsOrErrors"&gt;&lt;/a&gt;HasWarningsOrErrors&lt;/h2&gt;&lt;h4&gt;&lt;a id="Velocity" name="Velocity"&gt;&lt;/a&gt;&lt;em&gt;Velocity&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: velocity"&gt;#set($booleanResponse = $content.HasWarningsOrErrors())&lt;/pre&gt;&lt;h4&gt;&lt;a id="JavaScript" name="JavaScript"&gt;&lt;/a&gt;&lt;em&gt;JavaScript&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: javascript"&gt;var booleanResponse = content.HasWarningsOrErrors();&lt;/pre&gt;&lt;h4&gt;&lt;a id="Returns" name="Returns"&gt;&lt;/a&gt;&lt;em&gt;Returns&lt;/em&gt;&lt;/h4&gt;&lt;p&gt;&lt;div&gt;&lt;code&gt;Boolean&lt;/code&gt;&lt;/div&gt;&lt;/p&gt;&lt;a name="HtmlDescription"&gt;&lt;/a&gt;&lt;h2&gt;&lt;a id="HtmlDescription" name="HtmlDescription"&gt;&lt;/a&gt;HtmlDescription&lt;/h2&gt;&lt;p&gt;Return the Html encoded description of the content (the body, for example).  Possible values for “target” are “Web”, “Email”, “WebServices”, or “raw”.  When “raw” is specified as the target, the description should not be encoded or have any special rendering done to it.&lt;/p&gt;&lt;h4&gt;&lt;a id="Velocity" name="Velocity"&gt;&lt;/a&gt;&lt;em&gt;Velocity&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: velocity"&gt;#set($stringResponse = $content.HtmlDescription($target))&lt;/pre&gt;&lt;h4&gt;&lt;a id="JavaScript" name="JavaScript"&gt;&lt;/a&gt;&lt;em&gt;JavaScript&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: javascript"&gt;var stringResponse = content.HtmlDescription(target);&lt;/pre&gt;&lt;h4&gt;&lt;a id="Parameters" name="Parameters"&gt;&lt;/a&gt;&lt;em&gt;Parameters&lt;/em&gt;&lt;/h4&gt;&lt;table cellspacing="0" cellpadding="2" width="99%" class="WikiTable"&gt;&lt;thead&gt;&lt;tr class="WikiTableBgBlue"&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Type&lt;/th&gt;&lt;th&gt;Description&lt;/th&gt;&lt;th&gt;Required&lt;/th&gt;&lt;th&gt;Default&lt;/th&gt;&lt;th&gt;Options&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;target&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;String&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;Target&lt;/td&gt;&lt;td rowspan="1"&gt;Required&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;&lt;a id="Returns" name="Returns"&gt;&lt;/a&gt;&lt;em&gt;Returns&lt;/em&gt;&lt;/h4&gt;&lt;p&gt;&lt;div&gt;&lt;code&gt;String&lt;/code&gt;&lt;/div&gt;&lt;/p&gt;&lt;a name="HtmlName"&gt;&lt;/a&gt;&lt;h2&gt;&lt;a id="HtmlName" name="HtmlName"&gt;&lt;/a&gt;HtmlName&lt;/h2&gt;&lt;p&gt;Return the Html encoded name of the content (the subject for example).  Possible values for “target” are “Web”, “Email”, or “raw”.  When “raw” is specified as the target, the name should not be encoded.&lt;/p&gt;&lt;h4&gt;&lt;a id="Velocity" name="Velocity"&gt;&lt;/a&gt;&lt;em&gt;Velocity&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: velocity"&gt;#set($stringResponse = $content.HtmlName($target))&lt;/pre&gt;&lt;h4&gt;&lt;a id="JavaScript" name="JavaScript"&gt;&lt;/a&gt;&lt;em&gt;JavaScript&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: javascript"&gt;var stringResponse = content.HtmlName(target);&lt;/pre&gt;&lt;h4&gt;&lt;a id="Parameters" name="Parameters"&gt;&lt;/a&gt;&lt;em&gt;Parameters&lt;/em&gt;&lt;/h4&gt;&lt;table cellspacing="0" cellpadding="2" width="99%" class="WikiTable"&gt;&lt;thead&gt;&lt;tr class="WikiTableBgBlue"&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Type&lt;/th&gt;&lt;th&gt;Description&lt;/th&gt;&lt;th&gt;Required&lt;/th&gt;&lt;th&gt;Default&lt;/th&gt;&lt;th&gt;Options&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;target&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;String&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;Target&lt;/td&gt;&lt;td rowspan="1"&gt;Required&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;&lt;a id="Returns" name="Returns"&gt;&lt;/a&gt;&lt;em&gt;Returns&lt;/em&gt;&lt;/h4&gt;&lt;p&gt;&lt;div&gt;&lt;code&gt;String&lt;/code&gt;&lt;/div&gt;&lt;/p&gt;&lt;a name="ThrowErrors"&gt;&lt;/a&gt;&lt;h2&gt;&lt;a id="ThrowErrors" name="ThrowErrors"&gt;&lt;/a&gt;ThrowErrors&lt;/h2&gt;&lt;h4&gt;&lt;a id="Velocity" name="Velocity"&gt;&lt;/a&gt;&lt;em&gt;Velocity&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: velocity"&gt;$content.ThrowErrors()&lt;/pre&gt;&lt;h4&gt;&lt;a id="JavaScript" name="JavaScript"&gt;&lt;/a&gt;&lt;em&gt;JavaScript&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: javascript"&gt;content.ThrowErrors();&lt;/pre&gt;&lt;h4&gt;&lt;a id="Returns" name="Returns"&gt;&lt;/a&gt;&lt;em&gt;Returns&lt;/em&gt;&lt;/h4&gt;&lt;span&gt;Nothing&lt;/span&gt;&lt;a name="ViewHtml"&gt;&lt;/a&gt;&lt;h2&gt;&lt;a id="ViewHtml" name="ViewHtml"&gt;&lt;/a&gt;ViewHtml&lt;/h2&gt;&lt;h3&gt;&lt;a id="ViewHtml_Overload_1" name="ViewHtml_Overload_1"&gt;&lt;/a&gt;ViewHtml Overload 1&lt;/h3&gt;&lt;h4&gt;&lt;a id="Velocity" name="Velocity"&gt;&lt;/a&gt;&lt;em&gt;Velocity&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: velocity"&gt;#set($stringResponse = $content.ViewHtml())&lt;/pre&gt;&lt;h4&gt;&lt;a id="JavaScript" name="JavaScript"&gt;&lt;/a&gt;&lt;em&gt;JavaScript&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: javascript"&gt;var stringResponse = content.ViewHtml();&lt;/pre&gt;&lt;h3&gt;&lt;a id="ViewHtml_Overload_2" name="ViewHtml_Overload_2"&gt;&lt;/a&gt;ViewHtml Overload 2&lt;/h3&gt;&lt;h4&gt;&lt;a id="Velocity" name="Velocity"&gt;&lt;/a&gt;&lt;em&gt;Velocity&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: velocity"&gt;#set($stringResponse = $content.ViewHtml($target))&lt;/pre&gt;&lt;h4&gt;&lt;a id="JavaScript" name="JavaScript"&gt;&lt;/a&gt;&lt;em&gt;JavaScript&lt;/em&gt;&lt;/h4&gt;&lt;pre class="brush: javascript"&gt;var stringResponse = content.ViewHtml(target);&lt;/pre&gt;&lt;h4&gt;&lt;a id="Parameters" name="Parameters"&gt;&lt;/a&gt;&lt;em&gt;Parameters&lt;/em&gt;&lt;/h4&gt;&lt;table cellspacing="0" cellpadding="2" width="99%" class="WikiTable"&gt;&lt;thead&gt;&lt;tr class="WikiTableBgBlue"&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Type&lt;/th&gt;&lt;th&gt;Description&lt;/th&gt;&lt;th&gt;Required&lt;/th&gt;&lt;th&gt;Default&lt;/th&gt;&lt;th&gt;Options&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td rowspan="1"&gt;target&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;code&gt;String&lt;/code&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;Target&lt;/td&gt;&lt;td rowspan="1"&gt;Required&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;/td&gt;&lt;td rowspan="1"&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;&lt;a id="Returns" name="Returns"&gt;&lt;/a&gt;&lt;em&gt;Returns&lt;/em&gt;&lt;/h4&gt;&lt;p&gt;&lt;div&gt;&lt;code&gt;String&lt;/code&gt;&lt;/div&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;hr class="generated-documentation-end" style="border-width:0;" /&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;
</description></item></channel></rss>