web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Consuming web services

(0) ShareShare
ReportReport
Posted on by 570

Hi,

I need to consume an external WEB Services from AX 2012 and the web service provider asked me how to create this service:

- WCF Web Service

- RESTful web service

Which are the differences and which could be the best solution in AX? 

Are there any important request I could address to the provider to make the development easier from AX point of view?

 

 

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Martin Dráb Profile Picture
    237,795 Most Valuable Professional on at

    You're comparing apples and oranges - you can implement RESTful web services with Windows Communication Foundation (WCF); they're not alternatives. Maybe you wanted to compare REST and SOAP services?

    Since AX supports SOAP and not REST, the choice is obvious. If you have to use REST, you'll have to implement your own middle-tier web service.

  • Suggested answer
    nunomaia Profile Picture
    25 Moderator on at

    From my point of view, they are both valid technologies to consume web services on AX.  You can find a detailed article comparing bother technologies in MSDN msdn.microsoft.com/.../hh273094(v=vs.100).aspx

    From Dynamics AX perspective, shouldn’t exist a great difference between a WCF service and REST service, the main difference is that how client the .NET consumes the service. I personally prefer a WCF service if the client/service is a set of complex actions.

  • nunomaia Profile Picture
    25 Moderator on at

    An Additional comment, to consume an external web services in REST you need external libs, for example https://github.com/restsharp

  • Martin Dráb Profile Picture
    237,795 Most Valuable Professional on at

    Ah, sorry, forget my remark about the middle-tier service. I forgot for a moment that we're talking about consuming, not exposing services.

    @Nuno: WCF includes REST services, therefore talking about differences between WCF and REST services doesn't make sense.

  • nunomaia Profile Picture
    25 Moderator on at

    [quote user="Martin Dráb"]

    @Nuno: WCF includes REST services, therefore talking about differences between WCF and REST services doesn't make sense.

    [/quote]

    You are right on that point, my comment should be rephrased as SOAP versus REST.

  • PIX Profile Picture
    570 on at

    Martin,

    let me resume, pls correct me if wrong :

    REST and SOAP are both valid technologies both consumable by AX 2012

    The WCF can include both (REST and SOAP) and in both cases the provider which expose the service could send me a WSDL to start consuming the service

    Pls confirm

    TKS

  • nunomaia Profile Picture
    25 Moderator on at

    I’m not sure if a REST service will expose a WSDL to you, I don’t member a single REST service that I have consumed that exposed a WSDL. REST services are simple PUT / GET HTTP operations using JSON format. For REST I always used RestSharp lib and not WCF directly.

    To consume a WCF, it is a traditional .net client consumer using Visual Studio wizard.

  • Verified answer
    Martin Dráb Profile Picture
    237,795 Most Valuable Professional on at

    WSDL is used by SOAP services only; it has no place in REST APIs.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans