Freigeben über


Web Service Alternatives: SOAP and OData

Dynamics NAV supports OData web services in addition to the SOAP web services that have been available since Microsoft Dynamics NAV 2009. Developers planning to create Microsoft Dynamics NAV web services may need to decide which type of web service is better suited to their needs. First, there are some absolute limitations:

  • It is not currently possible to access Dynamics NAV query objects with SOAP web services. See Queries for information about Dynamics NAV queries.

  • It is not currently possible to access codeunits with OData web services.

SOAP Web Services

SOAP web services allow full flexibility for building operation-centric services. They provide industry standard interoperability. Windows Communication Framework (WCF) has supported SOAP services since its initial release in .NET Framework 3.0, and later releases of the .NET Framework have added additional support and default bindings to make it easier to build SOAP services using WCF.

The most common type of messaging pattern in SOAP is the Remote Procedure Call (RPC), where one network node (the client) sends a request message to another node (the server), and the server sends a response message to the client.

OData Web Services

The OData standard is well suited for web service applications that require a uniform, flexible, general purpose interface for exposing create retrieve update delete (CRUD) operations on a tabular data model to clients. OData is less suited for applications that are primarily RPC-oriented or in which data operations are constrained to certain prescribed patterns. OData supports Representational State Transfer (REST)-based data services, which enable resources, identified using Uniform Resource Identifiers (URIs), and defined in an abstract data model (EDM), to be published and edited by web clients within corporate networks and across the Internet using simple Hypertext Transfer Protocol (HTTP) messages. OData services are lightweight, with functionality often referenced directly in the URI.

Whereas SOAP web services expose a WSDL document, OData web services expose an EDMX document containing metadata for all published web services.

OData is supported in PowerPivot, a data-analysis add-in to Microsoft Excel that provides enhanced Business Intelligence capabilities. PowerPivot supports sharing and collaboration on user-generated business intelligence solutions in a Microsoft SharePoint Server environment. For more information about PowerPivot, see https://www.powerpivot.com/.

The extensions to the Atom Publishing Protocol defined in the AtomPub extensions to the OData protocol documentation (which you can download here) describe how REST-based data services can enable resources, identified using URIs and defined in an abstract data model (EDM), to be published and edited by web clients within corporate networks and across the Internet using simple HTTP messages.

In addition to the AtomPub format, the OData implementation in Microsoft Dynamics NAV 2018 also supports the JSON format, a somewhat less verbose format that may perform better in low-bandwidth environments.

See Also

Microsoft Dynamics NAV Web Services Overview
OData Web Services
SOAP Web Services