Project Description

Implementation of a module that provides OData protocol and then enables third parties to query (custom) creatable content types embedded in an Orchard CMS Site

How to
Simply add the downloaded nuget package into your orchard site from dashboard's module management or through the gallery.
Before activating this new module, be aware to check if your site enables hosting services with asp.net compatibility.
If not sure, you may manually consider Orchard.Web project's web.config, or use WebMatrix if already deployed into Azure. You should notice or add these lines :

<system.serviceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true" />
</system.serviceModel>
You might need to restart IIS Pool or Azure WebSites to complete these actions.

You are then able to activate the module and call your orchard site's url suffixed with "odata" :
http://localhost:10245/OrchardSite/odata/$metadata
http://localhost:10245/OrchardSite/odata/pages(12)?$format=json
http://localhost:10245/OrchardSite/odata/pages?$filter=startswith(TitlePart/Title,%27Welcome%27)&$format=json

Features
OData is built as an application of a set of internet standards, most especially the Atom Publishing Protocol (aka “AtomPub” specified as RFC 5023), which itself is built on top of the Atom Syndication Format (aka “Atom” specified as RFC 4287). Because of this layering, Atom is the XML format in which OData data is published. ... Finally, OData provides a set of features on top of Atom and AtomPub to make the data query and manipulation richer.

Links

Last edited May 21, 2014 at 5:11 PM by OSTEPHAN, version 11