You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@olingo.apache.org by Richard Senington <ri...@dataductus.se> on 2014/10/30 11:13:20 UTC
OData content types
Hi everyone,
I was wondering if there were any plans to extend the OLingo library to
set the content types automatically based on request, format and accept
header?
Right now it just responds application/xml or application/json depending
on either the accept header or the $format. This can be overriden but
this is very repetitive coding. Can the defaults be set to conform to
the MS example services? e.g.
application/json;odata=minimalmetadata;streaming=true;charset=utf-8
application/atom+xml;type=feed;charset=utf-8
Regards
Richard Senington
Re: OData content types
Posted by Ramesh Reddy <ra...@redhat.com>.
I believe "application/json" is preferred format with Odata V4, if one is not defined explicitly. Not sure in V2.
Ramesh..
----- Original Message -----
> Hi everyone,
> I was wondering if there were any plans to extend the OLingo library to set
> the content types automatically based on request, format and accept header?
> Right now it just responds application/xml or application/json depending on
> either the accept header or the $format. This can be overriden but this is
> very repetitive coding. Can the defaults be set to conform to the MS example
> services? e.g.
> application/json;odata=minimalmetadata;streaming=true;charset=utf-8
> application/atom+xml;type=feed;charset=utf-8
> Regards
> Richard Senington