EmailTrigger.UpdateEmailTriggerAsync
Description
Updates the properties of the specified Email Trigger inside the connected Control Room.
Signature [C#]
Task UpdateEmailTriggerAsync(EmailTrigger emailTrigger)
Properties
Input
Property | Description |
---|---|
EmailTrigger | Specify the details to be updated. |
Remarks
Use UpdateEmailTriggerAsync API to update details of Email Trigger inside the connected Control Room.
Example
C#
public void UpdateEmailTrigger()
{
IControlRoomContext context = LoginControlRoom("RegularBuild", "BasicAuth");
string updateTriggerName = "updateTrigger";
EmailTrigger emailTrigger = new EmailTrigger()
{
Id = 1,
Name = updateTriggerName
};
Task.Run(() => context.EmailTriggers.UpdateEmailTriggerAsync(emailTrigger)).Wait();
}
C#
public IControlRoomContext LoginControlRoom()
{
IControlRoomContext context;
string connectionString;
connectionString = "ServerUrl=https://demo.onnitellibuddies.com;UserName=demoadmin;Password=password";
context = new ControlRoomContext(connectionString);
context.Open();
return context;
}