Agent used for Ticket functions.
Constructors
NSTicketAgent()
Agent used for Ticket functions.
Methods
AddAttachments(Integer,Integer[])
Connects existing attachments with this TicketMessage. Can connect multiple attachments
Returns: CRMScript.Global.Void
CreateDefaultAttachmentEntity()
Sets default values into a new NSAttachmentEntity.
Returns: CRMScript.NetServer.NSAttachmentEntity
NetServer calculates default values (for example, Country) on the entity, which is required when creating/storing a new instance
Example:
CreateDefaultTicketEntity()
Sets default values into a new NSTicketEntity.
Returns: CRMScript.NetServer.NSTicketEntity
NetServer calculates default values (for example, Country) on the entity, which is required when creating/storing a new instance
Example:
CreateDefaultTicketMessageEntity()
Sets default values into a new NSTicketMessageEntity.
Returns: CRMScript.NetServer.NSTicketMessageEntity
NetServer calculates default values (for example, Country) on the entity, which is required when creating/storing a new instance
Example:
DeleteTicketEntity(Integer)
Deletes a ticket
Returns: CRMScript.Global.Void
Example:
DeleteTicketMessageEntity(Integer)
Deletes a ticket message
Returns: CRMScript.Global.Void
Example:
GetAttachmentEntity(Integer)
Gets an NSAttachmentEntity object.
Returns: CRMScript.NetServer.NSAttachmentEntity
Example:
GetAttachmentInfo(Integer)
Gets a list with meta data for all attached attachments
Returns: CRMScript.NetServer.NSAttachmentEntity[]
Example:
GetAttachmentStream(Integer)
Gets the content of an attachment
Returns: CRMScript.NetServer.NSStream
Example:
GetTicket(Integer)
Gets an NSTicket object.
Returns: CRMScript.NetServer.NSTicket
Example:
GetTicketAttachments(Integer)
Gets attachment infos for all attachments connected to messages in specified ticket
Returns: CRMScript.NetServer.NSAttachmentEntity[]
Example:
GetTicketEntity(Integer)
Gets an NSTicketEntity object.
Returns: CRMScript.NetServer.NSTicketEntity
Example:
GetTicketMessage(Integer)
Gets an NSTicketMessage object.
Returns: CRMScript.NetServer.NSTicketMessage
Example:
GetTicketMessageEntity(Integer)
Gets an NSTicketMessageEntity object.
Returns: CRMScript.NetServer.NSTicketMessageEntity
Example:
GetTickets(Integer[])
Gets multiple tickets
Returns: CRMScript.NetServer.NSTicket[]
Example:
Html2Text(String)
Creates a plain text version of the html, suitable for email
Returns: CRMScript.Global.String
Example:
NotifyNewTicket(Integer)
Notifies user agents about the creation of a new ticket
Returns: CRMScript.Global.Void
Example:
NotifyNewTicketMessage(Integer)
Notifies user agents about the creation of a new message on a ticket
Returns: CRMScript.Global.Void
Example:
SanitizeMailContent(String)
Removes harmful HTML tags and attributes from an email
Returns: CRMScript.Global.String
Example:
SanitizeMailContents(String[])
Removes harmful HTML tags and attributes from an email
Returns: CRMScript.Global.String[]
Example:
SaveAttachmentEntity(NSAttachmentEntity)
Updates the existing NSAttachmentEntity or creates a new NSAttachmentEntity if the id parameter is 0
Returns: CRMScript.NetServer.NSAttachmentEntity
Example:
SaveTicketEntity(NSTicketEntity)
Updates the existing NSTicketEntity or creates a new NSTicketEntity if the id parameter is 0
Returns: CRMScript.NetServer.NSTicketEntity
Example:
SaveTicketMessageEntity(NSTicketMessageEntity)
Updates the existing NSTicketMessageEntity or creates a new NSTicketMessageEntity if the id parameter is 0
Returns: CRMScript.NetServer.NSTicketMessageEntity
Example:
SendTicketMessage(Integer,String[],String[],String[],String,Integer,String)
Sends a message to recipients, e.g. by email or sms
Returns: CRMScript.Global.Void
Example:
SetTicketMessageImportant(Integer,Bool)
Sets the important flag on or off for a ticket message
Returns: CRMScript.Global.Void
SetTicketReadByOwner(Integer,Integer,Bool)
Sets the ReadByOwner status for a ticket. It will only have an effect if the calling user is the same as the owner of the ticket
Returns: CRMScript.NetServer.NSTicketEntity
Example:
UploadAttachment(Integer,NSStream)
Uploads an attachment and returns the attachment ID
Returns: CRMScript.Global.Integer