exacttarget preform automation

459 views Asked by At

I'm trying to trigger an automation on ExactTarget using SOAP in .net in C#

so far i have found the examples page help.exacttarget.com/en-GB/technical_library/web_service_guide/technical_articles/interacting_with_automation_studio_via_the_web_service_soap_api/

which says var performResponse = soapClient.Perform(performRequest);

however soapClient.Perform dose not take a singe agument.

what i have so far is this

Automation automation = new Automation();
PerformOptions options = new PerformOptions();
automation.CustomerKey = "53ba121d-2934-90d6-d86d-e0662c656165";
automation.ScheduledTime = DateTime.Now;
automation.ScheduledTimeSpecified = true;
automation.IsActive = true;
automation.AutomationSource = new AutomationSource()
{
   AutomationSourceID = Guid.NewGuid().ToString(),
   AutomationSourceType = "RestAPI"
};

automation.Notifications = new AutomationNotification[0];
//   automation.ObjectID = "7d88eb5b-80ea-43bb-97b2-4067aaa19c35";
automation.PartnerProperties = new APIProperty[0] { };
// automation.PartnerKey = "53ba121d-2934-90d6-d86d-e0662c656165";

string sA;
string sB;
string sC;


PerformResult[] steve = soapClient.Perform(new PerformOptions(), 
"start", new APIObject[] { automation }, out sA, out sB, out sC);

can anyone give me a hand or show me a simple example

thanks.

1

There are 1 answers

5
Grzegorz Gajos On

I'm using mainly Java to interact with ET but I can provide you some hints:

  • try to create automation first
  • if automation already exists try to find it/retrieve it
  • you can pass this retrieved object to Perform method

I think that if object already exists then CustomerKey should be sufficient for your needs, you don't need to specify nothing more.