Search code examples
odataasp.net-web-api

OData 4 custom provider with WebAPI


I'm looking for examples on how to implement a custom data provider for OData 4 and WebAPI (preferably for an in-memory untyped dataset).

Doese anyone know of any examples out there? My googeling turned up little of use.

I know of this example: http://msdn.microsoft.com/en-us/data/gg191846

But can't find the project-files for the example-code ... also it's from 2011 and things have changed since then...


Solution

  • You can refer to Web API OData Sample code at

    https://aspnet.codeplex.com/SourceControl/latest

    You can find the code at "Samples/WebApi/OData/v4/ODataUntypedSample" in the left panel.

    There is another blog talking about "Typeless Entity Object Support in WebApi".

    http://blogs.msdn.com/b/leohu/archive/2013/11/05/typeless-entity-object-support-in-webapi.aspx