Call a named workflow in Dynamics 365 from Laravel using PHP-CRM-Toolkit by AlexaCRM

373 views Asked by At

We have an application in Laravel 5 which has an integration with Dynamics 365 through PHP-CRM-Toolkit (https://github.com/AlexaCRM/php-crm-toolkit/).

I want to call a named workflow in Dynamics 365 but I'm unable to find the required function to use in the package. Any help would be really appreciated.

I have a similar code in .NET but I want its version in the given package.

try
{
  // Create an ExecuteWorkflow request.
  ExecuteWorkflowRequest request = new ExecuteWorkflowRequest();

  //Assign the ID of the workflow you want to execute to the request. 
  request.WorkflowId = new Guid("xxxxxx-xxx-xxx-xxxx-xxxxxx");

  //Assign the ID of the entity to execute the workflow on to the request.
  request.EntityId = accountGUID;

  // Execute the workflow.
  ExecuteWorkflowResponse response = (ExecuteWorkflowResponse)service.Execute(request);
}
0

There are 0 answers