Quantcast
Channel: Web API
Browsing all 4850 articles
Browse latest View live

Concurrent user Authentication in Asp/token

Hi I am using an api which users the owin Authentication var Name = User.Identity.Name; var Id = User.Identity.GetUserId();is always return in the last logged in users even if a user access the home...

View Article


How to return Xml response (with Xml declaration) from WebAPI?

I have managed to put two XDocuments together in my code. When I call my API (which returns IHttpActionResult) with PostMan, I get the following result:<ContentNode1>...

View Article


Where bearer token are saved

Hi,I wanna use bearer tokens for authorization in web api application but I wonder where these tokens are saved, is this more resource consuming process than storing own custom string in DB against...

View Article

Unable to Post and Put via Postman

Hi,I'm trying to do an HttpPost and HttpPut in the Web-Api via Postman.It's returning a Response code: 404.  It's  adding a request(shown above the method name) but it doesn't go into the method body...

View Article

How to know if user has been deactivated/deleted and remove access token

Hi,I am using OAuth bearer token to authorize users using bearer tokens.Though bearer tokens will be invalid after their expiry time but how do I invalidate those tokens when user has been deactivated...

View Article


Is WebAPI's security any better than it was 5 years ago?

According to this link on Microsoft's documentation, WebAPI with Windows authentication is best suited to Intranet applications. But that article is from a little over 5 years ago. I'd like to know if...

View Article

Serialization

Must the Post message be deserialized in the controller code POST method when it's been serialized in the client code? I am new to WebAPI. Thanks.

View Article

Partial Update, JsonPatchDocument gets null

Hi,I'm having problems passing the patch document to the JsonPatchDocument variable patchDoc for Patch.  patchDoc gets null.  I test using postman.Code is as follows:CodeTableController.csusing System;...

View Article


Restful request

Hi folks, basically I don’t know how to implement the .Gov uk apiI have spent ages trying various different ways to convert this curl to c#. Could someone please help. I keep getting error 500. here is...

View Article


unable to create default admin user in the startup.cs file

using System; using System.Collections.Generic; using System.Linq; using Microsoft.AspNet.Identity; using Microsoft.AspNet.Identity.EntityFramework; using Microsoft.Owin; using Owin; using...

View Article

Securing ASP.NET Web API

How to send encrypted string between native Android app and ASP.NET Web API?

View Article

Post JSON Data and image at the same time to a web Api 2

I have a function which adds data to a SQL Database and upload an image(s) to the server. I convert the image into base64 string to send it with my post but I read that the image size is 33% bigger...

View Article

StringContent vs String

What if use "string" instead of StringContent? What benefits we are getting by using the StringContent?

View Article


sending a request in json with specified format

Good day, i have the following Json request that i need to send when posting,{"UserName": "sample string 1","Password": "sample string 2","Credentials": {"ChannelName": "sample string...

View Article

Why we need GET with parameter while we can do it by POST method

Hi All,I am new to REST WEP APIsOne thing I noticed that if we can do every thing with POST method (by putting no of parameters regardless of insert update delete or select) why we need GET with...

View Article


Serializer runs in the new thread?

I have a Get (int Id) method in my controller that returns class instance.Instance is created correctly(i can see that in the debugger) but on attempt to returnreturn classInstance;my code crashes...

View Article

How to set timeout for API

Hello,We have a web API that's timing out way too soon (about a minute) even though we set the executionTimeout in the web.config file to 360 seconds. We are wondering why this is.My google research...

View Article


EventViewrErrorCode-4010:Event message: An unhandled security exception has...

Experts,when I deploy webapi on IIS 8.5   I get error 4010:Event message: An unhandled security exception has occurred.My Authentication for my websevice is windows and my web.config has code...

View Article

GetRequestContext().ClientCertificate always return null

I am working on client certificate-based authentication with self-hosted web API but web API always return when trying to get a certificate from the request using...

View Article

Web service or web page

Hi,I would like to know what is the best option for this: Need the ability to present a URL that accepts parameters, so something like www.domain.co.uk/page?id=1&name=loftty What is the best...

View Article
Browsing all 4850 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>