Click here to Skip to main content
15,891,248 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Hi,
 
I want my WEBAPI to send data in JSON Format when it receives the request from a Desktop Application and XML Format when it receives the request from a Mobile Application

How do I do that ?


What I have tried:

Tried Googling but didnt find anything specific
Posted
Updated 19-Dec-18 10:55am
v2
Comments
F-ES Sitecore 19-Dec-18 9:02am    
Have the calling apps indicate the format they want the data back. Unless the client tells your api what device it is on there is no way for the api to work it out.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900