In case you need to get or modify data in Dynamics Crm while calling from Azure Logic App I would recommend to use an action of Http type. This action provides you to request Dynamics CRM endpoint using most of relevant verbs (methods), among each other: GET, POST, PATCH, DELETE along with authentication header.
This is mandatory to bind your CRM user prior to consume Dynamics CRM Web API. Please refer to my previous blog where explained how to do it.
Dynamics CRM exposes RESTFul Web API with a plenty of features even fairly complex.
Dynamics CRM Web API implements OData protocol hence you need to consider it while constructing requests.
Below you can find the example how the Azure Logic App can be implemented. It accepts a CityName as an input parameter and is combined in the query sent to Web API resulted with accounts with a city of specified.
and a source code:
Please note the authentication is critical and you must provision Azure AD Application along with the binding prior to implementing the Logic App.
To obtain values retrieved by the Http action you need to use a property named 'value' which is an array. Logic App has a variety of string, conversion functions which would help you in parsing retrieved data. Please refer to the link .
This post first appeared on MSDN Blogs | Get The Latest Information, Insights, Announcements, And News From Microsoft Experts And Developers In The MSDN Blogs., please read the originial post: here