Data dodania Pytanie
2017-12-07 20:12 Incorrect endpoint firing using Route attribute »
I have the following methods in my UserController. The first two, Register and VerifyUser work fine. However - I can't get login to be called. No ma...
(1) odpowiedzi
2017-12-06 13:12 Adapting hypermedia links based on environment »
I have an on-premise ASP.NET Web API that's querying on-premise data. The plan is for the client web application to call an Azure Function which will ...
(1) odpowiedzi
2017-11-29 00:11 Resize an Image that has been uploaded as multipart/form-data in a WebAPI controller »
I am getting an image which has been uploaded to a Web API method using multipart/form-data using await Request.Content.ReadAsMultipartAsync(provider)...
(0) odpowiedzi
2017-11-28 12:11 Web API 2.0 Attribute Routing ("upgraded" from API v1 Code) »
I'm new to c# and asp.net web api. I'm working with Microsoft Visual Studios 2015 Community Edition. A few days back i got an old Code. It used the ol...
(1) odpowiedzi
2017-11-25 11:11 Force SnakeCase Deserializing on WebAPI Per Controller »
i want to change the incoming requests deserializing format just for one of my controllers. so i added this in to my Global.asax and it works just fin...
(1) odpowiedzi
2017-11-13 14:11 How to additionally include File as response of WebAPI »
My current web API already responding JSON data as below. public HttpResponseMessage GetFieldInfo() { //.... return Ok(GetFieldsInstance(...
(1) odpowiedzi
2017-11-10 20:11 Web Api 2 - converting values and combine values from sub query »
In a Web API 2 project, using EF, i am trying to get a controller to return a list of items from the database. That simple enough. The problem comes, ...
(1) odpowiedzi
2017-11-09 18:11 webapi multiple methods in MapHttpRoute »
Using route annotations in asp.net core I can do the following easily enough [HttpGet("ByID/{id}")] public int GetByID(int id) { return 5; } [Ht...
(1) odpowiedzi
2017-11-09 03:11 How to expose stored procedure from database for apicontroller »
I'm struggling to understand the recommended way of exposing a stored procedure using EF, and whether there's a benefit in doing so. I've implemented...
(0) odpowiedzi
2017-11-04 22:11 Handling AuthenticationFailureResult on client side »
I am using pretty much this approach to secure our api with tokens. Not sure, how to handle token expiry response on client side. I have seen two opti...
(1) odpowiedzi
2017-11-01 18:11 Web API: How to get a route parameter when controller action does not have corresponding argument »
We build multi-tenancy application with Web API 2. We want to embed tenant info into the URL so that every request can get it. E.g. http://localhost/t...
(1) odpowiedzi
2017-10-31 15:10 Content is missing for some 404 responses »
I'm trying to return custom error responses from web.api. Let it be simple string "Oops!" formatted as json. So I created simple delegating handler wh...
(1) odpowiedzi
2017-10-23 20:10 API works fine but parameters are not accepted c# »
I have my route prefix here: [RoutePrefix("api/Adresses")] public class AdressesController : ApiController { My function here: [Route("{codeEtudia...
(2) odpowiedzi
2017-10-15 01:10 System.Net.WebException: Error: ConnectFailure (Connection refused) »
Im building an xamarin app and am Im trying to post to Web api with IP address of http://192.168.1.108:51457/api/Home. the api already accepts this ...
(0) odpowiedzi
2017-10-13 09:10 How to protect Web API from CSRF attack if it called from cross domain client? »
I have a Web API and that is called by cross domain client application developed in angular. How I can protect my Web API from CSRF attack. I am usin...
(1) odpowiedzi
2017-10-08 22:10 ASP.NET Web Api 2 routing issue »
I really can't understand why it does not work. I have the following code: public static class WebApiConfig { public static void Register(HttpCon...
(2) odpowiedzi
2017-10-07 12:10 valid model c# properties »
somebody know, how to not allow other properties in controllers using annotations or some other method? for example, I have a model [required] publ...
(2) odpowiedzi
2017-09-29 23:09 Property of Observable is Empty »
I've worked through most of the Heroes tutorial and have decided to add a Hero Tracker which displays a map with the Hero's location on it. This work...
(1) odpowiedzi
2017-09-29 21:09 Response is undefined »
I've followed the Heroes tutorial and I am now attempting to retrieve my hero data from an MVC web api rest service. I have modified the GetHeroes() ...
(2) odpowiedzi
2017-09-18 19:09 How to extend IdentityServer4 workflow to run custom code »
I have a basic Identityserver4 implementation based on the quick start sample. In my startup I have the following: public void ConfigureServices...
(0) odpowiedzi
2017-09-14 08:09 ASP.NET Web API 2 custom routing to specific method »
How can I configure routing in ASP.NET Web API to route it to specific method in controller with GET method? http://mysite/healthcheck Registration ...
(4) odpowiedzi
2017-09-03 22:09 WebAPI with Lazy Loading »
I was following a tutorial from Pluralsight called "Building Web Apps & Services with Entity Framework and Web API". I followed the tutorial but ...
(0) odpowiedzi
2017-09-01 15:09 asp.net mvc web api help page not populating for given route »
I am having difficulties having the help page populate for a web api controller. The only method in the controller is the following: public HttpRespo...
(1) odpowiedzi
2017-09-01 02:09 How to prevent webapi endpoints for period of time »
I'm using web api/mvc 5 and trying to stop any further endpoints for a period. Is it possible to do this for a global filter based on ActionFilterAtt...
(1) odpowiedzi
2017-08-31 11:08 .NET Web API model binding prefixed properties »
I have a view model and models similar to this public class SupplierViewModel { public Supplier Supplier { get; set; } //Select Lists and ot...
(1) odpowiedzi
2017-08-25 19:08 How to access User in a service context in web API? »
If you are in a controller context, you can access the current authenticated User. Take an article such as Get the current user, within an ApiControll...
(1) odpowiedzi
2017-08-10 05:08 C# Web API POST method for Json Multiple Array »
I am working on a project which requires POST method for a multiple-array Json where the data are located on 5 different relating tables with FK. her...
(2) odpowiedzi
2017-08-02 13:08 is it possible to return sequential responses from asp.net web api or WCF or Restful Services? »
is it possible to return multiple sequential responses with asp.net web api or WCF or any other possible REST methodologies? So basically there will ...
(1) odpowiedzi
2017-07-25 12:07 Why is Entity Framework generating the following nested SQL for Azure Mobile Services Table Controllers »
I'm trying to get to the bottom of an entity Framework issue when using it with a TableController I've created the following setup. The basic TodoI...
(0) odpowiedzi
2017-07-21 11:07 C# Web Api 2 How to redirect request to default controller »
I've got a situation where most of the requests will be processed with dedicated controllers. config.Routes.MapHttpRoute( name: "Data...
(1) odpowiedzi
2017-07-05 15:07 ASP.NET Web API 2 and partial updates »
We are using ASP.NET Web API 2 and want to expose ability to partially edit some object in the following fashion: HTTP PATCH /customers/1 { "first...
(0) odpowiedzi
2017-07-04 12:07 Authentication and Authorization in asp.net core WEB API »
I am new in asp.net core and want to implement authentication and authorization in WEB API 2 project. I am little bit confuse to use basic authenticat...
(1) odpowiedzi
2017-07-01 20:07 Calling web api2 from angular 2 with CORS post request »
I am trying to bind below api response to html, { "ScreenData": { "ScreeNo": 101, "MovieName": "Movie101", "SeatRows": [ { ...
(1) odpowiedzi
2017-06-28 13:06 Pass datetime from angular $http.get request to Web API 2 controller »
I have a web API 2 controller: [HttpGet] [Route("api/MyRoute/{date:datetime}")] public IHttpActionResult Get(DateTime date) { return Ok(date); } ...
(1) odpowiedzi
2017-06-23 21:06 The 'ObjectContent`1' type failed to serialize the response body for content type 'application/json in Postman »
I'm doing a WebServices with WebApi 2 EntityFramework in MVC .... and creating the UI controller I have no problems, but I create the WebApi controlle...
(0) odpowiedzi