Work with status messages
This service is available via Telligent.Evolution.Extensibility.Apis.Get<Telligent.Evolution.Extensibility.Api.Version1.IStatusMessages>()
and is defined in Telligent.Evolution.Platform.dll
Events
Events.AfterCreate
Handler
void StatusMessageAfterCreateEventHandler(StatusMessageAfterCreateEventArgs e);
Events.AfterDelete
Handler
void StatusMessageAfterDeleteEventHandler(StatusMessageAfterDeleteEventArgs e);
Events.AfterUpdate
Handler
void StatusMessageAfterUpdateEventHandler(StatusMessageAfterUpdateEventArgs e);
Events.BeforeCreate
Handler
void StatusMessageBeforeCreateEventHandler(StatusMessageBeforeCreateEventArgs e);
Events.BeforeDelete
Handler
void StatusMessageBeforeDeleteEventHandler(StatusMessageBeforeDeleteEventArgs e);
Events.BeforeUpdate
Handler
void StatusMessageBeforeUpdateEventHandler(StatusMessageBeforeUpdateEventArgs e);
Events.Render
Handler
void StatusMessageRenderEventHandler(StatusMessageRenderEventArgs e);
Properties
Name | Type | Description | Default | Options |
---|---|---|---|---|
ContentTypeId | Guid | Content type Id |
Methods
bool CanUpdate(Guid id);
Returns whether the accessing user can update a StatusMessage
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
id | Guid | StatusMessage Id | Required |
Return Type
bool
StatusMessage Create(string messageBody, StatusMessagesCreateOptions options = null);
Create StatusMessage
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
messageBody | string | Message body | Required | ||
options | StatusMessagesCreateOptions | Status messages create options | Optional |
Return Type
AdditionalInfo Delete(Guid messageId);
Delete a status message
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
messageId | Guid | The ID of the message you want to delete | Required |
Return Type
StatusMessage Get(Guid messageId);
Get status message with a specific message ID
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
messageId | Guid | Message Id | Required |
Return Type
int GetCount(int userId);
Gets a count of status messages for an author.
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
userId | int | User Id | Required |
Return Type
int
ApiList<StatusMessage> List(StatusMessagesListOptions options = null);
Get a list of status messages. Due to performance considerations, the result may not always return the requested PageSize of results, but it is guaranteed to return at least 1 result if any results exist when using an open-ended date range. By default, the method will first query for the last 48 hours, then for the last 96 hours, and then for all time, returning when it finds at least 1 result that matches the other given criteria. It also will not return the TotalItems value. It is recommended to page by StartDate and/or EndDate instead of PageIndex and PageSize.
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
options | StatusMessagesListOptions | Status messages list get options | Optional |
Return Type
string PreviewAttachment(string messageBody, StatusMessagesPreviewOptions options = null);
Preview attachment
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
messageBody | string | Message body | Required | ||
options | StatusMessagesPreviewOptions | Status messages preview options | Optional |
Return Type
string
StatusMessage Update(Guid id, string messageBody, StatusMessagesUpdateOptions options = null);
Update StatusMessage
Parameters
Name | Type | Description | Required | Default | Options |
---|---|---|---|---|---|
id | Guid | Id | Required | ||
messageBody | string | Message body | Required | ||
options | StatusMessagesUpdateOptions | Status messages update options | Optional |