Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Twilio SMS generation activity throwing Invalid Operation Exception

Posted on by 5

Twilio solution for sending SMS to customer contact in the Field Service module is not working as expected. The SMS needs to be sent to the customer contact with some message to notify the customer about the activities performed after the work order status changes.

But the SMS is not sent successfully. After investigation, came to know that the workflow activity for SMS generation is failing with an exception as follows:

Sync workflow failed with error message - Unhandled Exception: Microsoft.Crm.Workflow.Services.InvalidCustomActivityExecutionException: Unexpected exception from plug-in (Execute): Microsoft.Dynamics.TwilioIntegration.TwilioWFA.TwilioSMSGenerationActivity: System.InvalidOperationException: Invalid Operation

   at System.Activities.WorkflowApplication.Invoke(Activity activity, IDictionary`2 inputs, WorkflowInstanceExtensionManager extensions, TimeSpan timeout)

   at System.Activities.WorkflowInvoker.Invoke(Activity workflow, IDictionary`2 inputs, TimeSpan timeout, WorkflowInstanceExtensionManager extensions)

   at Microsoft.Crm.Workflow.SynchronousRuntime.SynchronousWorkflowActivityHost.ExecuteWorkflowUsingInvoker(Activity workflow, ICommonWorkflowContext context)

   at Microsoft.Crm.Workflow.SynchronousRuntime.SynchronousWorkflowActivityHost.StartWorkflow(WorkflowActivationData activationData, ICommonWorkflowContext context)

, error code - -2147220891

Has anyone faced such a problem while integrating Twilio with MS Dynamics 365 CRM? If yes, what was the problem or what could be the problem. Any suggestion would be appreciated. Thanks.

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Twilio SMS generation activity throwing Invalid Operation Exception

    Hi Roopesh,

    I have integrated Twilio successfully.

    This Error occurs when you are trying to send SMS to a non domestic number which is not verified in Twilio[Trial Account].

    Regards,

    Madhu

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans