Questions tagged [wcf-web-api]

The WCF Web API project allows WCF developers to expose their APIs via HTTP. Under ASP.NET MVC4, WCF Web API has become ASP.NET Web API.

The WCF Web API project focuses on allowing WCF developers to expose their APIs for programmatic access over HTTP by browsers and devices. With the release of ASP.NET MVC4, WCF Web API is now ASP.NET Web API.

Project Links:

269 questions
0
votes
2 answers

How to return the Json value using WCF WebApi

I have create a one sample WCF rest template WebApi in this i have use Entity Framework to getting the data when i run the service for it return the string value it showing the result but at end of the json value add XML code like below how can i…
Victor
  • 555
  • 6
  • 15
  • 39
0
votes
1 answer

Send complex object to WCF Web API using JSONP

Thanks to Alex Zeitler's article I have my WCF Web API service accepting JSONP requests. This works really well for simple requests but I have a problem. One of the functions I need to be able to make accessible is a search function that currently…
Nick
  • 4,115
  • 10
  • 45
  • 57
0
votes
1 answer

Using jqGrid with WCF WebAPI

I'm using the wcf webapi to get data from my asp.net application, and trying to display it with jqGrid. The data comes back looking…
Tim Hoolihan
  • 12,316
  • 3
  • 41
  • 54
0
votes
1 answer

Encryption/Decryption through DelegatingChannel (MessageHandler)

I am trying to use DelegatingChannel (MessageHandler) to decrypt the incoming message and encrypt the outgoing message. Code looks like this, but with some placeholder i couldn't figure out how to achieve. protected override…
misaxi
  • 568
  • 2
  • 10
0
votes
1 answer

Convert set of KeyValuePairs to object instance. Kind of deserialisation for JSON

This is kind of a two part question. I suppose the first is, am I going the best way about doing this and the second is the roadblock I've hit. The following code works for string properties but not for example an int. I get the int value out of the…
Daniel Revell
  • 8,338
  • 14
  • 57
  • 95
0
votes
1 answer

How to enable Dependency Injection for ServiceRoute in MVC3 and WCF Web API

I am creating a MVC3 website that will expose a REST API using WCF Web API. To register routes to the REST API I add code to the Global.asax similar to the code below. routes.MapServiceRoute("relations"); This works well enough…
RogierBessem
  • 2,623
  • 3
  • 17
  • 15
0
votes
2 answers

C# Web Api GetAsync + MVC 3.0 Async Controller

I just want everyones feedback about the following Async Controller using the Web Api HttpClient. This looks very messy is there a way to make it cleaner? Does anyone have a good wrapper around chaining multiple async tasks together? public class…
Chris Kolenko
  • 1,020
  • 17
  • 32
0
votes
2 answers

WCF web API hosted in IIS

I want to try out WCF web API. My plan is to create an application hosted on IIS that runs by itself (not combined with an MVC 3 application, etc). Maybe I'll give it an address http://192.168.1.2/myapi. How do I set up my project from the…
Endy Tjahjono
  • 24,120
  • 23
  • 83
  • 123
0
votes
1 answer

Which HttpStatusCode should I return when a POST method to add an object fails

Which HttpStatusCode should I return when a POST method to add an object fails? It could be due to a db connectivity issue, a code bug, invalid data, or any other reason.
Simon Holman
  • 150
  • 6
0
votes
1 answer

WCF Web API How to Add Argument to Every Endpoint

I have a WCF Web Api Restful webservice. I want every single service call to take an optional parameters: suppress_status_codes. Is there a way to do this wihtout adding the parameter and handling to every end point like: [WebGet(UriTemplate =…
Luke Belbina
  • 5,708
  • 12
  • 52
  • 75
0
votes
1 answer

Publish/expose RESTful API using WCF-WebHttp

I have a requirement to expose/publish a RESTful API service from BizTalk 2013 r2. I have published a service in IIS and when I browse it is working, but I am unable to call the API from SOAP UI. I have tried using this link: Exploring REST…
0
votes
1 answer

BizTalk WCF-WebHttp adapter Client Certificate not found

When configuring the WCF-WebHttp security tab, I have set Security Mode to Transport, Client Credential type to Certificate. When I go to browse for Client Cert, it comes up with the only options being Current User/My Store instead of Local…
Bensonius
  • 1,501
  • 1
  • 15
  • 39
0
votes
0 answers

Solution to upload image file via WCF service?

Being surfing for last 3-4 days downloading, running and fixing issues with available demo projects online, none of them work so far. I need to upload an image using WCF webservice. Where from client side end I like to upload it by means of form…
KumailR
  • 505
  • 1
  • 4
  • 20
0
votes
2 answers

How do I use ASP.NET 5 WebAPI from WPF client

I have an existing WPF client, and I am building new standalone WebServices using ASP.NET 5 WebAPI. I want to expose some metadata, like WebApiProxy or .wsdl/Mex, so I can auto generate a Proxy class in my WPF client.
jenspo
  • 504
  • 4
  • 11
0
votes
1 answer

Service Behavior Equivalent in ASP.NET WEB API

I am modifying an existing WCF service to a WEB API. In the WCF service, we have some operation behaviors that checks the validity of session id passed in SOAP header.Do we have any equivalent for Operation Behaviors in WEB API, which will get…
Vishnu
  • 897
  • 6
  • 13