Enables scripted content fragments to use Blogs
- Properties
- Create
- CreateContactRequest
- Delete
- DeleteContactRequest
- Get
- GetContactRequest
- IsSubscribed
- List
- ListContactRequests
- ListForQuickPost
- ListTaggedContent
- ListTags
- Search
- SetSubscribed
- SubscribeAnonymously
- Update
Properties
Name | Access | Type | Description |
---|---|---|---|
ApplicationTypeId | Read | Guid | Blogs application type identifier |
ContentTypeId | Read | Guid | Blogs content type identifier |
Current | Read | Blog | Current contextual blog |
ThemeTypeId | Read | Guid | Blogs theme type identifier |
TotalLicensedRemaining | Read | Int32 | Total number licensed blogs remaining. |
Methods
Create
Create Overload 1
Creates a new blog
Velocity
#set($blogResponse = $core_v2_blog.Create($groupId, $name))
JavaScript
var blogResponse = core_v2_blog.Create(groupId, name);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
groupId | Int32 | Group Id | Required | ||
name | String | Name | Required |
Create Overload 2
Creates a new blog
Velocity
#set($blogResponse = $core_v2_blog.Create($groupId, $name, "%{ Authors = $authorsArg, DefaultPostImageUrl = $defaultPostImageUrlArg, Description = $descriptionArg, Enabled = $enabledArg, ExtendedAttributes = $extendedAttributesArg, Key = $keyArg }"))
JavaScript
var blogResponse = core_v2_blog.Create(groupId, name, { Authors: authorsArg, DefaultPostImageUrl: defaultPostImageUrlArg, Description: descriptionArg, Enabled: enabledArg, ExtendedAttributes: extendedAttributesArg, Key: keyArg });
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
groupId | Int32 | Group in which to create the blog | Required | ||
name | String | Name of the blog | Required | ||
options | Options | Set of optional parameters including: | Required | ||
Authors | String | Comma separated list of usernames | Optional | ||
DefaultPostImageUrl | String | Default Post Image Url | Optional | ||
Description | String | Description | Optional | ||
Enabled | Boolean | Enabled | Optional | True | |
ExtendedAttributes | String | Extended attributes are key-value pairs set using the syntax _ExtendedAttributes_key=value. i.e. _ExtendedAttributes_MyKey=MyValue sets ExtendedAttributes["MyKey"] to "MyValue". | Optional | ||
Key | String | If not specified, the key will be generated | Optional |
Returns
CreateContactRequest
Creates a contact request
Velocity
#set($blogContactRequestResponse = $core_v2_blog.CreateContactRequest($blogId, $subject, $body, $name, $emailAddress, $dateCreated, $ipAddress))
JavaScript
var blogContactRequestResponse = core_v2_blog.CreateContactRequest(blogId, subject, body, name, emailAddress, dateCreated, ipAddress);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
blogId | Int32 | Blog Id | Required | ||
subject | String | Subject | Required | ||
body | String | Body | Required | ||
name | String | Name | Required | ||
emailAddress | String | Email Address | Required | ||
dateCreated | DateTime | Date Created | Required | ||
ipAddress | String | Ip Address | Required |
Returns
Delete
Deletes a blog
Velocity
#set($additionalInfoResponse = $core_v2_blog.Delete($id))
JavaScript
var additionalInfoResponse = core_v2_blog.Delete(id);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
id | Int32 | Blog Id | Required |
Returns
DeleteContactRequest
Deletes a contact request
Velocity
#set($additionalInfoResponse = $core_v2_blog.DeleteContactRequest($blogId, $id))
JavaScript
var additionalInfoResponse = core_v2_blog.DeleteContactRequest(blogId, id);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
blogId | Int32 | Blog Id | Required | ||
id | Int32 | Id | Required |
Returns
Get
Get Overload 1
Gets a blog
Velocity
#set($blogResponse = $core_v2_blog.Get("%{ GroupId = $groupIdArg, Id = $idArg, Key = $keyArg }"))
JavaScript
var blogResponse = core_v2_blog.Get({ GroupId: groupIdArg, Id: idArg, Key: keyArg });
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
options | Options | Set of optional parameters including: | Required | ||
GroupId | Int32 | Either the Id or the Key + GroupId are required | Optional | ||
Id | Int32 | Either the Id or the Key + GroupId are required | Optional | ||
Key | String | Either the Id or the Key + GroupId are required | Optional |
Get Overload 2
Gets a blog
Velocity
#set($blogResponse = $core_v2_blog.Get($applicationId))
JavaScript
var blogResponse = core_v2_blog.Get(applicationId);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
applicationId | Guid | Application Id | Required |
Returns
GetContactRequest
Gets a contact request
Velocity
#set($blogContactRequestResponse = $core_v2_blog.GetContactRequest($id))
JavaScript
var blogContactRequestResponse = core_v2_blog.GetContactRequest(id);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
id | Int32 | Id | Required |
Returns
IsSubscribed
Returns subscribed status for the accessing user
Velocity
#set($booleanResponse = $core_v2_blog.IsSubscribed($blogId))
JavaScript
var booleanResponse = core_v2_blog.IsSubscribed(blogId);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
blogId | Int32 | Blog Id | Required |
Returns
Boolean
List
List Overload 1
Returns a listing of all blogs
Velocity
#set($pagedListResponse = $core_v2_blog.List())
JavaScript
var pagedListResponse = core_v2_blog.List();
List Overload 2
Returns a queried listing of blogs
Velocity
#set($pagedListResponse = $core_v2_blog.List("%{ ApplicationIds = $applicationIdsArg, GroupId = $groupIdArg, IncludeSubGroups = $includeSubGroupsArg, OwnerUserId = $ownerUserIdArg, PageIndex = $pageIndexArg, PageSize = $pageSizeArg, PermissionId = $permissionIdArg, SortBy = $sortByArg, SortOrder = $sortOrderArg, UserId = $userIdArg }"))
JavaScript
var pagedListResponse = core_v2_blog.List({ ApplicationIds: applicationIdsArg, GroupId: groupIdArg, IncludeSubGroups: includeSubGroupsArg, OwnerUserId: ownerUserIdArg, PageIndex: pageIndexArg, PageSize: pageSizeArg, PermissionId: permissionIdArg, SortBy: sortByArg, SortOrder: sortOrderArg, UserId: userIdArg });
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
options | Options | Set of optional parameters including: | Required | ||
ApplicationIds | String | Comma separated list of ContentIds. Used to limit to a specific set of blogs as well as sort order if SortBy is set to ApplicationIdsOrder | Optional | ||
GroupId | Int32 | Group ID | Optional | ||
IncludeSubGroups | Boolean | Whether or not query should include sub-groups | Optional | ||
OwnerUserId | Int32 | User ID of the owner of the blogs. When this value is present, only blogs where the given user is an owner are returned. The accessing user must specify their own user Id or the accessing user must have impersonation rights. | Optional | ||
PageIndex | Int32 | Specify the page number of paged results to return. Zero-based index. | Optional | 0 | |
PageSize | Int32 | Specify the number of results to return per page. | Optional | 20 | |
PermissionId | String | Used to get a list of blogs for which the user set in UserId has the provided Permission ID. | Optional | ||
SortBy | String | Attribute to order the results | Optional | ApplicationIdsOrder, MostComments, MostRecent, MostViewed | |
SortOrder | String | Direction to sort the results | Optional | Ascending | Ascending, Descending |
UserId | Int32 | Obsolete in 9.2: User Id should no longer be used. Rely on the authenticated or impersonated user instead. | Optional |
Returns
ListContactRequests
ListContactRequests Overload 1
Lists contact requests
Velocity
#set($pagedListResponse = $core_v2_blog.ListContactRequests($blogId))
JavaScript
var pagedListResponse = core_v2_blog.ListContactRequests(blogId);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
blogId | Int32 | Blog Id | Required |
ListContactRequests Overload 2
Lists contact requests
Velocity
#set($pagedListResponse = $core_v2_blog.ListContactRequests($blogId, "%{ IsModerated = $isModeratedArg, PageIndex = $pageIndexArg, PageSize = $pageSizeArg }"))
JavaScript
var pagedListResponse = core_v2_blog.ListContactRequests(blogId, { IsModerated: isModeratedArg, PageIndex: pageIndexArg, PageSize: pageSizeArg });
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
blogId | Int32 | Blog Id | Required | ||
options | Options | Set of optional parameters including: | Required | ||
IsModerated | Boolean | Is Moderated | Optional | False | |
PageIndex | Int32 | Specify the page number of paged results to return. Zero-based index. | Optional | 0 | |
PageSize | Int32 | Specify the number of results to return per page. | Optional | 20 |
Returns
ListForQuickPost
Lists blogs available for a quick post context for the accessing user and current group
Velocity
#set($iListResponse = $core_v2_blog.ListForQuickPost())
JavaScript
var iListResponse = core_v2_blog.ListForQuickPost();
Returns
IList of Blog
ListTaggedContent
Lists tagged content. DEPRECATED: This method is supported for backwards compatibility, but $core_v2_taggedContent.List() should be used if possible.
Velocity
#set($pagedListResponse = $core_v2_blog.ListTaggedContent($tags, "%{ BlogId = $blogIdArg, GroupId = $groupIdArg, PageIndex = $pageIndexArg, PageSize = $pageSizeArg }"))
JavaScript
var pagedListResponse = core_v2_blog.ListTaggedContent(tags, { BlogId: blogIdArg, GroupId: groupIdArg, PageIndex: pageIndexArg, PageSize: pageSizeArg });
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
tags | IList of String | Tags | Required | ||
options | Options | Set of optional parameters including: | Required | ||
BlogId | Int32 | Blog Id | Optional | ||
GroupId | Int32 | Group Id | Optional | ||
PageIndex | Int32 | Specify the page number of paged results to return. Zero-based index. | Optional | 0 | |
PageSize | Int32 | Specify the number of results to return per page. | Optional | 20 |
Returns
ListTags
Lists tags. DEPRECATED: This method is supported for backwards compatibility, but $core_v2_tags.List() should be used if possible.
Velocity
#set($pagedListResponse = $core_v2_blog.ListTags("%{ BlogId = $blogIdArg, FilterTags = $filterTagsArg, GroupId = $groupIdArg, MinimumItemsPerTag = $minimumItemsPerTagArg, PageIndex = $pageIndexArg, PageSize = $pageSizeArg }"))
JavaScript
var pagedListResponse = core_v2_blog.ListTags({ BlogId: blogIdArg, FilterTags: filterTagsArg, GroupId: groupIdArg, MinimumItemsPerTag: minimumItemsPerTagArg, PageIndex: pageIndexArg, PageSize: pageSizeArg });
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
options | Options | Set of optional parameters including: | Required | ||
BlogId | Int32 | Blog Id | Optional | ||
FilterTags | IList of String | Tags to filter by | Optional | ||
GroupId | Int32 | Group Id | Optional | ||
MinimumItemsPerTag | Int32 | Minimum Items Per Tag | Optional | ||
PageIndex | Int32 | Page Index | Optional | 0 | |
PageSize | Int32 | Page Size | Optional | 100 |
Returns
Search
Performs a blog search
Velocity
#set($pagedListResponse = $core_v2_blog.Search($queryText, "%{ GroupId = $groupIdArg, IncludeSubGroups = $includeSubGroupsArg, PageIndex = $pageIndexArg }"))
JavaScript
var pagedListResponse = core_v2_blog.Search(queryText, { GroupId: groupIdArg, IncludeSubGroups: includeSubGroupsArg, PageIndex: pageIndexArg });
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
queryText | String | Query Text | Required | ||
options | Options | Set of optional parameters including: | Required | ||
GroupId |
| Group Id | Optional | ||
IncludeSubGroups |
| Include Sub Groups | Optional | ||
PageIndex | Int32 | Specify the page number of paged results to return. Zero-based index. | Optional | 0 |
Returns
SetSubscribed
Sets subscribed status for the accessing user
Velocity
#set($additionalInfoResponse = $core_v2_blog.SetSubscribed($blogId, $subscribe))
JavaScript
var additionalInfoResponse = core_v2_blog.SetSubscribed(blogId, subscribe);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
blogId | Int32 | Blog Id | Required | ||
subscribe | Boolean | Subscribed Status | Required |
Returns
SubscribeAnonymously
Velocity
#set($nullableResponse = $core_v2_blog.SubscribeAnonymously($blogId, $email))
JavaScript
var nullableResponse = core_v2_blog.SubscribeAnonymously(blogId, email);
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
blogId | Int32 | Blog Id | Required | ||
String | Required |
Returns
Nullable of AnonymousBlogSubscriptionResponse
Update
Updates a blog
Velocity
#set($blogResponse = $core_v2_blog.Update($id, "%{ Authors = $authorsArg, DefaultPostImageUrl = $defaultPostImageUrlArg, Description = $descriptionArg, Enabled = $enabledArg, ExtendedAttributes = $extendedAttributesArg, GroupId = $groupIdArg, Key = $keyArg, Name = $nameArg }"))
JavaScript
var blogResponse = core_v2_blog.Update(id, { Authors: authorsArg, DefaultPostImageUrl: defaultPostImageUrlArg, Description: descriptionArg, Enabled: enabledArg, ExtendedAttributes: extendedAttributesArg, GroupId: groupIdArg, Key: keyArg, Name: nameArg });
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
id | Int32 | Id | Required | ||
options | Options | Set of optional parameters including: | Required | ||
Authors | String | Comma separated list of usernames | Optional | ||
DefaultPostImageUrl | String | Default Post Image Url | Optional | ||
Description | String | Description | Optional | ||
Enabled | Boolean | Enabled | Optional | True | |
ExtendedAttributes | String | Extended attributes are key-value pairs set using the syntax _ExtendedAttributes_key=value. i.e. _ExtendedAttributes_MyKey=MyValue sets ExtendedAttributes["MyKey"] to "MyValue". | Optional | ||
GroupId | Int32 | Group Id | Optional | ||
Key | String | If not specified, the key will be generated | Optional | ||
Name | String | Name | Optional |