How to Build XML and JSON Requests

Sana Commerce web service supports requests in XML and JSON
formats.
To see an example of valid requests in both formats you can refer
to the web service help page, which can be accessed by the URL in
the following format:
'[frontendurl]/api/CommerceService.svc/help'. Replace
'[frontendurl]' with the URL of the Sana Commerce frontend. On the
web service help page you can find information about each web
service's method, its description and examples of the valid
requests in the XML and JSON formats. Use the web service help page
to build requests in the valid format.

For example, the request to the 'customer/login' method in XML and
JSON formats:

In this example the ExternalLogin object is passed in
the request and it has two properties, UserName and
Password, which are used by the Sana Commerce framework to
authenticate the user.

The order of the nodes in the XML
request must be exactly the same for each method as it is listed on
the web service help page. Otherwise, the request will not be
parsed correctly by the Sana Commerce framework. This refers to the
XML format only, so in JSON the order of the nodes does not
matter.
For example, the following XML request to the
'customer/login' method will work correctly and return
HTTP Status 200:

Product Versions

Links

Sana Commerce does not accept any liability for the content of this website, or for the consequences of any actions taken on the basis of the information provided. The information below should be interpreted as an example. No rights can be derived from this information.
Sana Commerce – the integrated e-Commerce solution for Microsoft Dynamics NAV & AX